TimeZone
Creates a #GTimeZone corresponding to UTC.
This is equivalent to calling g_time_zone_new() with a value like "Z", "UTC", "+00", etc.
You should release the return value by calling g_time_zone_unref() when you are done with it.
Return
the universal timezone
Since
2.26
⚠️ Deprecated ⚠️
This is deprecated since version 2.68.
Use g_time_zone_new_identifier() instead, as it provides error reporting. Change your code to handle a potentially %NULL return value.
A version of g_time_zone_new_identifier() which returns the UTC time zone if @identifier could not be parsed or loaded.
If you need to check whether @identifier was loaded successfully, use g_time_zone_new_identifier().
Return
the requested timezone
Since
2.26
Parameters
a timezone identifier
Creates a #GTimeZone corresponding to the given constant offset from UTC, in seconds.
This is equivalent to calling g_time_zone_new() with a string in the form [+|-]hh[:mm[:ss]]
.
It is possible for this function to fail if @seconds is too big (greater than 24 hours), in which case this function will return the UTC timezone for backwards compatibility. To detect failures like this, use g_time_zone_new_identifier() directly.
Return
a timezone at the given offset from UTC, or UTC on failure
Since
2.58
Parameters
offset to UTC, in seconds