org.apache.commons.collections.primitives.adapters

Class LongIteratorIterator

public class LongIteratorIterator extends Object implements Iterator

Adapts an LongIterator to the java.util.Iterator Iterator interface.

This implementation delegates most methods to the provided LongIterator implementation in the "obvious" way.

Since: Commons Primitives 1.0

Version: $Revision: 1.3 $ $Date: 2003/10/16 20:49:39 $

Author: Rodney Waldhoff

Field Summary
LongIterator_iterator
Constructor Summary
LongIteratorIterator(LongIterator iterator)
Creates an Iterator Iterator wrapping the specified LongIterator.
Method Summary
booleanhasNext()
Objectnext()
voidremove()
static Iteratorwrap(LongIterator iterator)
Create an Iterator Iterator wrapping the specified LongIterator.

Field Detail

_iterator

private LongIterator _iterator

Constructor Detail

LongIteratorIterator

public LongIteratorIterator(LongIterator iterator)
Creates an Iterator Iterator wrapping the specified LongIterator.

See Also: LongIteratorIterator

Method Detail

hasNext

public boolean hasNext()

next

public Object next()

remove

public void remove()

wrap

public static Iterator wrap(LongIterator iterator)
Create an Iterator Iterator wrapping the specified LongIterator. When the given iterator is null, returns null.

Parameters: iterator the (possibly null) LongIterator to wrap

Returns: an Iterator Iterator wrapping the given iterator, or null when iterator is null.

Copyright (c) 2002-2003 - Apache Software Foundation