required property Null safety

bool? required
final

Declares annotated field as required for serialization / deserialization process i.e needs to be present explicitly in incoming JSON payload object Optional custom message requiredMessage could be provided as well Mild obligation If set to true states of ignore, ignoreForDeserialization, ignoreForSerialization, ignoreIfNull, Json.ignoreNullMembers has no meaning.

Implementation

final bool? required;