public class Polygon extends MultiPath implements Serializable
| Modifier and Type | Class and Description |
|---|---|
static interface |
Polygon.FillRule |
Geometry.GeometryAccelerationDegree, Geometry.GeometryType, Geometry.Type| Constructor and Description |
|---|
Polygon()
Creates a polygon.
|
Polygon(VertexDescription vd) |
| Modifier and Type | Method and Description |
|---|---|
double |
calculateRingArea2D(int ringIndex)
Calculates the ring area for this ring.
|
Geometry |
createInstance()
Creates an instance of an empty geometry of the same type.
|
boolean |
equals(Object other)
Returns TRUE when this geometry has exactly same type, properties, and
coordinates as the other geometry.
|
long |
estimateMemorySize()
Returns an estimate of this object size in bytes.
|
int |
getDimension()
Returns the topological dimension of the geometry object based on the
geometry's type.
|
int |
getExteriorRingCount() |
int |
getFillRule()
Fill rule for the polygon that defines the interior of the self intersecting
polygon.
|
Geometry.Type |
getType()
Returns the geometry type.
|
int |
hashCode()
Returns a hash code value for this polygon.
|
void |
interpolateAttributes(int path_index,
int from_point_index,
int to_point_index) |
void |
interpolateAttributes(int semantics,
int path_index,
int from_point_index,
int to_point_index) |
boolean |
isExteriorRing(int partIndex)
Returns TRUE if the ring is an exterior ring.
|
void |
setFillRule(int rule)
Fill rule for the polygon that defines the interior of the self intersecting
polygon.
|
void |
setXY(int i,
double x,
double y)
Sets a new vertex for the polygon.
|
_getImpl, add, addAttribute, addEnvelope, addEnvelope, addPath, addSegment, addSegmentsFromPath, applyTransformation, assignVertexDescription, calculateArea2D, calculateLength2D, calculatePathLength2D, closeAllPaths, closePathWithLine, copyTo, dropAllAttributes, dropAttribute, getAttributeAsDbl, getAttributeAsInt, getBoundary, getDescription, getPathCount, getPathEnd, getPathIndexFromPointIndex, getPathSize, getPathStart, getPoint, getPointByVal, getPointCount, getSegmentCount, getSegmentCount, getStateFlag, getXY, getXY, insertPath, insertPoint, insertPoints, isClosedPath, isClosedPathInXYPlane, isEmpty, lineTo, lineTo, mergeVertexDescription, queryCoordinates, queryCoordinates, queryCoordinates, queryEnvelope, queryEnvelope2D, queryInterval, queryLooseEnvelope, queryPathEnvelope2D, querySegmentIterator, querySegmentIteratorAtVertex, removePath, removePoint, replaceNaNs, reverseAllPaths, reversePath, setAttribute, setAttribute, setEmpty, setPoint, setPointByVal, setXY, startPath, startPath_assignVertexDescriptionImpl, getCoordinates2D, getPointaddID, addM, copy, estimateMemorySize, getDimensionFromType, hasAttribute, hasID, hasM, hasZ, isArea, isLinear, isMultiPath, isMultiVertex, isPoint, isSegment, queryLooseEnvelope2D, toString, vertex_countpublic Polygon()
public Polygon(VertexDescription vd)
public Geometry createInstance()
GeometrycreateInstance in class Geometrypublic int getDimension()
GeometryReturns 0 for point and multipoint.
Returns 1 for lines and polylines.
Returns 2 for polygons and envelopes
Returns 3 for objects with volume
getDimension in class Geometrypublic Geometry.Type getType()
Geometrypublic long estimateMemorySize()
Geometry
This estimate doesn't include the size of the VertexDescription object
because instances of VertexDescription are shared among
geometry objects.
estimateMemorySize in class Geometrypublic double calculateRingArea2D(int ringIndex)
ringIndex - The index of this ring.public boolean isExteriorRing(int partIndex)
public boolean equals(Object other)
public int hashCode()
public void setXY(int i,
double x,
double y)
i - The index of the new vertex.x - The X coordinate for the new vertex.y - The Y coordinate for the new vertex.public void interpolateAttributes(int path_index,
int from_point_index,
int to_point_index)
public void interpolateAttributes(int semantics,
int path_index,
int from_point_index,
int to_point_index)
public int getExteriorRingCount()
public void setFillRule(int rule)
public int getFillRule()
Copyright © 2018. All rights reserved.