Module org.dyn4j

Class WoundIterator

  • All Implemented Interfaces:
    java.util.Iterator<Vector2>

    final class WoundIterator
    extends java.lang.Object
    implements java.util.Iterator<Vector2>
    Represents an iterator of Vector2s for the vertices and normals of a Wound shape.
    Since:
    3.2.0
    Version:
    3.2.0
    Author:
    William Bittle
    • Field Summary

      Fields 
      Modifier and Type Field Description
      (package private) int index
      The current index
      (package private) Vector2[] vectors
      The array to iterate over
    • Constructor Summary

      Constructors 
      Constructor Description
      WoundIterator​(Vector2[] vectors)
      Minimal constructor.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean hasNext()  
      Vector2 next()  
      void remove()  
      • 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
    • Field Detail

      • vectors

        final Vector2[] vectors
        The array to iterate over
      • index

        int index
        The current index
    • Constructor Detail

      • WoundIterator

        public WoundIterator​(Vector2[] vectors)
        Minimal constructor.
        Parameters:
        vectors - the array to iterate over
    • Method Detail

      • hasNext

        public boolean hasNext()
        Specified by:
        hasNext in interface java.util.Iterator<Vector2>
      • next

        public Vector2 next()
        Specified by:
        next in interface java.util.Iterator<Vector2>
      • remove

        public void remove()
        Specified by:
        remove in interface java.util.Iterator<Vector2>