Module

ActiveRecord::Transactions

Inheritance

Classes & Modules

Methods

Class

Visibility Signature
public included (base)

Instance

Visibility Signature
public rollback_active_record_state! () {|| ...}
public transaction (&block)
public with_transaction_returning_status (method, *args)

Class Method Detail

included(base)

Instance Method Detail

rollback_active_record_state!() {|| ...}

Reset id and @new_record if the transaction rolls back.

transaction(&block)

See ActiveRecord::Transactions::ClassMethods for detailed documentation.

with_transaction_returning_status(method, *args)

Executes method within a transaction and captures its return value as a status flag. If the status is true the transaction is committed, otherwise a ROLLBACK is issued. In any case the status flag is returned.

This method is available within the context of an ActiveRecord::Base instance.