Safe Haskell | None |
---|---|
Language | Haskell2010 |
- type ProjectionMap key orderKey serialized = Map key (orderKey, serialized)
- emptyProjectionMap :: ProjectionMap key orderKey serialized
- projectionMapTVar :: IO (TVar (ProjectionMap key orderKey serialized))
- tvarProjectionCache :: Ord key => TVar (ProjectionMap key orderKey serialized) -> ProjectionCache key orderKey serialized STM
- embeddedStateProjectionCache :: (MonadState s m, Ord key) => (s -> ProjectionMap key orderKey serialized) -> (s -> ProjectionMap key orderKey serialized -> s) -> ProjectionCache key orderKey serialized m
- module Eventful.ProjectionCache.Types
Documentation
type ProjectionMap key orderKey serialized = Map key (orderKey, serialized) Source #
A ProjectionMap
just stores the latest snapshot for each UUID.
emptyProjectionMap :: ProjectionMap key orderKey serialized Source #
projectionMapTVar :: IO (TVar (ProjectionMap key orderKey serialized)) Source #
tvarProjectionCache :: Ord key => TVar (ProjectionMap key orderKey serialized) -> ProjectionCache key orderKey serialized STM Source #
A ProjectionCache
that uses a TVar
and runs in STM
.
embeddedStateProjectionCache :: (MonadState s m, Ord key) => (s -> ProjectionMap key orderKey serialized) -> (s -> ProjectionMap key orderKey serialized -> s) -> ProjectionCache key orderKey serialized m Source #
A ProjectionCache
for some MonadState
that contains a ProjectionMap
.