All Downloads are FREE. Search and download functionalities are using the official Maven repository.

webit.script.lang.iter.EnumerationIter Maven / Gradle / Ivy

// Copyright (c) 2013-2014, Webit Team. All Rights Reserved.
package webit.script.lang.iter;

import java.util.Enumeration;

/**
 *
 * @author Zqq
 */
public final class EnumerationIter extends AbstractIter {

    private final Enumeration enumeration;

    public EnumerationIter(Enumeration enumeration) {
        this.enumeration = enumeration;
    }

    @Override
    protected Object _next() {
        return enumeration.nextElement();
    }

    public boolean hasNext() {
        return enumeration.hasMoreElements();
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy