public class GeoJsonPolygon extends Object implements GeoJson<Iterable<GeoJsonLineString>>
GeoJson representation of a polygon. | Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object o) |
List<GeoJsonLineString> |
getCoordinates()
The value of the coordinates member is always an
Iterable. |
String |
getType()
String value representing the type of the
GeoJson object. |
int |
hashCode() |
static GeoJsonPolygon |
of(GeoJsonLineString geoJsonLineString)
Creates new
GeoJsonPolygon from the given GeoJsonLineString. |
static GeoJsonPolygon |
of(GeoPoint first,
GeoPoint second,
GeoPoint third,
GeoPoint fourth,
GeoPoint... others)
Creates new
GeoJsonPolygon from the given GeoPoints. |
static GeoJsonPolygon |
of(List<Point> points)
Creates new
GeoJsonPolygon from the given Points. |
static GeoJsonPolygon |
of(Point first,
Point second,
Point third,
Point fourth,
Point... others)
Creates new
GeoJsonPolygon from the given Points. |
static GeoJsonPolygon |
ofGeoPoints(List<GeoPoint> geoPoints)
Creates new
GeoJsonPolygon from the given GeoPoints. |
String |
toString() |
GeoJsonPolygon |
withInnerRing(GeoJsonLineString lineString)
Creates a new
GeoJsonPolygon with an inner ring defined be the given GeoJsonLineString. |
GeoJsonPolygon |
withInnerRing(GeoPoint first,
GeoPoint second,
GeoPoint third,
GeoPoint fourth,
GeoPoint... others)
Creates a new
GeoJsonPolygon with an inner ring defined be the given GeoPoints. |
GeoJsonPolygon |
withInnerRing(List<Point> points)
|
GeoJsonPolygon |
withInnerRing(Point first,
Point second,
Point third,
Point fourth,
Point... others)
Creates a new
GeoJsonPolygon with an inner ring defined be the given Points. |
GeoJsonPolygon |
withInnerRingOfGeoPoints(List<GeoPoint> geoPoints)
|
public static final String TYPE
public static GeoJsonPolygon of(GeoJsonLineString geoJsonLineString)
GeoJsonPolygon from the given GeoJsonLineString.geoJsonLineString - must not be null.public static GeoJsonPolygon of(List<Point> points)
GeoJsonPolygon from the given Points.points - must not be null.public static GeoJsonPolygon ofGeoPoints(List<GeoPoint> geoPoints)
GeoJsonPolygon from the given GeoPoints.geoPoints - must not be null.public static GeoJsonPolygon of(Point first, Point second, Point third, Point fourth, Point... others)
GeoJsonPolygon from the given Points.first - must not be null.second - must not be null.third - must not be null.fourth - must not be nullothers - can be empty.public static GeoJsonPolygon of(GeoPoint first, GeoPoint second, GeoPoint third, GeoPoint fourth, GeoPoint... others)
GeoJsonPolygon from the given GeoPoints.first - must not be null.second - must not be null.third - must not be null.fourth - must not be nullothers - can be empty.public GeoJsonPolygon withInnerRing(Point first, Point second, Point third, Point fourth, Point... others)
GeoJsonPolygon with an inner ring defined be the given Points.first - must not be null.second - must not be null.third - must not be null.fourth - must not be null.others - can be empty.GeoJsonPolygon.public GeoJsonPolygon withInnerRing(GeoPoint first, GeoPoint second, GeoPoint third, GeoPoint fourth, GeoPoint... others)
GeoJsonPolygon with an inner ring defined be the given GeoPoints.first - must not be null.second - must not be null.third - must not be null.fourth - must not be null.others - can be empty.GeoJsonPolygon.public GeoJsonPolygon withInnerRing(List<Point> points)
points - must not be null.GeoJsonPolygon.public GeoJsonPolygon withInnerRingOfGeoPoints(List<GeoPoint> geoPoints)
geoPoints - must not be null.GeoJsonPolygon.public GeoJsonPolygon withInnerRing(GeoJsonLineString lineString)
GeoJsonPolygon with an inner ring defined be the given GeoJsonLineString.lineString - must not be null.GeoJsonPolygon.public String getType()
GeoJsonGeoJson object.getType in interface GeoJson<Iterable<GeoJsonLineString>>public List<GeoJsonLineString> getCoordinates()
GeoJsonIterable. The structure for the elements within is
determined by GeoJson.getType() of geometry.getCoordinates in interface GeoJson<Iterable<GeoJsonLineString>>Copyright © 2011–2022 Pivotal Software, Inc.. All rights reserved.