Record Class FLogger

java.lang.Object
java.lang.Record
net.flectone.pulse.util.logging.FLogger

public record FLogger(Consumer<LogRecord> logConsumer, Supplier<FileFacade> fileFacadeSupplier) extends Record
  • Field Details

    • DEBUG_ENABLED

      public static final boolean DEBUG_ENABLED
    • ERROR_MESSAGE_REPORT

      public static final String ERROR_MESSAGE_REPORT
      See Also:
  • Constructor Details

    • FLogger

      public FLogger(Consumer<LogRecord> logConsumer, Supplier<FileFacade> fileFacadeSupplier)
      Creates an instance of a FLogger record class.
      Parameters:
      logConsumer - the value for the logConsumer record component
      fileFacadeSupplier - the value for the fileFacadeSupplier record component
  • Method Details

    • config

      public Config.Logger config()
    • log

      public void log(LogRecord logRecord)
    • logEnabling

      public void logEnabling()
    • logEnabled

      public void logEnabled()
    • logDisabling

      public void logDisabling()
    • logDisabled

      public void logDisabled()
    • logReloading

      public void logReloading()
    • logReloaded

      public void logReloaded()
    • logDescription

      public void logDescription()
    • info

      public void info(String string)
    • info

      public void info(String format, Object... args)
    • warning

      public void warning(Object object)
    • warning

      public void warning(String string)
    • warning

      public void warning(String format, Object... args)
    • warning

      public void warning(Throwable throwable)
    • warning

      public void warning(Throwable throwable, String string)
    • warning

      public void warning(Throwable throwable, String format, Object args)
    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • logConsumer

      public Consumer<LogRecord> logConsumer()
      Returns the value of the logConsumer record component.
      Returns:
      the value of the logConsumer record component
    • fileFacadeSupplier

      public Supplier<FileFacade> fileFacadeSupplier()
      Returns the value of the fileFacadeSupplier record component.
      Returns:
      the value of the fileFacadeSupplier record component