TemporalZ

from

Parses a ZonedDateTime from a string, with optional disambiguation and offset options.

See: Temporal.ZonedDateTime.from

Parameters

#
s:[]const u8
[]const u8
time_zone:?TimeZone
?TimeZone
disambiguation:Disambiguation
Disambiguation
offset_disambiguation:OffsetDisambiguation
OffsetDisambiguation

Source

Implementation

#
pub fn from(s: []const u8, time_zone: ?TimeZone, disambiguation: Disambiguation, offset_disambiguation: OffsetDisambiguation) !ZonedDateTime {
    _ = time_zone; // The time zone is parsed from the string
    const view = abi.toDiplomatStringView(s);
    return wrapZonedDateTime(abi.c.temporal_rs_ZonedDateTime_from_utf8(view, abi.to.toDisambiguation(disambiguation), abi.to.toOffsetDisambiguation(offset_disambiguation)));
}