java.lang.Object
org.apache.lucene.search.Query
org.apache.lucene.document.SpatialQuery
org.apache.lucene.document.LatLonPointQuery
Finds all previously indexed geo points that comply the given
ShapeField.QueryRelation with the
specified array of LatLonGeometry.
The field must be indexed using one or more LatLonPoint added per document.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.lucene.document.SpatialQuery
SpatialQuery.EncodedRectangle, SpatialQuery.SpatialVisitor -
Field Summary
Fields inherited from class org.apache.lucene.document.SpatialQuery
field, geometries, queryComponent2D, queryRelation -
Constructor Summary
ConstructorsConstructorDescriptionLatLonPointQuery(String field, ShapeField.QueryRelation queryRelation, LatLonGeometry... geometries) Creates a query that matches all indexed shapes to the provided array ofLatLonGeometry -
Method Summary
Modifier and TypeMethodDescriptionprotected Component2DcreateComponent2D(Geometry... geometries) protected booleanclass specific equals checkprotected SpatialQuery.SpatialVisitorreturns the spatial visitor to be used for this query.inthashCode()Override and implement query hash code properly in a subclass.Prints a query to a string, withfieldassumed to be the default field and omitted.private static LatLonGeometry[]validateGeometry(ShapeField.QueryRelation queryRelation, LatLonGeometry... geometries) Methods inherited from class org.apache.lucene.document.SpatialQuery
createWeight, equals, getField, getQueryRelation, getScorerSupplier, queryIsCacheable, transposeRelation, visit
-
Constructor Details
-
LatLonPointQuery
LatLonPointQuery(String field, ShapeField.QueryRelation queryRelation, LatLonGeometry... geometries) Creates a query that matches all indexed shapes to the provided array ofLatLonGeometry
-
-
Method Details
-
validateGeometry
private static LatLonGeometry[] validateGeometry(ShapeField.QueryRelation queryRelation, LatLonGeometry... geometries) -
createComponent2D
- Specified by:
createComponent2Din classSpatialQuery
-
getSpatialVisitor
Description copied from class:SpatialQueryreturns the spatial visitor to be used for this query. Called before generating the queryWeight- Specified by:
getSpatialVisitorin classSpatialQuery
-
toString
Description copied from class:QueryPrints a query to a string, withfieldassumed to be the default field and omitted.- Overrides:
toStringin classSpatialQuery
-
equalsTo
Description copied from class:SpatialQueryclass specific equals check- Overrides:
equalsToin classSpatialQuery
-
hashCode
public int hashCode()Description copied from class:QueryOverride and implement query hash code properly in a subclass. This is required so thatQueryCacheworks properly.- Overrides:
hashCodein classSpatialQuery- See Also:
-