One offset a custom time zone observes, and when it starts (RFC 8984 ยง4.7.2).
A rule is the JSCalendar equivalent of an iCalendar STANDARD or
DAYLIGHT subcomponent: from start, the zone stops using
offset_from and begins using offset_to, and recurrence_rules
says when that happens again.
start is a local time in offset_from โ the offset being left, not
the one being joined โ because the transition is announced in the
clock reading that people still have at that moment.
Summary
Functions
Read this object from a decoded JSON map.
The @type value RFC 8984 gives this object.
Write this object back to a JSON-ready map.
Types
@type t() :: %JSCalendar.TimeZoneRule{ comments: [String.t()] | nil, extra: map(), names: MapSet.t() | nil, offset_from: String.t() | nil, offset_to: String.t() | nil, recurrence_overrides: %{optional(NaiveDateTime.t()) => JSCalendar.Patch.t()} | nil, recurrence_rules: [JSCalendar.RecurrenceRule.t()] | nil, start: NaiveDateTime.t() | nil }
Functions
Read this object from a decoded JSON map.
Arguments
mapis a map with string keys, as:json.decode/1returns.
Returns
{:ok, object}; or{:error, reason}when a property does not match its declared type.
@spec jscalendar_type() :: String.t()
The @type value RFC 8984 gives this object.
Returns
- the type name as a string.
Write this object back to a JSON-ready map.
Arguments
objectis at/0.
Returns
- a map with string keys, ready for
:json.encode/1.