Trait DynamicCodeWrite

Source
pub trait DynamicCodeWrite {
    // Required method
    fn write<E: Endianness, CW: CodesWrite<E> + ?Sized>(
        &self,
        writer: &mut CW,
        value: u64,
    ) -> Result<usize, CW::Error>;
}
Expand description

A trait providing a method to write a code to a generic CodesWrite.

The difference with StaticCodeWrite is that this trait is more generic, as the CodesWrite is a parameter of the method, and not of the trait.

Required Methods§

Source

fn write<E: Endianness, CW: CodesWrite<E> + ?Sized>( &self, writer: &mut CW, value: u64, ) -> Result<usize, CW::Error>

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 DynamicCodeWrite for Codes

Source§

impl<W: DynamicCodeWrite, const ZETA: usize, const GOLOMB: usize, const EXP_GOLOMB: usize, const RICE: usize, const PI: usize> DynamicCodeWrite for CodesStatsWrapper<W, ZETA, GOLOMB, EXP_GOLOMB, RICE, PI>

Source§

impl<const CODE: usize> DynamicCodeWrite for ConstCode<CODE>