Class TypeConverters.LevelConverter

java.lang.Object
org.apache.logging.log4j.core.config.plugins.convert.TypeConverters.LevelConverter
All Implemented Interfaces:
TypeConverter<Level>
Enclosing class:
TypeConverters

@Plugin(name="Level", category="TypeConverter") public static class TypeConverters.LevelConverter extends Object implements TypeConverter<Level>
Converts a String into a Log4j Level. Returns null for invalid level names.
  • Constructor Details

    • LevelConverter

      public LevelConverter()
  • Method Details

    • convert

      public Level convert(String s)
      Description copied from interface: TypeConverter
      Converts a String to a given type.
      Specified by:
      convert in interface TypeConverter<Level>
      Parameters:
      s - the String to convert. Cannot be null.
      Returns:
      the converted object.