Package com.isomorphic.criteria
Interface Criterion
- All Known Implementing Classes:
AndCriterion,CustomCriterion,DateRangeCriterion,DoubleRangeCriterion,FloatRangeCriterion,IntegerRangeCriterion,IsBlankCriterion,IsNullCriterion,LogicalCriterion,LongRangeCriterion,NotBlankCriterion,NotCriterion,NotNullCriterion,OrCriterion,OtherFieldCriterion,RangeCriterion,RelativeDateRangeCriterion,SetCriterion,SimpleCriterion
public interface Criterion
An object representing a criterion to apply to a record.
A criterion is part of the definition of an AdvancedCriteria object, which is used to filter records according to search criteria.
A criterion consists of an operator and typically a fieldName from a Record and a value to compare to. However some operators either don't require a value (eg, isNull) or act on other criteria rather than directly on a Record's fields (eg, the "and" and "or" logical operators).
See com.isomorphic.criteria.criterion package for Criterion implementations.
-
Method Summary
Modifier and TypeMethodDescriptionGets field name to compare against.Gets fieldQuery.Gets operator id used in search criteria.getValue()Gets value used to compare to.Gets valueQuery.voidsetFieldName(String fieldName) Sets field name to compare against.voidsetFieldQuery(Map fieldQuery) Sets fieldQuery, if this is a fieldQuery criterionvoidsetOperatorId(String operator) Sets operator id to use in search criteria.voidSets value used to compare to.voidsetValueQuery(Map valueQuery) Sets valueQuery, if this is a valueQuery criterion
-
Method Details
-
getOperatorId
String getOperatorId()Gets operator id used in search criteria.- Returns:
- operator id.
-
setOperatorId
Sets operator id to use in search criteria.- Parameters:
operator- operator id.
-
getFieldName
String getFieldName()Gets field name to compare against.- Returns:
- field name.
-
setFieldName
Sets field name to compare against.- Parameters:
fieldName- field name.
-
getValue
Object getValue()Gets value used to compare to.- Returns:
- value to compare to.
-
setValue
Sets value used to compare to.- Parameters:
value- to compare to.
-
getFieldQuery
Map getFieldQuery()Gets fieldQuery. Returns null if this is not a fieldQuery criterion- Returns:
- fieldQuery.
-
setFieldQuery
Sets fieldQuery, if this is a fieldQuery criterion- Parameters:
fieldQuery- fieldQuery
-
getValueQuery
Map getValueQuery()Gets valueQuery. Returns null if this is not a valueQuery criterion- Returns:
- valueQuery
-
setValueQuery
Sets valueQuery, if this is a valueQuery criterion- Parameters:
valueQuery-
-