Package org.alfresco.query
Interface CannedQueryResults<R>
- All Superinterfaces:
PagingResults<R>
- All Known Implementing Classes:
EmptyCannedQueryResults
Interface for results returned by
canned queries
.- Since:
- 4.0
- Author:
- Derek Hulley, janv
-
Method Summary
Modifier and TypeMethodDescriptionGet the instance of the query that generated these results.int
Get the number of pages availableint
Get the total number of results available within the pages of this result.getPages()
Get the paged resultsGet a single result if there is only one result expected.Methods inherited from interface org.alfresco.query.PagingResults
getPage, getQueryExecutionId, getTotalResultCount, hasMoreItems
-
Method Details
-
getOriginatingQuery
CannedQuery<R> getOriginatingQuery()Get the instance of the query that generated these results.- Returns:
- the query that generated these results.
-
getPagedResultCount
int getPagedResultCount()Get the total number of results available within the pages of this result. The count excludes results chopped out by the paging process i.e. it is only the count of results physically obtainable through this instance.- Returns:
- number of results available in the pages
-
getPageCount
int getPageCount()Get the number of pages available- Returns:
- the number of pages available
-
getSingleResult
R getSingleResult()Get a single result if there is only one result expected.- Returns:
- a single result
- Throws:
IllegalStateException
- if the query returned more than one result
-
getPages
Get the paged results- Returns:
- a list of paged results
-