Expand description
Resolving wall clock (“local”) readings to instants.
Reading a NaiveDateTime as a wall clock time in an IANA timezone does not
always identify a unique instant, because of daylight savings transitions.
Everything that has to make that choice – the cast kernel and the string
parser – goes through resolve_local_offset so that the two cannot drift
apart.
Re-exports§
use chrono::DateTime;🔒use chrono::NaiveDateTime;🔒use chrono::Offset;🔒use chrono::TimeDelta;🔒use chrono::TimeZone;🔒
Functions§
- resolve_
local_ 🔒datetime - Reads
localas a wall clock time intz, resolving daylight savings ambiguities and gaps as described onresolve_local_offset. - resolve_
local_ 🔒offset - Returns the offset to use when interpreting
localas a wall clock reading intz, orNoneif it cannot be resolved.