Struct rustbreak::TransactionLock [] [src]

pub struct TransactionLock<'a: 'b, 'b, T: Serialize + Deserialize + Eq + Hash + 'a> { /* fields omitted */ }

A TransactionLock that is atomic in writes and defensive

You generate this by calling transaction on a Lock The transactionlock does not get automatically applied when it is dropped, you have to run it. This allows for defensive programming where the values are only applied once it is run.

Methods

impl<'a: 'b, 'b, T: Serialize + Deserialize + Eq + Hash + 'a> TransactionLock<'a, 'b, T>
[src]

Insert a given Object into the Database at that key

See Database::insert for details

Retrieves an Object from the Database

See Database::retrieve for details

Consumes the TransactionLock and runs it