Class TupleCompositeMultiplyByExample
- java.lang.Object
-
- uk.gov.gchq.koryphe.example.KorypheExample<I,O>
-
- uk.gov.gchq.koryphe.example.KorypheFunctionExample<Tuple<String>,Tuple<String>>
-
- uk.gov.gchq.koryphe.example.function.TupleCompositeMultiplyByExample
-
public class TupleCompositeMultiplyByExample extends KorypheFunctionExample<Tuple<String>,Tuple<String>>
This example shows a composite function that operates on a complex input object. It uses aTupleAdaptedFunctionComposite
containing 2MultiplyBy
functions, one that creates the field 'E' by multiplying the field 'A' by2
and another that creates the field 'D' by multiplying the field 'B' by3
.The input values
{{A:1, B:2, C:3}, {A:4, B:5, C:6}, {A:7, B:8, C:9}}
produces the result{{A:1, B:2, C:3, D:6, E:2}, {A:4, B:5, C:6, D:15, E:8}, {A:7, B:8, C:9, D:24, E:14}}
.
-
-
Constructor Summary
Constructors Constructor Description TupleCompositeMultiplyByExample()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Function<Tuple<String>,Tuple<String>>
getFunction()
Stream<Tuple<String>>
getInput()
-
Methods inherited from class uk.gov.gchq.koryphe.example.KorypheExample
execute, printInput, printOutput, printValue
-
-