|
From: <leg...@at...> - 2003-08-06 09:06:14
|
Message: A new issue has been created in JIRA. --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-235 Here is an overview of the issue: --------------------------------------------------------------------- Key: HB-235 Summary: Add a count() method on the Criteria interface Type: New Feature Status: Unassigned Priority: Major Project: Hibernate2 Components: core Versions: 2.0.2 Assignee: Reporter: Sebastien Cesbron Created: Wed, 6 Aug 2003 4:05 AM Updated: Wed, 6 Aug 2003 4:05 AM Description: It would be very convenient to have a count() method on the Criteria interface. Thus it would be possible to know the total size of a list when you don't want to load all the elements. Example : Criteria criteria = session.createCriteria(User.class); criteria.setFirstResult(0); criteria.setMaxResult(10); // Custom class that holds a page of the list and the total size Page page = new Page(); page.setList(criteria.list()); page.setTotalSize(criteria.count()); ___________________________^^^^^^^ => the new method --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |