aivika-lattice-0.7: Nested discrete event simulation module for the Aivika library using lattice
CopyrightCopyright (c) 2016-2017 David Sorokin <david.sorokin@gmail.com>
LicenseBSD3
MaintainerDavid Sorokin <david.sorokin@gmail.com>
Stabilityexperimental
Safe HaskellSafe-Inferred
LanguageHaskell2010

Simulation.Aivika.Lattice.Ref.Base.Lazy

Description

Tested with: GHC 7.10.3

Here is an implementation of lazy mutable references, where LIO is an instance of MonadRef and MonadRef0.

Orphan instances

MonadRef LIO Source #

The implementation of mutable references.

Instance details

Associated Types

data Ref LIO a #

Methods

newRef :: a -> Simulation LIO (Ref LIO a) #

readRef :: Ref LIO a -> Event LIO a #

writeRef :: Ref LIO a -> a -> Event LIO () #

modifyRef :: Ref LIO a -> (a -> a) -> Event LIO () #

equalRef :: Ref LIO a -> Ref LIO a -> Bool #

MonadRef0 LIO Source #

A subtype of mutable references that can be created under more weak conditions.

Instance details

Methods

newRef0 :: a -> LIO (Ref LIO a) #

Observable (Ref LIO) (Estimate LIO) Source #

An instance of the specified type class.

Instance details

Methods

readObservable :: Ref LIO a -> Estimate LIO a #