pub trait Hayson: Sized {
// Required methods
fn from_hayson(value: &Value) -> Result<Self, FromHaysonError>;
fn to_hayson(&self) -> Value;
}Expand description
Something which can be converted to and from Hayson (the new JSON encoding used by Project Haystack).
Required Methods§
fn from_hayson(value: &Value) -> Result<Self, FromHaysonError>
fn to_hayson(&self) -> Value
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.