pub trait ValueConvertible: Serialize + DeserializeOwned {
// Provided methods
fn to_object(&self) -> Result<Value, ProtocolError>
where Self: Sized { ... }
fn into_object(self) -> Result<Value, ProtocolError>
where Self: Sized { ... }
fn from_object(value: Value) -> Result<Self, ProtocolError>
where Self: Sized { ... }
fn from_object_ref(value: &Value) -> Result<Self, ProtocolError>
where Self: Sized { ... }
}Provided Methods§
fn to_object(&self) -> Result<Value, ProtocolError>where
Self: Sized,
fn into_object(self) -> Result<Value, ProtocolError>where
Self: Sized,
fn from_object(value: Value) -> Result<Self, ProtocolError>where
Self: Sized,
fn from_object_ref(value: &Value) -> Result<Self, ProtocolError>where
Self: Sized,
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.