public class UnflatTupleOperator extends Object
Say you have an input tuple containing
{ "top.a"="1" "top.b"="hello world" "c"="[1,2,3]" }
If you run :
Tuple nested = unflatTuple().on(input);
it produces a tuple 'nested' containing:
* { "top" : { "a"=1, "b"="hello world"}, "c"=[1,2,3] }
Constructor and Description |
---|
UnflatTupleOperator()
Create a new ToFlatTupleOperator operator.
|
Modifier and Type | Method and Description |
---|---|
UnflatTupleOperator |
nestedSeparator(String separator)
Set the string to be used to separate nested properties when creating the tuple keys.
|
Tuple |
on(Tuple input)
Make the operator work on an input Tuple.
|
public UnflatTupleOperator()
public Tuple on(Tuple input)
input
- the input Tuplepublic UnflatTupleOperator nestedSeparator(String separator)
separator
- the separator you want.Copyright © 2023. All rights reserved.