Class LevelAttributeConverter

java.lang.Object
org.apache.logging.log4j.core.appender.db.jpa.converter.LevelAttributeConverter
All Implemented Interfaces:
javax.persistence.AttributeConverter<Level,String>

public class LevelAttributeConverter extends Object implements javax.persistence.AttributeConverter<Level,String>
A JPA 2.1 attribute converter for Levels in LogEvents. This converter is capable of converting both to and from Strings.
  • Constructor Details

    • LevelAttributeConverter

      public LevelAttributeConverter()
  • Method Details

    • convertToDatabaseColumn

      public String convertToDatabaseColumn(Level level)
      Specified by:
      convertToDatabaseColumn in interface javax.persistence.AttributeConverter<Level,String>
    • convertToEntityAttribute

      public Level convertToEntityAttribute(String s)
      Specified by:
      convertToEntityAttribute in interface javax.persistence.AttributeConverter<Level,String>