/usr/share/doc/libghc-acid-state-doc/html/Data-Acid-Advanced.html is in libghc-acid-state-doc 0.14.0-1build1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.Acid.Advanced</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Data-Acid-Advanced.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="src/Data-Acid-Advanced.html">Source</a></li><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">acid-state-0.14.0: Add ACID guarantees to any serializable Haskell data structure.</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>PublicDomain</td></tr><tr><th>Maintainer</th><td>lemmih@gmail.com</td></tr><tr><th>Portability</th><td>non-portable (uses GHC extensions)</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell2010</td></tr></table><p class="caption">Data.Acid.Advanced</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Home of the more specialized functions.</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:scheduleUpdate">scheduleUpdate</a> :: <a href="Data-Acid-Memory-Pure.html#t:UpdateEvent">UpdateEvent</a> event => <a href="Data-Acid-Abstract.html#t:AcidState">AcidState</a> (<a href="Data-Acid-Memory-Pure.html#t:EventState">EventState</a> event) -> event -> <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.8.2.0/System-IO.html#t:IO">IO</a> (<a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.8.2.0/Control-Concurrent-MVar.html#t:MVar">MVar</a> (<a href="Data-Acid-Memory-Pure.html#t:EventResult">EventResult</a> event))</li><li class="src short"><a href="#v:groupUpdates">groupUpdates</a> :: <a href="Data-Acid-Memory-Pure.html#t:UpdateEvent">UpdateEvent</a> event => <a href="Data-Acid-Abstract.html#t:AcidState">AcidState</a> (<a href="Data-Acid-Memory-Pure.html#t:EventState">EventState</a> event) -> [event] -> <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.8.2.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:update-39-">update'</a> :: (<a href="Data-Acid-Memory-Pure.html#t:UpdateEvent">UpdateEvent</a> event, <a href="file:///usr/share/doc/ghc-doc/html/libraries/transformers-0.4.2.0/Control-Monad-IO-Class.html#t:MonadIO">MonadIO</a> m) => <a href="Data-Acid-Abstract.html#t:AcidState">AcidState</a> (<a href="Data-Acid-Memory-Pure.html#t:EventState">EventState</a> event) -> event -> m (<a href="Data-Acid-Memory-Pure.html#t:EventResult">EventResult</a> event)</li><li class="src short"><a href="#v:query-39-">query'</a> :: (<a href="Data-Acid-Memory-Pure.html#t:QueryEvent">QueryEvent</a> event, <a href="file:///usr/share/doc/ghc-doc/html/libraries/transformers-0.4.2.0/Control-Monad-IO-Class.html#t:MonadIO">MonadIO</a> m) => <a href="Data-Acid-Abstract.html#t:AcidState">AcidState</a> (<a href="Data-Acid-Memory-Pure.html#t:EventState">EventState</a> event) -> event -> m (<a href="Data-Acid-Memory-Pure.html#t:EventResult">EventResult</a> event)</li><li class="src short"><span class="keyword">class</span> (<a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.8.2.0/Data-Typeable-Internal.html#t:Typeable">Typeable</a> ev, <a href="file:///usr/share/doc/libghc-safecopy-doc/html/Data-SafeCopy.html#t:SafeCopy">SafeCopy</a> ev, <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.8.2.0/Data-Typeable-Internal.html#t:Typeable">Typeable</a> (<a href="Data-Acid-Advanced.html#t:MethodResult">MethodResult</a> ev), <a href="file:///usr/share/doc/libghc-safecopy-doc/html/Data-SafeCopy.html#t:SafeCopy">SafeCopy</a> (<a href="Data-Acid-Advanced.html#t:MethodResult">MethodResult</a> ev)) => <a href="#t:Method">Method</a> ev <span class="keyword">where</span><ul class="subs"><li><span class="keyword">type</span> <a href="#t:MethodResult">MethodResult</a> ev</li><li><span class="keyword">type</span> <a href="#t:MethodState">MethodState</a> ev</li><li><a href="#v:methodTag">methodTag</a> :: ev -> Tag</li></ul></li><li class="src short"><span class="keyword">class</span> <a href="file:///usr/share/doc/libghc-safecopy-doc/html/Data-SafeCopy.html#t:SafeCopy">SafeCopy</a> st => <a href="#t:IsAcidic">IsAcidic</a> st <span class="keyword">where</span><ul class="subs"><li><a href="#v:acidEvents">acidEvents</a> :: [<a href="Data-Acid-Advanced.html#t:Event">Event</a> st]</li></ul></li><li class="src short"><span class="keyword">data</span> <a href="#t:Event">Event</a> st <span class="keyword">where</span><ul class="subs"><li><a href="#v:UpdateEvent">UpdateEvent</a> :: <a href="Data-Acid-Memory-Pure.html#t:UpdateEvent">UpdateEvent</a> ev => (ev -> <a href="Data-Acid-Memory-Pure.html#t:Update">Update</a> (<a href="Data-Acid-Memory-Pure.html#t:EventState">EventState</a> ev) (<a href="Data-Acid-Memory-Pure.html#t:EventResult">EventResult</a> ev)) -> <a href="Data-Acid-Advanced.html#t:Event">Event</a> (<a href="Data-Acid-Memory-Pure.html#t:EventState">EventState</a> ev)</li><li><a href="#v:QueryEvent">QueryEvent</a> :: <a href="Data-Acid-Memory-Pure.html#t:QueryEvent">QueryEvent</a> ev => (ev -> <a href="Data-Acid-Memory-Pure.html#t:Query">Query</a> (<a href="Data-Acid-Memory-Pure.html#t:EventState">EventState</a> ev) (<a href="Data-Acid-Memory-Pure.html#t:EventResult">EventResult</a> ev)) -> <a href="Data-Acid-Advanced.html#t:Event">Event</a> (<a href="Data-Acid-Memory-Pure.html#t:EventState">EventState</a> ev)</li></ul></li></ul></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><a name="v:scheduleUpdate" class="def">scheduleUpdate</a> :: <a href="Data-Acid-Memory-Pure.html#t:UpdateEvent">UpdateEvent</a> event => <a href="Data-Acid-Abstract.html#t:AcidState">AcidState</a> (<a href="Data-Acid-Memory-Pure.html#t:EventState">EventState</a> event) -> event -> <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.8.2.0/System-IO.html#t:IO">IO</a> (<a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.8.2.0/Control-Concurrent-MVar.html#t:MVar">MVar</a> (<a href="Data-Acid-Memory-Pure.html#t:EventResult">EventResult</a> event)) <a href="src/Data-Acid-Abstract.html#scheduleUpdate" class="link">Source</a></p><div class="doc"><p>Issue an Update event and return immediately. The event is not durable
before the MVar has been filled but the order of events is honored.
The behavior in case of exceptions is exactly the same as for <code><a href="Data-Acid-Abstract.html#v:update">update</a></code>.</p><p>If EventA is scheduled before EventB, EventA <em>will</em> be executed before EventB:</p><pre>do scheduleUpdate acid EventA
scheduleUpdate acid EventB
</pre></div></div><div class="top"><p class="src"><a name="v:groupUpdates" class="def">groupUpdates</a> :: <a href="Data-Acid-Memory-Pure.html#t:UpdateEvent">UpdateEvent</a> event => <a href="Data-Acid-Abstract.html#t:AcidState">AcidState</a> (<a href="Data-Acid-Memory-Pure.html#t:EventState">EventState</a> event) -> [event] -> <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.8.2.0/System-IO.html#t:IO">IO</a> () <a href="src/Data-Acid-Abstract.html#groupUpdates" class="link">Source</a></p><div class="doc"><p>Schedule multiple Update events and wait for them to be durable, but
throw away their results. This is useful for importing existing
datasets into an AcidState.</p></div></div><div class="top"><p class="src"><a name="v:update-39-" class="def">update'</a> :: (<a href="Data-Acid-Memory-Pure.html#t:UpdateEvent">UpdateEvent</a> event, <a href="file:///usr/share/doc/ghc-doc/html/libraries/transformers-0.4.2.0/Control-Monad-IO-Class.html#t:MonadIO">MonadIO</a> m) => <a href="Data-Acid-Abstract.html#t:AcidState">AcidState</a> (<a href="Data-Acid-Memory-Pure.html#t:EventState">EventState</a> event) -> event -> m (<a href="Data-Acid-Memory-Pure.html#t:EventResult">EventResult</a> event) <a href="src/Data-Acid-Abstract.html#update%27" class="link">Source</a></p><div class="doc"><p>Same as <code><a href="Data-Acid-Abstract.html#v:update">update</a></code> but lifted into any monad capable of doing IO.</p></div></div><div class="top"><p class="src"><a name="v:query-39-" class="def">query'</a> :: (<a href="Data-Acid-Memory-Pure.html#t:QueryEvent">QueryEvent</a> event, <a href="file:///usr/share/doc/ghc-doc/html/libraries/transformers-0.4.2.0/Control-Monad-IO-Class.html#t:MonadIO">MonadIO</a> m) => <a href="Data-Acid-Abstract.html#t:AcidState">AcidState</a> (<a href="Data-Acid-Memory-Pure.html#t:EventState">EventState</a> event) -> event -> m (<a href="Data-Acid-Memory-Pure.html#t:EventResult">EventResult</a> event) <a href="src/Data-Acid-Abstract.html#query%27" class="link">Source</a></p><div class="doc"><p>Same as <code><a href="Data-Acid-Abstract.html#v:query">query</a></code> but lifted into any monad capable of doing IO.</p></div></div><div class="top"><p class="src"><span class="keyword">class</span> (<a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.8.2.0/Data-Typeable-Internal.html#t:Typeable">Typeable</a> ev, <a href="file:///usr/share/doc/libghc-safecopy-doc/html/Data-SafeCopy.html#t:SafeCopy">SafeCopy</a> ev, <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.8.2.0/Data-Typeable-Internal.html#t:Typeable">Typeable</a> (<a href="Data-Acid-Advanced.html#t:MethodResult">MethodResult</a> ev), <a href="file:///usr/share/doc/libghc-safecopy-doc/html/Data-SafeCopy.html#t:SafeCopy">SafeCopy</a> (<a href="Data-Acid-Advanced.html#t:MethodResult">MethodResult</a> ev)) => <a name="t:Method" class="def">Method</a> ev <span class="keyword">where</span> <a href="src/Data-Acid-Core.html#Method" class="link">Source</a></p><div class="doc"><p>The basic Method class. Each Method has an indexed result type
and a unique tag.</p></div><div class="subs minimal"><p class="caption">Minimal complete definition</p><p class="src">Nothing</p></div><div class="subs associated-types"><p class="caption">Associated Types</p><p class="src"><span class="keyword">type</span> <a name="t:MethodResult" class="def">MethodResult</a> ev <a href="src/Data-Acid-Core.html#MethodResult" class="link">Source</a></p><p class="src"><span class="keyword">type</span> <a name="t:MethodState" class="def">MethodState</a> ev <a href="src/Data-Acid-Core.html#MethodState" class="link">Source</a></p></div><div class="subs methods"><p class="caption">Methods</p><p class="src"><a name="v:methodTag" class="def">methodTag</a> :: ev -> Tag <a href="src/Data-Acid-Core.html#methodTag" class="link">Source</a></p></div></div><div class="top"><p class="src"><span class="keyword">class</span> <a href="file:///usr/share/doc/libghc-safecopy-doc/html/Data-SafeCopy.html#t:SafeCopy">SafeCopy</a> st => <a name="t:IsAcidic" class="def">IsAcidic</a> st <span class="keyword">where</span> <a href="src/Data-Acid-Common.html#IsAcidic" class="link">Source</a></p><div class="subs methods"><p class="caption">Methods</p><p class="src"><a name="v:acidEvents" class="def">acidEvents</a> <a href="src/Data-Acid-Common.html#acidEvents" class="link">Source</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: [<a href="Data-Acid-Advanced.html#t:Event">Event</a> st]</td><td class="doc"><p>List of events capable of updating or querying the state.</p></td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:Event" class="def">Event</a> st <span class="keyword">where</span> <a href="src/Data-Acid-Common.html#Event" class="link">Source</a></p><div class="doc"><p>We distinguish between events that modify the state and those that do not.</p><p>UpdateEvents are executed in a MonadState context and have to be serialized
to disk before they are considered durable.</p><p>QueryEvents are executed in a MonadReader context and obviously do not have
to be serialized to disk.</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:UpdateEvent" class="def">UpdateEvent</a> :: <a href="Data-Acid-Memory-Pure.html#t:UpdateEvent">UpdateEvent</a> ev => (ev -> <a href="Data-Acid-Memory-Pure.html#t:Update">Update</a> (<a href="Data-Acid-Memory-Pure.html#t:EventState">EventState</a> ev) (<a href="Data-Acid-Memory-Pure.html#t:EventResult">EventResult</a> ev)) -> <a href="Data-Acid-Advanced.html#t:Event">Event</a> (<a href="Data-Acid-Memory-Pure.html#t:EventState">EventState</a> ev)</td><td class="doc empty"> </td></tr><tr><td class="src"><a name="v:QueryEvent" class="def">QueryEvent</a> :: <a href="Data-Acid-Memory-Pure.html#t:QueryEvent">QueryEvent</a> ev => (ev -> <a href="Data-Acid-Memory-Pure.html#t:Query">Query</a> (<a href="Data-Acid-Memory-Pure.html#t:EventState">EventState</a> ev) (<a href="Data-Acid-Memory-Pure.html#t:EventResult">EventResult</a> ev)) -> <a href="Data-Acid-Advanced.html#t:Event">Event</a> (<a href="Data-Acid-Memory-Pure.html#t:EventState">EventState</a> ev)</td><td class="doc empty"> </td></tr></table></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.1</p></div></body></html>
|