2 Module : Gargantext.Prelude.Clock
3 Description : Useful Tools near Prelude of the project
4 Copyright : (c) CNRS, 2017-Present
5 License : AGPL + CECILL v3
6 Maintainer : team@gargantext.org
7 Stability : experimental
12 module Gargantext.Prelude.Clock
15 import Formatting.Clock (timeSpecs)
16 import Formatting.Internal (Format(..))
17 import Gargantext.Prelude
18 import qualified System.Clock as Clock (getTime, TimeSpec, Clock(..))
20 ---------------------------------------------------------------------------------
21 getTime :: MonadBase IO m => m Clock.TimeSpec
22 getTime = liftBase $ Clock.getTime Clock.ProcessCPUTime
24 hasTime :: Formatting.Internal.Format r (Clock.TimeSpec -> Clock.TimeSpec -> r)