org.kaboum.geom
Class KaboumGeometryFactory

java.lang.Object
  extended by org.kaboum.geom.KaboumGeometryFactory

public class KaboumGeometryFactory
extends java.lang.Object

Basic implementation of GeometryFactory.


Constructor Summary
KaboumGeometryFactory()
           
 
Method Summary
static KaboumGeometry buildGeometry(KaboumList geomKaboumList)
          Build an appropriate Geometry, MultiGeometry, or GeometryCollection to contain the Geometrys in it; for example,
If geomKaboumList contains a single Polygon, the Polygon is returned.
static KaboumGeometryCollection createGeometryCollection(KaboumGeometry[] geometries)
           
static KaboumLinearRing createLinearRing(KaboumCoordinate[] coordinates)
           
static KaboumLineString createLineString(KaboumCoordinate[] coordinates)
           
static KaboumMultiLineString createMultiLineString(KaboumLineString[] lineStrings)
           
static KaboumMultiPoint createMultiPoint(KaboumCoordinate[] coordinates)
           
static KaboumMultiPoint createMultiPoint(KaboumPoint[] point)
           
static KaboumMultiPolygon createMultiPolygon(KaboumPolygon[] polygons)
           
static KaboumPoint createPoint(KaboumCoordinate coordinate)
           
static KaboumPolygon createPolygon(KaboumLinearRing shell, KaboumLinearRing[] holes)
           
static KaboumGeometry toGeometry(KaboumExtent extent)
          If the Extent is a null Extent, returns an empty Point.
static KaboumGeometry[] toGeometryArray(KaboumList geometrys)
          Converts the KaboumList to an array.
static KaboumLinearRing[] toLinearRingArray(KaboumList linearRings)
          Converts the KaboumList to an array.
static KaboumLineString[] toLineStringArray(KaboumList lineStrings)
          Converts the KaboumList to an array.
static KaboumMultiLineString[] toMultiLineStringArray(KaboumList multiLineStrings)
          Converts the KaboumList to an array.
static KaboumMultiPoint[] toMultiPointArray(KaboumList multiPoints)
          Converts the KaboumList to an array.
static KaboumMultiPolygon[] toMultiPolygonArray(KaboumList multiPolygons)
          Converts the KaboumList to an array.
static KaboumPoint[] toPointArray(KaboumList points)
          Converts the KaboumList to an array.
static KaboumPolygon[] toPolygonArray(KaboumList polygons)
          Converts the KaboumList to an array.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

KaboumGeometryFactory

public KaboumGeometryFactory()
Method Detail

toPointArray

public static KaboumPoint[] toPointArray(KaboumList points)
Converts the KaboumList to an array.

Parameters:
points - the KaboumList to convert

toGeometryArray

public static KaboumGeometry[] toGeometryArray(KaboumList geometrys)
Converts the KaboumList to an array.

Parameters:
geometrys - the KaboumList of Geometrys to convert

toLinearRingArray

public static KaboumLinearRing[] toLinearRingArray(KaboumList linearRings)
Converts the KaboumList to an array.

Parameters:
linearRings - the KaboumList to convert

toLineStringArray

public static KaboumLineString[] toLineStringArray(KaboumList lineStrings)
Converts the KaboumList to an array.

Parameters:
lineStrings - the KaboumList to convert

toPolygonArray

public static KaboumPolygon[] toPolygonArray(KaboumList polygons)
Converts the KaboumList to an array.

Parameters:
polygons - the KaboumList to convert

toMultiPolygonArray

public static KaboumMultiPolygon[] toMultiPolygonArray(KaboumList multiPolygons)
Converts the KaboumList to an array.

Parameters:
multiPolygons - the KaboumList to convert

toMultiLineStringArray

public static KaboumMultiLineString[] toMultiLineStringArray(KaboumList multiLineStrings)
Converts the KaboumList to an array.

Parameters:
multiLineStrings - the KaboumList to convert

toMultiPointArray

public static KaboumMultiPoint[] toMultiPointArray(KaboumList multiPoints)
Converts the KaboumList to an array.

Parameters:
multiPoints - the KaboumList to convert

toGeometry

public static KaboumGeometry toGeometry(KaboumExtent extent)
If the Extent is a null Extent, returns an empty Point. If the Extent is a point, returns a non-empty Point. If the Extent is a rectangle, returns a Polygon whose points are (minx, miny), (maxx, miny), (maxx, maxy), (minx, maxy), (minx, miny).

Parameters:
extent - the Extent to convert to a Geometry

createPoint

public static KaboumPoint createPoint(KaboumCoordinate coordinate)

createMultiLineString

public static KaboumMultiLineString createMultiLineString(KaboumLineString[] lineStrings)

createGeometryCollection

public static KaboumGeometryCollection createGeometryCollection(KaboumGeometry[] geometries)

createMultiPolygon

public static KaboumMultiPolygon createMultiPolygon(KaboumPolygon[] polygons)

createLinearRing

public static KaboumLinearRing createLinearRing(KaboumCoordinate[] coordinates)

createMultiPoint

public static KaboumMultiPoint createMultiPoint(KaboumPoint[] point)

createMultiPoint

public static KaboumMultiPoint createMultiPoint(KaboumCoordinate[] coordinates)

createPolygon

public static KaboumPolygon createPolygon(KaboumLinearRing shell,
                                          KaboumLinearRing[] holes)

buildGeometry

public static KaboumGeometry buildGeometry(KaboumList geomKaboumList)
Build an appropriate Geometry, MultiGeometry, or GeometryCollection to contain the Geometrys in it; for example,

Parameters:
geomKaboumList - the Geometrys to combine

createLineString

public static KaboumLineString createLineString(KaboumCoordinate[] coordinates)


Copyright © 2005 Kaboum team. All Rights Reserved.