Module DataMapper::Adapters::AbstractAdapter::Transaction
In: lib/dm-core/adapters/abstract_adapter.rb

TODO: move to dm-more/dm-transaction

Methods

Public Instance methods

Retrieve the current transaction for this Adapter.

Everything done by this Adapter is done within the context of this Transaction.

@return <DataMapper::Transaction> the ‘current’ transaction for this Adapter.

TODO: move to dm-more/dm-transaction

Pop the ‘current’ Transaction from the per thread Transaction stack so that everything done by this Adapter is no longer necessarily within the context of said Transaction.

@return <DataMapper::Transaction> the former ‘current’ transaction.

TODO: move to dm-more/dm-transaction

Pushes the given Transaction onto the per thread Transaction stack so that everything done by this Adapter is done within the context of said Transaction.

@param transaction<DataMapper::Transaction> a Transaction to be the

  'current' transaction until popped.

TODO: move to dm-more/dm-transaction

Produces a fresh transaction primitive for this Adapter

Used by DataMapper::Transaction to perform its various tasks.

@return <Object> a new Object that responds to :close, :begin, :commit,

  :rollback, :rollback_prepared and :prepare

TODO: move to dm-more/dm-transaction (if possible)

Returns whether we are within a Transaction.

@return <Boolean> whether we are within a Transaction.

TODO: move to dm-more/dm-transaction

[Validate]