Get the current time.
Instances For
Get the current date.
Instances For
Converts a PlainDate
with a TimeZone
to a DateTime
Equations
Instances For
Converts a DateTime
to a PlainDate
Instances For
Converts a DateTime
to a PlainTime
Equations
- dt.toPlainTime = dt.date.get.time
Instances For
Gets the current ZonedDateTime
.
Equations
- Std.Time.DateTime.now = do let tm ← Std.Time.Timestamp.now pure (Std.Time.DateTime.ofTimestamp tm tz)
Instances For
Gets the current ZonedDateTime
.
Equations
- Std.Time.ZonedDateTime.now = do let tm ← Std.Time.Timestamp.now let rules ← Std.Time.Database.defaultGetLocalZoneRules pure (Std.Time.ZonedDateTime.ofTimestamp tm rules)
Instances For
Gets the current ZonedDateTime
using the identifier of a time zone.
Instances For
Converts a PlainDate
to a ZonedDateTime
.
Equations
Instances For
Converts a PlainDate
to a ZonedDateTime
using TimeZone
.
Equations
Instances For
Converts a ZonedDateTime
to a PlainDate
Instances For
Converts a ZonedDateTime
to a PlainTime
Instances For
Creates a new ZonedDateTime
out of a PlainDateTime
and a time zone identifier.
Instances For
Converts a PlainDateTime
to a Timestamp
using the ZoneRules
.
Equations
- pdt.toTimestamp zr = (Std.Time.ZonedDateTime.ofPlainDateTime pdt zr).toTimestamp
Instances For
Converts a PlainDateTime
to a Timestamp
using the TimeZone
.
Instances For
Converts a PlainDate
to a Timestamp
using the ZoneRules
.
Equations
- dt.toTimestamp zr = (Std.Time.ZonedDateTime.ofPlainDate dt zr).toTimestamp
Instances For
Converts a PlainDate
to a Timestamp
using the TimeZone
.
Equations
- dt.toTimestampWithZone tz = (Std.Time.ZonedDateTime.ofPlainDateWithZone dt tz).toTimestamp