Gamgine-0.5.3: Some kind of game library or set of utilities.

Safe HaskellNone
LanguageHaskell98

Gamgine.Lens.IORef

Synopsis

Documentation

mapIORef :: IORef a -> (a -> b) -> IO b Source #

map a function on the value of the IORef

get :: StateIORef a a Source #

get the value of the IORef inside of the State

gets :: (a -> b) -> StateIORef a b Source #

apply a function on the value of the IORef

getsL :: Lens a b -> StateIORef a b Source #

apply the getter lens on the value of the IORef inside of the State

put :: a -> StateIORef a () Source #

set the value of the IORef inside of the State

putL :: Lens a b -> b -> StateIORef a () Source #

put a value

modify :: (a -> a) -> StateIORef a () Source #

modify the value of the IORef inside of the State with a lens

modifyL :: Lens a b -> (b -> b) -> StateIORef a () Source #

modify the value of the IORef inside of the State with a lens

getL :: IORef a -> Lens a b -> IO b Source #

apply the getter of the lens on the value of the IORef

setL :: IORef a -> Lens a b -> b -> IO () Source #

apply the setter of the lens on the value of the IORef

modL :: IORef a -> Lens a b -> (b -> b) -> IO () Source #

modify the value of the IORef with a lens