|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.hibernate.util.ExternalSessionFactoryConfig org.hibernate.jmx.HibernateService
Implementation of HibernateServiceMBean. Creates a
SessionFactory and binds it to the specified JNDI name.
All mapping documents are loaded as resources by the MBean.
HibernateServiceMBean
,
SessionFactory
Constructor Summary | |
HibernateService()
|
Method Summary | |
void |
createSchema()
Export the CREATE DDL to the database |
void |
dropSchema()
Export the DROP DDL to the database |
String |
getAutoCloseSessionEnabled()
Is automatic Session closing enabled? |
String |
getDatasource()
The JNDI name of the datasource to use in this SessionFactory |
protected Map |
getExtraProperties()
|
String |
getFlushBeforeCompletionEnabled()
Is automatic Session flusing enabled? |
String |
getJndiName()
The JNDI name to bind to the SessionFactory |
String |
getName()
|
String |
getPassword()
Log into the database with this password |
Properties |
getProperties()
|
String |
getProperty(String property)
Get a property |
String |
getPropertyList()
Display the properties |
String |
getTransactionManagerLookupStrategy()
Get the strategy for obtaining the JTA TransactionManager |
String |
getTransactionStrategy()
The fully qualified class name of the Hibernate TransactionFactory implementation |
String |
getUserName()
Log into the database with this name |
String |
getUserTransactionName()
The JNDI name of the JTA UserTransaction object (used only be JTATransaction). |
void |
setAutoCloseSessionEnabled(String enabled)
Enable automatic closing of Session when JTA transaction ends. |
void |
setDatasource(String datasource)
Set the JNDI name of the datasource to use in this SessionFactory |
void |
setFlushBeforeCompletionEnabled(String enabled)
Enable automatic flushing of the Session when JTA transaction ends. |
void |
setJndiName(String jndiName)
The JNDI name to bind to the SessionFactory |
void |
setPassword(String password)
Log into the database with this password |
void |
setProperty(String property,
String value)
Set a property |
void |
setTransactionManagerLookupStrategy(String lkpStrategy)
Set the strategy for obtaining the JTA TransactionManager |
void |
setTransactionStrategy(String txnStrategy)
Set the fully qualified class name of the Hibernate TransactionFactory implementation |
void |
setUserName(String userName)
Log into the database with this name |
void |
setUserTransactionName(String utName)
Set the JNDI name of the JTA UserTransaction object (used only by JTATransaction). |
void |
start()
Create the SessionFactory and bind to the jndi name on startup |
void |
stop()
Unbind the SessionFactory or stub from JNDI |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public HibernateService()
Method Detail |
public void start() throws HibernateException
HibernateServiceMBean
start
in interface HibernateServiceMBean
HibernateException
public void stop()
HibernateServiceMBean
stop
in interface HibernateServiceMBean
protected Map getExtraProperties()
getExtraProperties
in class ExternalSessionFactoryConfig
public String getTransactionStrategy()
HibernateServiceMBean
getTransactionStrategy
in interface HibernateServiceMBean
TransactionFactory
public void setTransactionStrategy(String txnStrategy)
HibernateServiceMBean
setTransactionStrategy
in interface HibernateServiceMBean
txnStrategy
- the class nameTransactionFactory
public String getUserTransactionName()
HibernateServiceMBean
getUserTransactionName
in interface HibernateServiceMBean
JTATransaction
public void setUserTransactionName(String utName)
HibernateServiceMBean
setUserTransactionName
in interface HibernateServiceMBean
utName
- the JNDI nameJTATransaction
public String getTransactionManagerLookupStrategy()
HibernateServiceMBean
getTransactionManagerLookupStrategy
in interface HibernateServiceMBean
TransactionManagerLookup
public void setTransactionManagerLookupStrategy(String lkpStrategy)
HibernateServiceMBean
setTransactionManagerLookupStrategy
in interface HibernateServiceMBean
lkpStrategy
- the class nameTransactionManagerLookup
public String getPropertyList()
HibernateServiceMBean
getPropertyList
in interface HibernateServiceMBean
public String getProperty(String property)
HibernateServiceMBean
getProperty
in interface HibernateServiceMBean
property
- the property name
public void setProperty(String property, String value)
HibernateServiceMBean
setProperty
in interface HibernateServiceMBean
property
- the property namevalue
- the property valuepublic void dropSchema()
HibernateServiceMBean
dropSchema
in interface HibernateServiceMBean
public void createSchema()
HibernateServiceMBean
createSchema
in interface HibernateServiceMBean
public String getName()
public String getDatasource()
HibernateServiceMBean
getDatasource
in interface HibernateServiceMBean
public void setDatasource(String datasource)
HibernateServiceMBean
setDatasource
in interface HibernateServiceMBean
datasource
- public String getJndiName()
HibernateServiceMBean
getJndiName
in interface HibernateServiceMBean
public void setJndiName(String jndiName)
HibernateServiceMBean
setJndiName
in interface HibernateServiceMBean
jndiName
- public String getUserName()
HibernateServiceMBean
getUserName
in interface HibernateServiceMBean
public void setUserName(String userName)
HibernateServiceMBean
setUserName
in interface HibernateServiceMBean
userName
- public String getPassword()
HibernateServiceMBean
getPassword
in interface HibernateServiceMBean
public void setPassword(String password)
HibernateServiceMBean
setPassword
in interface HibernateServiceMBean
password
- public void setFlushBeforeCompletionEnabled(String enabled)
HibernateServiceMBean
setFlushBeforeCompletionEnabled
in interface HibernateServiceMBean
public String getFlushBeforeCompletionEnabled()
HibernateServiceMBean
getFlushBeforeCompletionEnabled
in interface HibernateServiceMBean
public void setAutoCloseSessionEnabled(String enabled)
HibernateServiceMBean
setAutoCloseSessionEnabled
in interface HibernateServiceMBean
public String getAutoCloseSessionEnabled()
HibernateServiceMBean
getAutoCloseSessionEnabled
in interface HibernateServiceMBean
public Properties getProperties()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |