public final class JNDIConnectionFactory extends Object implements ConnectionFactory
Constructor and Description |
---|
JNDIConnectionFactory(Jndi jndi,
boolean useProxies)
Constructs a new JNDIConnectionFactory with given database and mapping.
|
Modifier and Type | Method and Description |
---|---|
Connection |
createConnection()
Creates a new JDBC Connection instance.
|
void |
initializeFactory()
Initialize the concrete factory.
|
public JNDIConnectionFactory(Jndi jndi, boolean useProxies)
jndi
- JNDI configuration.useProxies
- Wrap JDBC connections by proxies?public void initializeFactory() throws MappingException
initializeFactory
in interface ConnectionFactory
MappingException
- If concrete factory could not be initialized.public Connection createConnection() throws SQLException
createConnection
in interface ConnectionFactory
SQLException
- If the JDBC connection cannot be created.Copyright © 2016. All rights reserved.