public class CoreDataSource extends JdbcUtil implements Referenceable, ObjectFactory, Serializable
This class is generic in the sense that it does not rely upon anything other than standard Java APIs. It uses java.sql.DriverManager and preconfigured properties to construct a JDBC connection.
| Modifier and Type | Field and Description |
|---|---|
PrintWriter |
logWriter |
String |
password |
String |
user |
| Constructor and Description |
|---|
CoreDataSource()
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
String |
getDescription()
Setter/Getter defined for standard properties
|
int |
getLoginTimeout() |
PrintWriter |
getLogWriter() |
Object |
getObjectInstance(Object refObj,
Name name,
Context nameCtx,
Hashtable env)
Methods inherited from ObjectFactory
|
String |
getPassword() |
Reference |
getReference()
Methods inherited from referenceable
|
JdbcThreadFactory |
getThreadFactory() |
String |
getUser() |
boolean |
isDebug() |
boolean |
isVerbose() |
void |
setDebug(boolean debug) |
void |
setDescription(String description) |
void |
setLoginTimeout(int seconds) |
void |
setLogWriter(PrintWriter out) |
void |
setPassword(String password) |
void |
setThreadFactory(JdbcThreadFactory f) |
void |
setUser(String user) |
void |
setVerbose(boolean verbose) |
void |
shutdown(boolean force)
shutdown is a placeholder for datasources which should shut down
any pools which they maintain.
|
String |
toString() |
public transient PrintWriter logWriter
public String user
public String password
public String getDescription()
public String getPassword()
public String getUser()
public JdbcThreadFactory getThreadFactory()
public boolean isDebug()
public boolean isVerbose()
public void setDescription(String description)
public void setPassword(String password)
public void setUser(String user)
public void setDebug(boolean debug)
public void setVerbose(boolean verbose)
public void setThreadFactory(JdbcThreadFactory f)
public PrintWriter getLogWriter()
public void setLogWriter(PrintWriter out)
public void shutdown(boolean force)
public void setLoginTimeout(int seconds)
public int getLoginTimeout()
public Reference getReference() throws NamingException
getReference in interface ReferenceableNamingExceptionpublic Object getObjectInstance(Object refObj, Name name, Context nameCtx, Hashtable env) throws Exception
getObjectInstance in interface ObjectFactoryExceptionCopyright © 2014–2015. All rights reserved.