M
- the type of input messageWK
- the type of key for the windowWV
- the type of aggregated value in the window output@InterfaceStability.Unstable public final class WindowInternal<M,WK,WV> extends java.lang.Object implements Window<M,WK,WV>
Window
. This specifies default, early and late triggers for the Window
and whether to accumulate or discard previously emitted panes.
Note: This class is meant to be used internally by Samza, and is not to be instantiated by programmers.Constructor and Description |
---|
WindowInternal(Trigger<M> defaultTrigger,
SupplierFunction<WV> initializer,
FoldLeftFunction<M,WV> foldLeftFunction,
MapFunction<M,WK> keyExtractor,
MapFunction<M,java.lang.Long> eventTimeExtractor,
WindowType windowType,
Serde<WK> keySerde,
Serde<WV> windowValueSerde,
Serde<M> msgSerde) |
Modifier and Type | Method and Description |
---|---|
AccumulationMode |
getAccumulationMode() |
Trigger<M> |
getDefaultTrigger() |
Trigger<M> |
getEarlyTrigger() |
MapFunction<M,java.lang.Long> |
getEventTimeExtractor() |
FoldLeftFunction<M,WV> |
getFoldLeftFunction() |
SupplierFunction<WV> |
getInitializer() |
MapFunction<M,WK> |
getKeyExtractor() |
Serde<WK> |
getKeySerde() |
Trigger<M> |
getLateTrigger() |
AccumulationMode |
getMode() |
Serde<M> |
getMsgSerde() |
WindowType |
getWindowType() |
Serde<WV> |
getWindowValSerde() |
Window<M,WK,WV> |
setAccumulationMode(AccumulationMode mode)
Specify how a
Window should process its previously emitted WindowPane s. |
Window<M,WK,WV> |
setEarlyTrigger(Trigger<M> trigger)
Set the early triggers for this
Window . |
Window<M,WK,WV> |
setLateTrigger(Trigger<M> trigger)
Set the late triggers for this
Window . |
public WindowInternal(Trigger<M> defaultTrigger, SupplierFunction<WV> initializer, FoldLeftFunction<M,WV> foldLeftFunction, MapFunction<M,WK> keyExtractor, MapFunction<M,java.lang.Long> eventTimeExtractor, WindowType windowType, Serde<WK> keySerde, Serde<WV> windowValueSerde, Serde<M> msgSerde)
public SupplierFunction<WV> getInitializer()
public FoldLeftFunction<M,WV> getFoldLeftFunction()
public MapFunction<M,WK> getKeyExtractor()
public MapFunction<M,java.lang.Long> getEventTimeExtractor()
public WindowType getWindowType()
public AccumulationMode getAccumulationMode()
public AccumulationMode getMode()
public Window<M,WK,WV> setEarlyTrigger(Trigger<M> trigger)
Window
public Window<M,WK,WV> setLateTrigger(Trigger<M> trigger)
Window
public Window<M,WK,WV> setAccumulationMode(AccumulationMode mode)
Window
Window
should process its previously emitted WindowPane
s.
There are two types of AccumulationMode
s:
setAccumulationMode
in interface Window<M,WK,WV>
mode
- the accumulation modeWindow
function with mode
set as its AccumulationMode
.