Skip to main content

SizeSettings

Trait SizeSettings 

Source
pub trait SizeSettings: EndianSettings {
    const SIZE: Size;

    // Provided methods
    fn size_to_stream<W: Write>(size: usize, stream: &mut W) -> Result<()> { ... }
    fn size_from_stream<R: Read>(stream: &mut R) -> Result<usize> { ... }
}
Expand description

The size settings required for reading and writing collections.

Required Associated Constants§

Source

const SIZE: Size

The size used by these size settings.

Provided Methods§

Source

fn size_to_stream<W: Write>(size: usize, stream: &mut W) -> Result<()>

Writes some size using specific settings.

Source

fn size_from_stream<R: Read>(stream: &mut R) -> Result<usize>

Reads some size using specific settings.

Dyn Compatibility§

This trait is not dyn compatible.

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

Implementors§