Interface CodeUnitIterator

All Superinterfaces:
Iterable<CodeUnit>, Iterator<CodeUnit>
All Known Implementing Classes:
CodeUnitKeyIterator, CommentTypeFilterIterator, EmptyCodeUnitIterator

public interface CodeUnitIterator extends Iterator<CodeUnit>, Iterable<CodeUnit>
Interface to define an iterator over over some set of code units.
See Also:
  • Field Details

  • Method Details

    • hasNext

      boolean hasNext()
      Return true if there is a next CodeUnit.
      Specified by:
      hasNext in interface Iterator<CodeUnit>
    • next

      CodeUnit next()
      Get the next CodeUnit or null if no more CodeUnits.

      NOTE: This deviates from the standard Iterator interface by returning null instead of throwing an exception.

      Specified by:
      next in interface Iterator<CodeUnit>