Skip to main content

is_due

Function is_due 

Source
pub fn is_due(
    policy: RefreshPolicy,
    now_secs: u64,
    last_run: Option<u64>,
) -> bool
Expand description

Decide whether a single measure is due to refresh.

  • Manual — never scheduled (only refresh/refresh-all run it).
  • OnLoad — due once, when it has never run in this daemon session (last_run is None).
  • Interval { secs } — due when it has never run, or when now_secs is at least secs past last_run.