class HibernateSessionDAO extends HibernatePersistentObjectDAO<Session> implements SessionDAO {

	@Override
	public List<Session> findByNode(String node) {
		try {
			if (StringUtils.isEmpty(node))
				return findByWhere(" 1=1 ", null, "order by _entity.creation desc", null);
			else
				return findByWhere("_entity.node = ?1", new Object[] { node }, "order by _entity.creation desc", null);
		} catch (PersistenceException e) {
			log.error(e.getMessage(), e);
			return new ArrayList<Session>();
		}
	}

	protected  HibernateSessionDAO();

}