1 package ch.busyboxes.agoo.dao.impl;
2
3 import org.hibernate.SessionFactory;
4 import org.springframework.orm.hibernate3.HibernateTemplate;
5
6 /**
7 * Abstract class for DAOs
8 *
9 * @author julien@busyboxes.ch
10 */
11 public abstract class AbstractHibernateDAO {
12
13 /** Spring hibernate facility */
14 protected HibernateTemplate hibernateTemplate;
15
16 /**
17 * Sets the Hibernate session factory to be used by this DAO
18 *
19 * @param sessionFactory the Hibernate session Factory
20 */
21 public void setSessionFactory(SessionFactory sessionFactory) {
22 this.hibernateTemplate = new HibernateTemplate(sessionFactory);
23 }
24
25 }