Skip to main content

parse_timezone

Function parse_timezone 

Source
pub fn parse_timezone(tz: &str) -> Result<TimezoneInfo, String>
Expand description

Parse a timezone string.

Supports:

  • IANA timezone names: “America/New_York”, “Europe/London”, “Australia/Sydney”
  • Fixed UTC offsets: “+01:00”, “-05:30”, “02:00” (positive assumed)

Returns a FixedOffset that can be used with chrono.