Struct dflake::Dflake[][src]

pub struct Dflake {
    pub timestamp: u32,
    pub worker_id: u8,
    pub process_id: u8,
    pub increment: u16,
    // some fields omitted

Structure holding a valid Discord snowflake.


timestamp: u32

Unix timestamp in miliseconds, represented as an u32.

worker_id: u8

Internal worker ID.

process_id: u8

Internal process ID.

increment: u16

The amount of times an ID was created on a process.


impl Dflake[src]

pub fn raw(&self) -> u64[src]

Returns the raw u64 this Dflake was made from.

Trait Implementations

impl Clone for Dflake[src]

impl Copy for Dflake[src]

impl Debug for Dflake[src]

impl Eq for Dflake[src]

impl Ord for Dflake[src]

impl PartialEq<Dflake> for Dflake[src]

impl PartialOrd<Dflake> for Dflake[src]

impl StructuralEq for Dflake[src]

impl StructuralPartialEq for Dflake[src]

Auto Trait Implementations

impl RefUnwindSafe for Dflake

impl Send for Dflake

impl Sync for Dflake

impl Unpin for Dflake

impl UnwindSafe for Dflake

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized

impl<T> Borrow<T> for T where
    T: ?Sized

impl<T> BorrowMut<T> for T where
    T: ?Sized

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 

impl<T> ToOwned for T where
    T: Clone

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.