'I am trying to update value in map whose key is child node. put method is not working
formJson {
"NTLFee": 0,
"OperationType": "Y",
"MobileLobList": [
{
"GrossPremium": 1227.72,
"MobileCoverageList": [
{ "Vat": 0 } ],
"MobileElementId": 195490042,
"MobileId": 195490040,
"MobileRiskList": [
{ isAppilcable=’Y’,
"MobileStatus"=2}
]
]
In java i have
public Map copyMobile(Long mobileId)
{
Map result = mobileRestful.copyMobile(mobileId);
result = copiedMobileConverter.getMobileCopyConverter(result).convert(result, null);
return result;
}
I want to update the MobileStatus in Map result.... I am trying result.put("MobileStatus",3) but it is not working as it is child node you can see in Json result. How can i access and update it.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
