public class LogHandlerProxy
extends java.util.logging.Handler
| Constructor and Description |
|---|
LogHandlerProxy(java.util.logging.Handler delegate,
TimestampProvider timesrc)
Creates a proxy log handler with a given delegate using timestamps from the
specified TimestampProvider.
|
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Close log output stream.
|
void |
flush()
Flush log output stream.
|
static void |
install(TimestampProvider timesrc,
java.util.logging.Logger log)
Installs this handler for all handlers in the root logger.
|
void |
publish(java.util.logging.LogRecord rec)
Publish log record with modified timestamp.
|
void |
setTimestampProvider(TimestampProvider timesrc)
Sets the current TimestampProvider used for log timestamp.
|
public LogHandlerProxy(java.util.logging.Handler delegate,
TimestampProvider timesrc)
delegate - log handler delegate.timesrc - TimestampProvider to use for timestamps.public void setTimestampProvider(TimestampProvider timesrc)
timesrc - TimestampProvider to use for timestamps, null to leave timestamps unchanged.public void publish(java.util.logging.LogRecord rec)
publish in class java.util.logging.HandlerHandler.publish(java.util.logging.LogRecord)public void close()
close in class java.util.logging.HandlerHandler.close()public void flush()
flush in class java.util.logging.HandlerHandler.flush()public static void install(TimestampProvider timesrc, java.util.logging.Logger log)
timesrc - TimestampProvider to use for timestamps.log - logger to install on, null for root logger.