public class QueryString extends Object
Constructor and Description |
---|
QueryString(Class<?> domainClass)
Creates a SELECT query for the given domain class.
|
QueryString(Class<?> domainClass,
boolean isCountQuery)
Creates a SELECT query for the given domain class.
|
QueryString(String source)
Creates a
QueryString from the given String query. |
Modifier and Type | Method and Description |
---|---|
QueryString |
bindIn(Collection<?> values)
Binds the given values to the IN parameter keyword by expanding the given values into a comma-separated
String . |
QueryString |
forRegion(Class<?> domainClass,
Region<?,?> region)
Replaces the domain classes referenced inside the current query with the given
Region . |
Iterable<Integer> |
getInParameterIndexes()
Returns the parameter indexes used in this query.
|
QueryString |
orderBy(org.springframework.data.domain.Sort sort)
Appends the Sort order to this GemFire OQL Query string.
|
String |
toString() |
public QueryString(String source)
QueryString
from the given String
query.source
- a String containing the OQL Query.public QueryString(Class<?> domainClass)
domainClass
- must not be null.public QueryString(Class<?> domainClass, boolean isCountQuery)
domainClass
- must not be null.isCountQuery
- indicates if this is a count querypublic QueryString bindIn(Collection<?> values)
String
.values
- the values to bind, returns the QueryString
as is if null is given.public QueryString forRegion(Class<?> domainClass, Region<?,?> region)
Region
.domainClass
- the class type of the GemFire persistent entity to query; must not be null.region
- the GemFire Region in which to query; must not be null.Region
public Iterable<Integer> getInParameterIndexes()
public QueryString orderBy(org.springframework.data.domain.Sort sort)
sort
- the Sort object indicating the order by criteria.Sort
,
QueryString