Please send your Questions & Answers or Feedback to ""

Explain Criteria API

Criteria is a simplified API for retrieving entities by composing Criterion objects. This is a very convenient approach for functionality like "search" screens where there is a variable number of conditions to be placed upon the result set.
Example :
List employees = session.createCriteria(Employee.class)
        .add("name", "a%") )
        .add("address", "Boston"))
.addOrder(Order.asc("name") )

Related Posts Plugin for WordPress, Blogger...
Flag Counter