OxL Reference

method Period.ofWeeks

A calendar period of n weeks (7 days each).

Example:

oxl✓ checked in CI
use std.time { Period }

fn main() io {
  print("{Period.ofWeeks(2).days}")
}
Output
14
pub(api) static fn ofWeeks(n: i64) -> Period

Since. 1.0.0-beta

Parameters

NameType
ni64

Returns

Period

Effects

none declared (pure unless the body says otherwise)

Defined in: std/time/time.oxl:919

See also