private void internalLogFormatted()

in webbeans-slf4j/src/main/java/org/apache/openwebbeans/slf4j/Slf4jLogger.java [501:606]


    private void internalLogFormatted(final String msg, final LogRecord record)
    {
        final Level level = record.getLevel();
        final Throwable t = record.getThrown();
        final Handler[] targets = getHandlers();
        if (targets != null)
        {
            for (Handler h : targets)
            {
                h.publish(record);
            }
        }
        if (!getUseParentHandlers())
        {
            return;
        }

        if (Level.FINE.equals(level))
        {
            if (locationAwareLogger == null)
            {
                logger.debug(msg, t);
            }
            else
            {
                locationAwareLogger.log(null, FQN, LocationAwareLogger.DEBUG_INT, msg, null, t);
            }
        }
        else if (Level.INFO.equals(level))
        {
            if (locationAwareLogger == null)
            {
                logger.info(msg, t);
            }
            else
            {
                locationAwareLogger.log(null, FQN, LocationAwareLogger.INFO_INT, msg, null, t);
            }
        }
        else if (Level.WARNING.equals(level))
        {
            if (locationAwareLogger == null)
            {
                logger.warn(msg, t);
            }
            else
            {
                locationAwareLogger.log(null, FQN, LocationAwareLogger.WARN_INT, msg, null, t);
            }
        }
        else if (Level.FINER.equals(level))
        {
            if (locationAwareLogger == null)
            {
                logger.trace(msg, t);
            }
            else
            {
                locationAwareLogger.log(null, FQN, LocationAwareLogger.DEBUG_INT, msg, null, t);
            }
        }
        else if (Level.FINEST.equals(level))
        {
            if (locationAwareLogger == null)
            {
                logger.trace(msg, t);
            }
            else
            {
                locationAwareLogger.log(null, FQN, LocationAwareLogger.TRACE_INT, msg, null, t);
            }
        }
        else if (Level.ALL.equals(level))
        {
            if (locationAwareLogger == null)
            {
                logger.error(msg, t);
            }
            else
            {
                locationAwareLogger.log(null, FQN, LocationAwareLogger.ERROR_INT, msg, null, t);
            }
        }
        else if (Level.SEVERE.equals(level))
        {
            if (locationAwareLogger == null)
            {
                logger.error(msg, t);
            }
            else
            {
                locationAwareLogger.log(null, FQN, LocationAwareLogger.ERROR_INT, msg, null, t);
            }
        }
        else if (Level.CONFIG.equals(level))
        {
            if (locationAwareLogger == null)
            {
                logger.debug(msg, t);
            }
            else
            {
                locationAwareLogger.log(null, FQN, LocationAwareLogger.DEBUG_INT, msg, null, t);
            }
        }
    }