Class YieldingSequenceBase<T>

    • Constructor Detail

      • YieldingSequenceBase

        public YieldingSequenceBase()
    • Method Detail

      • accumulate

        public <OutType> OutType accumulate​(OutType initValue,
                                            Accumulator<OutType,​T> accumulator)
        Description copied from interface: Sequence
        Accumulate this sequence using the given accumulator.
        Specified by:
        accumulate in interface Sequence<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.