我只想根据我们在属性文件中指定的字段更新JSON结构。
e.g。我有样本JSON:
{"Accounts": [{
"AccountId": "aaa",
"Currency": "xxx",
"Account": {
"SchemeName": "BBAN",
"Identification": "10203345",
"Name": "Lorem"
},
"Servicer": {
"SchemeName": "hhss",
"Identification": "SC802001"
},
"links": {
"self": "/accounts/aaa",
"related": "/accounts"
}
}],
"links": {
"self": "/accounts"
}
}
在我们指定的propery文件中
Accounts
Accounts/AccountId
Accounts/Currency
Accounts/Nickname
Accounts/links
links
现在我要删除属性文件中未指定的所有其他标记。
有人可以帮助我知道我们如何在JAVA中做到这一点?