package common.dao;

import java.io.Serializable;
import java.util.List;

public interface IDAO<T, ID extends Serializable> {
	T read(ID id);
	T saveOrUpdate(T entity) throws Exception;
	T merge(T entity) throws Exception;
	T saveOrUpdateNoTransaction(T entity)  throws Exception;;
	boolean startTransaction();
	boolean commit();
	boolean rollback();
	void delete(T entity);
	List<T> listAll();
}
