public class DelegatingDataSource extends java.lang.Object implements javax.sql.DataSource, Closeable
equals and
hashCode methods pass through to the base underlying data store.| Constructor and Description |
|---|
DelegatingDataSource(javax.sql.DataSource ds)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
appendInfo(java.lang.StringBuffer buf) |
void |
close() |
boolean |
equals(java.lang.Object other) |
java.sql.Connection |
getConnection() |
java.sql.Connection |
getConnection(java.lang.String user,
java.lang.String pass) |
javax.sql.DataSource |
getDelegate()
Return the wrapped data source.
|
javax.sql.DataSource |
getInnermostDelegate()
Return the inner-most wrapped delegate.
|
int |
getLoginTimeout() |
java.io.PrintWriter |
getLogWriter() |
java.util.logging.Logger |
getParentLogger() |
int |
hashCode() |
boolean |
isWrapperFor(java.lang.Class iface) |
void |
setLoginTimeout(int timeout) |
void |
setLogWriter(java.io.PrintWriter out) |
java.lang.String |
toString() |
java.lang.Object |
unwrap(java.lang.Class iface) |
public DelegatingDataSource(javax.sql.DataSource ds)
public javax.sql.DataSource getDelegate()
public javax.sql.DataSource getInnermostDelegate()
public int hashCode()
hashCode in class java.lang.Objectpublic boolean equals(java.lang.Object other)
equals in class java.lang.Objectpublic java.lang.String toString()
toString in class java.lang.Objectprotected void appendInfo(java.lang.StringBuffer buf)
public java.io.PrintWriter getLogWriter()
throws java.sql.SQLException
getLogWriter in interface javax.sql.CommonDataSourcejava.sql.SQLExceptionpublic void setLogWriter(java.io.PrintWriter out)
throws java.sql.SQLException
setLogWriter in interface javax.sql.CommonDataSourcejava.sql.SQLExceptionpublic int getLoginTimeout()
throws java.sql.SQLException
getLoginTimeout in interface javax.sql.CommonDataSourcejava.sql.SQLExceptionpublic void setLoginTimeout(int timeout)
throws java.sql.SQLException
setLoginTimeout in interface javax.sql.CommonDataSourcejava.sql.SQLExceptionpublic java.sql.Connection getConnection()
throws java.sql.SQLException
getConnection in interface javax.sql.DataSourcejava.sql.SQLExceptionpublic java.sql.Connection getConnection(java.lang.String user,
java.lang.String pass)
throws java.sql.SQLException
getConnection in interface javax.sql.DataSourcejava.sql.SQLExceptionpublic void close()
throws java.lang.Exception
public boolean isWrapperFor(java.lang.Class iface)
isWrapperFor in interface java.sql.Wrapperpublic java.lang.Object unwrap(java.lang.Class iface)
unwrap in interface java.sql.Wrapperpublic java.util.logging.Logger getParentLogger()
throws java.sql.SQLFeatureNotSupportedException
getParentLogger in interface javax.sql.CommonDataSourcejava.sql.SQLFeatureNotSupportedExceptionCopyright © 2006-2013 Apache Software Foundation. All Rights Reserved.