org.jboss.seam.rest.example.tasks.resource
Class CollectionBean
java.lang.Object
org.jboss.seam.rest.example.tasks.resource.CollectionBean
public class CollectionBean
- extends Object
Loads collections of Tasks and Categories from database.
- Author:
- Jozef Hartinger
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
CollectionBean
public CollectionBean()
getCategories
public List<Category> getCategories(int start,
int limit)
getTasks
public List<Task> getTasks(int start,
int limit,
String status,
String categoryName)
applyResolutionParameter
protected Query applyResolutionParameter(Query query,
String status)
- Modifies query passed as a parameter to filter out tasks based on their status (resolved/unresolved/all)
applyPaginationParameters
protected void applyPaginationParameters(Query query,
int start,
int limit)
- Sets paginatation parameters
- Parameters:
query - JPA querystart - the first itemlimit - how many items to return (use 0 for unlimited result)
- Throws:
IllegalArgumentException - if any of the integer parameters is lesser than 0
Copyright © 2011 Seam Framework. All Rights Reserved.