deegree 2.2 (2008/12/22 11:33 build-3038-official)

org.deegree.model.spatialschema
Interface Aggregate

All Superinterfaces:
Geometry, Serializable
All Known Subinterfaces:
MultiCurve, MultiPoint, MultiPrimitive, MultiSolid, MultiSurface
All Known Implementing Classes:
AggregateImpl, MultiCurveImpl, MultiPointImpl, MultiPrimitiveImpl, MultiSurfaceImpl

public interface Aggregate
extends Geometry

This interface defines the basis functionallity of all geometry aggregations. it will be specialized for the use of primitive, and solid geometries.

-----------------------------------------------------

Version:
$Revision: 9343 $ $Date: 2007-12-27 14:30:32 +0100 (Do, 27 Dez 2007) $

Author:
Andreas Poth

Method Summary
 void add(Geometry gmo)
          adds an Geometry to the aggregation
 Geometry[] getAll()
          returns all Geometries as array
 Iterator getIterator()
          returns the aggregation as an iterator
 Geometry getObjectAt(int index)
          returns the Geometry at the submitted index.
 int getSize()
          returns the number of Geometry within the aggregation
 void insertObjectAt(Geometry gmo, int index)
          inserts a Geometry in the aggregation. all elements with an index equal or larger index will be moved. if index is larger then getSize() - 1 an exception will be thrown.
 boolean isMember(Geometry gmo)
          returns true if the submitted Geometry is within the aggregation
 void merge(Aggregate aggregate)
          merges two aggregation.
 void removeAll()
          removes all Geometry from the aggregation.
 Geometry removeObject(Geometry gmo)
          removes the submitted Geometry from the aggregation
 Geometry removeObjectAt(int index)
          removes the Geometry at the submitted index from the aggregation. if index is larger then getSize() - 1 an exception will be thrown.
 void setObjectAt(Geometry gmo, int index)
          sets the submitted Geometry at the submitted index. the element at the position index will be removed. if index is larger then getSize() - 1 an exception will be thrown.
 
Methods inherited from interface org.deegree.model.spatialschema.Geometry
contains, contains, difference, distance, getBoundary, getBuffer, getCentroid, getConvexHull, getCoordinateDimension, getCoordinateSystem, getDimension, getEnvelope, getTolerance, intersection, intersects, isEmpty, isWithinDistance, setTolerance, translate, union
 

Method Detail

getSize

int getSize()
returns the number of Geometry within the aggregation


merge

void merge(Aggregate aggregate)
           throws GeometryException
merges two aggregation.

Throws:
GeometryException - a GeometryException will be thrown if the submitted isn't the same type as the recieving one.

add

void add(Geometry gmo)
adds an Geometry to the aggregation


insertObjectAt

void insertObjectAt(Geometry gmo,
                    int index)
                    throws GeometryException
inserts a Geometry in the aggregation. all elements with an index equal or larger index will be moved. if index is larger then getSize() - 1 an exception will be thrown.

Parameters:
gmo - Geometry to insert.
index - position where to insert the new Geometry
Throws:
GeometryException

setObjectAt

void setObjectAt(Geometry gmo,
                 int index)
                 throws GeometryException
sets the submitted Geometry at the submitted index. the element at the position index will be removed. if index is larger then getSize() - 1 an exception will be thrown.

Parameters:
gmo - Geometry to set.
index - position where to set the new Geometry
Throws:
GeometryException

removeObject

Geometry removeObject(Geometry gmo)
removes the submitted Geometry from the aggregation

Returns:
the removed Geometry

removeObjectAt

Geometry removeObjectAt(int index)
                        throws GeometryException
removes the Geometry at the submitted index from the aggregation. if index is larger then getSize() - 1 an exception will be thrown.

Returns:
the removed Geometry
Throws:
GeometryException

removeAll

void removeAll()
removes all Geometry from the aggregation.


getObjectAt

Geometry getObjectAt(int index)
returns the Geometry at the submitted index.


getAll

Geometry[] getAll()
returns all Geometries as array


isMember

boolean isMember(Geometry gmo)
returns true if the submitted Geometry is within the aggregation


getIterator

Iterator getIterator()
returns the aggregation as an iterator


deegree 2.2 (2008/12/22 11:33 build-3038-official)

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