Skip to main content

reachable_until

Function reachable_until 

Source
pub fn reachable_until(
    length: Length,
    now: i64,
    hours_end: Option<i64>,
    night: Option<i64>,
    waking: Option<i64>,
) -> Option<(i64, bool)>
Expand description

When Reachable pressed now for length ends (Unix seconds), and whether it is “until you turn it off”: hours_end the end of the hours you are in, night the night’s start (by day: the next one), waking the end of the night you are in (none by day). Pressed at night, “until tonight” and “until you turn it off” last until waking. None when it cannot end: no night known, or an end already past.