LatLonShape

A geo shape utility class for indexing and searching GIS geometries whose vertices are latitude, longitude values (in decimal degrees).

This class defines static factory methods for common indexing and search operations:

WARNING: Like LatLonPoint, vertex values are indexed with some loss of precision from the original Double values.

Functions

Link copied to clipboard
fun createDocValueField(fieldName: String, indexableFields: Array<Field>): LatLonShapeDocValuesField

create a shape docvalue field from indexable fields

create a LatLonShapeDocValuesField from an existing tessellation

create doc value field for lat lon line geometry without creating indexable fields.

create doc value field for lat lon polygon geometry without creating indexable fields

create a LatLonShapeDocValuesField from an existing encoded representation

create doc value field for lat lon point geometry without creating indexable fields.

fun createDocValueField(fieldName: String, polygon: Polygon, checkSelfIntersections: Boolean): LatLonShapeDocValuesField

create doc value field for lat lon polygon geometry without creating indexable fields.

Link copied to clipboard
fun createIndexableFields(fieldName: String, line: Line): Array<Field>

create indexable fields for line geometry

fun createIndexableFields(fieldName: String, polygon: Polygon): Array<Field>

create indexable fields for polygon geometry.

fun createIndexableFields(fieldName: String, lat: Double, lon: Double): Array<Field>

create indexable fields for point geometry

fun createIndexableFields(fieldName: String, polygon: Polygon, checkSelfIntersections: Boolean): Array<Field>

create indexable fields for polygon geometry. If checkSelfIntersections is set to true, the validity of the provided polygon is checked with a small performance penalty.

Link copied to clipboard
Link copied to clipboard
fun newBoxQuery(field: String, queryRelation: ShapeField.QueryRelation, minLatitude: Double, maxLatitude: Double, minLongitude: Double, maxLongitude: Double): Query

create a query to find all indexed geo shapes that intersect a defined bounding box

Link copied to clipboard
fun newDistanceQuery(field: String, queryRelation: ShapeField.QueryRelation, vararg circle: Circle): Query

create a query to find all polygons that intersect a provided circle.

Link copied to clipboard
fun newGeometryQuery(field: String, queryRelation: ShapeField.QueryRelation, vararg latLonGeometries: LatLonGeometry): Query

create a query for geometries.

Link copied to clipboard
fun newLineQuery(field: String, queryRelation: ShapeField.QueryRelation, vararg lines: Line): Query

create a query to find all indexed geo shapes that intersect a provided linestring (or array of linestrings) note: does not support dateline crossing

Link copied to clipboard
fun newPointQuery(field: String, queryRelation: ShapeField.QueryRelation, vararg points: DoubleArray): Query

create a query to find all indexed shapes that comply the QueryRelation with the provided points

Link copied to clipboard
fun newPolygonQuery(field: String, queryRelation: ShapeField.QueryRelation, vararg polygons: Polygon): Query

create a query to find all indexed geo shapes that intersect a provided polygon (or array of polygons) note: does not support dateline crossing

Link copied to clipboard
fun newSlowDocValuesBoxQuery(field: String, queryRelation: ShapeField.QueryRelation, minLatitude: Double, maxLatitude: Double, minLongitude: Double, maxLongitude: Double): Query

create a docvalue query to find all geo shapes that intersect a defined bounding box