Class Parallelogram2afp.ProjectionToParallelogramLocalCoordinateSystemPathIterator<T extends PathElement2afp>
- java.lang.Object
-
- org.arakhne.afc.math.geometry.d2.afp.Parallelogram2afp.ProjectionToParallelogramLocalCoordinateSystemPathIterator<T>
-
- Type Parameters:
T- the type of the path elements.
- All Implemented Interfaces:
Cloneable,Iterator<T>,PathIterator2afp<T>,PathIterator2D<T>
- Enclosing interface:
- Parallelogram2afp<ST extends Shape2afp<?,?,IE,P,V,B>,IT extends Parallelogram2afp<?,?,IE,P,V,B>,IE extends PathElement2afp,P extends Point2D<? super P,? super V>,V extends Vector2D<? super V,? super P>,B extends Rectangle2afp<?,?,IE,P,V,B>>
public static class Parallelogram2afp.ProjectionToParallelogramLocalCoordinateSystemPathIterator<T extends PathElement2afp> extends Object implements PathIterator2afp<T>
An iterator that automatically transform and reply the path elements from the given iterator such that the coordinates of the path elements are projected in the local coordinate system of the given parallelogram.- Since:
- 13.0
- Version:
- 17.0 2020-01-04 14:41:43
- Author:
- Stéphane GALLAND, Maxime Grolleau
- Maven Group Id:
- org.arakhne.afc.core
- Maven Artifact Id:
- mathgeom
-
-
Constructor Summary
Constructors Constructor Description ProjectionToParallelogramLocalCoordinateSystemPathIterator(double x, double y, double axis1X, double axis1Y, double axis2X, double axis2Y, PathIterator2afp<T> iterator)Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description GeomFactory2afp<T,?,?,?>getGeomFactory()Replies the factory of geometrical elements.PathWindingRulegetWindingRule()Replies the winding rule for the path.booleanhasNext()booleanisCurved()Replies the path contains a curve.booleanisMultiParts()Replies the path has multiple parts, i.e. multipleMOVE_TOare inside.booleanisPolygon()Replies the path is composed only by oneMOVE_TO, a sequence ofLINE_TOorQUAD_TOorCURVE_TOorARC_TO, and a singleCLOSEprimitives.booleanisPolyline()Replies the path is composed only by oneMOVE_TO, and a sequence ofLINE_TOprimitives.Tnext()voidremove()PathIterator2afp<T>restartIterations()Replies a reset instance of this iterator.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface java.util.Iterator
forEachRemaining
-
-
-
-
Constructor Detail
-
ProjectionToParallelogramLocalCoordinateSystemPathIterator
public ProjectionToParallelogramLocalCoordinateSystemPathIterator(double x, double y, double axis1X, double axis1Y, double axis2X, double axis2Y, PathIterator2afp<T> iterator)Constructor.- Parameters:
x- the specified X coordinate of the rectangle center.y- the specified Y coordinate of the rectangle center.axis1X- the X coordinate of the first axis of the parallelogram.axis1Y- the Y coordinate of the first axis of the parallelogram.axis2X- the X coordinate of the second axis of the parallelogram.axis2Y- the Y coordinate of the second axis of the parallelogram.iterator- the iterator to transform.
-
-
Method Detail
-
restartIterations
public PathIterator2afp<T> restartIterations()
Description copied from interface:PathIterator2DReplies a reset instance of this iterator.The reset instance enables to restart iterations with the replied iterator.
- Specified by:
restartIterationsin interfacePathIterator2afp<T extends PathElement2afp>- Specified by:
restartIterationsin interfacePathIterator2D<T extends PathElement2afp>- Returns:
- the reset iterator.
-
hasNext
@Pure public boolean hasNext()
- Specified by:
hasNextin interfaceIterator<T extends PathElement2afp>
-
next
public T next()
- Specified by:
nextin interfaceIterator<T extends PathElement2afp>
-
remove
public void remove()
- Specified by:
removein interfaceIterator<T extends PathElement2afp>
-
getWindingRule
@Pure public PathWindingRule getWindingRule()
Description copied from interface:PathIterator2DReplies the winding rule for the path.- Specified by:
getWindingRulein interfacePathIterator2D<T extends PathElement2afp>- Returns:
- the winding rule for the path.
-
isPolyline
@Pure public boolean isPolyline()
Description copied from interface:PathIterator2DReplies the path is composed only by oneMOVE_TO, and a sequence ofLINE_TOprimitives.- Specified by:
isPolylinein interfacePathIterator2D<T extends PathElement2afp>- Returns:
trueif the path does not contain curve primitives,falseotherwise.
-
isCurved
@Pure public boolean isCurved()
Description copied from interface:PathIterator2DReplies the path contains a curve.- Specified by:
isCurvedin interfacePathIterator2D<T extends PathElement2afp>- Returns:
trueif the path contains curve primitives,falseotherwise.
-
isPolygon
@Pure public boolean isPolygon()
Description copied from interface:PathIterator2DReplies the path is composed only by oneMOVE_TO, a sequence ofLINE_TOorQUAD_TOorCURVE_TOorARC_TO, and a singleCLOSEprimitives.- Specified by:
isPolygonin interfacePathIterator2D<T extends PathElement2afp>- Returns:
trueif the path does not contain curve primitives,falseotherwise.
-
isMultiParts
@Pure public boolean isMultiParts()
Description copied from interface:PathIterator2DReplies the path has multiple parts, i.e. multipleMOVE_TOare inside. primitives.- Specified by:
isMultiPartsin interfacePathIterator2D<T extends PathElement2afp>- Returns:
trueif the path has multiple move-to primitive,falseotherwise.
-
getGeomFactory
public GeomFactory2afp<T,?,?,?> getGeomFactory()
Description copied from interface:PathIterator2DReplies the factory of geometrical elements.- Specified by:
getGeomFactoryin interfacePathIterator2afp<T extends PathElement2afp>- Specified by:
getGeomFactoryin interfacePathIterator2D<T extends PathElement2afp>- Returns:
- the factory.
-
-