Skip to main content

Split

Trait Split 

Source
pub trait Split: Key {
    // Required method
    fn split_last<'k>(key: &'k Self::Borrowed) -> (Self::Read<'k>, u8);
}
Expand description

Key types that can split off their last byte, which enables an efficient set implementation.

Required Methods§

Source

fn split_last<'k>(key: &'k Self::Borrowed) -> (Self::Read<'k>, u8)

Split a key into a reader and the last byte.

Dyn Compatibility§

This trait is not dyn compatible.

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

Implementations on Foreign Types§

Source§

impl Split for u16

Source§

fn split_last<'k>(key: &'k Self::Borrowed) -> (Self::Read<'k>, u8)

Source§

impl Split for u32

Source§

fn split_last<'k>(key: &'k Self::Borrowed) -> (Self::Read<'k>, u8)

Source§

impl Split for u64

Source§

fn split_last<'k>(key: &'k Self::Borrowed) -> (Self::Read<'k>, u8)

Source§

impl Split for u128

Source§

fn split_last<'k>(key: &'k Self::Borrowed) -> (Self::Read<'k>, u8)

Source§

impl<const N: usize> Split for [u8; N]

Source§

fn split_last<'k>(key: &'k Self::Borrowed) -> (Self::Read<'k>, u8)

Implementors§