[][src]Struct types::slot_epoch::Slot

pub struct Slot(_);

Methods

impl Slot[src]

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

impl Slot[src]

pub fn as_usize(&self) -> usize[src]

impl Slot[src]

pub fn saturating_sub<T: Into<Slot>>(&self, other: T) -> Slot[src]

pub fn saturating_add<T: Into<Slot>>(&self, other: T) -> Slot[src]

pub fn checked_div<T: Into<Slot>>(&self, rhs: T) -> Option<Slot>[src]

pub fn is_power_of_two(&self) -> bool[src]

impl Slot[src]

pub fn new(slot: u64) -> Slot[src]

pub fn epoch(self, slots_per_epoch: u64) -> Epoch[src]

pub fn height(self, genesis_slot: Slot) -> SlotHeight[src]

pub fn max_value() -> Slot[src]

Trait Implementations

impl TestRandom for Slot[src]

impl Into<u64> for Slot[src]

impl Into<usize> for Slot[src]

impl Eq for Slot[src]

impl Default for Slot[src]

impl Clone for Slot[src]

impl PartialOrd<Slot> for Slot[src]

fn partial_cmp(&self, other: &Slot) -> Option<Ordering>[src]

Utilizes partial_cmp on the underlying u64.

impl PartialOrd<u64> for Slot[src]

fn partial_cmp(&self, other: &u64) -> Option<Ordering>[src]

Utilizes partial_cmp on the underlying u64.

impl PartialEq<Slot> for Slot[src]

impl PartialEq<u64> for Slot[src]

impl Ord for Slot[src]

impl From<u64> for Slot[src]

impl From<usize> for Slot[src]

impl Copy for Slot[src]

impl Hash for Slot[src]

impl Add<Slot> for Slot[src]

type Output = Slot

The resulting type after applying the + operator.

impl Add<u64> for Slot[src]

type Output = Slot

The resulting type after applying the + operator.

impl Sub<Slot> for Slot[src]

type Output = Slot

The resulting type after applying the - operator.

impl Sub<u64> for Slot[src]

type Output = Slot

The resulting type after applying the - operator.

impl Mul<Slot> for Slot[src]

type Output = Slot

The resulting type after applying the * operator.

impl Mul<u64> for Slot[src]

type Output = Slot

The resulting type after applying the * operator.

impl Div<Slot> for Slot[src]

type Output = Slot

The resulting type after applying the / operator.

impl Div<u64> for Slot[src]

type Output = Slot

The resulting type after applying the / operator.

impl Rem<Slot> for Slot[src]

type Output = Slot

The resulting type after applying the % operator.

impl Rem<u64> for Slot[src]

type Output = Slot

The resulting type after applying the % operator.

impl AddAssign<Slot> for Slot[src]

impl AddAssign<u64> for Slot[src]

impl SubAssign<Slot> for Slot[src]

impl SubAssign<u64> for Slot[src]

impl MulAssign<Slot> for Slot[src]

impl MulAssign<u64> for Slot[src]

impl DivAssign<Slot> for Slot[src]

impl DivAssign<u64> for Slot[src]

impl Debug for Slot[src]

impl Display for Slot[src]

impl TreeHash for Slot[src]

impl Serialize for Slot[src]

impl<'de> Deserialize<'de> for Slot[src]

impl Decode for Slot[src]

impl Encode for Slot[src]

impl Value for Slot[src]

Auto Trait Implementations

impl Send for Slot

impl Unpin for Slot

impl Sync for Slot

impl UnwindSafe for Slot

impl RefUnwindSafe for Slot

Blanket Implementations

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

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

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

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

impl<V, T> VZip<V> for T where
    V: MultiLane<T>, 

impl<T> DeserializeOwned for T where
    T: Deserialize<'de>, 
[src]

impl<T, Rhs, Output> NumOps<Rhs, Output> for T where
    T: Sub<Rhs, Output = Output> + Mul<Rhs, Output = Output> + Div<Rhs, Output = Output> + Add<Rhs, Output = Output> + Rem<Rhs, Output = Output>, 
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> SendSyncUnwindSafe for T where
    T: Send + Sync + UnwindSafe + ?Sized