public class ReduceWindowFunctionWithWindow<K,W extends Window,T> extends RichWindowFunction<T,org.apache.flink.api.java.tuple.Tuple2<W,T>,K,W>
| Constructor and Description |
|---|
ReduceWindowFunctionWithWindow(ReduceFunction<T> reduceFunction) |
| Modifier and Type | Method and Description |
|---|---|
void |
apply(K k,
W window,
Iterable<T> values,
Collector<org.apache.flink.api.java.tuple.Tuple2<W,T>> out)
Evaluates the window and outputs none or several elements.
|
void |
close() |
void |
open(Configuration parameters) |
void |
setRuntimeContext(RuntimeContext ctx) |
getIterationRuntimeContext, getRuntimeContextpublic ReduceWindowFunctionWithWindow(ReduceFunction<T> reduceFunction)
public void setRuntimeContext(RuntimeContext ctx)
setRuntimeContext in interface RichFunctionsetRuntimeContext in class AbstractRichFunctionpublic void open(Configuration parameters) throws Exception
open in interface RichFunctionopen in class AbstractRichFunctionExceptionpublic void close()
throws Exception
close in interface RichFunctionclose in class AbstractRichFunctionExceptionpublic void apply(K k, W window, Iterable<T> values, Collector<org.apache.flink.api.java.tuple.Tuple2<W,T>> out) throws Exception
WindowFunctionk - The key for which this window is evaluated.window - The window that is being evaluated.values - The elements in the window being evaluated.out - A collector for emitting elements.Exception - The function may throw exceptions to fail the program and trigger recovery.Copyright © 2014–2016 The Apache Software Foundation. All rights reserved.