org.apache.ibatis.datasource.unpooled
Class UnpooledDataSource

java.lang.Object
  extended by org.apache.ibatis.datasource.unpooled.UnpooledDataSource
All Implemented Interfaces:
java.sql.Wrapper, javax.sql.CommonDataSource, javax.sql.DataSource

public class UnpooledDataSource
extends java.lang.Object
implements javax.sql.DataSource


Constructor Summary
UnpooledDataSource()
           
UnpooledDataSource(java.lang.ClassLoader driverClassLoader, java.lang.String driver, java.lang.String url, java.util.Properties driverProperties)
           
UnpooledDataSource(java.lang.ClassLoader driverClassLoader, java.lang.String driver, java.lang.String url, java.lang.String username, java.lang.String password)
           
UnpooledDataSource(java.lang.String driver, java.lang.String url, java.util.Properties driverProperties)
           
UnpooledDataSource(java.lang.String driver, java.lang.String url, java.lang.String username, java.lang.String password)
           
 
Method Summary
 java.sql.Connection getConnection()
           
 java.sql.Connection getConnection(java.lang.String username, java.lang.String password)
           
 java.lang.Integer getDefaultTransactionIsolationLevel()
           
 java.lang.String getDriver()
           
 java.lang.ClassLoader getDriverClassLoader()
           
 java.util.Properties getDriverProperties()
           
 int getLoginTimeout()
           
 java.io.PrintWriter getLogWriter()
           
 java.lang.String getPassword()
           
 java.lang.String getUrl()
           
 java.lang.String getUsername()
           
 boolean isAutoCommit()
           
 boolean isWrapperFor(java.lang.Class<?> iface)
           
 void setAutoCommit(boolean autoCommit)
           
 void setDefaultTransactionIsolationLevel(java.lang.Integer defaultTransactionIsolationLevel)
           
 void setDriver(java.lang.String driver)
           
 void setDriverClassLoader(java.lang.ClassLoader driverClassLoader)
           
 void setDriverProperties(java.util.Properties driverProperties)
           
 void setLoginTimeout(int loginTimeout)
           
 void setLogWriter(java.io.PrintWriter logWriter)
           
 void setPassword(java.lang.String password)
           
 void setUrl(java.lang.String url)
           
 void setUsername(java.lang.String username)
           
<T> T
unwrap(java.lang.Class<T> iface)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

UnpooledDataSource

public UnpooledDataSource()

UnpooledDataSource

public UnpooledDataSource(java.lang.String driver,
                          java.lang.String url,
                          java.lang.String username,
                          java.lang.String password)

UnpooledDataSource

public UnpooledDataSource(java.lang.String driver,
                          java.lang.String url,
                          java.util.Properties driverProperties)

UnpooledDataSource

public UnpooledDataSource(java.lang.ClassLoader driverClassLoader,
                          java.lang.String driver,
                          java.lang.String url,
                          java.lang.String username,
                          java.lang.String password)

UnpooledDataSource

public UnpooledDataSource(java.lang.ClassLoader driverClassLoader,
                          java.lang.String driver,
                          java.lang.String url,
                          java.util.Properties driverProperties)
Method Detail

getConnection

public java.sql.Connection getConnection()
                                  throws java.sql.SQLException
Specified by:
getConnection in interface javax.sql.DataSource
Throws:
java.sql.SQLException

getConnection

public java.sql.Connection getConnection(java.lang.String username,
                                         java.lang.String password)
                                  throws java.sql.SQLException
Specified by:
getConnection in interface javax.sql.DataSource
Throws:
java.sql.SQLException

setLoginTimeout

public void setLoginTimeout(int loginTimeout)
                     throws java.sql.SQLException
Specified by:
setLoginTimeout in interface javax.sql.CommonDataSource
Throws:
java.sql.SQLException

getLoginTimeout

public int getLoginTimeout()
                    throws java.sql.SQLException
Specified by:
getLoginTimeout in interface javax.sql.CommonDataSource
Throws:
java.sql.SQLException

setLogWriter

public void setLogWriter(java.io.PrintWriter logWriter)
                  throws java.sql.SQLException
Specified by:
setLogWriter in interface javax.sql.CommonDataSource
Throws:
java.sql.SQLException

getLogWriter

public java.io.PrintWriter getLogWriter()
                                 throws java.sql.SQLException
Specified by:
getLogWriter in interface javax.sql.CommonDataSource
Throws:
java.sql.SQLException

getDriverClassLoader

public java.lang.ClassLoader getDriverClassLoader()

setDriverClassLoader

public void setDriverClassLoader(java.lang.ClassLoader driverClassLoader)

getDriverProperties

public java.util.Properties getDriverProperties()

setDriverProperties

public void setDriverProperties(java.util.Properties driverProperties)

getDriver

public java.lang.String getDriver()

setDriver

public void setDriver(java.lang.String driver)

getUrl

public java.lang.String getUrl()

setUrl

public void setUrl(java.lang.String url)

getUsername

public java.lang.String getUsername()

setUsername

public void setUsername(java.lang.String username)

getPassword

public java.lang.String getPassword()

setPassword

public void setPassword(java.lang.String password)

isAutoCommit

public boolean isAutoCommit()

setAutoCommit

public void setAutoCommit(boolean autoCommit)

getDefaultTransactionIsolationLevel

public java.lang.Integer getDefaultTransactionIsolationLevel()

setDefaultTransactionIsolationLevel

public void setDefaultTransactionIsolationLevel(java.lang.Integer defaultTransactionIsolationLevel)

unwrap

public <T> T unwrap(java.lang.Class<T> iface)
         throws java.sql.SQLException
Specified by:
unwrap in interface java.sql.Wrapper
Throws:
java.sql.SQLException

isWrapperFor

public boolean isWrapperFor(java.lang.Class<?> iface)
                     throws java.sql.SQLException
Specified by:
isWrapperFor in interface java.sql.Wrapper
Throws:
java.sql.SQLException


Copyright © 2010 MyBatis.org. All Rights Reserved.