Function serialize
Source pub fn serialize<S>(
value: &Option<bool>,
serializer: S,
) -> Result<S::Ok, S::Error>
Expand description
Serializes an optional boolean value to its string representation
Converts true to “1” and false to “0”
§Arguments
value - The optional boolean value to serialize
serializer - The serializer to use
§Returns
A Result containing the serialized value or an error