Safe Haskell | None |
---|---|
Language | GHC2021 |
Polysemy.Time.At
Description
Interceptors for fixing a specific time, Internal
Synopsis
- dateCurrentRelative :: forall diff t d (r :: EffectRow). (Torsor t diff, Members '[Time t d, AtomicState (t, t) :: (Type -> Type) -> Type -> Type] r) => Sem r t
- interceptTimeAtWithStart :: forall diff t d (r :: EffectRow) a. (Torsor t diff, TimeUnit diff, HasDate t d, Members '[Time t d, AtomicState (t, t) :: (Type -> Type) -> Type -> Type] r) => Sem r a -> Sem r a
- interceptTimeAt :: forall diff t d (r :: EffectRow) a. (TimeUnit diff, Torsor t diff, HasDate t d, Members '[Time t d, Embed IO] r) => t -> Sem r a -> Sem r a
- interceptTimeConstantState :: forall t d diff (r :: EffectRow) a. (Ord diff, HasDate t d, TimeUnit diff, Torsor t diff, Members '[Time t d, AtomicState t :: (Type -> Type) -> Type -> Type] r) => Sem r a -> Sem r a
- interceptTimeConstant :: forall t d diff (r :: EffectRow) a. (Ord diff, HasDate t d, TimeUnit diff, Torsor t diff, Members '[Time t d, Embed IO] r) => t -> Sem r a -> Sem r a
- interceptTimeConstantNow :: forall t d diff (r :: EffectRow) a. (Ord diff, HasDate t d, TimeUnit diff, Torsor t diff, Members '[Time t d, Embed IO] r) => Sem r a -> Sem r a
Documentation
dateCurrentRelative :: forall diff t d (r :: EffectRow). (Torsor t diff, Members '[Time t d, AtomicState (t, t) :: (Type -> Type) -> Type -> Type] r) => Sem r t Source #
Determine the current time adjusted for the difference between a custom instant and the time at which the program was started.
interceptTimeAtWithStart :: forall diff t d (r :: EffectRow) a. (Torsor t diff, TimeUnit diff, HasDate t d, Members '[Time t d, AtomicState (t, t) :: (Type -> Type) -> Type -> Type] r) => Sem r a -> Sem r a Source #
interceptTimeAt :: forall diff t d (r :: EffectRow) a. (TimeUnit diff, Torsor t diff, HasDate t d, Members '[Time t d, Embed IO] r) => t -> Sem r a -> Sem r a Source #
Interpret Time
so that the time when the program starts is startAt
.
interceptTimeConstantState :: forall t d diff (r :: EffectRow) a. (Ord diff, HasDate t d, TimeUnit diff, Torsor t diff, Members '[Time t d, AtomicState t :: (Type -> Type) -> Type -> Type] r) => Sem r a -> Sem r a Source #
interceptTimeConstant :: forall t d diff (r :: EffectRow) a. (Ord diff, HasDate t d, TimeUnit diff, Torsor t diff, Members '[Time t d, Embed IO] r) => t -> Sem r a -> Sem r a Source #