public class DistributedDataSource extends DecoratingDataSource implements java.lang.Iterable<javax.sql.DataSource>
Constructor and Description |
---|
DistributedDataSource(java.util.List<javax.sql.DataSource> dataSources) |
Modifier and Type | Method and Description |
---|---|
void |
addDataSource(javax.sql.DataSource ds) |
java.sql.Connection |
getConnection() |
(package private) java.sql.Connection |
getConnection(javax.sql.DataSource ds) |
(package private) java.sql.Connection |
getConnection(javax.sql.DataSource ds,
java.lang.String user,
java.lang.String pwd) |
java.sql.Connection |
getConnection(java.lang.String username,
java.lang.String password) |
int |
getLoginTimeout() |
java.io.PrintWriter |
getLogWriter() |
java.util.logging.Logger |
getParentLogger() |
java.util.Iterator<javax.sql.DataSource> |
iterator() |
void |
setLoginTimeout(int seconds) |
void |
setLogWriter(java.io.PrintWriter out) |
addDecorator, addDecorators, clearDecorators, getDecorators, removeDecorator
appendInfo, close, equals, getDelegate, getInnermostDelegate, hashCode, isWrapperFor, toString, unwrap
public DistributedDataSource(java.util.List<javax.sql.DataSource> dataSources)
public void addDataSource(javax.sql.DataSource ds)
java.sql.Connection getConnection(javax.sql.DataSource ds) throws java.sql.SQLException
java.sql.SQLException
java.sql.Connection getConnection(javax.sql.DataSource ds, java.lang.String user, java.lang.String pwd) throws java.sql.SQLException
java.sql.SQLException
public java.util.Iterator<javax.sql.DataSource> iterator()
iterator
in interface java.lang.Iterable<javax.sql.DataSource>
public java.sql.Connection getConnection() throws java.sql.SQLException
getConnection
in interface javax.sql.DataSource
getConnection
in class DecoratingDataSource
java.sql.SQLException
public java.sql.Connection getConnection(java.lang.String username, java.lang.String password) throws java.sql.SQLException
getConnection
in interface javax.sql.DataSource
getConnection
in class DecoratingDataSource
java.sql.SQLException
public java.io.PrintWriter getLogWriter() throws java.sql.SQLException
getLogWriter
in interface javax.sql.CommonDataSource
getLogWriter
in class DelegatingDataSource
java.sql.SQLException
public int getLoginTimeout() throws java.sql.SQLException
getLoginTimeout
in interface javax.sql.CommonDataSource
getLoginTimeout
in class DelegatingDataSource
java.sql.SQLException
public void setLogWriter(java.io.PrintWriter out) throws java.sql.SQLException
setLogWriter
in interface javax.sql.CommonDataSource
setLogWriter
in class DelegatingDataSource
java.sql.SQLException
public void setLoginTimeout(int seconds) throws java.sql.SQLException
setLoginTimeout
in interface javax.sql.CommonDataSource
setLoginTimeout
in class DelegatingDataSource
java.sql.SQLException
public java.util.logging.Logger getParentLogger() throws java.sql.SQLFeatureNotSupportedException
getParentLogger
in interface javax.sql.CommonDataSource
getParentLogger
in class DelegatingDataSource
java.sql.SQLFeatureNotSupportedException
Copyright © 2006-2013 Apache Software Foundation. All Rights Reserved.