ibrokerkit.epptools4java.store.impl.db
Class DatabaseStore

java.lang.Object
  extended by ibrokerkit.epptools4java.store.impl.db.DatabaseStore
All Implemented Interfaces:
Store

public class DatabaseStore
extends java.lang.Object
implements Store


Constructor Summary
DatabaseStore(java.util.Properties properties)
           
 
Method Summary
 void close()
           
 Action createAction(java.lang.Character gcs, java.lang.String transactionId, java.lang.String request, java.lang.String response)
           
 Poll createPoll(java.lang.Character gcs, java.lang.String transactionId, java.lang.String response)
           
 void deleteObject(java.lang.Object object)
           
 org.hibernate.SessionFactory getSessionFactory()
          Checks if the database connection is still alive; if not, try to reconnect, then throw exception.
 void init()
           
 boolean isClosed()
           
 boolean isInitialized()
           
 Action[] listActions()
           
 Poll[] listPolls()
           
 void setSessionFactory(org.hibernate.SessionFactory sessionFactory)
          Allow the connection to be changed externally.
 void updateObject(java.lang.Object object)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DatabaseStore

public DatabaseStore(java.util.Properties properties)
Method Detail

init

public void init()
          throws StoreException
Specified by:
init in interface Store
Throws:
StoreException

isInitialized

public boolean isInitialized()
Specified by:
isInitialized in interface Store

close

public void close()
Specified by:
close in interface Store

isClosed

public boolean isClosed()
Specified by:
isClosed in interface Store

getSessionFactory

public org.hibernate.SessionFactory getSessionFactory()
                                               throws StoreException
Checks if the database connection is still alive; if not, try to reconnect, then throw exception.

Returns:
The database connection.
Throws:
StoreException

setSessionFactory

public void setSessionFactory(org.hibernate.SessionFactory sessionFactory)
Allow the connection to be changed externally.

Parameters:
sessionFactory -

updateObject

public void updateObject(java.lang.Object object)
                  throws StoreException
Specified by:
updateObject in interface Store
Throws:
StoreException

deleteObject

public void deleteObject(java.lang.Object object)
                  throws StoreException
Specified by:
deleteObject in interface Store
Throws:
StoreException

listActions

public Action[] listActions()
                     throws StoreException
Specified by:
listActions in interface Store
Throws:
StoreException

createAction

public Action createAction(java.lang.Character gcs,
                           java.lang.String transactionId,
                           java.lang.String request,
                           java.lang.String response)
                    throws StoreException
Specified by:
createAction in interface Store
Throws:
StoreException

listPolls

public Poll[] listPolls()
                 throws StoreException
Specified by:
listPolls in interface Store
Throws:
StoreException

createPoll

public Poll createPoll(java.lang.Character gcs,
                       java.lang.String transactionId,
                       java.lang.String response)
                throws StoreException
Specified by:
createPoll in interface Store
Throws:
StoreException


Copyright © 2009. All Rights Reserved.