org.geotools.geometry.jts.spatialschema.geometry.complex
Class ComplexImpl
java.lang.Object
org.geotools.geometry.jts.spatialschema.geometry.GeometryImpl
org.geotools.geometry.jts.spatialschema.geometry.complex.ComplexImpl
- All Implemented Interfaces:
- java.io.Serializable, java.lang.Cloneable, JTSGeometry, org.opengis.geometry.complex.Complex, org.opengis.geometry.Geometry, org.opengis.geometry.TransfiniteSet
- Direct Known Subclasses:
- BoundaryImpl, CompositeImpl
public class ComplexImpl
- extends GeometryImpl
- implements org.opengis.geometry.complex.Complex
A collection of geometrically disjoint, simple primitives. If a
primitive (other than a point
is in a particular Complex
, then there exists a set of primitives of lower dimension
in the same complex that form the boundary of this primitive.
A geometric complex can be thought of as a set in two distinct ways. First, it is a finite set
of objects (via delegation to its elements member) and, second, it is an infinite set of point
values as a subtype of geometric object. The dual use of delegation and subtyping is to
disambiguate the two types of set interface. To determine if a primitive
P is an element of a Complex
C,
call: C.element().contains(P)
.
The "elements" attribute allows Complex
to inherit the
behavior of Set<Primitive>
without confusing the same sort of behavior
inherited from TransfiniteSet<DirectPosition>
inherited through Geometry
. Complexes shall be used in application schemas where
the sharing of geometry is important, such as in the use of computational topology. In a
complex, primitives may be aggregated many-to-many into composites for use as attributes
of features.
- Version:
- 2.0
- Author:
- ISO/DIS 19107, OpenGIS® consortium
- See Also:
- Serialized Form
Constructor Summary |
ComplexImpl(org.opengis.referencing.crs.CoordinateReferenceSystem crs)
|
Method Summary |
protected com.vividsolutions.jts.geom.Geometry |
computeJTSPeer()
Creates the JTS peer. |
protected java.util.List |
getElementList()
|
java.util.Collection |
getElements()
Returns a modifiable reference to our set of elements. |
org.opengis.geometry.complex.Complex[] |
getSubComplexes()
Returns an array that lists the subcomplexes currently added to this
object. |
java.util.Set |
getSubComplexSet()
Returns a modifiable set that allows the user to add to the list of
subcomplexes. |
org.opengis.geometry.complex.Complex[] |
getSuperComplexes()
This implementation does not support knowing about "larger" objects that
contain this one. |
boolean |
isMaximal()
This implementation does not support knowing about "larger" objects that
contain this one. |
Methods inherited from class org.geotools.geometry.jts.spatialschema.geometry.GeometryImpl |
clone, contains, contains, difference, distance, equals, getBoundary, getBuffer, getCentroid, getClosure, getConvexHull, getCoordinateDimension, getCoordinateReferenceSystem, getDimension, getDistance, getEnvelope, getJTSGeometry, getMaximalComplex, getMbRegion, getPrecision, getRepresentativePoint, intersection, intersects, invalidateCachedJTSPeer, isCycle, isMutable, isSimple, listAsSet, setJTSPeer, setParent, symmetricDifference, toImmutable, transform, transform, union |
Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.opengis.geometry.Geometry |
clone, distance, getBoundary, getBuffer, getCentroid, getClosure, getConvexHull, getCoordinateDimension, getCoordinateReferenceSystem, getDimension, getEnvelope, getMaximalComplex, getMbRegion, getPrecision, getRepresentativePoint, isCycle, isMutable, isSimple, toImmutable, transform, transform |
Methods inherited from interface org.opengis.geometry.TransfiniteSet |
contains, contains, difference, equals, intersection, intersects, symmetricDifference, union |
setViewOfElements
protected java.util.Set setViewOfElements
ComplexImpl
public ComplexImpl(org.opengis.referencing.crs.CoordinateReferenceSystem crs)
getElementList
protected java.util.List getElementList()
isMaximal
public final boolean isMaximal()
- This implementation does not support knowing about "larger" objects that
contain this one. Therefore it cannot be known if a complex is maximal.
So this method always returns false.
- Specified by:
isMaximal
in interface org.opengis.geometry.complex.Complex
getSuperComplexes
public final org.opengis.geometry.complex.Complex[] getSuperComplexes()
- This implementation does not support knowing about "larger" objects that
contain this one. Therefore this method always returns null.
- Specified by:
getSuperComplexes
in interface org.opengis.geometry.complex.Complex
getSubComplexes
public final org.opengis.geometry.complex.Complex[] getSubComplexes()
- Returns an array that lists the subcomplexes currently added to this
object.
- Specified by:
getSubComplexes
in interface org.opengis.geometry.complex.Complex
getSubComplexSet
public final java.util.Set getSubComplexSet()
- Returns a modifiable set that allows the user to add to the list of
subcomplexes.
getElements
public final java.util.Collection getElements()
- Returns a modifiable reference to our set of elements. This class makes
no attempt to keep the set of subComplexes up to date when this set is
modified, so modify with caution.
- Specified by:
getElements
in interface org.opengis.geometry.complex.Complex
computeJTSPeer
protected final com.vividsolutions.jts.geom.Geometry computeJTSPeer()
- Creates the JTS peer.
- Specified by:
computeJTSPeer
in class GeometryImpl
Copyright © 1996-2010 Geotools. All Rights Reserved.