Interface DeserializationConfiguration
public interface DeserializationConfiguration
Configuration for deserialization.
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic enumDeserialization format features. -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Set<DeserializationConfiguration.Feature> static final String -
Method Summary
Modifier and TypeMethodDescriptiondefault booleanDetermines whether to accept case-insensitive enumeration values during deserialization.default booleanDetermines whether properties should be matched case-insensitively.default booleanDetermines whether scalar values can be accepted as single-element arrays.default booleanDetermines whether temporal values are adjusted to the configured context time zone.default booleanDetermines whether generated deserializers should fall back to the runtime deserializer.default Set<DeserializationConfiguration.Feature> features()Returns the active format features for deserialization.features(@Nullable DeserializationConfiguration configuration) Resolve the active format features for the given deserialization configuration.intdefault booleanWhether a null field for a primitive should fail the deserialization.booleanWhether to ignore unknown values during deserialization.booleanWhether null field should be annotated with a nullable annotations.default booleanWhether the supertype is used by default when no supertype is resolved.default booleanDetermines whether numeric timestamps are read with nanosecond precision.default booleanDetermines whether unknown enum values should deserialize asnull.default booleanDetermines whether unknown enum values should use the configured default enum value.
-
Field Details
-
PREFIX
- See Also:
-
DEFAULT_FEATURES
-
-
Method Details
-
isIgnoreUnknown
@Bindable(defaultValue="true") boolean isIgnoreUnknown()Whether to ignore unknown values during deserialization.- Returns:
- True if unknown values should simply be ignored.
-
getArraySizeThreshold
@Bindable(defaultValue="100") int getArraySizeThreshold()- Returns:
- The array size thresh hold for use in binding. Defaults to
100.
-
isStrictNullable
@Bindable(defaultValue="false") boolean isStrictNullable()Whether null field should be annotated with a nullable annotations. Defaults tofalse- Returns:
- True if null field should be annotated with a nullable annotations
-
isFailOnNullForPrimitives
@Bindable(defaultValue="true") default boolean isFailOnNullForPrimitives()Whether a null field for a primitive should fail the deserialization. Defaults totrue- Returns:
- True if a null field for a primitive should fail the deserialization
-
isSubtypesRequireDefaultImpl
@Bindable(defaultValue="true") default boolean isSubtypesRequireDefaultImpl()Whether the supertype is used by default when no supertype is resolved.- Returns:
- True to avoid the supertype and use `defaultImpl` property
-
acceptCaseInsensitiveEnums
@Bindable(defaultValue="false") default boolean acceptCaseInsensitiveEnums()Determines whether to accept case-insensitive enumeration values during deserialization. By default, case-insensitive enums are not accepted.- Returns:
trueif case-insensitive enumeration values are accepted;falseotherwise- Since:
- 2.15.2
-
acceptSingleValueAsArray
@Bindable(defaultValue="false") default boolean acceptSingleValueAsArray()Determines whether scalar values can be accepted as single-element arrays.- Returns:
trueif scalar values can be read as arrays- Since:
- 3.0
-
acceptCaseInsensitiveProperties
@Bindable(defaultValue="false") default boolean acceptCaseInsensitiveProperties()Determines whether properties should be matched case-insensitively.- Returns:
trueif property names are case-insensitive- Since:
- 3.0
-
readUnknownEnumValuesAsNull
@Bindable(defaultValue="false") default boolean readUnknownEnumValuesAsNull()Determines whether unknown enum values should deserialize asnull.- Returns:
trueif unknown enum values should deserialize asnull- Since:
- 3.0
-
readUnknownEnumValuesUsingDefaultValue
@Bindable(defaultValue="false") default boolean readUnknownEnumValuesUsingDefaultValue()Determines whether unknown enum values should use the configured default enum value.- Returns:
trueif unknown enum values should use the default enum value- Since:
- 3.0
-
readDateTimestampsAsNanoseconds
@Bindable(defaultValue="true") default boolean readDateTimestampsAsNanoseconds()Determines whether numeric timestamps are read with nanosecond precision.- Returns:
trueif numeric timestamps use nanoseconds- Since:
- 3.0
-
adjustDatesToContextTimeZone
@Bindable(defaultValue="false") default boolean adjustDatesToContextTimeZone()Determines whether temporal values are adjusted to the configured context time zone.- Returns:
trueif dates should be adjusted to the context time zone- Since:
- 3.0
-
disableGeneratedDeserializer
@Bindable(defaultValue="false") default boolean disableGeneratedDeserializer()Determines whether generated deserializers should fall back to the runtime deserializer.- Returns:
trueif generated deserializers should be disabled- Since:
- 3.0
-
features
Returns the active format features for deserialization.- Returns:
- The active format features for deserialization.
- Since:
- 3.0
-
features
static Set<DeserializationConfiguration.Feature> features(@Nullable DeserializationConfiguration configuration) Resolve the active format features for the given deserialization configuration.- Parameters:
configuration- The deserialization configuration- Returns:
- The active format features
- Since:
- 3.0
-