Class PolygonIterator

  • All Implemented Interfaces:
    PathIterator

    public class PolygonIterator
    extends Object
    implements PathIterator
    An iterator over Polygon2D. This class is private to this package.
    • Constructor Detail

      • PolygonIterator

        public PolygonIterator​(Polygon2D pl,
                               AffineTransform at)
        Create a new iterator over the given polygon and with the given transform. If the transform is null, that is taken to be the same as a unit Transform.
    • Method Detail

      • currentSegment

        public int currentSegment​(double[] coords)
        Get the current segment
        Specified by:
        currentSegment in interface PathIterator
      • currentSegment

        public int currentSegment​(float[] coords)
        Get the current segment
        Specified by:
        currentSegment in interface PathIterator
      • getWindingRule

        public int getWindingRule()
        Return the winding rule. This is WIND_NON_ZERO.
        Specified by:
        getWindingRule in interface PathIterator
      • isDone

        public boolean isDone()
        Test if the iterator is done.
        Specified by:
        isDone in interface PathIterator
      • next

        public void next()
        Move the iterator along by one point.
        Specified by:
        next in interface PathIterator