pub trait FromJson<T> {
// Required method
fn from_json(json: &Value) -> Result<T>;
// Provided method
fn from_json_string(json_str: &str) -> Result<T> { ... }
}
Expand description
Convert from JSON to SWIFT message
Required Methods§
Provided Methods§
Sourcefn from_json_string(json_str: &str) -> Result<T>
fn from_json_string(json_str: &str) -> Result<T>
Parse from JSON string
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.