Ejemplo n.º 1
0
        private void OnTranscationCommit(object sender, EventArgs e)
        {
            DbObjectOperator @operator = sender as DbObjectOperator;

            @operator.TranscationCommit -= new EventHandler(this.OnTranscationCommit);
            this.previousState           = null;
        }
Ejemplo n.º 2
0
 public virtual void OnWrote(object sender, DbEventArgs e)
 {
     this.State.ObjectWrote = true;
     this.State.ModifiedValues.Clear();
     this.State.UpdateInitialValues(this);
     this.previousState              = DbObjectTools.Clone <DbObjectState>(this.State);
     e.Operator.TranscationRollback -= new EventHandler(this.OnTranscationRollback);
     e.Operator.TranscationRollback += new EventHandler(this.OnTranscationRollback);
     e.Operator.TranscationCommit   -= new EventHandler(this.OnTranscationCommit);
     e.Operator.TranscationCommit   += new EventHandler(this.OnTranscationCommit);
 }