org.geotools.shapefile
Class PointHandler

java.lang.Object
  extended by org.geotools.shapefile.PointHandler
All Implemented Interfaces:
ShapeHandler

public class PointHandler
extends java.lang.Object
implements ShapeHandler

Wrapper for a Shapefile point.


Constructor Summary
PointHandler()
           
PointHandler(int type)
           
 
Method Summary
 int getLength(com.vividsolutions.jts.geom.Geometry geometry)
          Calcuates the record length of this object.
 int getShapeType()
          Returns the shapefile shape type value for a point
 com.vividsolutions.jts.geom.Geometry read(EndianDataInputStream file, com.vividsolutions.jts.geom.GeometryFactory geometryFactory, int contentLength)
           
 void write(com.vividsolutions.jts.geom.Geometry geometry, EndianDataOutputStream file)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PointHandler

public PointHandler(int type)
             throws InvalidShapefileException
Throws:
InvalidShapefileException

PointHandler

public PointHandler()
Method Detail

read

public com.vividsolutions.jts.geom.Geometry read(EndianDataInputStream file,
                                                 com.vividsolutions.jts.geom.GeometryFactory geometryFactory,
                                                 int contentLength)
                                          throws java.io.IOException,
                                                 InvalidShapefileException
Specified by:
read in interface ShapeHandler
Throws:
java.io.IOException
InvalidShapefileException

write

public void write(com.vividsolutions.jts.geom.Geometry geometry,
                  EndianDataOutputStream file)
           throws java.io.IOException
Specified by:
write in interface ShapeHandler
Throws:
java.io.IOException

getShapeType

public int getShapeType()
Returns the shapefile shape type value for a point

Specified by:
getShapeType in interface ShapeHandler
Returns:
int Shapefile.POINT

getLength

public int getLength(com.vividsolutions.jts.geom.Geometry geometry)
Calcuates the record length of this object.

Specified by:
getLength in interface ShapeHandler
Returns:
int The length of the record that this shapepoint will take up in a shapefile