public override void Begin() { try { base.Begin(); } catch (TransactionException e) { this.Logger.TryLogFail(() => TransactionFailed.Fire(this, new TransactionFailedEventArgs(this, e))); throw; } }
public override void Rollback() { try { base.Rollback(); this.Logger.TryLogFail(() => TransactionRolledBack.Fire(this, new TransactionEventArgs(this))); } catch (TransactionException e) { this.Logger.TryLogFail(() => TransactionFailed.Fire(this, new TransactionFailedEventArgs(this, e))); throw; } }
public override void Commit() { try { base.Commit(); _Logger.TryLogFail(() => TransactionCompleted.Fire(this, new TransactionEventArgs(this))); } catch (TransactionException e) { _Logger.TryLogFail(() => TransactionFailed.Fire(this, new TransactionFailedEventArgs(this, e))); throw; } }
private void FailedHandler(object sender, TransactionFailedEventArgs e) { TransactionFailed.Fire(this, e); }