// Collection of code snippets by Arne Vajhøj 
// (likely posted to comp.os.vms/INFO-VAX, INFO-TPU, MACRO32, eksperten.dk, newz.dk, LinkedIn or other place sometime between 1990 and now) 
package test;

import java.util.List;

import org.springframework.orm.hibernate.support.HibernateDaoSupport;

import net.sf.hibernate.HibernateException;

public class T1DAONew extends HibernateDaoSupport {
    public T1 findOne(int f1) throws HibernateException {
        return (T1)getHibernateTemplate().load(T1.class, new Integer(f1));
    }
    public List findAll() throws HibernateException {
        return getHibernateTemplate().find("FROM T1 AS t1");
    }
 }
