List of utility methods to do Database Driver Load
Class | loadDriver() load Driver String jdbcDriver = System.getenv("JDBC_DRIVER"); if (jdbcDriver == null) { jdbcDriver = "com.mysql.jdbc.Driver"; return Class.forName(jdbcDriver); |
boolean | loadDriver(String driverClassName) Loads and registers a database driver class. try { Class.forName(driverClassName).newInstance(); return true; } catch (ClassNotFoundException e) { return false; } catch (IllegalAccessException e) { return true; } catch (InstantiationException e) { ... |