public static void Log(this ReflectionTypeLoadException ex, ISHLogStrategy log, string message)
    {
        var builder = new StringBuilder();
        builder.AppendLine(message);
        builder.AppendLine("ReflectionTypeLoadException: {0}".With(ex.Message));
        builder.AppendLine("    LoaderExceptions:".With(ex.Message));

        foreach (var l in ex.LoaderExceptions)
        {
            builder.AppendLine("        * {0}: {1}".With(l.GetType().Name, l.Message));
        }

        log.Error(builder.ToString());
    }
예제 #2
0
    public static void Log(this ReflectionTypeLoadException ex, ISHLogStrategy log, string message)
    {
        var builder = new StringBuilder();

        builder.AppendLine(message);
        builder.AppendLine("ReflectionTypeLoadException: {0}".With(ex.Message));
        builder.AppendLine("    LoaderExceptions:".With(ex.Message));

        foreach (var l in ex.LoaderExceptions)
        {
            builder.AppendLine("        * {0}: {1}".With(l.GetType().Name, l.Message));
        }

        log.Error(builder.ToString());
    }
 /// <summary>
 /// Writes the error log level message.
 /// </summary>
 /// <param name='message'>
 /// Message.
 /// </param>
 /// <param name='args'>
 /// Arguments.
 /// </param>
 public void Error(string message, params object[] args)
 {
     m_underlyingLogStrategy.Error(BuildMessage(message), args);
 }