getopt-0.3

jrowe.util
Interface TokenIterator


public interface TokenIterator
extends Iterator

Version:
1.1 MAR 11 2000 Moved from no package to jrowe.util
Author:
Joshua T. Rowe

Method Summary
 Set getTokenTypes()
          Returns the token types that could potentially be returned by this TokenIterator.
 Object getType()
          Returns the type of the current token.
 void remove()
          This is an unsupported method in a TokenIterator object.
 
Methods inherited from interface java.util.Iterator
hasNext, next
 

Method Detail

getTokenTypes

public Set getTokenTypes()
Returns the token types that could potentially be returned by this TokenIterator.
Returns:
a Set containing the potential token types. The actual class of the elements of the set are implementation dependant.

getType

public Object getType()
Returns the type of the current token. The current token being the token retreived by calling next().
Returns:
the type of the current token.
Throws:
java.lang.IllegalStateException - thrown if the next method has not yet been called, or the remove method has already been called after the last call to the next method.

remove

public void remove()
This is an unsupported method in a TokenIterator object.
Specified by:
remove in interface Iterator
Throws:
java.lang.UnsupportedOperationException - always thrown in this implementation.

getopt-0.3