01: /*-------------------------------------------------------------------------
02: *
03: * Copyright (c) 2004-2005, PostgreSQL Global Development Group
04: *
05: * IDENTIFICATION
06: * $PostgreSQL: pgjdbc/org/postgresql/jdbc2/Jdbc2Statement.java,v 1.13 2005/01/11 08:25:46 jurka Exp $
07: *
08: *-------------------------------------------------------------------------
09: */
10: package org.postgresql.jdbc2;
11:
12: import java.sql.*;
13: import java.util.Vector;
14: import org.postgresql.core.*;
15:
16: /**
17: * This class implements the java.sql.Statement interface for JDBC2.
18: * However most of the implementation is really done in
19: * org.postgresql.jdbc2.AbstractJdbc2Statement
20: */
21: class Jdbc2Statement extends AbstractJdbc2Statement implements
22: Statement {
23: Jdbc2Statement(Jdbc2Connection c, int rsType, int rsConcurrency)
24: throws SQLException {
25: super (c, rsType, rsConcurrency);
26: }
27:
28: protected Jdbc2Statement(Jdbc2Connection connection, String sql,
29: boolean isCallable, int rsType, int rsConcurrency)
30: throws SQLException {
31: super (connection, sql, isCallable, rsType, rsConcurrency);
32: }
33:
34: public ResultSet createResultSet(Query originalQuery,
35: Field[] fields, Vector tuples, ResultCursor cursor)
36: throws SQLException {
37: Jdbc2ResultSet newResult = new Jdbc2ResultSet(originalQuery,
38: this, fields, tuples, cursor, getMaxRows(),
39: getMaxFieldSize(), getResultSetType(),
40: getResultSetConcurrency());
41: newResult.setFetchSize(getFetchSize());
42: newResult.setFetchDirection(getFetchDirection());
43: return newResult;
44: }
45: }
|