biegunka-0.2: DSL definitions, interpreters, templating, git support

Safe HaskellNone

Control.Biegunka.Execute.Settings

Contents

Description

Controlling execution

Synopsis

Documentation

type Executor s a = TaggedT s IO aSource

Convenient type alias for task-local-state-ful IO tagged with crosstask execution environment s

env :: (Applicative m, Reifies s a) => TaggedT s m aSource

Get execution environment

Executor environment

data Execution Source

Multithread accessable parts

Mip

data Mip k a Source

0-to-1 key/value pairs Map

 Map k a ~ [(k, a)]
 Mip k a ~ Maybe (k, a)

Constructors

Empty 
Mip k a 

Instances

(Applicative f, Eq k) => Ixed f (Mip k a) 
Functor (Mip k) 
(Eq k, Eq a) => Eq (Mip k a) 
(Ord k, Ord a) => Ord (Mip k a) 
(Read k, Read a) => Read (Mip k a) 
(Show k, Show a) => Show (Mip k a) 
Eq k => At (Mip k a) 

lookup :: Eq k => k -> Mip k a -> Maybe aSource

Check if key is here

insert :: Eq k => k -> a -> Mip k a -> Mip k aSource

Insert value at key if Mip is empty or holds the value of the same key

delete :: Eq k => k -> Mip k a -> Mip k aSource

Delete value at key if Mip has it

singleton :: k -> a -> Mip k aSource

Construct Mip from pair

fromList :: Eq k => [(k, a)] -> Mip k aSource

Construct Mip from list

null :: Mip k a -> BoolSource

Is Mip empty?

keys :: Mip k a -> Maybe kSource

All 0 or 1 Mip keys

elems :: Mip k a -> Maybe aSource

All 0 or 1 Mip values

assocs :: Mip k a -> Maybe (k, a)Source

All 0 or 1 Mip key/value pairs

Lenses

execution :: HasExecution t => Lens' t ExecutionSource

watch :: HasExecution t => Lens' t WatcherSource

user :: HasExecution t => Lens' t (TVar (Mip CUid Int))Source

repos :: HasExecution t => Lens' t (TVar (Set String))Source

Initializations

initializeSTM :: Watcher -> IO ExecutionSource

Prepare Executor environment to stm transactions

Auxiliary types

data Work Source

Workload

Constructors

Do (IO ())

Task to come

Stop

Task is done