Package java.util.logging

Examples of java.util.logging.Level.intValue()


      con = getConnection();
      stm = con.prepareStatement(INSERT_SQL);

      int col = 1;
      stm.setTimestamp(col++, new Timestamp(millis));
      stm.setInt(col++, level.intValue());
      setNullableVarchar(stm, col++, transactionID);
      setNullableVarchar(stm, col++, eventID);
      setNullableVarchar(stm, col++, eventType);
      setNullableVarchar(stm, col++, componentID);
      setNullableVarchar(stm, col++, threadID);
View Full Code Here


           
            // Include the integer level value in the log
            Level level = record.getLevel();
            if (!excludeFieldsSupport.isSet(ExcludeFieldsSupport.SupplementalAttribute.LEVEL_VALUE)) {
                recordBuffer.append("_LevelValue").append(NV_SEPARATOR);
                int levelValue = level.intValue();
                logEvent.setLevelValue(levelValue);
                recordBuffer.append(levelValue).append(NVPAIR_SEPARATOR);               
            }
           
            String msgId = getMessageId(record);
View Full Code Here

            }

            // See 6316018. ClassName and MethodName information should be
            // included for FINER and FINEST log levels.
            if (LOG_SOURCE_IN_KEY_VALUE ||
                    (level.intValue() <= Level.FINE.intValue())) {
                String sourceClassName = record.getSourceClassName();
                // sourceClassName = (sourceClassName == null) ? "" : sourceClassName;
                if (sourceClassName != null && !sourceClassName.isEmpty()) {
                    recordBuffer.append(CLASS_NAME).append(NV_SEPARATOR);
                    logEvent.getSupplementalAttributes().put(CLASS_NAME, sourceClassName);
View Full Code Here

           
            // Include the integer level value in the log
            Level level = record.getLevel();
            if (!excludeFieldsSupport.isSet(ExcludeFieldsSupport.SupplementalAttribute.LEVEL_VALUE)) {
                recordBuffer.append("_LevelValue").append(NV_SEPARATOR);
                int levelValue = level.intValue();
                logEvent.setLevelValue(levelValue);
                recordBuffer.append(levelValue).append(NVPAIR_SEPARATOR);               
            }
           
            String msgId = getMessageId(record);
View Full Code Here

            }

            // See 6316018. ClassName and MethodName information should be
            // included for FINER and FINEST log levels.
            if (LOG_SOURCE_IN_KEY_VALUE ||
                    (level.intValue() <= Level.FINE.intValue())) {
                String sourceClassName = record.getSourceClassName();
                // sourceClassName = (sourceClassName == null) ? "" : sourceClassName;
                if (sourceClassName != null && !sourceClassName.isEmpty()) {
                    recordBuffer.append(CLASS_NAME).append(NV_SEPARATOR);
                    logEvent.getSupplementalAttributes().put(CLASS_NAME, sourceClassName);
View Full Code Here

  }

  private void setUpMyLevel() {
    Level l = _myConfigLFH._defaultLevel;
    for (LogConfig.L_LogFilterHandler.L_LogFilterConfigEntry fce : _myConfigLFH._logFCEList)
      if (fce._level.intValue() < l.intValue())
        l = fce._level;
    setLevel(l);
  }

  private void getMyHandlers() {
View Full Code Here

  private void resetMightPublish(final Level l) {
    Set<Map.Entry<LogConfig.L_LogHandler, L_HandlerEx>> handlerSet = _myHandlers.entrySet();
    for (Map.Entry<LogConfig.L_LogHandler, L_HandlerEx> handlerEnt : handlerSet) {
      Level handlerMinLevel = handlerEnt.getKey()._minimalLevel;
      handlerEnt.getValue()._mightPublish = (handlerMinLevel == null || l.intValue() >= handlerMinLevel.intValue());
    }
  }

  private void publishDefault(final LogRecord logRec) {
    if (logRec.getLevel().intValue() < _myConfigLFH._defaultLevel.intValue())
View Full Code Here

            }
            if (level != null) {
                // If a level was specified, changes to a finer level if needed
                // (e.g. from FINE to FINER, but not the opposite).
                final Level current = logger.getLevel();
                if (current == null || current.intValue() > level.intValue()) {
                    logger.setLevel(level);
                }
            }
        }
    }
View Full Code Here

        }
    }
   
    private boolean isSufficientLoggingEnabled() {
        Level level = log.getLevel();
        return level != null && level.intValue() <= Level.INFO.intValue();
    }

    private String createLogString(DatabaseObject[] tables, BeginEndQuote quotes) {
        this.quotes = quotes;
        tableString = new StringBuilder("Populating the following tables:");
View Full Code Here

            final Logger logger = LogManager.getLogManager().getLogger(loggerName);
            if (logger == null) {
                final String msg = MessageFormat.format(
                        rb.getString("appclient.nullLogger"),
                        loggerName);
                if (level.intValue() <= Level.CONFIG.intValue()) {
                    System.err.println(msg);
                }
            } else {
                reviseLogger(
                        logger,
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.