aivika-transformers-4.5: Transformers for the Aivika simulation library

CopyrightCopyright (c) 2009-2016, David Sorokin <david.sorokin@gmail.com>
LicenseBSD3
MaintainerDavid Sorokin <david.sorokin@gmail.com>
Stabilityexperimental
Safe HaskellSafe
LanguageHaskell2010

Simulation.Aivika.IO.Ref.Base

Contents

Description

Tested with: GHC 8.0.1

The MonadIO-based monad can be an instance of MonadRef.

Orphan instances

(MonadIO m, MonadTemplate m) => MonadRef0 m Source #

The MonadIO based monad is an instance of MonadRef0.

Methods

newRef0 :: a -> m (Ref m a) Source #

(Monad m, MonadIO m, MonadTemplate m) => MonadRef m Source #

The MonadIO based monad is an instance of MonadRef.

Associated Types

data Ref (m :: * -> *) a :: * Source #

Methods

newRef :: a -> Simulation m (Ref m a) Source #

readRef :: Ref m a -> Event m a Source #

writeRef :: Ref m a -> a -> Event m () Source #

modifyRef :: Ref m a -> (a -> a) -> Event m () Source #

equalRef :: Ref m a -> Ref m a -> Bool Source #