Google News
logo
Java Hibernates - Interview Questions
Define criteria in terms of hibernate?
The hibernate Session interface provides createCriteria() method, which can be used to create a criteria object that returns instances of the persistence object’s class when your application executes a criteria query.
 
Example of criteria :
 
Criteria cr = session.createCriteria(Freetimelearning.class);
 
List results = cr.list();
Advertisement