001    // Copyright 2008 Thiago H. de Paula Figueiredo
002    //
003    // Licensed under the Apache License, Version 2.0 (the "License");
004    // you may not use this file except in compliance with the License.
005    // You may obtain a copy of the License at
006    //
007    //     http://www.apache.org/licenses/LICENSE-2.0
008    //
009    // Unless required by applicable law or agreed to in writing, software
010    // distributed under the License is distributed on an "AS IS" BASIS,
011    // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
012    // See the License for the specific language governing permissions and
013    // limitations under the License.
014    
015    package br.com.arsmachina.dao.hibernate;
016    
017    import java.io.Serializable;
018    
019    import org.hibernate.SessionFactory;
020    
021    import br.com.arsmachina.dao.DAO;
022    
023    /**
024     * A concrete {@link GenericDAOImpl} subclass. It is meant to be used to instantiate a DAO
025     * for entities that need only the methods that {@link DAO} has. Never subclass
026     * <code>ConcreteDAOImpl</code>: subclass {@link GenericDAOImpl} instead.
027     * 
028     * @author Thiago H. de Paula Figueiredo
029     * @param <T> the entity class related to this DAO.
030     * @param <K> the type of the field that represents the entity class' primary key.
031     */
032    public class ConcreteDAOImpl<T, K extends Serializable> extends GenericDAOImpl<T, K> {
033    
034            /**
035             * Single constructor.
036             * 
037             * @param clasz the entity class. It cannot be null.
038             * @param sessionFactory a {@link SessionFactory}. It cannot be null.
039             */
040            public ConcreteDAOImpl(Class<T> clasz, SessionFactory sessionFactory) {
041                    super(clasz, sessionFactory);
042            }
043    
044    }