Skip to main content

local_offset

Function local_offset 

Source
pub fn local_offset() -> Option<i16>
Expand description

Minutes local time is ahead of UTC right now, or None when the system does not say.

The offset is read from the system time zone file — what TZ names, or /etc/localtime — once per process. None means there was no such file or it could not be understood: Windows, a system with no zone database, or a TZ holding a POSIX rule rather than a zone name. An application that wants to be exact can tell its user the local time is unknown instead of showing UTC as if it were local.