View Source LocalTime (local_time v0.1.1)
Documentation for LocalTime
.
Summary
Functions
Converts anything to local DateTime.
Converts anything to local DateTime or raises.
Converts a Local NaiveDateTime to a DateTime in the local time zone.
Converts a UTC NaiveDateTime to a DateTime in the local time zone.
Converts a unix timestamp to a DateTime in the local time zone.
Converts a Date and Time to a DateTime in the local time zone.
Returns the current time in the local time zone.
Gets the configured timezone.
Returns the number of seconds since 1970. Note that a UNIX time is always UTC, so this doesn't change that.
Functions
Converts anything to local DateTime.
Converts anything to local DateTime or raises.
Converts a Local NaiveDateTime to a DateTime in the local time zone.
Converts a UTC NaiveDateTime to a DateTime in the local time zone.
Converts a unix timestamp to a DateTime in the local time zone.
Converts a Date and Time to a DateTime in the local time zone.
Returns the current time in the local time zone.
Gets the configured timezone.
Examples
iex> LocalTime.time_zone()
"America/New_York"
Returns the number of seconds since 1970. Note that a UNIX time is always UTC, so this doesn't change that.