Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- printUTC :: UTCTime -> Text
- parseUTC :: Text -> Maybe UTCTime
- parseDay :: Text -> Maybe Day
- unsafeParseUTC :: HasCallStack => Text -> UTCTime
- unsafeParseDay :: HasCallStack => Text -> Day
- parseUTC_old :: Text -> Maybe UTCTime
Documentation
printUTC :: UTCTime -> Text Source #
Render a UTCTime
in ISO 8601 format to a precision of seconds
(i.e. omitting any subseconds).
parseUTC :: Text -> Maybe UTCTime Source #
Parse text as a UTCTime
in ISO 8601 format or a number of slight
variations thereof (the T
may be replaced with a space, and the seconds,
milliseconds and/or Z
timezone indicator may optionally be omitted).
Time zone designations other than Z
for UTC are not currently supported.
unsafeParseUTC :: HasCallStack => Text -> UTCTime Source #
Variant of parseUTC
that throws an error if the input text could not be
parsed.
unsafeParseDay :: HasCallStack => Text -> Day Source #
Variant of parseDay
that throws an error if the input text could not be
parsed.
parseUTC_old :: Text -> Maybe UTCTime Source #
Parse text as a UTCTime
in ISO 8601 format or a number of slight
variations thereof (the T
may be replaced with a space, and the seconds and
timezone indicator may optionally be omitted).