Rollback() public method

public Rollback ( ) : void
return void
コード例 #1
0
ファイル: DebugJournal.cs プロジェクト: IdanHaim/ravendb
 private void ReplayWriteTransaction(TransactionActivityEntry transactionAwareActivityEntry, ref Transaction currentWriteTransaction)
 {
     Transaction tx;
     switch (transactionAwareActivityEntry.ActionType)
     {
         case DebugActionType.TransactionStart:
             tx = _env.NewTransaction(transactionAwareActivityEntry.Flags);
             currentWriteTransaction = tx;
             break;
         case DebugActionType.TransactionCommit:
             currentWriteTransaction.Commit();
             break;
         case DebugActionType.TransactionRollback:
             currentWriteTransaction.Rollback();
             break;
         case DebugActionType.TransactionDisposing:
             currentWriteTransaction.Dispose();
             currentWriteTransaction = null;
             break;
         default:
             throw new InvalidOperationException("unsupported action type for readWrite transaction: " + transactionAwareActivityEntry.ActionType);
     }
 }