org.apache.tapestry.contrib.jdbc
Interface IStatement

All Known Implementing Classes:
ParameterizedStatement, SimpleStatement

public interface IStatement

A wrapper around Statement or PreparedStatement which hides the differences between the two.

Author:
Howard Lewis Ship
See Also:
StatementAssembly.createStatement(Connection)

Method Summary
 void close()
          Closes the underlying statement, and nulls the reference to it.
 java.sql.ResultSet executeQuery()
          Executes the statement as a query, returning a ResultSet.
 int executeUpdate()
          Executes the statement as an update, returning the number of rows affected.
 java.lang.String getSQL()
          Returns the SQL associated with this statement.
 java.sql.Statement getStatement()
          Returns the underlying Statement (or PreparedStatement).
 

Method Detail

getSQL

java.lang.String getSQL()
Returns the SQL associated with this statement.


getStatement

java.sql.Statement getStatement()
Returns the underlying Statement (or PreparedStatement).


close

void close()
           throws java.sql.SQLException
Closes the underlying statement, and nulls the reference to it.

Throws:
java.sql.SQLException

executeQuery

java.sql.ResultSet executeQuery()
                                throws java.sql.SQLException
Executes the statement as a query, returning a ResultSet.

Throws:
java.sql.SQLException

executeUpdate

int executeUpdate()
                  throws java.sql.SQLException
Executes the statement as an update, returning the number of rows affected.

Throws:
java.sql.SQLException