public class GenericDriver extends AbstractScriptellaDriver
Constructor and Description |
---|
GenericDriver() |
Modifier and Type | Method and Description |
---|---|
JdbcConnection |
connect(ConnectionParameters params)
Implementor should create a new connection based on specified parameters.
|
protected JdbcConnection |
connect(ConnectionParameters parameters,
java.util.Properties props)
Creates Scriptella JDBC connection.
|
protected java.sql.Connection |
getConnection(java.lang.String url,
java.util.Properties props)
A helper method for subclasses to avoid direct interaction with DriverManager API.
|
protected void |
loadDrivers(java.lang.String... drivers)
Tries to load one of the specified driver class names.
|
getScriptellaTitle, getScriptellaVersion, toString
protected void loadDrivers(java.lang.String... drivers)
drivers
- database driver candidate names.JdbcException
- if no drivers were loadedpublic JdbcConnection connect(ConnectionParameters params)
ScriptellaDriver
params
- connection parameters defined in <connection> element.protected JdbcConnection connect(ConnectionParameters parameters, java.util.Properties props) throws java.sql.SQLException
parameters
- connection parametersprops
- properties to pass to jdbc driverjava.sql.SQLException
- if DB exception occurs.protected java.sql.Connection getConnection(java.lang.String url, java.util.Properties props) throws java.sql.SQLException
Calls DriverManager.getConnection(String,java.util.Properties)
java.sql.SQLException
Copyright © Copyright 2006-2019 The Scriptella Project Team.