hourglass-0.1.1: simple performant time related library

Portabilityunknown
Stabilityexperimental
MaintainerVincent Hanquez <vincent@snarc.org>
Safe HaskellNone

System.Hourglass

Contents

Description

Get the system timezone and current time value in multiple formats

Synopsis

Current time in computer friendly format

timeCurrent :: IO ElapsedSource

Get the current elapsed seconds since epoch

timeCurrentP :: IO ElapsedPSource

Get the current elapsed seconds (precise to the nanosecond) since epoch

Current time in human friendly DateTime format

dateCurrent :: IO DateTimeSource

Get the current time

This is equivalent to:

 timeGetDateTimeOfDay `fmap` timeCurrentP

System timezone

timezoneCurrent :: IO TimezoneOffsetSource

Get the current timezone offset

This include daylight saving time when in operation.