Description

This predicate is used to convert between local time (taking
into account time zone and daylight savings time settings) and
UTC (Universal Coordinated Time, represented as 'Unix time', i.e.
in seconds since 1970-01-01, 00:00).

The conversion works in both directions. If the UnixTime argument
is instantiated, it gets converted to the local date and time, and
the first 6 arguments get unified accordingly.

If the first 6 (or 7) arguments are instantiated, they will be
interpreted under the current time zone and daylight savings time
rules, and converted into 'Unix time', which is unified with the
last argument.

In both directions, the DST argument can usually remain uninstantiated,
and will be unified with 1 if the date specified is while daylight
savings time is in effect, and 0 otherwise. Note however, that during
the switch from summer to winter time, there is usually a one hour
overlap, where the same time of day exists twice, once in summer and
once in winter time. In this case, when converting from local time
to UTC, the caller should instantiate DST in order to disambiguate.

The predicate can also be used to test for valid local date and time:
If the first 6 (or 7) arguments do not represent a valid date, the
predicate fails.

This predicate is based on the POSIX localtime() and mktime() functions.