public class SearchResultImpl<E> extends Object implements SearchResult<E>
| Constructor and Description |
|---|
SearchResultImpl(List<E> result,
int totalCount,
int requestedCount,
int requestedStart)
Default constructor.
|
| Modifier and Type | Method and Description |
|---|---|
int |
getCount()
Gets size of result collection.
|
int |
getRequestedCount()
Gets requested result count.
|
int |
getRequestedStart()
Gets requested start index.
|
List<E> |
getResult()
Gets the search result.
|
int |
getTotalCount()
Gets size of collection without using range.
|
boolean |
isFromCache() |
void |
setFromCache(boolean fromCache) |
public SearchResultImpl(List<E> result, int totalCount, int requestedCount, int requestedStart)
result - the result list from the jalo searchtotalCount - the overall count (all elements) of the jalo searchrequestedCount - the requested count (how many elements should be in the list?)requestedStart - the start count (this list should start at this element)public int getCount()
SearchResultSearchResult.getRequestedCount() or less (if less elements are found)getCount in interface SearchResult<E>public int getRequestedCount()
SearchResultAbstractQuery.setCount(int)getRequestedCount in interface SearchResult<E>public int getRequestedStart()
SearchResultAbstractQuery.setStart(int)getRequestedStart in interface SearchResult<E>public List<E> getResult()
SearchResultnull value at this
position.getResult in interface SearchResult<E>public int getTotalCount()
SearchResultAbstractQuery.isNeedTotal()=
false (default) than this total count is the same as SearchResult.getRequestedCount() or less. It is not
the total count of all elements in the db. (only when isNeedTotal=true)getTotalCount in interface SearchResult<E>public boolean isFromCache()
public void setFromCache(boolean fromCache)
Copyright © 2017 SAP SE. All Rights Reserved.