|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.zphinx.spine.data.impl.HibernateSessionFactory
class HibernateSessionFactory
Configures and provides access to Hibernate sessions, tied to the current thread of execution. Follows the Thread Local Session pattern.
| Method Summary | |
|---|---|
static void |
closeSession()
Close the single hibernate session instance. |
org.hibernate.Session |
currentSession()
Returns the ThreadLocal Session instance. |
org.hibernate.cfg.Configuration |
getConfiguration()
return hibernate configuration |
static HibernateSessionFactory |
getInstance()
Creates and returns the only instance of this object |
org.hibernate.SessionFactory |
getSessionFactory()
return session factory |
void |
rebuildSessionFactory()
Rebuild hibernate session factory |
void |
setConfigFile(String configFile)
Sets the configuration file session factory will be rebuilded in the next call |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public org.hibernate.Session currentSession()
throws org.hibernate.HibernateException
SessionFactory if needed.
org.hibernate.HibernateExceptionpublic void rebuildSessionFactory()
public static void closeSession()
throws org.hibernate.HibernateException
org.hibernate.HibernateExceptionpublic static HibernateSessionFactory getInstance()
public org.hibernate.SessionFactory getSessionFactory()
public void setConfigFile(String configFile)
public org.hibernate.cfg.Configuration getConfiguration()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||