public class Query extends Object implements Serializable, Cloneable
Defines the query to run against an object.
Constructor and Description |
---|
Query() |
Modifier and Type | Method and Description |
---|---|
Query |
clone() |
boolean |
equals(Object obj) |
List<Selector> |
getSelectors()
List of selectors that define the query.
|
int |
hashCode() |
void |
setSelectors(Collection<Selector> selectors)
List of selectors that define the query.
|
String |
toString()
Returns a string representation of this object; useful for testing and
debugging.
|
Query |
withSelectors(Collection<Selector> selectors)
List of selectors that define the query.
|
Query |
withSelectors(Selector... selectors)
List of selectors that define the query.
|
public List<Selector> getSelectors()
public void setSelectors(Collection<Selector> selectors)
selectors
- List of selectors that define the query. An object must satisfy all of
the selectors to match the query.public Query withSelectors(Selector... selectors)
NOTE: This method appends the values to the existing list (if
any). Use setSelectors(java.util.Collection)
or withSelectors(java.util.Collection)
if you want to override the
existing values.
Returns a reference to this object so that method calls can be chained together.
selectors
- List of selectors that define the query. An object must satisfy all of
the selectors to match the query.public Query withSelectors(Collection<Selector> selectors)
Returns a reference to this object so that method calls can be chained together.
selectors
- List of selectors that define the query. An object must satisfy all of
the selectors to match the query.public String toString()
toString
in class Object
Object.toString()
Copyright © 2015. All rights reserved.