Example #1
0
        private JValue CleanseValue(JValue value)
        {
            var text     = value.Value <string>();
            var cleansed = CleanseLogMessage.Cleanse(text);

            return(new JValue(cleansed));
        }
Example #2
0
 public override void Visit(JArray json)
 {
     for (var i = 0; i < json.Count; i++)
     {
         if (json[i].Type == JTokenType.String)
         {
             var text = json[i].Value <string>();
             json[i] = new JValue(CleanseLogMessage.Cleanse(text));
         }
     }
     foreach (JToken token in json)
     {
         Visit(token);
     }
 }
Example #3
0
 protected override string GetFormattedMessage(LogEventInfo logEvent)
 {
     return(CleanseLogMessage.Cleanse(Layout.Render(logEvent)));
 }