T - specifies the return type of the follwing methodspublic interface BaseQuery<T>
| Modifier and Type | Interface and Description |
|---|---|
static class |
BaseQuery.SortDirection
Determines the sort direction.
|
| Modifier and Type | Method and Description |
|---|---|
long |
count()
Counting the amount of rows/results for the current query.
|
List<T> |
list()
This method will return a list of defined
T objects. |
List<T> |
list(int offset,
int limit)
This method will return a list of defined
T objects with specified offset and an limit. |
default List<T> |
listPage(int pageNumber,
int pageSize)
This method will return all results for page X with a size of Y of the current query.
Negative pageNumber/size will be changed to 1 or 0 and the last page might contains less elements. |
List<String> |
listValues(String dbColumnName,
BaseQuery.SortDirection sortDirection)
This method will return all currently existing values of a DB-Table once.
|
T |
single()
This method will return a single object of
T. |
List<T> list()
T objects. In case of a TaskQuery, this method can throw a
NotAuthorizedToQueryWorkbasketException.List<T> list(int offset, int limit)
T objects with specified offset and an limit. In case of a
TaskQuery, this method can throw a NotAuthorizedToQueryWorkbasketException.offset - index of the first element which should be returned.limit - number of elements which should be returned beginning with offset.List<String> listValues(String dbColumnName, BaseQuery.SortDirection sortDirection)
dbColumnName - column name of a existing DB Table.sortDirection - Determines whether the result is sorted in ascending or descending order. If sortDirection is null,
the result is sorted in ascending orderdefault List<T> listPage(int pageNumber, int pageSize)
pageNumber - current pagination page starting at 1.pageSize - amount of elements for this page.T single()
T. In case of a TaskQuery, this method can throw a
NotAuthorizedToQueryWorkbasketException.long count()
Copyright © 2018. All rights reserved.