Trait EncodeExt

Source
pub trait EncodeExt<'a, OUT>: Sized {
    // Required methods
    fn encode<E>(&'a self) -> OUT
       where E: Encode<Target = &'a Self, Output = OUT>;
    fn encode_mut<E>(&'a mut self) -> OUT
       where E: Encode<Target = &'a mut Self, Output = OUT>;
}
Expand description

Trait that provides the encode method for any value.

Required Methods§

Source

fn encode<E>(&'a self) -> OUT
where E: Encode<Target = &'a Self, Output = OUT>,

Call this method if the value is immutable.

Source

fn encode_mut<E>(&'a mut self) -> OUT
where E: Encode<Target = &'a mut Self, Output = OUT>,

Call this method if the value is mutable.

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<'a, T, OUT> EncodeExt<'a, OUT> for T