org.jikesrvm.compilers.opt.util
Class ReverseEnumerator<T>
java.lang.Object
org.jikesrvm.compilers.opt.util.ReverseEnumerator<T>
- All Implemented Interfaces:
- Enumeration<T>
public final class ReverseEnumerator<T>
- extends Object
- implements Enumeration<T>
An enumerator that provides access to the reverse order of elements for
a given Enumeration
.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
vec
private final ArrayList<T> vec
index
private int index
ReverseEnumerator
public ReverseEnumerator(Enumeration<T> e)
hasMoreElements
public boolean hasMoreElements()
- Specified by:
hasMoreElements
in interface Enumeration<T>
nextElement
public T nextElement()
- Specified by:
nextElement
in interface Enumeration<T>