Class PathIteratorWrapper
- java.lang.Object
-
- org.arakhne.afc.math.geometry.d3.afp.PathIteratorWrapper
-
- All Implemented Interfaces:
Cloneable,Iterator,PathIterator3afp,PathIterator3D
class PathIteratorWrapper extends Object implements PathIterator3afp
Wrapper of a path iterator.- Since:
- 13.0
- Version:
- 17.0 2020-01-04 14:41:43
- Author:
- Stéphane GALLAND, Thomas PIOTROWSKI
- Maven Group Id:
- org.arakhne.afc.core
- Maven Artifact Id:
- mathgeom
-
-
Constructor Summary
Constructors Constructor Description PathIteratorWrapper(GeomFactory3afp<?,?,?,?> factory, PathIterator3ai<?> iterator)Create the wrapper.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description GeomFactory3afp<?,?,?,?>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_TO, and a singleCLOSEprimitives.booleanisPolyline()Replies the path is composed only by oneMOVE_TO, and a sequence ofLINE_TOprimitives.PathElement3afpnext()PathIteratorWrapperrestartIterations()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, remove
-
-
-
-
Constructor Detail
-
PathIteratorWrapper
PathIteratorWrapper(GeomFactory3afp<?,?,?,?> factory, PathIterator3ai<?> iterator)
Create the wrapper.- Parameters:
factory- the geometry factory.iterator- the original iterator.
-
-
Method Detail
-
getGeomFactory
public GeomFactory3afp<?,?,?,?> getGeomFactory()
Description copied from interface:PathIterator3afpReplies the factory of geometrical elements.- Specified by:
getGeomFactoryin interfacePathIterator3afp- Returns:
- the factory.
-
restartIterations
public PathIteratorWrapper restartIterations()
Description copied from interface:PathIterator3DReplies a reset instance of this iterator.The reset instance enables to restart iterations with the replied iterator.
- Specified by:
restartIterationsin interfacePathIterator3afp- Specified by:
restartIterationsin interfacePathIterator3D- Returns:
- the reset iterator.
-
getWindingRule
public PathWindingRule getWindingRule()
Description copied from interface:PathIterator3DReplies the winding rule for the path.- Specified by:
getWindingRulein interfacePathIterator3D- Returns:
- the winding rule for the path.
-
isPolyline
public boolean isPolyline()
Description copied from interface:PathIterator3DReplies the path is composed only by oneMOVE_TO, and a sequence ofLINE_TOprimitives.- Specified by:
isPolylinein interfacePathIterator3D- Returns:
trueif the path does not contain curve primitives,falseotherwise.
-
isCurved
public boolean isCurved()
Description copied from interface:PathIterator3DReplies the path contains a curve.- Specified by:
isCurvedin interfacePathIterator3D- Returns:
trueif the path contains curve primitives,falseotherwise.
-
isMultiParts
public boolean isMultiParts()
Description copied from interface:PathIterator3DReplies the path has multiple parts, i.e. multipleMOVE_TOare inside. primitives.- Specified by:
isMultiPartsin interfacePathIterator3D- Returns:
trueif the path has multiple move-to primitive,falseotherwise.
-
isPolygon
public boolean isPolygon()
Description copied from interface:PathIterator3DReplies the path is composed only by oneMOVE_TO, a sequence ofLINE_TOorQUAD_TOorCURVE_TO, and a singleCLOSEprimitives.- Specified by:
isPolygonin interfacePathIterator3D- Returns:
trueif the path does not contain curve primitives,falseotherwise.
-
next
public PathElement3afp next()
-
-