A
- the type of the accumulatorR
- type of the aggregation resultpublic static class AggregateOperationBuilder.VarArity<A,R> extends Object
accumulate
primitives and associates
them with Tag
s. Does not capture the static type of the
stream items.Modifier and Type | Method and Description |
---|---|
<T> AggregateOperationBuilder.VarArity<A,R> |
andAccumulate(Tag<T> tag,
BiConsumerEx<? super A,T> accumulateFn)
Registers the
accumulate
primitive for the stream tagged with the supplied tag. |
AggregateOperationBuilder.VarArity<A,R> |
andCombine(BiConsumerEx<? super A,? super A> combineFn)
Registers the
combine primitive. |
AggregateOperationBuilder.VarArity<A,R> |
andDeduct(BiConsumerEx<? super A,? super A> deductFn)
Registers the
deduct primitive. |
<R_NEW> AggregateOperationBuilder.VarArity<A,R_NEW> |
andExport(FunctionEx<? super A,? extends R_NEW> exportFn)
Registers the
export primitive. |
<R_NEW> AggregateOperation<A,R_NEW> |
andExportFinish(FunctionEx<? super A,? extends R_NEW> exportFinishFn)
|
AggregateOperation<A,R> |
andFinish(FunctionEx<? super A,? extends R> finishFn)
Registers the
finish primitive. |
@Nonnull public <T> AggregateOperationBuilder.VarArity<A,R> andAccumulate(@Nonnull Tag<T> tag, @Nonnull BiConsumerEx<? super A,T> accumulateFn)
accumulate
primitive for the stream tagged with the supplied tag.T
- the expected type of input itemtag
- the tag of the associated input streamaccumulateFn
- the accumulate
primitive. It must be
stateless and cooperative.@Nonnull public AggregateOperationBuilder.VarArity<A,R> andCombine(@Nullable BiConsumerEx<? super A,? super A> combineFn)
combine
primitive.
The given function must be stateless and cooperative.
@Nonnull public AggregateOperationBuilder.VarArity<A,R> andDeduct(@Nullable BiConsumerEx<? super A,? super A> deductFn)
deduct
primitive.
The given function must be stateless and cooperative.
@Nonnull public <R_NEW> AggregateOperationBuilder.VarArity<A,R_NEW> andExport(@Nonnull FunctionEx<? super A,? extends R_NEW> exportFn)
export
primitive.
The given function must be stateless and cooperative.
@Nonnull public AggregateOperation<A,R> andFinish(@Nonnull FunctionEx<? super A,? extends R> finishFn)
finish
primitive.
Constructs and returns an AggregateOperation
from the current
state of the builder.
The given function must be stateless and cooperative.
IllegalStateException
- if the export
primitive was
not registered@Nonnull public <R_NEW> AggregateOperation<A,R_NEW> andExportFinish(@Nonnull FunctionEx<? super A,? extends R_NEW> exportFinishFn)
export
and finish
primitive.
Constructs and returns an AggregateOperation
from the current
state of the builder.
The given function must be stateless and cooperative.
IllegalStateException
- if the export
primitive is
already registeredCopyright © 2023 Hazelcast, Inc.. All rights reserved.