Class MergeSequence<T>
- java.lang.Object
-
- org.apache.druid.java.util.common.guava.YieldingSequenceBase<T>
-
- org.apache.druid.java.util.common.guava.MergeSequence<T>
-
- All Implemented Interfaces:
Sequence<T>
public class MergeSequence<T> extends YieldingSequenceBase<T>
Used to perform an n-way merge on n ordered sequences
-
-
Constructor Summary
Constructors Constructor Description MergeSequence(com.google.common.collect.Ordering<? super T> ordering, Sequence<? extends Sequence<? extends T>> baseSequences)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description <OutType> Yielder<OutType>
toYielder(OutType initValue, YieldingAccumulator<OutType,T> accumulator)
Return a Yielder for accumulated sequence.-
Methods inherited from class org.apache.druid.java.util.common.guava.YieldingSequenceBase
accumulate
-
-
-
-
Method Detail
-
toYielder
public <OutType> Yielder<OutType> toYielder(OutType initValue, YieldingAccumulator<OutType,T> accumulator)
Description copied from interface:Sequence
Return a Yielder for accumulated sequence.- Type Parameters:
OutType
- the type of accumulated value.- Parameters:
initValue
- the initial value to pass along to start the accumulation.accumulator
- the accumulator which is responsible for accumulating input values.- Returns:
- a Yielder for accumulated sequence.
- See Also:
Yielder
-
-