Interface TextLogEventParser

All Superinterfaces:
LogEventParser
All Known Implementing Classes:
JsonLogEventParser, XmlLogEventParser, YamlLogEventParser

public interface TextLogEventParser extends LogEventParser
Parses the output from a text based layout into instances of LogEvent.
  • Method Summary

    Modifier and Type
    Method
    Description
    Parses a String, which is expected to contain exactly one log event.

    Methods inherited from interface org.apache.logging.log4j.core.parser.LogEventParser

    parseFrom, parseFrom
  • Method Details

    • parseFrom

      LogEvent parseFrom(String input) throws ParseException
      Parses a String, which is expected to contain exactly one log event.
      Parameters:
      input - the string
      Returns:
      the parsed LogEvent, never null.
      Throws:
      ParseException - if the input is malformed and cannot be parsed as a LogEvent