pub unsafe trait Storable: Ord + 'static {
    type AlignedRef<'a>: Deref<Target = Self> + PointerIntoOwned;
    type BytesRef<'a>: Deref<Target = [u8]>
    where
        Self: 'a
; const CONST_BYTES_LEN: bool; const OPTIMIZE_INT: bool = false; const TRIVIAL_CMP: bool = false; fn to_bytes(&self) -> Self::BytesRef<'_>; unsafe fn from_bytes_unchecked(bytes: &[u8]) -> Self::AlignedRef<'_>; fn bytes_len(&self) -> usize { ... } unsafe fn cmp_bytes_unchecked(a: &[u8], b: &[u8]) -> Ordering { ... } }
Expand description

Types that can be stored

Required Associated Types

Pointer to aligned version of Self

Pointer to byte representation

Required Associated Constants

Does byte representation have fixed length?

Provided Associated Constants

Is type equivalent to c_uint or c_size_t?

Is Ord consistent with lexicographical sorting of binary representation?

Required Methods

Converts to byte slice

Converts from byte slice

Provided Methods

Length of byte representation

Compares byte representation

Implementations on Foreign Types

Implementors