Answer the question
In order to leave comments, you need to log in
Java method implementation?
Friends tell me how to do such things in java.
Here are methods like:
public static List<User> findAll() {
List<User> list = (List<User>) HibernateSessionFactoryUtil.getSessionFactory().openSession().createQuery("From "+User.class.getSimpleName()).list();
return list;
}
public static List<Group> findAll() {
List<Group> list = (List<Group>) HibernateSessionFactoryUtil.getSessionFactory().openSession().createQuery("From "+Group.class.getSimpleName()).list();
return list;
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question