rhine-0.6.0: Functional Reactive Programming with type-level clocks

Safe HaskellNone
LanguageHaskell2010

FRP.Rhine.Clock.Periodic

Description

Periodic clocks are defined by a stream of ticks with periodic time differences. They model subclocks of a fixed reference clock. The time differences are supplied at the type level.

Synopsis

Documentation

data Periodic (v :: [Nat]) where Source #

A clock whose tick lengths cycle through a (nonempty) list of type-level natural numbers. E.g. Periodic '[1, 2] ticks at times 1, 3, 4, 5, 7, 8, etc.

The waiting side effect is formal, in ScheduleT. You can use e.g. runScheduleIO to produce an actual delay.

Constructors

Periodic :: Periodic (n ': ns) 
Instances
(Monad m, NonemptyNatList v) => Clock (ScheduleT Integer m) (Periodic v) Source # 
Instance details

Defined in FRP.Rhine.Clock.Periodic

Associated Types

type Time (Periodic v) :: Type Source #

type Tag (Periodic v) :: Type Source #

type Time (Periodic v) Source # 
Instance details

Defined in FRP.Rhine.Clock.Periodic

type Time (Periodic v) = Integer
type Tag (Periodic v) Source # 
Instance details

Defined in FRP.Rhine.Clock.Periodic

type Tag (Periodic v) = ()