monky-2.1.0.0: A system state collecting library and application

Portabilitylinux
Stabilitytesting
Maintainerongy
Safe HaskellNone

Monky.Examples.Combine

Description

The functions in this module can be used to avoid printing seperators between modules.

Nearly equivalend example (image is missing):

pollPack 1 $ getCPUHandle' ScalingCur
pollPack 1 $ (getFreqHandle ScalingCur) combine getRawCPU combine getTempHandle'

The main function exported by this module are: * combine * combineD * combineE * combineF

They are mainly overloads of the same concept, for combinations of EvtModule and PollModule

The mixed functions (combineD and combineF) create a PollModule. The EvtModule will update a cache in the new module and output will be updated when the PollModule is asked to do so.

NOTE: because of this, the event will be handled when it is detected, but the output will not update until the PollModule wrapper ticks once.

Synopsis

Documentation

data (PollModule a, PollModule b) => CombiHandle a b Source

Wrapper type for PollModules

Instances

combine :: (PollModule a, PollModule b) => IO a -> IO b -> IO (CombiHandle a b)Source

Combine two PollModules. The first arguments output will be printed first

data (EvtModule a, EvtModule b) => EvtCombi a b Source

Wrapper type for EvtModules

Instances

combineE :: (EvtModule a, EvtModule b) => IO a -> IO b -> IO (EvtCombi a b)Source

Combine two EvtModules. The first argument will be printed first.

data (EvtModule a, PollModule b) => EPCombi a b Source

Wrapper type for mixed combination.

Instances

combineF :: (EvtModule a, PollModule b) => IO a -> IO b -> IO (EPCombi a b)Source

Combine a EvtModule with a PollModule. This will alwasy create a PollModule. |Event updates will not be displayed until the poll modules ticks once.

data (PollModule a, EvtModule b) => PECombi a b Source

Wrapper type for mixed combination.

Instances

combineD :: (PollModule a, EvtModule b) => IO a -> IO b -> IO (PECombi a b)Source

Look at combineF for documentation