using System.Collections.Generic; using System.Text; namespace Timeline.Helpers { public static class MyLogHelper { public static KeyValuePair Pair(string key, object value) => new KeyValuePair(key, value); public static string FormatLogMessage(string summary, params KeyValuePair[] properties) { var builder = new StringBuilder(); builder.Append(summary); foreach (var property in properties) { builder.AppendLine(); builder.Append(property.Key); builder.Append(" : "); builder.Append(property.Value); } return builder.ToString(); } } }