Interface TokenIterator

All Superinterfaces:
Iterator
All Known Implementing Classes:
BasicTokenIterator

public interface TokenIterator
extends Iterator
An iterator for String tokens. This interface is designed as a complement to HeaderElementIterator, in cases where the items are plain strings rather than full header elements.
Version:
$Revision: 601000 $
  • Method Summary

    Modifier and Type Method Description
    boolean hasNext()
    Indicates whether there is another token in this iteration.
    String nextToken()
    Obtains the next token from this iteration.

    Methods inherited from interface java.util.Iterator

    next, remove
  • Method Details

    • hasNext

      boolean hasNext()
      Indicates whether there is another token in this iteration.
      Specified by:
      hasNext in interface Iterator
      Returns:
      true if there is another token, false otherwise
      See Also:
      Iterator.next()
    • nextToken

      String nextToken()
      Obtains the next token from this iteration. This method should only be called while hasNext is true.
      Returns:
      the next token in this iteration