License | BSD-style |
---|---|
Maintainer | Vincent Hanquez <vincent@snarc.org> |
Stability | experimental |
Portability | unknown |
Safe Haskell | None |
Language | Haskell2010 |
Get the system timezone and current time value in multiple formats
Current time in computer friendly format
timeCurrent :: IO Elapsed
Get the current elapsed seconds since epoch
Get the current elapsed seconds (precise to the nanosecond) since epoch
Current time in human friendly DateTime format
Get the current global date
This is equivalent to:
timeGetDateTimeOfDay `fmap` timeCurrentP
localDateCurrent :: IO (LocalTime DateTime)
Get the localized date by using timezoneCurrent
and dateCurrent
localDateCurrentAt :: TimezoneOffset -> IO (LocalTime DateTime)
Get the localized date at a specific timezone offset.
System timezone
timezoneCurrent :: IO TimezoneOffset
Get the current timezone offset
This include daylight saving time when in operation.