org.opengts.extra.shapefile
Class Shape

java.lang.Object
  extended by org.opengts.extra.shapefile.Shape

public class Shape
extends java.lang.Object


Field Summary
static int MAX_SHAPE_SIZE
           
static int PARTTYPE_FIRST_RING
           
static int PARTTYPE_INNER_RING
           
static int PARTTYPE_OUTER_RING
           
static int PARTTYPE_RING
           
static int PARTTYPE_TRIANGLE_FAN
           
static int PARTTYPE_TRIANGLE_STRIP
           
static int SHAPETYPE_MULTIPATCH
           
static int SHAPETYPE_MULTIPOINT
           
static int SHAPETYPE_MULTIPOINT_M
           
static int SHAPETYPE_MULTIPOINT_Z
           
static int SHAPETYPE_NULL
           
static int SHAPETYPE_POINT
           
static int SHAPETYPE_POINT_M
           
static int SHAPETYPE_POINT_Z
           
static int SHAPETYPE_POLYGON
           
static int SHAPETYPE_POLYGON_M
           
static int SHAPETYPE_POLYGON_Z
           
static int SHAPETYPE_POLYLINE
           
static int SHAPETYPE_POLYLINE_M
           
static int SHAPETYPE_POLYLINE_Z
           
static int SHAPETYPE_UNDEFINED
           
 
Constructor Summary
Shape(int rcdNdx, GeoPoint gp)
          Constructor Initialize with single GeoPoint
Shape(int rcdNdx, GeoPolygon gp)
          Constructor Initialize with single GeoPolygon
Shape(int rcdNdx, int type, BoundingBox bb, Point[] pp, int[] parts, int[] partTypes, Range mRange, Range zRange)
           
Shape(Payload p)
           
Shape(Shape s)
           
 
Method Summary
protected  byte[] createShapeBytes()
           
protected  Payload createShapePayload(boolean saveData)
           
 BoundingBox getBoundingBox()
           
 GeoPolygon[] getPolygons()
           
 int getRecordIndex()
           
 int getShapeLength()
           
 Range getShapeMRange()
           
 int[] getShapeParts()
           
 int[] getShapePartTypes()
           
 Point[] getShapePoints()
           
 int getShapeType()
           
static java.lang.String GetShapeTypeDescription(int shapeType)
           
 Range getShapeZRange()
           
 java.lang.String toString()
           
 java.lang.String toString(java.lang.StringBuffer sb)
          Returns a String representation of this instance
 int writeShape(Payload p, int rcdNdx)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

MAX_SHAPE_SIZE

public static final int MAX_SHAPE_SIZE
See Also:
Constant Field Values

SHAPETYPE_UNDEFINED

public static final int SHAPETYPE_UNDEFINED
See Also:
Constant Field Values

SHAPETYPE_NULL

public static final int SHAPETYPE_NULL
See Also:
Constant Field Values

SHAPETYPE_POINT

public static final int SHAPETYPE_POINT
See Also:
Constant Field Values

SHAPETYPE_POLYLINE

public static final int SHAPETYPE_POLYLINE
See Also:
Constant Field Values

SHAPETYPE_POLYGON

public static final int SHAPETYPE_POLYGON
See Also:
Constant Field Values

SHAPETYPE_MULTIPOINT

public static final int SHAPETYPE_MULTIPOINT
See Also:
Constant Field Values

SHAPETYPE_POINT_Z

public static final int SHAPETYPE_POINT_Z
See Also:
Constant Field Values

SHAPETYPE_POLYLINE_Z

public static final int SHAPETYPE_POLYLINE_Z
See Also:
Constant Field Values

SHAPETYPE_POLYGON_Z

public static final int SHAPETYPE_POLYGON_Z
See Also:
Constant Field Values

SHAPETYPE_MULTIPOINT_Z

public static final int SHAPETYPE_MULTIPOINT_Z
See Also:
Constant Field Values

SHAPETYPE_POINT_M

public static final int SHAPETYPE_POINT_M
See Also:
Constant Field Values

SHAPETYPE_POLYLINE_M

public static final int SHAPETYPE_POLYLINE_M
See Also:
Constant Field Values

SHAPETYPE_POLYGON_M

public static final int SHAPETYPE_POLYGON_M
See Also:
Constant Field Values

SHAPETYPE_MULTIPOINT_M

public static final int SHAPETYPE_MULTIPOINT_M
See Also:
Constant Field Values

SHAPETYPE_MULTIPATCH

public static final int SHAPETYPE_MULTIPATCH
See Also:
Constant Field Values

PARTTYPE_TRIANGLE_STRIP

public static final int PARTTYPE_TRIANGLE_STRIP
See Also:
Constant Field Values

PARTTYPE_TRIANGLE_FAN

public static final int PARTTYPE_TRIANGLE_FAN
See Also:
Constant Field Values

PARTTYPE_OUTER_RING

public static final int PARTTYPE_OUTER_RING
See Also:
Constant Field Values

PARTTYPE_INNER_RING

public static final int PARTTYPE_INNER_RING
See Also:
Constant Field Values

PARTTYPE_FIRST_RING

public static final int PARTTYPE_FIRST_RING
See Also:
Constant Field Values

PARTTYPE_RING

public static final int PARTTYPE_RING
See Also:
Constant Field Values
Constructor Detail

Shape

public Shape(Shape s)

Shape

public Shape(Payload p)

Shape

public Shape(int rcdNdx,
             int type,
             BoundingBox bb,
             Point[] pp,
             int[] parts,
             int[] partTypes,
             Range mRange,
             Range zRange)

Shape

public Shape(int rcdNdx,
             GeoPoint gp)
Constructor Initialize with single GeoPoint


Shape

public Shape(int rcdNdx,
             GeoPolygon gp)
Constructor Initialize with single GeoPolygon

Method Detail

GetShapeTypeDescription

public static java.lang.String GetShapeTypeDescription(int shapeType)

getRecordIndex

public int getRecordIndex()

getShapeType

public int getShapeType()

getBoundingBox

public BoundingBox getBoundingBox()

getShapePoints

public Point[] getShapePoints()

getShapeParts

public int[] getShapeParts()

getShapePartTypes

public int[] getShapePartTypes()

getShapeMRange

public Range getShapeMRange()

getShapeZRange

public Range getShapeZRange()

getPolygons

public GeoPolygon[] getPolygons()

createShapeBytes

protected byte[] createShapeBytes()

createShapePayload

protected Payload createShapePayload(boolean saveData)

getShapeLength

public int getShapeLength()

writeShape

public int writeShape(Payload p,
                      int rcdNdx)

toString

public java.lang.String toString(java.lang.StringBuffer sb)
Returns a String representation of this instance


toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object