| Modifier and Type | Method and Description |
|---|---|
Query |
columns(Collection<String> columns)
Add columns to the query.
|
Query |
columns(SqlIdentifier... columns)
Add columns to the query.
|
Query |
columns(String... columns)
Add columns to the query.
|
static Query |
empty()
Create a new empty
Query. |
List<SqlIdentifier> |
getColumns()
Return the columns that this query should project.
|
Optional<CriteriaDefinition> |
getCriteria()
Return the
Criteria to be applied. |
int |
getLimit()
Return the maximum number of rows to be return.
|
long |
getOffset()
Return the number of rows to skip.
|
Sort |
getSort() |
boolean |
isSorted()
Return true if the
Query has a sort parameter. |
Query |
limit(int limit)
Limit the number of returned documents to
limit. |
Query |
offset(long offset)
Set number of rows to skip before returning results.
|
static Query |
query(CriteriaDefinition criteria)
Static factory method to create a
Query using the provided CriteriaDefinition. |
Query |
sort(Sort sort)
|
Query |
with(Pageable pageable)
Set the given pagination information on the
Query instance. |
public static Query query(CriteriaDefinition criteria)
Query using the provided CriteriaDefinition.public Query columns(String... columns)
columns - Query object containing the former settings with columns applied.public Query columns(Collection<String> columns)
columns - Query object containing the former settings with columns applied.public Query columns(SqlIdentifier... columns)
columns - Query object containing the former settings with columns applied.public Query offset(long offset)
offset - Query object containing the former settings with offset applied.public Query limit(int limit)
limit.limit - Query object containing the former settings with limit applied.public Optional<CriteriaDefinition> getCriteria()
Criteria to be applied.public List<SqlIdentifier> getColumns()
public boolean isSorted()
Query has a sort parameter.Sort.isSorted()public Sort getSort()
public long getOffset()
public int getLimit()
Copyright © 2017–2021 Pivotal Software, Inc.. All rights reserved.