deegree 2.5 (2011/06/29 09:44 build-8-official)

org.deegree.io.shpapi.shape_new
Interface Shape

All Known Implementing Classes:
ShapeEnvelope, ShapeMultiPatch, ShapeMultiPoint, ShapePoint, ShapePolygon, ShapePolyline

public interface Shape

Shape defines methods to read, write and use objects read from/written to a shapefile (as well as some basic information).

Version:
$Revision: 18195 $, $Date: 2009-06-18 17:55:39 +0200 (Do, 18 Jun 2009) $
Author:
Andreas Schmitz, last edited by: $Author: mschneider $

Method Summary
 int getByteLength()
           
 ShapeEnvelope getEnvelope()
           
 Geometry getGeometry()
           
 int getType()
           
 int read(byte[] bytes, int offset)
          Reads the object from a byte array.
 int write(byte[] bytes, int offset)
          Writes the object to a byte array.
 

Method Detail

read

int read(byte[] bytes,
         int offset)
Reads the object from a byte array.

Parameters:
bytes -
offset - where to start reading
Returns:
the new offset or -1, if the type was wrong.

write

int write(byte[] bytes,
          int offset)
Writes the object to a byte array.

Parameters:
bytes -
offset -
Returns:
the new offset.

getByteLength

int getByteLength()
Returns:
the number of bytes necessary to write this instance.

getType

int getType()
Returns:
the type of the shape

getEnvelope

ShapeEnvelope getEnvelope()
Returns:
the shapes' envelope, or null, if it has none

getGeometry

Geometry getGeometry()
                     throws ShapeGeometryException
Returns:
the shape as deegree Geometry
Throws:
ShapeGeometryException - if the deegree geometry could not be constructed

deegree 2.5 (2011/06/29 09:44 build-8-official)

an open source project founded by lat/lon, Bonn, Germany.
For more information visit: http://www.deegree.org