internal ServiceResult?BeforeAction(CrudAction arg1, Model?_) { if (arg1.HasFlag(CrudAction.Commit)) { _stopwatch.Restart(); } return(null); }
internal ServiceResult?AfterAction(CrudAction arg1, Model?_) { if (arg1.HasFlag(CrudAction.Commit)) { _stopwatch.Stop(); Elapsed?.Invoke(this, _stopwatch.Elapsed.TotalMilliseconds.PushInto(_events)); Notify(nameof(EventCount)); Notify(nameof(AverageMs)); Notify(nameof(MinMs)); Notify(nameof(MaxMs)); } return(null); }