Skip to main content

deserialize_with_context

Function deserialize_with_context 

Source
pub fn deserialize_with_context<T, E>(
    json: &str,
    context: &str,
    error_mapper: impl FnOnce(Error, &str) -> E,
) -> Result<T, E>
Expand description

Deserialize a JSON string, mapping any error through error_mapper.