haskey-0.1.0.1: A transcatoinal, ACID compliant, embeddable key-value store.

Safe HaskellNone
LanguageHaskell2010

Database.Haskey.Alloc.Transaction

Description

This module implements mechanisms to work with transactions.

Synopsis

Documentation

data Transaction key val a Source #

A committed or aborted transaction, with a return value of type a.

Constructors

Commit (Tree key val) a 
Abort a 

commit :: AllocM n => a -> Tree key val -> n (Transaction key val a) Source #

Commit the new tree and return a computed value.

commit_ :: AllocM n => Tree key val -> n (Transaction key val ()) Source #

Commit the new tree, without return a computed value.

abort :: AllocM n => a -> n (Transaction key val a) Source #

Abort the transaction and return a computed value.

abort_ :: AllocM n => n (Transaction key val ()) Source #

Abort the transaction, without returning a computed value.