public override void Clear() { var oldErrors = this.ToList(); base.Clear(); oldErrors.ForEach(ve => EntityAspect.OnErrorsChanged(ve)); }
public override void Add(ValidationError item) { if (!this.Contains(item)) { base.Add(item); EntityAspect.OnErrorsChanged(item); } }
public override bool Remove(ValidationError item) { if (base.Remove(item)) { EntityAspect.OnErrorsChanged(item); return(true); } else { return(false); } }
public override bool RemoveKey(string key) { var removedError = this[key]; if (removedError != null) { base.RemoveKey(key); EntityAspect.OnErrorsChanged(removedError); return(true); } else { return(false); } }