Skip to main content

WriteVal

Trait WriteVal 

Source
pub trait WriteVal {
    // Required method
    fn write_to<B: JsonBackend>(self, backend: &mut B) -> Result<()>;
}
Expand description

A value that can be written through a JsonBackend.

Required Methods§

Source

fn write_to<B: JsonBackend>(self, backend: &mut B) -> Result<()>

Write self to backend.

§Errors

Returns any error produced while writing the value.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl WriteVal for &str

Source§

fn write_to<B: JsonBackend>(self, backend: &mut B) -> Result<()>

Source§

impl WriteVal for bool

Source§

fn write_to<B: JsonBackend>(self, backend: &mut B) -> Result<()>

Source§

impl WriteVal for u8

Source§

fn write_to<B: JsonBackend>(self, backend: &mut B) -> Result<()>

Source§

impl WriteVal for u32

Source§

fn write_to<B: JsonBackend>(self, backend: &mut B) -> Result<()>

Implementors§