I have the following map where every key is a map which its values are lists as the following json:
{
"key": {
"source": ["element1", "element2"],
"target": ["element1", "element2"]
},
"key2": {
"source": ["element1"],
"target": ["element1"]
}
}
I want to do the following:
Get key ( get("key2")) which will return the map
Go over every key in this map( source and target)
iterate over each item in the result list (element1, element2)
How can I achieve this?