Summer.Batch.Common.Transaction.TransactionScopeManager Class Reference

Utility class for managing transaction scopes. More...

Static Public Member Functions

static TransactionScope CreateScope (TransactionScopeOption scopeOption=TransactionScopeOption.Required, IsolationLevel isolationLevel=IsolationLevel.ReadCommitted, TimeSpan?timeout=null)
 Creates a new transaction scope with the given options and registers the ITransactionSynchronization and IEnlistmentNotification with the current transaction. More...
 
static void RegisterTransactionSynchronization (TransactionScope scope, ITransactionSynchronization synchronization)
 Registers a new ITransactionSynchronization to a scope. More...
 
static void RegisterResource (IEnlistmentNotification resource)
 Registers a new IEnlistmentNotification. More...
 
static void UnregisterResource (IEnlistmentNotification resource)
 Unregisters a new IEnlistmentNotification. More...
 

Detailed Description

Utility class for managing transaction scopes.

Member Function Documentation

static TransactionScope Summer.Batch.Common.Transaction.TransactionScopeManager.CreateScope ( TransactionScopeOption  scopeOption = TransactionScopeOption.Required,
IsolationLevel  isolationLevel = IsolationLevel.ReadCommitted,
TimeSpan?  timeout = null 
)
static

Creates a new transaction scope with the given options and registers the ITransactionSynchronization and IEnlistmentNotification with the current transaction.

Parameters
scopeOptionThe scope options to use, TransactionScopeOption.Required by default.
isolationLevelThe isolation level, IsolationLevel.ReadUncommitted by default.
timeoutThe transaction timeout, TransactionManager.MaximumTimeout by default.
Returns
A new TransactionScope with the given options
static void Summer.Batch.Common.Transaction.TransactionScopeManager.RegisterResource ( IEnlistmentNotification  resource)
static

Registers a new IEnlistmentNotification.

Parameters
resourcethe resource to register
static void Summer.Batch.Common.Transaction.TransactionScopeManager.RegisterTransactionSynchronization ( TransactionScope  scope,
ITransactionSynchronization  synchronization 
)
static

Registers a new ITransactionSynchronization to a scope.

Parameters
scopethe scope to register the synchronization to
synchronizationthe synchronization to register
static void Summer.Batch.Common.Transaction.TransactionScopeManager.UnregisterResource ( IEnlistmentNotification  resource)
static

Unregisters a new IEnlistmentNotification.

Parameters
resourcethe resource to unregister

The documentation for this class was generated from the following file:
  • Summer.Batch.Common/Transaction/TransactionScopeManager.cs