org.geotools.geometry.jts.spatialschema.geometry.primitive
Class SurfaceImpl

java.lang.Object
  extended by org.geotools.geometry.jts.spatialschema.geometry.GeometryImpl
      extended by org.geotools.geometry.jts.spatialschema.geometry.primitive.SurfaceImpl
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable, JTSGeometry, org.opengis.geometry.coordinate.GenericSurface, org.opengis.geometry.Geometry, org.opengis.geometry.primitive.OrientablePrimitive, org.opengis.geometry.primitive.OrientableSurface, org.opengis.geometry.primitive.Primitive, org.opengis.geometry.primitive.Surface, org.opengis.geometry.TransfiniteSet

public class SurfaceImpl
extends GeometryImpl
implements org.opengis.geometry.primitive.Surface

Surface with a positive orientation. Surface is a subclass of Primitive and is the basis for 2-dimensional geometry. Unorientable surfaces such as the Möbius band are not allowed. The orientation of a surface chooses an "up" direction through the choice of the upward normal, which, if the surface is not a cycle, is the side of the surface from which the exterior boundary appears counterclockwise. Reversal of the surface orientation reverses the curve orientation of each boundary component, and interchanges the conceptual "up" and "down" direction of the surface. If the surface is the boundary of a solid, the "up" direction is usually outward. For closed surfaces, which have no boundary, the up direction is that of the surface patches, which must be consistent with one another. Its included surface patches describe the interior structure of a Surface.

NOTE: Other than the restriction on orientability, no other "validity" condition is required for GM_Surface.

Version:
2.0
Author:
ISO/DIS 19107, OpenGIS® consortium
See Also:
PrimitiveFactory#createSurface(List), PrimitiveFactory#createSurface(SurfaceBoundary), Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class org.geotools.geometry.jts.spatialschema.geometry.GeometryImpl
GeometryImpl.MathTransformFilter
 
Field Summary
protected  java.util.List<SurfacePatchImpl> patches
           
 
Constructor Summary
SurfaceImpl()
           
SurfaceImpl(org.opengis.referencing.crs.CoordinateReferenceSystem crs)
           
 
Method Summary
protected  com.vividsolutions.jts.geom.Geometry computeJTSPeer()
          Subclasses must override this method to compute the JTS equivalent of this geometry.
 double getArea()
           
 org.opengis.geometry.primitive.SurfaceBoundary getBoundary()
          Returns the boundary of this geometry.
 java.util.Set getComplexes()
           
 org.opengis.geometry.complex.CompositeSurface getComposite()
           
 java.util.Set getContainedPrimitives()
           
 java.util.Set getContainingPrimitives()
           
 int getOrientation()
           
 java.util.List<SurfacePatchImpl> getPatches()
           
 double getPerimeter()
           
 org.opengis.geometry.primitive.Surface getPrimitive()
           
 org.opengis.geometry.primitive.OrientableSurface[] getProxy()
           
 double[] getUpNormal(org.opengis.geometry.DirectPosition point)
           
 
Methods inherited from class org.geotools.geometry.jts.spatialschema.geometry.GeometryImpl
clone, contains, contains, difference, distance, equals, 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, 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
 

Field Detail

patches

protected java.util.List<SurfacePatchImpl> patches
Constructor Detail

SurfaceImpl

public SurfaceImpl()

SurfaceImpl

public SurfaceImpl(org.opengis.referencing.crs.CoordinateReferenceSystem crs)
Method Detail

getPatches

public java.util.List<SurfacePatchImpl> getPatches()
Specified by:
getPatches in interface org.opengis.geometry.primitive.Surface

getBoundary

public org.opengis.geometry.primitive.SurfaceBoundary getBoundary()
Description copied from class: GeometryImpl
Returns the boundary of this geometry. Returns null if the boundary is empty.

Specified by:
getBoundary in interface org.opengis.geometry.Geometry
Specified by:
getBoundary in interface org.opengis.geometry.primitive.OrientableSurface
Specified by:
getBoundary in interface org.opengis.geometry.primitive.Primitive
Overrides:
getBoundary in class GeometryImpl

getUpNormal

public double[] getUpNormal(org.opengis.geometry.DirectPosition point)
Specified by:
getUpNormal in interface org.opengis.geometry.coordinate.GenericSurface

getPerimeter

public double getPerimeter()
Specified by:
getPerimeter in interface org.opengis.geometry.coordinate.GenericSurface

getArea

public double getArea()
Specified by:
getArea in interface org.opengis.geometry.coordinate.GenericSurface

getComposite

public org.opengis.geometry.complex.CompositeSurface getComposite()
Specified by:
getComposite in interface org.opengis.geometry.primitive.OrientableSurface
Specified by:
getComposite in interface org.opengis.geometry.primitive.Primitive

getOrientation

public int getOrientation()
Specified by:
getOrientation in interface org.opengis.geometry.primitive.OrientablePrimitive

getPrimitive

public org.opengis.geometry.primitive.Surface getPrimitive()
Specified by:
getPrimitive in interface org.opengis.geometry.primitive.OrientablePrimitive
Specified by:
getPrimitive in interface org.opengis.geometry.primitive.OrientableSurface

getComplexes

public java.util.Set getComplexes()
Specified by:
getComplexes in interface org.opengis.geometry.primitive.Primitive

getContainingPrimitives

public java.util.Set getContainingPrimitives()
Specified by:
getContainingPrimitives in interface org.opengis.geometry.primitive.Primitive

getProxy

public org.opengis.geometry.primitive.OrientableSurface[] getProxy()
Specified by:
getProxy in interface org.opengis.geometry.primitive.Primitive
Specified by:
getProxy in interface org.opengis.geometry.primitive.Surface

getContainedPrimitives

public java.util.Set getContainedPrimitives()
Specified by:
getContainedPrimitives in interface org.opengis.geometry.primitive.Primitive

computeJTSPeer

protected com.vividsolutions.jts.geom.Geometry computeJTSPeer()
Description copied from class: GeometryImpl
Subclasses must override this method to compute the JTS equivalent of this geometry.

Specified by:
computeJTSPeer in class GeometryImpl
Returns:
See Also:
com.polexis.lite.spatialschema.geometry.GeometryImpl#computeJTSPeer()


Copyright © 1996-2010 Geotools. All Rights Reserved.