Class FilteredSequence<T>
java.lang.Object
org.apache.druid.java.util.common.guava.FilteredSequence<T>
- All Implemented Interfaces:
Sequence<T>
-
Constructor Summary
ConstructorsConstructorDescriptionFilteredSequence(Sequence<T> baseSequence, com.google.common.base.Predicate<? super T> pred) -
Method Summary
Modifier and TypeMethodDescription<OutType> OutTypeaccumulate(OutType initValue, Accumulator<OutType, T> accumulator) Accumulate this sequence using the given accumulator.<OutType> Yielder<OutType>toYielder(OutType initValue, YieldingAccumulator<OutType, T> accumulator) Return a Yielder for accumulated sequence.
-
Constructor Details
-
FilteredSequence
-
-
Method Details
-
accumulate
Description copied from interface:SequenceAccumulate this sequence using the given accumulator.- Specified by:
accumulatein interfaceSequence<T>- 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:
- accumulated value.
-
toYielder
public <OutType> Yielder<OutType> toYielder(OutType initValue, YieldingAccumulator<OutType, T> accumulator) Description copied from interface:SequenceReturn a Yielder for accumulated sequence.- Specified by:
toYielderin interfaceSequence<T>- 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:
-