示例#1
0
        private string FormatLoggingData(LoggingData[] loggingData)
        {
            StringBuilder sb = new StringBuilder();

            foreach (var item in loggingData)
            {
                sb.AppendLine(item.Name + ": " + item.Value);
            }

            return sb.ToString();
        }
示例#2
0
 public void LogError(LoggingData[] loggingData, Exception exception)
 {
     Console.WriteLine("Error" + Environment.NewLine + FormatLoggingData(loggingData));
     Console.WriteLine(exception.Message);
 }
示例#3
0
 public void LogSuccess(LoggingData[] loggingData)
 {
     Console.WriteLine("Success" + Environment.NewLine + FormatLoggingData(loggingData));
 }
 public ConstantMethodLoggingDataExtractor(LoggingData[] constantData)
 {
     this.constantData = constantData;
 }