
See the Answer by Ole V.V.: ZoneId.of( "Etc/GMT" ) Politicians around the world have shown a penchant for redefining their time zones with surprising frequency.ĭoes the Java SDK understand this time zone? I say “permanently” with a chuckle, as that really means “until the politicians change their mind again”. For example, in that Africa/Casablanca zone in Morocco, the politicians have decided last year that rather than switching an hour twice a year for standard time & DST, they will now stay permanently on DST year-round.

Most other time zones such as Europe/Berlin or Africa/Casablanca have varied in their offset over history. The string Etc/GMT is a name for a time zone which has had only one offset-from-UTC ever, an offset of zero hours-minutes-seconds. The letter Z (pronounced “Zulu”) seen commonly at the end of date-time strings means the same thing, an offset of zero. The string Etc/GMT is one canonical label for an offset-from-UTC of zero hours-minutes-seconds. Rationale behind Apple using Etc/GMT timezone Never use the terrible legacy classes, Calendar, SimpleDateFormat, and such.įortunately the java.time classes can help you through this muddle. Use java.time classes only for all your date-time work.Never assume the meaning of an input string. Understand the meaning and intentions of those people publishing data.Etc/GMT-12 = +12:00 offset = Twelve hours ahead of UTCĬonfusing? Welcome to the wacky world of date-time handling.Etc/GMT-1 = +01:00 offset = One hour ahead of UTC.Etc/GMT+12 = -12:00 offset = Twelve hours behind UTC.Etc/GMT+1 = -01:00 offset = One hour behind UTC.The Etc/GMT… names carry the opposite plus/minus convention: See this list on Wikipedia (may not be up-to-date). Time zone names are generally in the format Continent/Region, such as America/Edmonton, Europe/Paris, Africa/Tunis, Asia/Kolkata, and Pacific/Auckland. I suggest you learn to think of this manner (right of UTC is positive, left of UTC is negative) as mainstream, and the opposite as a minor annoying variation. So the offsets used by zones in the Americas have negative numbers such as America/Los_Angeles having an offset of -07:00 or -08:00 nowadays (varies during the year because of Daylight Saving Time (DST)).
#Etc utc time zone iso#
In most modern protocols I’ve seen, such as the ISO 8601, offsets ahead of UTC (towards the east) are positive, while offsets behind UTC (towards the west) are negative.

Symmetrically, some considered offsets behind UTC to be negative while others used positive. A time zone is a history of the past, present, and future changes to the offset used by the people of a particular region.ĭifferent protocols in various industries have varied in their numbering, with some considering offsets ahead of UTC to be positive numbers while others used negative. An offset-from-UTC is simply a number of hours-minutes-seconds, ahead of the baseline of UTC, or behind UTC.
