View Javadoc

1   package com.imcode.db.jdbc;
2   
3   import java.sql.*;
4   import java.util.Map;
5   
6   public class ConnectionWrapper implements Connection {
7   
8       public ConnectionWrapper(Connection connection) {
9           this.connection = connection;
10      }
11  
12      public void clearWarnings() throws SQLException {
13          connection.clearWarnings();
14      }
15  
16      public void close() throws SQLException {
17          connection.close();
18      }
19  
20      public void commit() throws SQLException {
21          connection.commit();
22      }
23  
24      public Statement createStatement() throws SQLException {
25          return connection.createStatement();
26      }
27  
28      public Statement createStatement(int resultSetType, int resultSetConcurrency) throws SQLException {
29          return connection.createStatement(resultSetType, resultSetConcurrency);
30      }
31  
32      public Statement createStatement(int resultSetType, int resultSetConcurrency, int resultSetHoldability) throws SQLException {
33          return connection.createStatement(resultSetType, resultSetConcurrency, resultSetHoldability);
34      }
35  
36      public boolean getAutoCommit() throws SQLException {
37          return connection.getAutoCommit();
38      }
39  
40      public String getCatalog() throws SQLException {
41          return connection.getCatalog();
42      }
43  
44      public int getHoldability() throws SQLException {
45          return connection.getHoldability();
46      }
47  
48      public DatabaseMetaData getMetaData() throws SQLException {
49          return connection.getMetaData();
50      }
51  
52      public int getTransactionIsolation() throws SQLException {
53          return connection.getTransactionIsolation();
54      }
55  
56      public Map getTypeMap() throws SQLException {
57          return connection.getTypeMap();
58      }
59  
60      public SQLWarning getWarnings() throws SQLException {
61          return connection.getWarnings();
62      }
63  
64      public boolean isClosed() throws SQLException {
65          return connection.isClosed();
66      }
67  
68      public boolean isReadOnly() throws SQLException {
69          return connection.isReadOnly();
70      }
71  
72      public String nativeSQL(String sql) throws SQLException {
73          return connection.nativeSQL(sql);
74      }
75  
76      public CallableStatement prepareCall(String sql) throws SQLException {
77          return connection.prepareCall(sql);
78      }
79  
80      public CallableStatement prepareCall(String sql, int resultSetType, int resultSetConcurrency) throws SQLException {
81          return connection.prepareCall(sql, resultSetType, resultSetConcurrency);
82      }
83  
84      public CallableStatement prepareCall(String sql, int resultSetType, int resultSetConcurrency,
85                                           int resultSetHoldability) throws SQLException {
86          return connection.prepareCall(sql, resultSetType, resultSetConcurrency, resultSetHoldability);
87      }
88  
89      public PreparedStatement prepareStatement(String sql) throws SQLException {
90          return connection.prepareStatement(sql);
91      }
92  
93      public PreparedStatement prepareStatement(String sql, int autoGeneratedKeys) throws SQLException {
94          return connection.prepareStatement(sql, autoGeneratedKeys);
95      }
96  
97      public PreparedStatement prepareStatement(String sql, int[] columnIndexes) throws SQLException {
98          return connection.prepareStatement(sql, columnIndexes);
99      }
100 
101     public PreparedStatement prepareStatement(String sql, String[] columnNames) throws SQLException {
102         return connection.prepareStatement(sql, columnNames);
103     }
104 
105     public PreparedStatement prepareStatement(String sql, int resultSetType, int resultSetConcurrency) throws SQLException {
106         return connection.prepareStatement(sql, resultSetType, resultSetConcurrency);
107     }
108 
109     public PreparedStatement prepareStatement(String sql, int resultSetType, int resultSetConcurrency,
110                                               int resultSetHoldability) throws SQLException {
111         return connection.prepareStatement(sql, resultSetType, resultSetConcurrency, resultSetHoldability);
112     }
113 
114     public void releaseSavepoint(Savepoint savepoint) throws SQLException {
115         connection.releaseSavepoint(savepoint);
116     }
117 
118     public void rollback() throws SQLException {
119         connection.rollback();
120     }
121 
122     public void rollback(Savepoint savepoint) throws SQLException {
123         connection.rollback(savepoint);
124     }
125 
126     public void setAutoCommit(boolean autoCommit) throws SQLException {
127         connection.setAutoCommit(autoCommit);
128     }
129 
130     public void setCatalog(String catalog) throws SQLException {
131         connection.setCatalog(catalog);
132     }
133 
134     public void setHoldability(int holdability) throws SQLException {
135         connection.setHoldability(holdability);
136     }
137 
138     public void setReadOnly(boolean readOnly) throws SQLException {
139         connection.setReadOnly(readOnly);
140     }
141 
142     public Savepoint setSavepoint() throws SQLException {
143         return connection.setSavepoint();
144     }
145 
146     public Savepoint setSavepoint(String name) throws SQLException {
147         return connection.setSavepoint(name);
148     }
149 
150     public void setTransactionIsolation(int level) throws SQLException {
151         connection.setTransactionIsolation(level);
152     }
153 
154     public void setTypeMap(Map map) throws SQLException {
155         connection.setTypeMap(map);
156     }
157 
158     protected Connection connection ;
159 }