Class PolygonHandler
java.lang.Object
org.geotools.shapefile.PolygonHandler
- All Implemented Interfaces:
ShapeHandler
Wrapper for a Shapefile Polygon.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.locationtech.jts.geom.GeometrygetEmptyGeometry(org.locationtech.jts.geom.GeometryFactory factory) Return a empty geometry.intgetLength(org.locationtech.jts.geom.Geometry geometry) intReturns one of the ShapeType int defined by the specification.org.locationtech.jts.geom.Geometryread(EndianDataInputStream file, org.locationtech.jts.geom.GeometryFactory geometryFactory, int contentLength) voidwrite(org.locationtech.jts.geom.Geometry geometry, EndianDataOutputStream file)
-
Constructor Details
-
PolygonHandler
public PolygonHandler() -
PolygonHandler
- Throws:
InvalidShapefileException
-
-
Method Details
-
read
public org.locationtech.jts.geom.Geometry read(EndianDataInputStream file, org.locationtech.jts.geom.GeometryFactory geometryFactory, int contentLength) throws IOException, InvalidShapefileException - Specified by:
readin interfaceShapeHandler- Throws:
IOExceptionInvalidShapefileException
-
write
public void write(org.locationtech.jts.geom.Geometry geometry, EndianDataOutputStream file) throws IOException - Specified by:
writein interfaceShapeHandler- Throws:
IOException
-
getShapeType
public int getShapeType()Description copied from interface:ShapeHandlerReturns one of the ShapeType int defined by the specification.- 0 Null Shape
- 1 Point
- 3 PolyLine
- 5 Polygon
- 8 MultiPoint
- 11 PointZ
- 13 PolyLineZ
- 15 PolygonZ
- 18 MultiPointZ
- 21 PointM
- 23 PolyLineM
- 25 PolygonM
- 28 MultiPointM
- 31 MultiPatch
- Specified by:
getShapeTypein interfaceShapeHandler
-
getLength
public int getLength(org.locationtech.jts.geom.Geometry geometry) - Specified by:
getLengthin interfaceShapeHandler
-
getEmptyGeometry
public org.locationtech.jts.geom.Geometry getEmptyGeometry(org.locationtech.jts.geom.GeometryFactory factory) Return a empty geometry.- Specified by:
getEmptyGeometryin interfaceShapeHandler
-