ToList
See javadoc - uk.gov.gchq.koryphe.impl.function.ToList
Available since Koryphe version 1.6.0
Converts an Object to a List
Examples
To list
Java
JSON
Full JSON
Python
final ToList function = new ToList();
{
"class" : "uk.gov.gchq.koryphe.impl.function.ToList"
}
{
"class" : "uk.gov.gchq.koryphe.impl.function.ToList"
}
g.ToList()
Input type:
java.lang.Object
Example inputs:
Input Type | Input | Result Type | Result |
---|---|---|---|
java.lang.String | test | java.util.ArrayList | [test] |
null | java.util.ArrayList | [null] | |
java.lang.Long | 30 | java.util.ArrayList | [30] |
uk.gov.gchq.gaffer.types.TypeSubTypeValue | TypeSubTypeValue[type=t,subType=st,value=v] | java.util.ArrayList | [TypeSubTypeValue[type=t,subType=st,value=v]] |
[Ljava.lang.String; | [a, b, c] | java.util.ArrayList | [a, b, c] |
java.util.HashSet | [1, 2] | java.util.ArrayList | [1, 2] |