public void log(int priority, String msg, Throwable t) { // Boost the priority of NPE and friends so they get seen and reported //if (t != null && t instanceof RuntimeException && !(t instanceof IllegalArgumentException)) // priority = CRIT; if (priority >= _minPriority) { _manager.addRecord(new LogRecord(_class, _name, Thread.currentThread().getName(), priority, msg, t)); } }
public void log(int priority, String msg) { if (priority >= _minPriority) { _manager.addRecord(new LogRecord(_class, _name, Thread.currentThread().getName(), priority, msg, null)); } }
/** * Always log this messge with the given priority, ignoring current minimum priority level. * This allows an INFO message about changing port numbers, for example, to always be logged. * @since 0.8.2 */ public void logAlways(int priority, String msg) { _manager.addRecord(new LogRecord(_class, _name, Thread.currentThread().getName(), priority, msg, null)); }