Ejemplo n.º 1
0
 /// ------------------------------------------------------------------------------------
 /// <summary>
 /// Irreversably commits all actions that have been executed so far (or at least since
 /// the last Commit) and clears the action stack. (Currently, both undo and
 /// redo actions are cleared).
 /// Use uowService.Save() to persist stuff without clearing the stack.
 /// </summary>
 /// ------------------------------------------------------------------------------------
 public void Commit()
 {
     if (this != m_uowService.ActiveUndoStack)
     {
         m_uowService.ActiveUndoStack.Commit();
         return;
     }
     // m_currentProcessingState *must* be FdoBusinessTransactionState.ReadyForBeginTask.
     CheckReadyForCommit("Commit at wrong place.");
     m_uowService.Save();
     Clear();
 }