jackson-annotations
jackson-annotations copied to clipboard
enable @jsonignores ignore property of property of and more...
suppose we have Product Object it has
Attribute["attributeValues"]
->
AttributeValue["products"]
->
Product["seller"]
->
Seller["shops"]
->
Shop["attributes"]
->
Attribute["attributeValues"]
->
AttributeValue["products"]
->
Product["seller"]
Seller["shops"]
->
Shop["attributes"]
->
Attribute["attributeValues"]
we need something like
@JsonIgnoreProperties(value = {"products","shops['products'],"S['X[""Z]']""})
No, Jackson does not support such nested configuration. The reason is technical, in that serializers/deserializers do not have access in hierarchy beyond immediate next level: because of this, annotations cannot specify deeper processing constraints either.
You can add @JsonIgnoreProperties on fields, however, to do some of what you want.
But it does and will not support general path expressions.