java.lang.Object
org.elasticsearch.lucene.spatial.TriangleTreeVisitor.TriangleTreeDecodedVisitor
org.elasticsearch.lucene.spatial.Component2DVisitor
- All Implemented Interfaces:
TriangleTreeVisitor
A
TriangleTreeVisitor.TriangleTreeDecodedVisitor implementation for Component2D geometries.
It can solve spatial relationships against a serialize triangle tree.-
Nested Class Summary
Nested classes/interfaces inherited from interface org.elasticsearch.lucene.spatial.TriangleTreeVisitor
TriangleTreeVisitor.TriangleTreeDecodedVisitor -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionstatic Component2DVisitorgetVisitor(org.apache.lucene.geo.Component2D component2D, org.apache.lucene.document.ShapeField.QueryRelation relation, CoordinateEncoder encoder) Creates a visitor from the provided Component2D and spatial relationship.abstract booleanmatches()If the relationship has been honour.protected booleanpushDecoded(double maxX, double maxY) Equivalent toTriangleTreeVisitor.TriangleTreeDecodedVisitor.push(int, int)but coordinates are decoded.protected booleanpushDecoded(double minX, double minY, double maxX, double maxY) Equivalent toTriangleTreeVisitor.TriangleTreeDecodedVisitor.push(int, int, int, int)but coordinates are decoded.protected abstract booleanpushDecoded(org.apache.lucene.index.PointValues.Relation relation) Relation between the query shape and the doc value bounding box.protected booleanpushDecodedX(double minX) Equivalent toTriangleTreeVisitor.TriangleTreeDecodedVisitor.pushX(int)but coordinates are decoded.protected booleanpushDecodedY(double minY) Equivalent toTriangleTreeVisitor.TriangleTreeDecodedVisitor.pushY(int)but coordinates are decoded.abstract voidreset()Reset the visitor to the initial state.Methods inherited from class org.elasticsearch.lucene.spatial.TriangleTreeVisitor.TriangleTreeDecodedVisitor
push, push, pushX, pushY, visitDecodedLine, visitDecodedPoint, visitDecodedTriangle, visitLine, visitPoint, visitTriangleMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.elasticsearch.lucene.spatial.TriangleTreeVisitor
push
-
Field Details
-
component2D
protected final org.apache.lucene.geo.Component2D component2D
-
-
Method Details
-
matches
public abstract boolean matches()If the relationship has been honour. -
reset
public abstract void reset()Reset the visitor to the initial state. -
pushDecodedX
protected boolean pushDecodedX(double minX) Description copied from class:TriangleTreeVisitor.TriangleTreeDecodedVisitorEquivalent toTriangleTreeVisitor.TriangleTreeDecodedVisitor.pushX(int)but coordinates are decoded.- Specified by:
pushDecodedXin classTriangleTreeVisitor.TriangleTreeDecodedVisitor
-
pushDecodedY
protected boolean pushDecodedY(double minY) Description copied from class:TriangleTreeVisitor.TriangleTreeDecodedVisitorEquivalent toTriangleTreeVisitor.TriangleTreeDecodedVisitor.pushY(int)but coordinates are decoded.- Specified by:
pushDecodedYin classTriangleTreeVisitor.TriangleTreeDecodedVisitor
-
pushDecoded
protected boolean pushDecoded(double maxX, double maxY) Description copied from class:TriangleTreeVisitor.TriangleTreeDecodedVisitorEquivalent toTriangleTreeVisitor.TriangleTreeDecodedVisitor.push(int, int)but coordinates are decoded.- Specified by:
pushDecodedin classTriangleTreeVisitor.TriangleTreeDecodedVisitor
-
pushDecoded
protected boolean pushDecoded(double minX, double minY, double maxX, double maxY) Description copied from class:TriangleTreeVisitor.TriangleTreeDecodedVisitorEquivalent toTriangleTreeVisitor.TriangleTreeDecodedVisitor.push(int, int, int, int)but coordinates are decoded.- Specified by:
pushDecodedin classTriangleTreeVisitor.TriangleTreeDecodedVisitor
-
pushDecoded
protected abstract boolean pushDecoded(org.apache.lucene.index.PointValues.Relation relation) Relation between the query shape and the doc value bounding box. Depending on the query relationship, decide if we should traverse the tree.- Returns:
- if true, the visitor keeps traversing the tree, else it stops.
-
getVisitor
public static Component2DVisitor getVisitor(org.apache.lucene.geo.Component2D component2D, org.apache.lucene.document.ShapeField.QueryRelation relation, CoordinateEncoder encoder) Creates a visitor from the provided Component2D and spatial relationship. Visitors are re-usable by calling thereset()method.
-