Code example for LogRecord

Methods: getLevel, getLoggerName, getMessage, getMillis

0
        super(); 
    } 
     
    @Override public String format(LogRecord record) {
        Object[] arguments = new Object[6];
        arguments[0] = record.getLoggerName();
        arguments[0] = ""; // as long as there's only 1 logger this just takes unnecessary space -atomy
        arguments[1] = String.format("%8s", record.getLevel());
        arguments[2] = String.format("%10s", Thread.currentThread().getName());
        arguments[3] = new Date(record.getMillis());
        arguments[4] = record.getMessage();
        arguments[5] = System.getProperty("line.separator");
        return messageFormat.format(arguments);
    }    
  
}