public List loadUsersByPage(Integer groupId, int firstRow, int pageSize, String orderBy, boolean orderAscending) { Criteria c = getUsersCriteria(groupId); c.setFirstResult(firstRow); c.setMaxResults(pageSize); Order order = orderAscending ? Order.asc(orderBy) : Order.desc(orderBy); c.addOrder(order); List users = c.list(); return users;
public List loadUsersByPage(Integer groupId, int firstRow, int pageSize, String orderBy, boolean orderAscending) { return loadBeansByPage(User.class, groupId, firstRow, pageSize, orderBy, orderAscending);
    public List loadUsersByPage(Integer groupId, int firstRow, int pageSize, String orderBy, boolean orderAscending) {        Criteria c = getUsersCriteria(groupId);        c.setFirstResult(firstRow);        c.setMaxResults(pageSize);        Order order = orderAscending ? Order.asc(orderBy) : Order.desc(orderBy);        c.addOrder(order);        List users = c.list();        return users;    }