org.jboss.logmanager.handlers
Class ConsoleHandler
java.lang.Object
java.util.logging.Handler
org.jboss.logmanager.ExtHandler
org.jboss.logmanager.handlers.WriterHandler
org.jboss.logmanager.handlers.OutputStreamHandler
org.jboss.logmanager.handlers.ConsoleHandler
- All Implemented Interfaces:
- Closeable, Flushable, FlushableCloseable
public class ConsoleHandler
- extends OutputStreamHandler
A console handler which writes to System.out
by default.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ConsoleHandler
public ConsoleHandler()
- Construct a new instance.
ConsoleHandler
public ConsoleHandler(Formatter formatter)
- Construct a new instance.
- Parameters:
formatter
- the formatter to use
ConsoleHandler
public ConsoleHandler(ConsoleHandler.Target target)
- Construct a new instance.
- Parameters:
target
- the target to write to, or null
to start with an uninitialized target
ConsoleHandler
public ConsoleHandler(ConsoleHandler.Target target,
Formatter formatter)
- Construct a new instance.
- Parameters:
target
- the target to write to, or null
to start with an uninitialized targetformatter
- the formatter to use
setTarget
public void setTarget(ConsoleHandler.Target target)
- Set the target for this console handler.
- Parameters:
target
- the target to write to, or null
to clear the target
setOutputStream
public void setOutputStream(OutputStream outputStream)
- Set the output stream to write to.
- Overrides:
setOutputStream
in class OutputStreamHandler
- Parameters:
outputStream
- the new output stream or null
for none
Copyright © 2011 JBoss, a division of Red Hat, Inc.. All Rights Reserved.