Trait bebop::FixedSized

source ·
pub trait FixedSized: Copy + Sized {
    const SERIALIZED_SIZE: usize = _;
}
Expand description

A trait which should be given to any type which will always take up the same amount of space when serialized. This goes one step beyond the Sized trait which only requires it to take up a set amount of space on the stack. This is saying that the total data it contains and points to must always be of the exact same size for every instance.

Provided Associated Constants§

Implementations on Foreign Types§

source§

impl FixedSized for i16

source§

impl FixedSized for f64

source§

impl FixedSized for f32

source§

impl FixedSized for u16

source§

impl FixedSized for u128

source§

impl FixedSized for i64

source§

impl<T: FixedSized, const S: usize> FixedSized for [T; S]

source§

impl FixedSized for u8

source§

impl FixedSized for isize

source§

impl FixedSized for i8

source§

impl FixedSized for i32

source§

impl FixedSized for u32

source§

impl FixedSized for usize

source§

impl FixedSized for u64

source§

impl FixedSized for i128

source§

impl FixedSized for char

source§

impl FixedSized for bool

Implementors§