This project has retired. For details please refer to its Attic page.
SingleUseIterable (Apache Crunch 0.10.0 API)

Class SingleUseIterable<T>

  extended by org.apache.crunch.impl.SingleUseIterable<T>
All Implemented Interfaces:

public class SingleUseIterable<T>
extends Object
implements Iterable<T>

Wrapper around a Reducer's input Iterable. Ensures that the iterator() method is not called more than once.

Constructor Summary
SingleUseIterable(Iterable<T> toWrap)
          Instantiate around an Iterable that may only be used once.
Method Summary
 Iterator<T> iterator()
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Detail


public SingleUseIterable(Iterable<T> toWrap)
Instantiate around an Iterable that may only be used once.

toWrap - iterable to wrap
Method Detail


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

Copyright © 2014 The Apache Software Foundation. All Rights Reserved.