GLib.DateTime.new_from_timeval_local
function new_from_timeval_local(tv: GLib.TimeVal): GLib.DateTime { // Gjs wrapper for g_date_time_new_from_timeval_local() }
Creates a GLib.DateTime corresponding to the given GLib.TimeVal tv in the local time zone.
The time contained in a GLib.TimeVal is always stored in the form of seconds elapsed since 1970-01-01 00:00:00 UTC, regardless of the local time offset.
This call can fail (returning null) if tv represents a time outside of the supported range of GLib.DateTime.
You should release the return value by calling GLib.DateTime.prototype.unref when you are done with it.
Since 2.26
- tv
- Returns
a new GLib.DateTime, or null