You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently required property of @JsonProperty is only provided as metadata, and used for creating things like JSON Schemas. Deserialization does not enforce required-ness due to technical difficulties; specifically, since JsonDeserializer instances can not have state (they are shared and need to be stateless), any state needs to be either stored in DeserializationContext somehow, or carried along as extra parameter throughout internal calls within BeanDeserializer.
However: handling of Creator methods is different in that state is already tracked: values of Creator parameters must be buffered, to be passed when everything has been collected. Adding bit of extra tracking and checking for required-ness should be much less work.
The initial implementation could just use required property; and once this works, additional functionality for per-creator/global-defaults (DeserializationFeature) may be considered as well.
The text was updated successfully, but these errors were encountered:
Currently
required
property of@JsonProperty
is only provided as metadata, and used for creating things like JSON Schemas. Deserialization does not enforce required-ness due to technical difficulties; specifically, sinceJsonDeserializer
instances can not have state (they are shared and need to be stateless), any state needs to be either stored inDeserializationContext
somehow, or carried along as extra parameter throughout internal calls withinBeanDeserializer
.However: handling of Creator methods is different in that state is already tracked: values of Creator parameters must be buffered, to be passed when everything has been collected. Adding bit of extra tracking and checking for required-ness should be much less work.
The initial implementation could just use
required
property; and once this works, additional functionality for per-creator/global-defaults (DeserializationFeature
) may be considered as well.The text was updated successfully, but these errors were encountered: