chaperon v0.3.1 Chaperon.Timing View Source
Timing related helper functions and type definitions used within Chaperon
.
Link to this section Summary
Functions
Returns the correct amount of milliseconds for a given amount of days.
Returns the correct amount of milliseconds for a given amount of hours.
Returns the correct amount of milliseconds for a given amount of minutes.
Returns the correct amount of milliseconds for a given amount of seconds.
Returns a timestamp with the given time unit.
Returns the correct amount of milliseconds for a given amount of weeks.
Link to this section Types
duration()
View Sourceduration() :: duration_number() | {:random, duration_number()}
duration_number()
View Sourceduration_number() :: non_neg_integer() | float() | Range.t()
time_unit()
View Sourcetime_unit() :: :seconds | :milli_seconds | :micro_seconds | :nano_seconds
Link to this section Functions
Returns the correct amount of milliseconds for a given amount of days.
Returns the correct amount of milliseconds for a given amount of hours.
Returns the correct amount of milliseconds for a given amount of minutes.
Returns the correct amount of milliseconds for a given amount of seconds.
timestamp(unit \\ :milli_seconds)
View Sourcetimestamp(time_unit()) :: non_neg_integer()
Returns a timestamp with the given time unit.
Returns the correct amount of milliseconds for a given amount of weeks.