Module from_str_allow_null
Expand description
Combines from_str
and allow_null
.
Use this module to serialize and deserialize any T
where T
implements
FromStr
and Display
to convert from or into a string.
The serialized form is that of Option<String>
,
and a nil is deserialized to the Default
value. For JSON, this means both
quoted string values and null
are accepted. A value is always serialized
as Some<String>
.
Note that this can be used for all primitive data types.
Functionsยง
- Deserialize a nullable string into T
- Serialize from T into string