Class Sfl4jLoggerFactory

  • All Implemented Interfaces:
    Prioritized, java.lang.Comparable<Prioritized>

    public class Sfl4jLoggerFactory
    extends LoggerFactory
    The LoggerFactory implementation for creating and managing SLF4J-based Logger instances.

    SLF4J (Simple Logging Facade for Java) is a popular logging abstraction that allows the end-user to plug in their desired logging framework at deployment time. This factory checks for the availability of the SLF4J logging infrastructure and creates corresponding logger instances.

    Configuration

    This factory has a fixed priority level of Prioritized.NORMAL_PRIORITY, meaning it will be used if no higher-priority logger factory is available.

    Example Usage

    
     // Get a logger instance by class
     Logger logger = LoggerFactory.getLogger(MyClass.class);
    
     // Log a message
     logger.info("This is an info message");
     
    Since:
    1.0.0
    Author:
    Mercy
    See Also:
    LoggerFactory, Logger
    • Field Detail

      • SLF4J_LOGGER_CLASS_NAME

        public static final java.lang.String SLF4J_LOGGER_CLASS_NAME
        See Also:
        Constant Field Values
    • Constructor Detail

      • Sfl4jLoggerFactory

        public Sfl4jLoggerFactory()