serde_this_or_that

Function as_string

Source
pub fn as_string<'de, D>(deserializer: D) -> Result<String, D::Error>
where D: Deserializer<'de>,
Expand description

De-serialize either a null, str, bool, i64, f64, or u64 as an (owned) string value.

ยงReturns

The owned String value of a string, boolean, or number.