public class ReturnClassFilter extends java.lang.Object implements Filter<EntityQuery>
EntityQuery
are compatible
with the specified class. Intended to be used
with a conditiona restriction or expression as
created by Restrictions.conditionalRestriction(Filter, Restriction, Restriction, boolean)
and Expressions.conditionalExpression(Filter, Expression, Expression)
Modifier and Type | Field and Description |
---|---|
private java.lang.Class<?> |
returnClass |
Constructor and Description |
---|
ReturnClassFilter(java.lang.Class<?> returnClass)
Creates a filter that matches the specified item class.
|
Modifier and Type | Method and Description |
---|---|
boolean |
evaluate(EntityQuery query)
Returns TRUE if the
EntityQuery.getItemType() returns
an item type whose Item.getItemClass() is compatible with
the specified class. |
public ReturnClassFilter(java.lang.Class<?> returnClass)
public boolean evaluate(EntityQuery query)
EntityQuery.getItemType()
returns
an item type whose Item.getItemClass()
is compatible with
the specified class.evaluate
in interface Filter<EntityQuery>
query
- The object to evaluate