Id

Trait Id 

Source
pub trait Id {
    type BaseType;

    // Required method
    fn id(&self) -> Self::BaseType;
}
Expand description

basic Snowflake structure

Required Associated Types§

Source

type BaseType

what the id can be turned to and from

Required Methods§

Source

fn id(&self) -> Self::BaseType

creates the a value of BaseType from the id

Implementors§

Source§

impl<const TS: u8, const PID: u8, const SEQ: u8> Id for snowcloud::i64::SingleIdFlake<TS, PID, SEQ>

Source§

impl<const TS: u8, const PID: u8, const SEQ: u8> Id for snowcloud::u64::SingleIdFlake<TS, PID, SEQ>

Source§

impl<const TS: u8, const PID: u8, const SID: u8, const SEQ: u8> Id for snowcloud::i64::DualIdFlake<TS, PID, SID, SEQ>

Source§

impl<const TS: u8, const PID: u8, const SID: u8, const SEQ: u8> Id for snowcloud::u64::DualIdFlake<TS, PID, SID, SEQ>