Package dev.morphia.geo
Class GeoJson
- java.lang.Object
-
- dev.morphia.geo.GeoJson
-
@Deprecated(since="2.0", forRemoval=true) public final class GeoJson extends Object
Deprecated, for removal: This API element is subject to removal in a future version.use the driver-provided types insteadFactory class for creating GeoJSON types. See the documentation for all the types.
-
-
Method Summary
All Methods Static Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static List<List<Position>>convertLineStrings(List<LineString> values)Deprecated, for removal: This API element is subject to removal in a future version.static List<Position>convertPoints(List<Point> values)Deprecated, for removal: This API element is subject to removal in a future version.static GeometryCollectiongeometryCollection(Geometry... geometries)Deprecated, for removal: This API element is subject to removal in a future version.Return a GeometryCollection that will let you create a GeoJSON GeometryCollection.static LineStringlineString(Point... points)Deprecated, for removal: This API element is subject to removal in a future version.Create a new LineString representing a GeoJSON LineString type.static MultiLineStringmultiLineString(LineString... lines)Deprecated, for removal: This API element is subject to removal in a future version.Create a new MultiLineString representing a GeoJSON MultiLineString type.static MultiPointmultiPoint(Point... points)Deprecated, for removal: This API element is subject to removal in a future version.Create a new MultiPoint representing a GeoJSON MultiPoint type.static MultiPolygonmultiPolygon(Polygon... polygons)Deprecated, for removal: This API element is subject to removal in a future version.Create a new MultiPolygon representing a GeoJSON MultiPolygon type.static Polygonpolygon(LineString exteriorBoundary, LineString... interiorBoundaries)Deprecated, for removal: This API element is subject to removal in a future version.Lets you create a Polygon representing a GeoJSON Polygon type.static Polygonpolygon(Point... points)Deprecated, for removal: This API element is subject to removal in a future version.Create a new Polygon representing a GeoJSON Polygon type.
-
-
-
Method Detail
-
polygon
public static Polygon polygon(Point... points)
Deprecated, for removal: This API element is subject to removal in a future version.Create a new Polygon representing a GeoJSON Polygon type. This helper method usespolygon(LineString, LineString...)to create the Polygon. If you need to create Polygons with interior rings (holes), use that method.- Parameters:
points- an ordered series of Points that make up the polygon. The first and last points should be the same to close the polygon- Returns:
- a Polygon as defined by the points.
- Throws:
IllegalArgumentException- if the start and end points are not the same- See Also:
polygon(LineString, LineString...), GeoJSON- Since server release
- 2.4
-
lineString
public static LineString lineString(Point... points)
Deprecated, for removal: This API element is subject to removal in a future version.Create a new LineString representing a GeoJSON LineString type.
-
polygon
public static Polygon polygon(LineString exteriorBoundary, LineString... interiorBoundaries)
Deprecated, for removal: This API element is subject to removal in a future version.Lets you create a Polygon representing a GeoJSON Polygon type. This method is especially useful for defining polygons with inner rings.- Parameters:
exteriorBoundary- a LineString that contains a series of Points that make up the polygon. The first and last points should be the same to close the polygoninteriorBoundaries- optional varargs that let you define the boundaries for any holes inside the polygon- Returns:
- a PolygonBuilder to be used to build up the required Polygon
- Throws:
IllegalArgumentException- if the start and end points are not the same- See Also:
- GeoJSON
- Since server release
- 2.4
-
multiPoint
public static MultiPoint multiPoint(Point... points)
Deprecated, for removal: This API element is subject to removal in a future version.Create a new MultiPoint representing a GeoJSON MultiPoint type.
-
multiLineString
public static MultiLineString multiLineString(LineString... lines)
Deprecated, for removal: This API element is subject to removal in a future version.Create a new MultiLineString representing a GeoJSON MultiLineString type.
-
multiPolygon
public static MultiPolygon multiPolygon(Polygon... polygons)
Deprecated, for removal: This API element is subject to removal in a future version.Create a new MultiPolygon representing a GeoJSON MultiPolygon type.
-
geometryCollection
public static GeometryCollection geometryCollection(Geometry... geometries)
Deprecated, for removal: This API element is subject to removal in a future version.Return a GeometryCollection that will let you create a GeoJSON GeometryCollection.
-
convertPoints
@MorphiaInternal public static List<Position> convertPoints(List<Point> values)
Deprecated, for removal: This API element is subject to removal in a future version.- Parameters:
values- the values to convert- Returns:
- the converted values
Developer note.This is an internal item. Its function and presence are subject to change without warning. Its use is highly discouraged.
-
convertLineStrings
@MorphiaInternal public static List<List<Position>> convertLineStrings(List<LineString> values)
Deprecated, for removal: This API element is subject to removal in a future version.- Parameters:
values- the values to convert- Returns:
- the converted values
Developer note.This is an internal item. Its function and presence are subject to change without warning. Its use is highly discouraged.
-
-