Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Neo4j Community
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.neo4j.helpers.collection
Class PositionedIterator<T>

    java.lang.Object
      org.neo4j.helpers.collection.PositionedIterator<T>

All Implemented Interfaces:
  Iterator<T>

    public class PositionedIterator<T>

extends Object
implements Iterator<T>

Decorator class that wraps any iterator and remembers the current node.

Constructor Summary
`PositionedIterator(Iterator<? extends T> iterator)` Creates an instance of the class, wrapping iterator

Method Summary
`T` | `current()` Returns the current node.
`boolean` | `hasNext()`
`T` | `next()`
`void` | `remove()`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### PositionedIterator

    public PositionedIterator(Iterator<? extends T> iterator)

  Creates an instance of the class, wrapping iterator

  Parameters:
    `iterator` - The iterator to wrap

Method Detail

### hasNext

    public boolean hasNext()

  Specified by:
    `hasNext` in interface `Iterator<T>`

### next

    public T next()

  Specified by:
    `next` in interface `Iterator<T>`

### remove

    public void remove()

  Specified by:
    `remove` in interface `Iterator<T>`

### current

    public T current()

  Returns the current node. Any subsequent calls to current will return the same object, unless the next() method has been called.

  Returns:
    The current node.

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Neo4j Community
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2011 The Neo4j Graph Database Project. All Rights Reserved.