org.postgis
Class PointComposedGeom

java.lang.Object
  extended by org.postgis.Geometry
      extended by org.postgis.ComposedGeom
          extended by org.postgis.PointComposedGeom
All Implemented Interfaces:
java.io.Serializable
Direct Known Subclasses:
LinearRing, LineString, MultiPoint

public abstract class PointComposedGeom
extends ComposedGeom

PointComposedGeom - base class for all composed geoms that contain only points.

Author:
markus.schaber@logix-tt.com
See Also:
Serialized Form

Field Summary
 
Fields inherited from class org.postgis.ComposedGeom
EMPTY, subgeoms
 
Fields inherited from class org.postgis.Geometry
ALLTYPES, dimension, GEOMETRYCOLLECTION, haveMeasure, LINEARRING, LINESTRING, MULTILINESTRING, MULTIPOINT, MULTIPOLYGON, POINT, POLYGON, srid, type, UNKNOWN_SRID
 
Constructor Summary
protected PointComposedGeom(int type)
           
protected PointComposedGeom(int type, Point[] points)
           
  PointComposedGeom(int type, java.lang.String value)
           
  PointComposedGeom(int type, java.lang.String value, boolean haveM)
           
 
Method Summary
protected  Geometry[] createSubGeomArray(int pointcount)
          Return the appropriate instance of the subgeometry array - this encapsulates subclass specific array instantiation
protected  Geometry createSubGeomInstance(java.lang.String token, boolean haveM)
          Return the appropriate instance of the subgeometry - this encapsulates subclass specific constructor calls
 Point getPoint(int idx)
          optimized version
 Point[] getPoints()
          Get the underlying Point array
protected  void innerWKT(java.lang.StringBuffer sb)
          Render the "inner" part of the WKT (inside the brackets) into the StringBuffer.
 int numPoints()
          optimized version
 
Methods inherited from class org.postgis.ComposedGeom
checkConsistency, equalsintern, getFirstPoint, getLastPoint, getSubGeometry, hashCode, isEmpty, iterator, mediumWKT, numGeoms, setSrid
 
Methods inherited from class org.postgis.Geometry
equals, equals, getDimension, getSrid, getType, getTypeString, getTypeString, getValue, initSRID, isMeasured, outerWKT, outerWKT, parseSRID, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

PointComposedGeom

protected PointComposedGeom(int type)

PointComposedGeom

protected PointComposedGeom(int type,
                            Point[] points)

PointComposedGeom

public PointComposedGeom(int type,
                         java.lang.String value)
                  throws java.sql.SQLException
Throws:
java.sql.SQLException

PointComposedGeom

public PointComposedGeom(int type,
                         java.lang.String value,
                         boolean haveM)
                  throws java.sql.SQLException
Throws:
java.sql.SQLException
Method Detail

createSubGeomInstance

protected Geometry createSubGeomInstance(java.lang.String token,
                                         boolean haveM)
                                  throws java.sql.SQLException
Description copied from class: ComposedGeom
Return the appropriate instance of the subgeometry - this encapsulates subclass specific constructor calls

Specified by:
createSubGeomInstance in class ComposedGeom
Throws:
java.sql.SQLException

createSubGeomArray

protected Geometry[] createSubGeomArray(int pointcount)
Description copied from class: ComposedGeom
Return the appropriate instance of the subgeometry array - this encapsulates subclass specific array instantiation

Specified by:
createSubGeomArray in class ComposedGeom

innerWKT

protected void innerWKT(java.lang.StringBuffer sb)
Description copied from class: Geometry
Render the "inner" part of the WKT (inside the brackets) into the StringBuffer.

Overrides:
innerWKT in class ComposedGeom

numPoints

public int numPoints()
optimized version

Overrides:
numPoints in class ComposedGeom

getPoint

public Point getPoint(int idx)
optimized version

Overrides:
getPoint in class ComposedGeom
Parameters:
idx - the index of the point, from 0 to numPoints()-1;

getPoints

public Point[] getPoints()
Get the underlying Point array