Struct rusted_cypher::cypher::transaction::Transaction [] [src]

pub struct Transaction<'a, State: Any = Created> { /* fields omitted */ }

Provides methods to interact with a transaction

This struct is used to begin a transaction, send queries, commit an rollback a transaction. Some methods are provided depending on the state of the transaction, for example, Transaction::begin is provided on a Created transaction and Transaction::commit is provided on Started transaction

Methods

impl<'a, State: Any> Transaction<'a, State>
[src]

Adds a statement to the transaction

Gets the expiration time of the transaction

impl<'a> Transaction<'a, Created>
[src]

Adds a statement to the transaction in builder style

Begins the transaction

Consumes the Transaction<Created> and returns the a Transaction<Started> alongside with the results of any Statement sent.

impl<'a> Transaction<'a, Started>
[src]

Adds a statement to the transaction in builder style

Executes the given statement

Any statements added via add_statement or with_statement will be discarded

Executes the statements added via add_statement or with_statement

Commits the transaction, returning the results

Rollback the transaction

Sends a query to just reset the transaction timeout

All transactions have a timeout. Use this method to keep a transaction alive.