pub trait JSON: Serialize + for<'de> Deserialize<'de> {
    // Provided methods
    fn to_json(&self) -> Result<String> { ... }
    fn from_json(json: &str) -> Result<Self> { ... }
}Expand description
Handles the to and from JSON conversion.
Provided Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.