| JGL - The Generic Collection Library for Java |
All Packages Class Hierarchy This Package Previous Next Index
Interface com.objectspace.jgl.InputIterator
- public interface InputIterator
- extends Enumeration, Cloneable
InputIterator is the interface of all iterators that can read one
item at a time in a forward direction. InputIterator is an extension
of the java.lang.Enumeration class.
- See Also:
- OutputIterator, Enumeration
-
advance()
- Advance by one.
-
advance(int)
- Advance by a specified amount.
-
atBegin()
- Return true if I'm positioned at the first item of my input stream.
-
atEnd()
- Return true if I'm positioned after the last item in my input stream.
-
clone()
- Return a clone of myself.
-
get()
- Return the object at my current position.
-
isCompatibleWith(InputIterator)
- Return true if both
iterator
and myself can be used
as a range.
atBegin
public abstract boolean atBegin()
- Return true if I'm positioned at the first item of my input stream.
atEnd
public abstract boolean atEnd()
- Return true if I'm positioned after the last item in my input stream.
get
public abstract Object get()
- Return the object at my current position.
advance
public abstract void advance()
- Advance by one.
advance
public abstract void advance(int n)
- Advance by a specified amount.
- Parameters:
- n - The amount to advance.
clone
public abstract Object clone()
- Return a clone of myself.
- Overrides:
- clone in class Object
isCompatibleWith
public abstract boolean isCompatibleWith(InputIterator iterator)
- Return true if both
iterator
and myself can be used
as a range.
All Packages Class Hierarchy This Package Previous Next Index