package gov.nih.nci.cabig.caaers.dao;

import org.springframework.orm.hibernate3.support.HibernateDaoSupport;
import gov.nih.nci.cabig.caaers.domain.DomainObject;

import java.lang.annotation.ElementType;

/**
 * @author Rhett Sutphin
 */
/* TODO: much of this class is shared with PSC.  Refactor into a shared library. */
public abstract class CaaersDao<T extends DomainObject> extends HibernateDaoSupport {
    @SuppressWarnings("unchecked")
    public T getById(int id) {
        return (T) getHibernateTemplate().get(domainClass(), id);
    }

    public abstract Class<T> domainClass();
}

@@ -36,79 +36,8 @@
 o;%0A%0A
-import org.springframework.orm.hibernate3.support.HibernateDaoSupport;%0A
 impo
@@ -89,48 +89,162 @@
 ct;%0A
-%0A
 import 
-java.lang.annotation.ElementType
+org.apache.commons.logging.Log;%0Aimport org.apache.commons.logging.LogFactory;%0Aimport org.springframework.orm.hibernate3.support.HibernateDaoSupport
 ;%0A%0A/
@@ -445,16 +445,78 @@
 pport %7B%0A
+    protected final Log log = LogFactory.getLog(getClass());%0A%0A
     @Sup

Add protected log instance for subclass use (fix SiteDao not compiling)