public void Warning( Exception exception, string format, params object[] args )
 {
     var msg = string.Format( format, args );
     Warning( "{0}{1}{2}", msg, Environment.NewLine, exception.Dump() );
 }
        public void LogError(Exception exception, string shortMessage = null, string fullMessage = null, bool notify = false, IList<string> errors = null)
        {
            try
            {
                if (exception != null)
                {
                    shortMessage = exception.Message;
                    fullMessage = exception.ToString();
                    exception.Dump();
                }

                if (shortMessage.HasValue())
                {
                    Logger.InsertLog(LogLevel.Error, shortMessage, fullMessage.EmptyNull());

                    if (notify)
                        _services.Notifier.Error(new LocalizedString(shortMessage));
                }
            }
            catch (Exception) { }

            if (errors != null && shortMessage.HasValue())
                errors.Add(shortMessage);
        }
 public static bool Log(Exception e)
 {
     e.Dump();
     return false;
 }
Beispiel #4
0
 public void ReportError( Exception exception )
 {
     ReportError( exception.Dump() );
 }