Hello,
This is a module code to retrieve value from complex structure (combination of list, map, array and primitives types).
Give the path with a dot (.) separator to get the value or the default value if not accessible.
example : m=createmap("Name":"John" ,"Friends":array as map(createmap("Name":"Alan","Age":30),createmap("Name":"Mary","Age":28)))
get(m,"Friends.1.Age","Not Found") returns 28
get(m,"Friends.3.Age","Not Found") returns "Not Found"
This module runs on B4J and B4A
spsp
This is a module code to retrieve value from complex structure (combination of list, map, array and primitives types).
Give the path with a dot (.) separator to get the value or the default value if not accessible.
example : m=createmap("Name":"John" ,"Friends":array as map(createmap("Name":"Alan","Age":30),createmap("Name":"Mary","Age":28)))
get(m,"Friends.1.Age","Not Found") returns 28
get(m,"Friends.3.Age","Not Found") returns "Not Found"
This module runs on B4J and B4A
spsp
Attachments
Last edited: