netwire-4.0.4: Flexible wire arrows for FRP

MaintainerErtugrul Soeylemez <es@ertes.de>
Safe HaskellNone

Control.Wire.Trans.Embed

Contents

Description

Combinators for embedding wires.

Synopsis

Embedding wires

embedSource

Arguments

:: Monad m 
=> (a -> Time)

Time delta for the subwire.

-> (Either e c -> Either e b -> Either e c)

Folding function.

-> Either e c

Fold base value.

-> Wire e m a b

Subwire to step.

-> Wire e m a c 

Performs the argument wire with the input time delta. It is stepped often enough to catch up with the main wire. The individual results are combined as given by the fold (second and third argument).

  • Complexity: O(n) time wrt stepping the subwire, where n is the number of times the subwire is stepped.
  • Depends: like argument wire, if stepped.
  • Inhibits: When the fold results in a Left.