|
SRJRCFrames v0.1.296 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object de.schwarzrot.data.access.jdbc.DriverConnectionFactory
public class DriverConnectionFactory
as DriverManager
does not work with dynamically loaded
jdbc-drivers, this class is a try to bypass limitations of
DriverManager
. Seems to work at first sight ...
Constructor Summary | |
---|---|
DriverConnectionFactory(Driver driver,
String connectUri,
Properties props)
Constructor for DriverConnectionFactory, where the driver can be configured by given java.util.Properties . |
|
DriverConnectionFactory(Driver driver,
String connectUri,
String uname,
String passwd)
Simple Constructor for DriverConnectionFactory. |
Method Summary | |
---|---|
Connection |
createConnection()
|
protected Properties |
setupDefaults(String uname,
String passwd)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public DriverConnectionFactory(Driver driver, String connectUri, Properties props)
java.util.Properties
.
driver
- the jdbc-Driver instanceconnectUri
- a database url of the form
jdbc:subprotocol:subname
props
- the properties to configure the driver and the connections it
will return. The java.util.Properties
should contain
at least "user" and "password".public DriverConnectionFactory(Driver driver, String connectUri, String uname, String passwd)
driver
- the jdbc-Driver instanceconnectUri
- a database url of the form
jdbc:subprotocol:subname
uname
- the database userpasswd
- the user's passwordMethod Detail |
---|
public Connection createConnection() throws SQLException
createConnection
in interface org.apache.commons.dbcp.ConnectionFactory
SQLException
protected Properties setupDefaults(String uname, String passwd)
|
SRJRCFrames v0.1.296 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |