Class LoggerFactory


  • public class LoggerFactory
    extends java.lang.Object
    LoggerFactory can be used to set a logger. The logger should be created by implementing Logger. In the implementation users can choose how they log received messages. Added for developers. For some cases it can be handy to receive logging statements while developing applications with iText
    • Constructor Detail

      • LoggerFactory

        private LoggerFactory()
    • Method Detail

      • getLogger

        public static Logger getLogger​(java.lang.Class<?> klass)
        Returns the logger set in this LoggerFactory. Defaults to NoOpLogger
        Parameters:
        klass -
        Returns:
        the logger.
      • getLogger

        public static Logger getLogger​(java.lang.String name)
        Returns the logger set in this LoggerFactory. Defaults to NoOpLogger
        Parameters:
        name -
        Returns:
        the logger.
      • getInstance

        public static LoggerFactory getInstance()
        Returns the LoggerFactory
        Returns:
        singleton instance of this LoggerFactory
      • setLogger

        public void setLogger​(Logger logger)
        Set the global logger to process logging statements with.
        Parameters:
        logger - the logger
      • logger

        public Logger logger()
        Get the logger.
        Returns:
        the logger