Tempo.Range (Tempo v0.5.0)

Copy Markdown View Source

A pair of Tempo values denoting a range, produced by the ISO 8601-2 range operator (2022..2024). The first and last bounds are inclusive — contrast with %Tempo.Interval{} which uses the half-open [from, to) convention.

Open-ended ranges are represented by :undefined on either endpoint (../2024, 2022/.., ../..).

Summary

Types

endpoint()

@type endpoint() :: Tempo.t() | :undefined

t()

@type t() :: %Tempo.Range{first: endpoint(), last: endpoint()}