Trait JSONSerialize

Source
pub trait JSONSerialize
where Self: Serialize,
{ // Provided methods fn write_json<W: Write>(&self, writer: &mut W) -> Result<(), SmolStr> { ... } fn to_json(&self) -> Vec<u8> { ... } }

Provided Methods§

Source

fn write_json<W: Write>(&self, writer: &mut W) -> Result<(), SmolStr>

Source

fn to_json(&self) -> Vec<u8>

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.

Implementors§

Source§

impl<E> JSONSerialize for E
where E: Serialize,