| java.lang.Object org.apache.lucene.search.Filter org.apache.lucene.search.RangeFilter
RangeFilter | public class RangeFilter extends Filter (Code) | | A Filter that restricts search results to a range of values in a given
field.
This code borrows heavily from
RangeQuery , but is implemented as a Filter
|
Method Summary | |
public static RangeFilter | Less(String fieldName, String upperTerm) Constructs a filter for field fieldName matching
less than or equal to upperTerm . | public static RangeFilter | More(String fieldName, String lowerTerm) Constructs a filter for field fieldName matching
greater than or equal to lowerTerm . | public BitSet | bits(IndexReader reader) Returns a BitSet with true for documents which should be
permitted in search results, and false for those that should
not. | public boolean | equals(Object o) Returns true if o is equal to this. | public int | hashCode() Returns a hash code value for this object. | public String | toString() |
RangeFilter | public RangeFilter(String fieldName, String lowerTerm, String upperTerm, boolean includeLower, boolean includeUpper)(Code) | | Parameters: fieldName - The field this range applies to Parameters: lowerTerm - The lower bound on this range Parameters: upperTerm - The upper bound on this range Parameters: includeLower - Does this range include the lower bound? Parameters: includeUpper - Does this range include the upper bound? throws: IllegalArgumentException - if both terms are null or iflowerTerm is null and includeLower is true (similar for upperTermand includeUpper) |
Less | public static RangeFilter Less(String fieldName, String upperTerm)(Code) | | Constructs a filter for field fieldName matching
less than or equal to upperTerm .
|
More | public static RangeFilter More(String fieldName, String lowerTerm)(Code) | | Constructs a filter for field fieldName matching
greater than or equal to lowerTerm .
|
bits | public BitSet bits(IndexReader reader) throws IOException(Code) | | Returns a BitSet with true for documents which should be
permitted in search results, and false for those that should
not.
|
equals | public boolean equals(Object o)(Code) | | Returns true if o is equal to this.
|
hashCode | public int hashCode()(Code) | | Returns a hash code value for this object.
|
|
|