Table of Contents

Enum DeserializeDefaultValuesPolicy

Namespace
Nerdbank.MessagePack
Assembly
Nerdbank.MessagePack.dll

Enumerates policies that control how deserialization handles default values.

[Flags]
public enum DeserializeDefaultValuesPolicy

Fields

AllowMissingValuesForRequiredProperties = 3

Allows deserialization to succeed even if required properties are not specified in the data stream. These will be left at their default values.

This flag includes AllowNullValuesForNonNullableProperties, since accepting missing values will tend to leave reference typed properties at their default null values.

AllowNullValuesForNonNullableProperties = 1

Allow a null value to be deserialized into a non-nullable property.

Default = 0

Deserialization will fail if any required properties have no specified values in the data stream, or when null values are encountered for non-nullable properties.