Neo4j Community

org.neo4j.helpers.collection
Class IterableWrapper<T,U>

java.lang.Object
  extended by org.neo4j.helpers.collection.IterableWrapper<T,U>
Type Parameters:
T - the type of items to return
U - the type of items to wrap/convert from
All Implemented Interfaces:
Iterable<T>

public abstract class IterableWrapper<T,U>
extends Object
implements Iterable<T>

Wraps an Iterable so that it returns items of another type. The iteration is done lazily.


Constructor Summary
IterableWrapper(Iterable<U> iterableToWrap)
           
 
Method Summary
 Iterator<T> iterator()
           
protected abstract  T underlyingObjectToObject(U object)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

IterableWrapper

public IterableWrapper(Iterable<U> iterableToWrap)
Method Detail

underlyingObjectToObject

protected abstract T underlyingObjectToObject(U object)

iterator

public Iterator<T> iterator()
Specified by:
iterator in interface Iterable<T>

Neo4j Community

Copyright © 2002-2012 The Neo4j Graph Database Project. All Rights Reserved.