newtype Duration { } #
Duration { durationNanos :: Integer }
data Instant { } #
Instant { instantSecs :: !Integer, instantNanos :: !Int }
A point in time.
data Time { } #
Time { timeHour :: !Int, timeMinute :: !Int, timeSecond :: !Int, timeNano :: !Int }
A time of day.
data DateTime { } #
DateTime { dtDate :: !Date, dtTime :: !Time }
A date and time.
<> :: { } #
+ :: { } #
b :: { } #
negate :: { } #
abs :: { } #
signum :: { } #
fromInteger :: { } #
fromNanos :: Integer -> Duration { } #
fromMicros :: Integer -> Duration { } #
fromMillis :: Integer -> Duration { } #
fromSecs :: Integer -> Duration { } #
fromMins :: Integer -> Duration { } #
fromHours :: Integer -> Duration { } #
fromDays :: Integer -> Duration { } #
toNanos :: Duration -> Integer { } #
toMicros :: Duration -> Integer { } #
toMillis :: Duration -> Integer { } #
toSecs :: Duration -> Integer { } #
date :: Int -> Int -> Int -> Date { } #
year :: Date -> Int { } #
month :: Date -> Int { } #
day :: Date -> Int { } #
dayOfWeek :: Date -> Int { } #
dayOfYear :: Date -> Int { } #
weekOfYear :: Date -> Int { } #
isLeapYear :: Int -> Bool { } #
daysInMonth :: Int -> Int -> Int { } #
time :: Int -> Int -> Int -> Time { } #
Create a time.
hour :: Time -> Int { } #
minute :: Time -> Int { } #
second :: Time -> Int { } #
nanosecond :: Time -> Int { } #
dateTime :: Date -> Time -> DateTime { } #
Create a datetime.
getDate :: DateTime -> Date { } #
getTime :: DateTime -> Time { } #
parseDateTime :: String -> Maybe DateTime { } #
Parse an ISO 8601 datetime.
formatDateTime :: DateTime -> String { } #
Format as ISO 8601.
parseDate :: String -> Maybe Date { } #
Parse a date (YYYY-MM-DD).
formatDate :: Date -> String { } #
Format a date as YYYY-MM-DD.
parseTime :: String -> Maybe Time { } #
Parse a time (HH:MM:SS).
formatTime :: Time -> String { } #
Format a time as HH:MM:SS.
pad2 :: Int -> String { } #
readMaybe :: (Read a) => String -> Maybe a { } #
measure :: (IO a) -> IO (a, Duration) { } #
Measure the time taken by an action.
instance Monoid Duration { }