math.geom2d.curve
Class AbstractSmoothCurve2D

Package class diagram package AbstractSmoothCurve2D
java.lang.Object
  extended by math.geom2d.curve.AbstractContinuousCurve2D
      extended by math.geom2d.curve.AbstractSmoothCurve2D
All Implemented Interfaces:
Serializable, Cloneable, ContinuousCurve2D, Curve2D, SmoothCurve2D, Shape2D
Direct Known Subclasses:
AbstractLine2D, CubicBezierCurve2D, Ellipse2D, EllipseArc2D, HyperbolaBranch2D, HyperbolaBranchArc2D, Line2D, Parabola2D, ParabolaArc2D, QuadBezierCurve2D

public abstract class AbstractSmoothCurve2D
extends AbstractContinuousCurve2D
implements SmoothCurve2D, Cloneable

Provides a base implementation for smooth curves.

Author:
dlegland
See Also:
Serialized Form

Field Summary
 
Fields inherited from interface math.geom2d.Shape2D
ACCURACY
 
Constructor Summary
AbstractSmoothCurve2D()
           
 
Method Summary
abstract  SmoothCurve2D clone()
          Overrides Object declaration to ensure Curve2D implementation are cloned as Curve2D.
 Vector2D getLeftTangent(double t)
           
 Vector2D getRightTangent(double t)
           
 Collection<Point2D> getSingularPoints()
          Returns an empty set of Point2D, as a smooth curve does not have singular points by definition.
 Collection<? extends SmoothCurve2D> getSmoothPieces()
          Returns a set of smooth curves.
 boolean isSingular(double pos)
          Returns always false, as a smooth curve does not have singular points by definition.
 
Methods inherited from class math.geom2d.curve.AbstractContinuousCurve2D
draw, getAsAWTShape, getAsPolyline, getContinuousCurves, getFirstPoint, getLastPoint, wrapCurve
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface math.geom2d.curve.SmoothCurve2D
clip, getCurvature, getReverseCurve, getSubCurve, getTangent, transform
 
Methods inherited from interface math.geom2d.curve.ContinuousCurve2D
appendPath, getAsPolyline, isClosed
 
Methods inherited from interface math.geom2d.curve.Curve2D
draw, getAsAWTShape, getContinuousCurves, getFirstPoint, getIntersections, getLastPoint, getPoint, getPosition, getT0, getT1, project
 
Methods inherited from interface math.geom2d.Shape2D
contains, contains, getBoundingBox, getDistance, getDistance, isBounded, isEmpty
 

Constructor Detail

AbstractSmoothCurve2D

public AbstractSmoothCurve2D()
Method Detail

getLeftTangent

public Vector2D getLeftTangent(double t)
Specified by:
getLeftTangent in interface ContinuousCurve2D

getRightTangent

public Vector2D getRightTangent(double t)
Specified by:
getRightTangent in interface ContinuousCurve2D

getSmoothPieces

public Collection<? extends SmoothCurve2D> getSmoothPieces()
Description copied from interface: ContinuousCurve2D
Returns a set of smooth curves.

Specified by:
getSmoothPieces in interface ContinuousCurve2D

getSingularPoints

public Collection<Point2D> getSingularPoints()
Returns an empty set of Point2D, as a smooth curve does not have singular points by definition.

Specified by:
getSingularPoints in interface Curve2D
Returns:
a collection of Point2D.
See Also:
Curve2D.getSingularPoints()

isSingular

public boolean isSingular(double pos)
Returns always false, as a smooth curve does not have singular points by definition.

Specified by:
isSingular in interface Curve2D
Parameters:
pos - the position of the point on the curve
Returns:
true if the point at this location is singular
See Also:
Curve2D.isSingular(double)

clone

public abstract SmoothCurve2D clone()
Description copied from interface: Curve2D
Overrides Object declaration to ensure Curve2D implementation are cloned as Curve2D.

Specified by:
clone in interface Curve2D
Specified by:
clone in class AbstractContinuousCurve2D
Returns:
the cloned curve


Copyright © 2012 AMIS research group, Faculty of Mathematics and Physics, Charles University in Prague, Czech Republic. All Rights Reserved.