-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Closed
Milestone
Description
(and other inclusion values)
Currently use of something like:
@JsonInclude(Include.NON_EMPTY)
only affects value itself. But for structured values (arrays, Collection
s, Map
s), there is also the question of inclusion strategy for contents.
Currently the only way to control such inclusion is via global feature SerializationFeature.WRITE_NULL_MAP_VALUES
, and that only affects handling of Map
s.
But it would seem reasonable to add an additional property in @JsonInclude
, say, contents
, and modify structured type serializers to consider this for filtering.
The first one to use it with should be Map
(and specialized variants like EnumMap
). But due to amount of work involved, let's add support for arrays and Collection
s if and when specifically requested.
Metadata
Metadata
Assignees
Labels
No labels