Package net.sf.ehcache.search.expression
Class Between
- java.lang.Object
-
- net.sf.ehcache.search.expression.BaseCriteria
-
- net.sf.ehcache.search.expression.ComparableValue
-
- net.sf.ehcache.search.expression.Between
-
- All Implemented Interfaces:
Criteria
public class Between extends ComparableValue
Range criteria- Author:
- teck
-
-
Constructor Summary
Constructors Constructor Description Between(java.lang.String attributeName, java.lang.Object min, java.lang.Object max, boolean minInclusive, boolean maxInclusive)Constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected booleanexecuteComparable(java.lang.Comparable attributeValue)Execute this criteria for the givenComparableattribute valueprotected booleanexecuteComparableString(java.lang.Comparable attributeValue)Execute this criteria for the givenComparablestrin type attribute valuejava.lang.ComparablegetMax()Get the maximum valuejava.lang.ComparablegetMin()Get the minimum valuebooleanisMaxInclusive()booleanisMinInclusive()-
Methods inherited from class net.sf.ehcache.search.expression.ComparableValue
execute, getAttributeName, getAttributes, getType, luceneStringCompare
-
Methods inherited from class net.sf.ehcache.search.expression.BaseCriteria
and, getExtractor, not, or
-
-
-
-
Constructor Detail
-
Between
public Between(java.lang.String attributeName, java.lang.Object min, java.lang.Object max, boolean minInclusive, boolean maxInclusive)Constructor- Parameters:
attributeName- attribute namemin- minimum value of rangemax- maximum value of rangeminInclusive- is minimum inclusive?maxInclusive- is maximum inclusive?
-
-
Method Detail
-
getMin
public java.lang.Comparable getMin()
Get the minimum value- Returns:
- min value
-
getMax
public java.lang.Comparable getMax()
Get the maximum value- Returns:
- max value
-
isMinInclusive
public boolean isMinInclusive()
- Returns:
- true if the min is included in range
-
isMaxInclusive
public boolean isMaxInclusive()
- Returns:
- true if the max is included in range
-
executeComparable
protected boolean executeComparable(java.lang.Comparable attributeValue)
Execute this criteria for the givenComparableattribute value- Specified by:
executeComparablein classComparableValue- Parameters:
attributeValue- Comparable attribute value- Returns:
- true if criteria is met
-
executeComparableString
protected boolean executeComparableString(java.lang.Comparable attributeValue)
Execute this criteria for the givenComparablestrin type attribute value- Specified by:
executeComparableStringin classComparableValue- Parameters:
attributeValue- Comparable attribute value- Returns:
- true if criteria is met
-
-