org.deegree.geometry.standard.curvesegments
Class DefaultOffsetCurve

java.lang.Object
  extended by org.deegree.geometry.standard.curvesegments.DefaultOffsetCurve
All Implemented Interfaces:
CurveSegment, OffsetCurve

public class DefaultOffsetCurve
extends Object
implements OffsetCurve

Default implementation of OffsetCurve segments.

Version:
$Revision: 31641 $, $Date: 2011-08-24 21:24:55 +0200 (Wed, 24 Aug 2011) $
Author:
Markus Schneider , last edited by: $Author: mschneider $

Nested Class Summary
 
Nested classes/interfaces inherited from interface org.deegree.geometry.primitive.segments.CurveSegment
CurveSegment.CurveSegmentType
 
Constructor Summary
DefaultOffsetCurve(Curve baseCurve, Point direction, Measure distance)
          Creates a new DefaultOffsetCurve instance from the given parameters.
 
Method Summary
 Curve getBaseCurve()
          Returns the Curve that the curve segment's definition is based on.
 int getCoordinateDimension()
          Returns the coordinate dimension, i.e. the dimension of the space that the curve is embedded in.
 Point getDirection()
          Returns the direction of the offset from the base Curve.
 Measure getDistance(Unit requestedUnits)
          Returns the distance from the base Curve.
 Point getEndPoint()
          Returns the end point of the segment.
 CurveSegment.CurveSegmentType getSegmentType()
          Returns the type of curve segment.
 Point getStartPoint()
          Returns the start point of the segment.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultOffsetCurve

public DefaultOffsetCurve(Curve baseCurve,
                          Point direction,
                          Measure distance)
Creates a new DefaultOffsetCurve instance from the given parameters.

Parameters:
baseCurve - the base geometry
direction - the direction of the offset
distance - the distance from the base curve
Method Detail

getBaseCurve

public Curve getBaseCurve()
Description copied from interface: OffsetCurve
Returns the Curve that the curve segment's definition is based on.

Specified by:
getBaseCurve in interface OffsetCurve
Returns:
the Curve used as the base geometry

getDirection

public Point getDirection()
Description copied from interface: OffsetCurve
Returns the direction of the offset from the base Curve.

Specified by:
getDirection in interface OffsetCurve
Returns:
the direction of the offset (to be understood as an offset vector)

getDistance

public Measure getDistance(Unit requestedUnits)
Description copied from interface: OffsetCurve
Returns the distance from the base Curve.

Specified by:
getDistance in interface OffsetCurve
Parameters:
requestedUnits - units-of-measure that the distance shall be expressed as, or null for units of the underlying coordinate system
Returns:
the distance in the the requested uom

getCoordinateDimension

public int getCoordinateDimension()
Description copied from interface: CurveSegment
Returns the coordinate dimension, i.e. the dimension of the space that the curve is embedded in.

Specified by:
getCoordinateDimension in interface CurveSegment
Returns:
the coordinate dimension

getStartPoint

public Point getStartPoint()
Description copied from interface: CurveSegment
Returns the start point of the segment.

Specified by:
getStartPoint in interface CurveSegment
Returns:
the start point of the segment

getEndPoint

public Point getEndPoint()
Description copied from interface: CurveSegment
Returns the end point of the segment.

Specified by:
getEndPoint in interface CurveSegment
Returns:
the end point of the segment

getSegmentType

public CurveSegment.CurveSegmentType getSegmentType()
Description copied from interface: CurveSegment
Returns the type of curve segment.

Specified by:
getSegmentType in interface CurveSegment
Returns:
the type of curve segment


Copyright © 2011. All Rights Reserved.