DocValuesRangeQuery
instead@Deprecated public abstract class DocTermOrdsRangeFilter extends Filter
LeafReader.getSortedSetDocValues(java.lang.String)
).
Like DocValuesRangeFilter
, this is just a specialized range query versus
using a TermRangeQuery with DocValuesRewriteMethod
: it will only do
two ordinal to term lookups.
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object o)
Deprecated.
|
abstract DocIdSet |
getDocIdSet(LeafReaderContext context,
Bits acceptDocs)
Deprecated.
This method is implemented for each data type
|
String |
getField()
Deprecated.
Returns the field name for this filter
|
BytesRef |
getLowerVal()
Deprecated.
Returns the lower value of this range filter
|
BytesRef |
getUpperVal()
Deprecated.
Returns the upper value of this range filter
|
int |
hashCode()
Deprecated.
|
boolean |
includesLower()
Deprecated.
Returns
true if the lower endpoint is inclusive |
boolean |
includesUpper()
Deprecated.
Returns
true if the upper endpoint is inclusive |
static DocTermOrdsRangeFilter |
newBytesRefRange(String field,
BytesRef lowerVal,
BytesRef upperVal,
boolean includeLower,
boolean includeUpper)
Deprecated.
Creates a BytesRef range filter using
LeafReader.getSortedSetDocValues(java.lang.String) . |
String |
toString(String defaultField)
Deprecated.
Prints a query to a string, with
field assumed to be the
default field and omitted. |
createWeight
public abstract DocIdSet getDocIdSet(LeafReaderContext context, Bits acceptDocs) throws IOException
getDocIdSet
in class Filter
context
- a LeafReaderContext
instance opened on the index currently
searched on. Note, it is likely that the provided reader info does not
represent the whole underlying index i.e. if the index has more than
one segment the given reader only represents a single segment.
The provided context is always an atomic context, so you can call
LeafReader.fields()
on the context's reader, for example.acceptDocs
- Bits that represent the allowable docs to match (typically deleted docs
but possibly filtering other documents)null
should be returned if
the filter doesn't accept any documents otherwise internal optimization might not apply
in the case an empty DocIdSet
is returned.IOException
public static DocTermOrdsRangeFilter newBytesRefRange(String field, BytesRef lowerVal, BytesRef upperVal, boolean includeLower, boolean includeUpper)
LeafReader.getSortedSetDocValues(java.lang.String)
. This works with all
fields containing zero or one term in the field. The range can be half-open by setting one
of the values to null
.public final String toString(String defaultField)
Query
field
assumed to be the
default field and omitted.public String getField()
public boolean includesLower()
true
if the lower endpoint is inclusivepublic boolean includesUpper()
true
if the upper endpoint is inclusivepublic BytesRef getLowerVal()
public BytesRef getUpperVal()
Copyright © 2000-2015 Apache Software Foundation. All Rights Reserved.