T - type of result elementspublic final class QueryResults<T> extends Object implements Serializable
QueryResults bundles data for paged query results| Constructor and Description |
|---|
QueryResults(List<T> results,
Long limit,
Long offset,
long total)
Create a new
QueryResults instance |
QueryResults(List<T> results,
QueryModifiers mod,
long total)
Create a new
QueryResults instance |
| Modifier and Type | Method and Description |
|---|---|
static <T> QueryResults<T> |
emptyResults() |
long |
getLimit()
Get the limit value used for the query
|
long |
getOffset()
Get the offset value used for the query
|
List<T> |
getResults()
Get the results in List form
An empty list is returned for no results.
|
long |
getTotal()
Get the total number of results
|
boolean |
isEmpty()
Return whether there are results in the current query window
|
public QueryResults(List<T> results, @Nullable Long limit, @Nullable Long offset, long total)
QueryResults instanceresults - paged resultslimit - used limitoffset - used offsettotal - total result rows countpublic QueryResults(List<T> results, QueryModifiers mod, long total)
QueryResults instanceresults - paged resultsmod - limit and offsettotal - total result rows countpublic static <T> QueryResults<T> emptyResults()
public List<T> getResults()
public long getTotal()
public boolean isEmpty()
public long getLimit()
public long getOffset()
Copyright © 2007–2016 Querydsl. All rights reserved.