private bool SetExtraMetadata(IEvent report, Dictionary <string, object> extraData) { if (extraData != null && extraData.Any()) { report.AddMetadata("Extra", extraData); } return(true); }
public static void AddMetadata(this IEvent e, Enum section, string key, object value) { var sectionName = section.ToLabelName(); if (!string.IsNullOrEmpty(sectionName)) { e.AddMetadata(sectionName, key, value); } else { throw new ArgumentException("section has not LabelName"); } }
public static void AddMetadata(this IEvent e, Section section, string key, object value) { e.AddMetadata((Enum)section, key, value); }