R - The type of reference used to select data from input tuples in this context.F - The type of ConsumerFunction wrapped by the context.public class ConsumerFunctionContext<R,F extends ConsumerFunction> extends FunctionContext<F>
ConsumerFunctionContext wraps a ConsumerFunction, and provides the
references to select data from an input Tuple so they can be consumed by the function.| Modifier and Type | Class and Description |
|---|---|
static class |
ConsumerFunctionContext.Builder<R,F extends ConsumerFunction>
Implementation of the Builder pattern for
ConsumerFunctionContext. |
| Constructor and Description |
|---|
ConsumerFunctionContext()
Default constructor - used for serialisation.
|
ConsumerFunctionContext(F function,
List<R> selection)
Create a
ConsumerFunctionContext that selects data from input Tuples using
the specified selection references to pass arguments to the ConsumerFunction. |
| Modifier and Type | Method and Description |
|---|---|
List<R> |
getSelection() |
Object[] |
select(Tuple<R> tuple)
Select data from an input
Tuple. |
void |
setSelection(List<R> selection) |
getFunction, setFunctionpublic ConsumerFunctionContext()
public ConsumerFunctionContext(F function, List<R> selection)
ConsumerFunctionContext that selects data from input Tuples using
the specified selection references to pass arguments to the ConsumerFunction.function - ConsumerFunction to be wrapped by the context.selection - References to select input data.Copyright © 2017. All rights reserved.