Safe Haskell | None |
---|---|
Language | Haskell98 |
Documentation
class (Ord i, Next i, Monad m) => States i m where Source
extentRefs :: Refs i m a -> i Source
Get the extent of the collection.
newRefs :: i -> a -> m (Refs i m a) Source
Allocate a new state of the given arity, also returning an index to the first element of the collection.
readRefs :: Refs i m a -> i -> m a Source
Write an element of the state.
writeRefs :: Refs i m a -> i -> a -> m () Source
Read an element of the state.