/// <summary> /// Called to inform the viewer of an exception state. /// </summary> /// <param name="Exception">Exception.</param> public void Exception(Exception Exception) { AggregateException ex; Exception = Log.UnnestException(Exception); if ((ex = Exception as AggregateException) != null) { foreach (Exception ex2 in ex.InnerExceptions) { this.Exception(ex2); } } else { string Msg = Exception.Message + "\r\n\r\n" + Exception.StackTrace; if (this.hasSniffers) { foreach (ISniffer Sniffer in this.staticList) { Sniffer.Exception(Msg); } } } }
/// <summary> /// Called to inform the viewer of an exception state. /// </summary> /// <param name="Exception">Exception.</param> public void Exception(Exception Exception) { Exception = Log.UnnestException(Exception); if (Exception is AggregateException ex) { foreach (Exception ex2 in ex.InnerExceptions) { this.Exception(ex2); } } else { string Msg = Exception.Message + "\r\n\r\n" + Log.CleanStackTrace(Exception.StackTrace); if (this.hasSniffers) { foreach (ISniffer Sniffer in this.staticList) { Sniffer.Exception(Msg); } } } }