Class JoinUncertainIteratorsIterator<T>

java.lang.Object
com.github.basking2.sdsai.itrex.iterators.splitjoin.JoinUncertainIteratorsIterator<T>
Type Parameters:
T - The types being joined.
All Implemented Interfaces:
Iterator<T>

public class JoinUncertainIteratorsIterator<T> extends Object implements Iterator<T>
Collect and present data from a set of UncertainIterators. Every iterator with available data will be scheduled to fetch its in the given ExecutorService. Thus this job processes, roughly, as widely as the distribution of iterator data. If every UncertainIterator returns UncertainIterator.HAS_NEXT.MAYBE then this iterator will report false from hasNext(). The processing model is that of the set of input iterators, at least 1 will have some work to do at all times. This is suitable for distributing work in which we always know that some work is available, but we do not know where it comes from.