FileDocCategorySizeDatePackage
VectorEnumerator.javaAPI DocGlassfish v2 API928Wed Aug 30 15:34:16 BST 2006persistence.antlr.collections.impl

VectorEnumerator

public class VectorEnumerator extends Object implements Enumeration

Fields Summary
Vector
vector
int
i
Constructors Summary
VectorEnumerator(Vector v)

        vector = v;
        i = 0;
    
Methods Summary
public booleanhasMoreElements()

        synchronized (vector) {
            return i <= vector.lastElement;
        }
    
public java.lang.ObjectnextElement()

        synchronized (vector) {
            if (i <= vector.lastElement) {
                return vector.data[i++];
            }
            throw new NoSuchElementException("VectorEnumerator");
        }