您的位置:首页 > 其它

Class HibernateDaoSupport

2011-10-11 17:11 239 查看
 
java.lang.Object
org.springframework.dao.support.DaoSupport
org.springframework.orm.hibernate3.support.HibernateDaoSupport

Requires a 
SessionFactory
to be set, providing a
HibernateTemplate
based on it to subclasses through the
getHibernateTemplate()
method. Can alternatively be initialized directly with a HibernateTemplate, in order to reuse the latter's settings such as the SessionFactory, exception translator, flush mode, etc.
 

 [/code]
getHibernateTemplate()

          Return the HibernateTemplate for this DAO, pre-initialized with the SessionFactory or set explicitly.[/code]
 

getSession()

          Obtain a Hibernate Session, either from the current transaction or a new one.[/code]
getSessionFactory()

          Return the Hibernate SessionFactory used by this DAO.[/code]
setSessionFactory(SessionFactory sessionFactory)

          Set the Hibernate SessionFactory to be used by this DAO.[/code]
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息