У меня есть конкретный JSON Node, который соответствует import org.codehaus.jackson.JsonNode, а не import org.codehaus.jackson.map.JsonNode.
[
{
"givenName": "Jim",
"formattedName": "jimJackson",
"familyName": null,
"middleName": "none",
"honorificPrefix": "mr",
"honorificSuffix": "none"
},
{
"givenName": "john",
"formattedName": "johnLasher",
"familyName": null,
"middleName": "none",
"honorificPrefix": "mr",
"honorificSuffix": "none"
},
{
"givenName": "carlos",
"formattedName": "carlosAddner",
"familyName": null,
"middleName": "none",
"honorifiPrefix": "mr",
"honorificSuffix": "none"
},
{
"givenName": "lisa",
"formattedName": "lisaRay",
"familyName": null,
"middleName": "none",
"honorificPrefix": "mrs",
"honorificSuffix": "none"
},
{
"givenName": "bradshaw",
"formattedName": "bradshawLion",
"familyName": null,
"middleName": "none",
"honorificPrefix": "mr",
"honorificSuffix": "none"
},
{
"givenName": "phill",
"formattedName": "phillKane",
"familyName": null,
"middleName": "none",
"honorificPrefix": "mr",
"honorificSuffix": "none"
},
{
"givenName": "Gabriel",
"formattedName": "gabrielMoosa",
"familyName": null,
"middleName": "none",
"honorificPrefix": "mr",
"honorificSuffix": "none"
}
]
Я хочу удалить "familyName" и "middleName" из всех узлов JSON указанного массива. Есть ли способ достичь этого?