public class ShapeValuesPredicate extends Object implements SegmentCacheable
ShapeValuesSource with a given Shape and sees
if it matches a given SpatialOperation (the predicate).
Consumers should call iterator(LeafReaderContext, DocIdSetIterator) to obtain a
TwoPhaseIterator over a particular DocIdSetIterator. The initial DocIdSetIterator
will be used as the approximation, and the SpatialOperation comparison will only be
performed in TwoPhaseIterator.matches()| Constructor and Description |
|---|
ShapeValuesPredicate(ShapeValuesSource shapeValuesource,
SpatialOperation op,
org.locationtech.spatial4j.shape.Shape queryShape) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object o) |
int |
hashCode() |
boolean |
isCacheable(LeafReaderContext ctx) |
TwoPhaseIterator |
iterator(LeafReaderContext ctx,
DocIdSetIterator approximation) |
String |
toString() |
public ShapeValuesPredicate(ShapeValuesSource shapeValuesource, SpatialOperation op, org.locationtech.spatial4j.shape.Shape queryShape)
shapeValuesource - Must yield Shape instances from its objectVal(doc). If null
then the result is false. This is the left-hand (indexed) side.op - the predicatequeryShape - The shape on the right-hand (query) side.public TwoPhaseIterator iterator(LeafReaderContext ctx, DocIdSetIterator approximation) throws IOException
IOExceptionpublic boolean isCacheable(LeafReaderContext ctx)
isCacheable in interface SegmentCacheableCopyright © 2000-2024 Apache Software Foundation. All Rights Reserved.