public class MultiPolygon extends GeometryCollection
GeometryCollection
that contains only Polygon
s.geometries, points
Constructor and Description |
---|
MultiPolygon(Polygon[] polygons)
Constructs a
MultiPolygon from the specified array of Polygon s. |
Modifier and Type | Method and Description |
---|---|
double |
area()
Returns the sum of the areas of all element
Polygon s. |
Point |
centroid()
Returns the mathematical centroid for this
MultiPolygon . |
static MultiPolygon |
createEmpty()
Constructs an empty
MultiPolygon . |
Polygon |
getGeometryN(int num)
Returns the
Geometry element at the specified (zero-based) position in this GeometryCollection . |
GeometryType |
getGeometryType()
Returns the type of this
Geometry . |
Point |
pointOnSurface()
Returns a
Point guaranteed to be on this MultiPolygon . |
accept, getDimension, getNumGeometries, getPoints, iterator
asBinary, asText, buffer, collectPointSets, contains, convexHull, crosses, difference, disjoint, distance, equals, getBoundary, getCoordinateDimension, getCrsId, getCrsId, getDimensionalFlag, getEnvelope, getGeometryOperations, getGeometryOperations, getNumPoints, getPointN, getSRID, hashCode, intersection, intersects, is3D, isEmpty, isMeasured, isSimple, locateAlong, locateBetween, overlaps, relate, symDifference, toString, touches, union, within
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
forEach, spliterator
public MultiPolygon(Polygon[] polygons)
MultiPolygon
from the specified array of Polygon
s.polygons
- the element Polygon
s for the constructed MultiPolygon
public static MultiPolygon createEmpty()
MultiPolygon
.MultiPolygon
.public Polygon getGeometryN(int num)
GeometryCollection
Geometry
element at the specified (zero-based) position in this GeometryCollection
.getGeometryN
in class GeometryCollection
num
- the position in the collection of the requested Geometry
Geometry
at the position specified by the num parameter.public double area()
Polygon
s.Polygon
s.public Point centroid()
MultiPolygon
.MultiPolygon
.public Point pointOnSurface()
Point
guaranteed to be on this MultiPolygon
.Point
guaranteed to be on this MultiPolygon
.public GeometryType getGeometryType()
Geometry
Geometry
.getGeometryType
in class GeometryCollection
GeometryType
of this instance.Copyright © 2015 geolatte.org. All rights reserved.