Class HybrisLoggingEvent

java.lang.Object
de.hybris.platform.util.logging.HybrisLoggingEvent
Direct Known Subclasses:
TestLogListener.TestHybrisLoggingEvent

public class HybrisLoggingEvent extends Object
Extended version of the LoggingEvent class to allow modifying of the message field and to manage the deny flag. Since 6.0 it no longer extends LoggingEvent class due to log4j2 migration.
  • Constructor Details

    • HybrisLoggingEvent

      public HybrisLoggingEvent(String fqnOfCategoryClass, org.apache.log4j.Category logger, org.apache.log4j.Level level, Object message, Throwable throwable)
      Creates a new logging event similar to LoggingEvent. Resets the deny flag.
      Parameters:
      fqnOfCategoryClass - Fully qualified name of the calling category class.
      logger - The logger generating this event.
      level - The level of this event.
      message - The message of this event.
      throwable - The throwable of this event.
    • HybrisLoggingEvent

      public HybrisLoggingEvent(String fqnOfCategoryClass, org.apache.log4j.Category logger, org.apache.log4j.Level level, Object message, Throwable throwable, String name)
      Creates a new logging event similar to LoggingEvent. Resets the deny flag.
      Parameters:
      fqnOfCategoryClass - Fully qualified name of the calling category class.
      logger - The logger generating this event.
      level - The level of this event.
      message - The message of this event.
      throwable - The throwable of this event.
      name - The name of this event
  • Method Details

    • deny

      public void deny()
      Sets the deny flag and therefore the event will not be logged anymore.
    • isDenied

      public boolean isDenied()
      Checks the deny flag.
      Returns:
      true if the event is denied and will not be logged, false otherwise
    • getMessage

      public Object getMessage()
    • setMessage

      public void setMessage(Object message)
      Sets a new message for this event.
      Parameters:
      message - new message
    • getRenderedMessage

      public String getRenderedMessage()
    • getLevel

      public org.apache.log4j.Level getLevel()
    • getFQNOfLoggerClass

      public String getFQNOfLoggerClass()
    • getLogger

      public org.apache.log4j.Category getLogger()
    • getThrowable

      public Throwable getThrowable()
    • getName

      public String getName()