com.alibaba.druid.util.jdbc
Class ConnectionBase

java.lang.Object
  extended by com.alibaba.druid.util.jdbc.ConnectionBase
All Implemented Interfaces:
Connection, Wrapper
Direct Known Subclasses:
MockConnection

public abstract class ConnectionBase
extends Object
implements Connection


Field Summary
 
Fields inherited from interface java.sql.Connection
TRANSACTION_NONE, TRANSACTION_READ_COMMITTED, TRANSACTION_READ_UNCOMMITTED, TRANSACTION_REPEATABLE_READ, TRANSACTION_SERIALIZABLE
 
Constructor Summary
ConnectionBase(String url, Properties info)
           
 
Method Summary
 void clearWarnings()
           
 boolean getAutoCommit()
           
 String getCatalog()
           
 Properties getConnectProperties()
           
 int getHoldability()
           
 int getTransactionIsolation()
           
 Map<String,Class<?>> getTypeMap()
           
 String getUrl()
           
 SQLWarning getWarnings()
           
 boolean isReadOnly()
           
 void setAutoCommit(boolean autoCommit)
           
 void setCatalog(String catalog)
           
 void setHoldability(int holdability)
           
 void setReadOnly(boolean readOnly)
           
 void setTransactionIsolation(int level)
           
 void setTypeMap(Map<String,Class<?>> map)
           
 void setWarings(SQLWarning warings)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface java.sql.Connection
close, commit, createArrayOf, createBlob, createClob, createNClob, createSQLXML, createStatement, createStatement, createStatement, createStruct, getClientInfo, getClientInfo, getMetaData, isClosed, isValid, nativeSQL, prepareCall, prepareCall, prepareCall, prepareStatement, prepareStatement, prepareStatement, prepareStatement, prepareStatement, prepareStatement, releaseSavepoint, rollback, rollback, setClientInfo, setClientInfo, setSavepoint, setSavepoint
 
Methods inherited from interface java.sql.Wrapper
isWrapperFor, unwrap
 

Constructor Detail

ConnectionBase

public ConnectionBase(String url,
                      Properties info)
Method Detail

getUrl

public String getUrl()

getConnectProperties

public Properties getConnectProperties()

setAutoCommit

public void setAutoCommit(boolean autoCommit)
                   throws SQLException
Specified by:
setAutoCommit in interface Connection
Throws:
SQLException

getAutoCommit

public boolean getAutoCommit()
                      throws SQLException
Specified by:
getAutoCommit in interface Connection
Throws:
SQLException

setCatalog

public void setCatalog(String catalog)
                throws SQLException
Specified by:
setCatalog in interface Connection
Throws:
SQLException

getCatalog

public String getCatalog()
                  throws SQLException
Specified by:
getCatalog in interface Connection
Throws:
SQLException

setTransactionIsolation

public void setTransactionIsolation(int level)
                             throws SQLException
Specified by:
setTransactionIsolation in interface Connection
Throws:
SQLException

getTransactionIsolation

public int getTransactionIsolation()
                            throws SQLException
Specified by:
getTransactionIsolation in interface Connection
Throws:
SQLException

getWarnings

public SQLWarning getWarnings()
                       throws SQLException
Specified by:
getWarnings in interface Connection
Throws:
SQLException

clearWarnings

public void clearWarnings()
                   throws SQLException
Specified by:
clearWarnings in interface Connection
Throws:
SQLException

setWarings

public void setWarings(SQLWarning warings)

getTypeMap

public Map<String,Class<?>> getTypeMap()
                                throws SQLException
Specified by:
getTypeMap in interface Connection
Throws:
SQLException

setTypeMap

public void setTypeMap(Map<String,Class<?>> map)
                throws SQLException
Specified by:
setTypeMap in interface Connection
Throws:
SQLException

setHoldability

public void setHoldability(int holdability)
                    throws SQLException
Specified by:
setHoldability in interface Connection
Throws:
SQLException

getHoldability

public int getHoldability()
Specified by:
getHoldability in interface Connection

setReadOnly

public void setReadOnly(boolean readOnly)
                 throws SQLException
Specified by:
setReadOnly in interface Connection
Throws:
SQLException

isReadOnly

public boolean isReadOnly()
                   throws SQLException
Specified by:
isReadOnly in interface Connection
Throws:
SQLException


Copyright © 2012 Alibaba Group. All Rights Reserved.