org.lyra.Database
Class Interface.myConnections

java.lang.Object
  extended by org.lyra.Database.Interface.myConnections
Enclosing class:
Interface

private class Interface.myConnections
extends java.lang.Object

For some reason it is difficult to properly separate preparation and query results running without running into trouble. So this class is essentially a holder class for the PreparedStatement and ResultSet handles.

Author:
Martin Foster

Field Summary
private  java.sql.PreparedStatement myPrepared
           
private  java.sql.ResultSet myResult
           
 
Constructor Summary
Interface.myConnections()
          Default Constructor
 
Method Summary
 void close()
          Closes and nulls out all of the handles in this class.
 java.sql.PreparedStatement getPreparedStatement()
          Gets the PreparedStatement element.
 java.sql.ResultSet getResultSet()
          Sets the ResultSet element.
 void setPreparedStatement(java.sql.PreparedStatement ps)
          Sets the PreparedStatement element.
 void setResultSet(java.sql.ResultSet rs)
          Sets the ResultSet element.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

myPrepared

private java.sql.PreparedStatement myPrepared

myResult

private java.sql.ResultSet myResult
Constructor Detail

Interface.myConnections

public Interface.myConnections()
Default Constructor

Method Detail

setPreparedStatement

public void setPreparedStatement(java.sql.PreparedStatement ps)
Sets the PreparedStatement element.

Parameters:
ps - PreparedStatement

getPreparedStatement

public java.sql.PreparedStatement getPreparedStatement()
Gets the PreparedStatement element.

Returns:
PreparedStatement

setResultSet

public void setResultSet(java.sql.ResultSet rs)
Sets the ResultSet element.

Parameters:
rs - ResultSet.

getResultSet

public java.sql.ResultSet getResultSet()
Sets the ResultSet element.

Returns:
ResultSet.

close

public void close()
           throws java.sql.SQLException
Closes and nulls out all of the handles in this class.

Throws:
java.sql.SQLException