pub trait GetSize {
    const USES_DYN_MEM: bool = false;

    fn size_bytes_dyn(&self) -> usize { ... }
    fn size_bytes(&self) -> usize { ... }
}
Expand description

Provides methods to get dynamic and total size of the variable.

Provided Associated Constants

true if and only if the variables of this type can use dynamic (heap) memory.

Provided Methods

Returns approximate number of bytes occupied by dynamic (heap) part of self. Same as self.size_bytes() - std::mem::size_of_val(self).

Returns approximate, total (including heap memory) number of bytes occupied by self.

Implementations on Foreign Types

Implementors