HMS
Class jdbcConnection

java.lang.Object
  |
  +--java.lang.Thread
        |
        +--HMS.jdbcConnection
All Implemented Interfaces:
java.lang.Runnable

public class jdbcConnection
extends java.lang.Thread


Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
 
Constructor Summary
jdbcConnection()
           
 
Method Summary
 boolean commit()
          Commits all changes to the database
 void dropConnection()
           
protected  void finalize()
          Overriden method that will drop the connection when the object is destroyed
 java.sql.ResultSet getData(java.lang.String sData)
          Allows queries of the database
 boolean rollback()
          Rolls back any changes to the database
 boolean setData(java.lang.String sUpdate)
          Allows inserts into the database
 
Methods inherited from class java.lang.Thread
activeCount, checkAccess, countStackFrames, currentThread, destroy, dumpStack, enumerate, getContextClassLoader, getName, getPriority, getThreadGroup, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, run, setContextClassLoader, setDaemon, setName, setPriority, sleep, sleep, start, stop, stop, suspend, toString, yield
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

jdbcConnection

public jdbcConnection()
Method Detail

dropConnection

public void dropConnection()

finalize

protected void finalize()
Overriden method that will drop the connection when the object is destroyed
Overrides:
finalize in class java.lang.Object

setData

public boolean setData(java.lang.String sUpdate)
Allows inserts into the database
Parameters:
sUpdate - -- SQL statement to insert into database
Returns:
indicates if insert into database was successful

getData

public java.sql.ResultSet getData(java.lang.String sData)
Allows queries of the database
Parameters:
sData - contains statement regarding database select
Returns:
contains result of database select

commit

public boolean commit()
Commits all changes to the database
Returns:
indicates if commit is successful

rollback

public boolean rollback()
Rolls back any changes to the database
Returns:
indicates if rollback is successful