* Returns the driver.
* @return String
*/
- public String getDriver() {
+ String getDriver() {
return driver;
}
* Returns the driverFile.
* @return String
*/
- public String getDriverFile() {
+ String getDriverFile() {
return driverFile;
}
* Sets the driver.
* @param driver The driver to set
*/
- public void setDriver(String driver) {
+ void setDriver(String driver) {
if (driver == null) {
driver = ""; //$NON-NLS-1$
}
* Sets the driverFile.
* @param driverFile The driverFile to set
*/
- public void setDriverFile(String driverFile) {
+ void setDriverFile(String driverFile) {
if (driverFile == null) {
driverFile = ""; //$NON-NLS-1$
}
return true;
}
-
+
+ public void setJDBCDriver(JDBCDriver jdbcDriver) {
+ jdbcDriver = BookmarkCollection.getInstance().findDriver(jdbcDriver);
+ setDriver(jdbcDriver.getClassName());
+ setDriverFile(jdbcDriver.getJarFileName());
+ }
+
+ public JDBCDriver getJDBCDriver() {
+ return BookmarkCollection.getInstance().findDriver(getDriver(), getDriverFile());
+ }
}