unix_time_to_enclosing_slot

Function unix_time_to_enclosing_slot 

Source
pub fn unix_time_to_enclosing_slot(
    unix_time: u64,
    slot_config: &SlotConfig,
) -> u64
Expand description

Convert a POSIX time to the enclosing slot number.

§Arguments

  • unix_time - The POSIX time in milliseconds
  • slot_config - The slot configuration for the network

§Returns

The slot number that contains the given time