junobuild_shared::day

Function calendar_date

Source
pub fn calendar_date(timestamp: &u64) -> CalendarDate
Expand description

Converts a Unix timestamp (in nanoseconds) to a CalendarDate.

§Arguments

  • timestamp: A reference to a u64 Unix timestamp in nanoseconds.

§Returns

A CalendarDate representing the date of the given timestamp.