1 2 12 package com.versant.core.jdbc.sql.conv; 13 14 import java.sql.*; 15 import java.io.Reader ; 16 import java.io.InputStream ; 17 import java.util.Calendar ; 18 import java.net.URL ; 19 import java.math.BigDecimal ; 20 21 24 public class DummyPreparedStmt implements PreparedStatement { 25 26 public String value; 27 public boolean toQuote = false; 28 29 public DummyPreparedStmt() { 30 } 31 32 public void setFloat(int parameterIndex, float x) throws SQLException { 33 value = String.valueOf(x); 34 } 35 36 public void setDouble(int parameterIndex, double x) throws SQLException { 37 value = String.valueOf(x); 38 } 39 40 public void setRef(int i, Ref x) throws SQLException { 41 } 43 44 public void setBoolean(int parameterIndex, boolean x) throws SQLException { 45 value = String.valueOf(x); 46 } 47 48 public void setString(int parameterIndex, String x) throws SQLException { 49 value = String.valueOf(x); 50 toQuote = true; 51 } 52 53 54 55 public void setLong(int parameterIndex, long x) throws SQLException 56 { 57 value = String.valueOf(x); 58 } 59 60 public void setShort(int parameterIndex, short x) throws SQLException { 61 value = String.valueOf(x); 62 } 63 64 public void setDate(int parameterIndex, Date x) throws SQLException { 65 value = String.valueOf(x); 66 } 67 68 public void setDate(int parameterIndex, Date x, Calendar cal) throws SQLException { 69 value = String.valueOf(x); 70 } 71 72 public void setInt(int parameterIndex, int x) throws SQLException { 73 value = String.valueOf(x); 74 } 75 76 public void setByte(int parameterIndex, byte x) throws SQLException { 77 value = String.valueOf(x); 78 } 79 80 public void setCharacterStream(int parameterIndex, Reader reader, int length) throws SQLException { 81 } 83 84 public void setBlob(int i, Blob x) throws SQLException { 85 } 87 88 public void setBinaryStream(int parameterIndex, InputStream x, int length) throws SQLException { 89 } 91 92 public void setTimestamp(int parameterIndex, Timestamp x) throws SQLException { 93 } 95 96 97 98 public void setTimestamp(int parameterIndex, Timestamp x, Calendar cal) throws SQLException { 99 } 101 102 public void setBytes(int parameterIndex, byte x[]) throws SQLException { 103 } 105 106 public void setClob(int i, Clob x) throws SQLException { 107 } 109 110 public void setAsciiStream(int parameterIndex, InputStream x, int length) throws SQLException { 111 } 113 114 public void setURL(int parameterIndex, URL x) throws SQLException { 115 } 117 118 public void setArray(int i, Array x) throws SQLException { 119 } 121 122 public void setObject(int parameterIndex, Object x, int targetSqlType) throws SQLException { 123 } 125 126 public void setObject(int parameterIndex, Object x, int targetSqlType, int scale) throws SQLException { 127 } 129 130 public void setBigDecimal(int parameterIndex, BigDecimal x) throws SQLException { 131 } 133 134 public void setUnicodeStream(int parameterIndex, InputStream x, int length) throws SQLException { 135 } 137 138 public void setTime(int parameterIndex, Time x) throws SQLException { 139 } 141 142 public void setTime(int parameterIndex, Time x, Calendar cal) throws SQLException { 143 } 145 146 147 148 149 150 151 152 153 154 155 156 public ResultSet executeQuery() throws SQLException { 157 return null; } 159 160 public int executeUpdate() throws SQLException { 161 return 0; } 163 164 public void clearParameters() throws SQLException { 165 } 167 168 public void addBatch() throws SQLException { 169 } 171 172 public void setNull(int parameterIndex, int sqlType) throws SQLException { 173 } 175 176 public void setNull(int paramIndex, int sqlType, String typeName) throws SQLException { 177 } 179 180 public ParameterMetaData getParameterMetaData() throws SQLException { 181 return null; } 183 184 public ResultSetMetaData getMetaData() throws SQLException { 185 return null; } 187 188 public boolean execute() throws SQLException { 189 return false; } 191 192 public void setObject(int parameterIndex, Object x) throws SQLException { 193 } 195 196 public void setQueryTimeout(int seconds) throws SQLException { 197 } 199 200 public void setCursorName(String name) throws SQLException { 201 } 203 204 public int getFetchSize() throws SQLException { 205 return 0; } 207 208 public int getUpdateCount() throws SQLException { 209 return 0; } 211 212 public ResultSet getGeneratedKeys() throws SQLException { 213 return null; } 215 216 public ResultSet executeQuery(String sql) throws SQLException { 217 return null; } 219 220 public Connection getConnection() throws SQLException { 221 return null; } 223 224 public void cancel() throws SQLException { 225 } 227 228 public void setMaxFieldSize(int max) throws SQLException { 229 } 231 232 public void setEscapeProcessing(boolean enable) throws SQLException { 233 } 235 236 public void setMaxRows(int max) throws SQLException { 237 } 239 240 public SQLWarning getWarnings() throws SQLException { 241 return null; } 243 244 public int getResultSetConcurrency() throws SQLException { 245 return 0; } 247 248 public int executeUpdate(String sql) throws SQLException { 249 return 0; } 251 252 public int executeUpdate(String sql, int autoGeneratedKeys) throws SQLException { 253 return 0; } 255 256 public int executeUpdate(String sql, int columnIndexes[]) throws SQLException { 257 return 0; } 259 260 public int executeUpdate(String sql, String columnNames[]) throws SQLException { 261 return 0; } 263 264 public int getFetchDirection() throws SQLException { 265 return 0; } 267 268 public void setFetchDirection(int direction) throws SQLException { 269 } 271 272 public int getQueryTimeout() throws SQLException { 273 return 0; } 275 276 public int getResultSetType() throws SQLException { 277 return 0; } 279 280 public void clearWarnings() throws SQLException { 281 } 283 284 public void addBatch(String sql) throws SQLException { 285 } 287 288 public void close() throws SQLException { 289 } 291 292 public int getMaxFieldSize() throws SQLException { 293 return 0; } 295 296 public void clearBatch() throws SQLException { 297 } 299 300 public boolean getMoreResults() throws SQLException { 301 return false; } 303 304 public boolean getMoreResults(int current) throws SQLException { 305 return false; } 307 308 public int getMaxRows() throws SQLException { 309 return 0; } 311 312 public boolean execute(String sql) throws SQLException { 313 return false; } 315 316 public boolean execute(String sql, int autoGeneratedKeys) throws SQLException { 317 return false; } 319 320 public boolean execute(String sql, int columnIndexes[]) throws SQLException { 321 return false; } 323 324 public boolean execute(String sql, String columnNames[]) throws SQLException { 325 return false; } 327 328 public void setFetchSize(int rows) throws SQLException { 329 } 331 332 public ResultSet getResultSet() throws SQLException { 333 return null; } 335 336 public int[] executeBatch() throws SQLException { 337 return new int[0]; } 339 340 public int getResultSetHoldability() throws SQLException { 341 return 0; } 343 } 344 | Popular Tags |