예제 #1
0
 public void InitTransaction(SingleRequestTransaction tx)
 {
     Transaction           = tx;
     TransactionCommitted  = false;
     TransactionRolledBack = false;
     TransactionDisposed   = false;
 }
예제 #2
0
        public ITransaction BeginTransaction()
        {
            TransactionDepth += 1;
            if (_backingSession != null && _backingSession.Transaction != null)
            {
                if (_backingSession.Transaction.IsActive)
                {
                    var tx1 = new SingleRequestTransaction(_backingSession.Transaction, this);
                    GetCurrentContext().InitTransaction(tx1);
                    return(tx1);
                }
            }
            var tx = new SingleRequestTransaction(_backingSession.BeginTransaction(), this);

            GetCurrentContext().InitTransaction(tx);

            return(tx);
        }