| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
Time.TimeStamp
Description
This module introduces TimeStamp data type
and corresponding functions for operations with time.
- newtype TimeStamp = TimeStamp Rational
- timeDiff :: forall (unit :: Rat). KnownRat unit => TimeStamp -> TimeStamp -> (Ordering, Time unit)
- timeAdd :: forall (unit :: Rat). KnownRat unit => Time unit -> Time unit -> Time unit
- timeMul :: forall (unit :: Rat). KnownRat unit => RatioNat -> Time unit -> Time unit
- timeDiv :: forall (unit :: Rat). KnownRat unit => Time unit -> Time unit -> RatioNat
Documentation
Similar to Time but has no units and can be negative.
timeDiff :: forall (unit :: Rat). KnownRat unit => TimeStamp -> TimeStamp -> (Ordering, Time unit) Source #
Returns the result of comparison of two Timestamps and
the Time of that difference of given time unit.
timeAdd :: forall (unit :: Rat). KnownRat unit => Time unit -> Time unit -> Time unit Source #
Returns the result of addition of two Time elements.