public class ChainSawHandler extends ChainHandler
Output is a variant of the common logfile format. The common logfile format is as follows:
remotehost rfc931 authuser [date] "request" status bytes
Additional Configuration options:
See the LogHandler handler for generating logs whose
contents are configurable.
| Modifier and Type | Field and Description |
|---|---|
static int |
BUFSIZE |
static java.lang.String |
FLUSH |
static java.lang.String |
LOG |
exitOnError, handlers, isMine, names, prefix, report| Constructor and Description |
|---|
ChainSawHandler() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
init(Server server,
java.lang.String prefix)
Initializes this
ChainHandler by initializing all the
"wrapped" handlers in the list of handlers. |
boolean |
respond(Request request)
Run the chain-handler, counting the # of bytes of output generated
by its chained handlers.
|
initHandlerpublic static final java.lang.String LOG
public static final java.lang.String FLUSH
public static final int BUFSIZE
public boolean init(Server server, java.lang.String prefix)
ChainHandlerChainHandler by initializing all the
"wrapped" handlers in the list of handlers. If a wrapped handler
cannot be initialized, this method logs a message and skips it. If no
handlers were specified, or no handlers were successfully initialized,
then the initialization of this ChainHandler is
considered to have failed.init in interface Handlerinit in class ChainHandlerserver - The HTTP server that created this ChainHandler.prefix - The prefix for this ChainHandler's properties.true if at least one of the wrapped handlers
was successfully initialized.public boolean respond(Request request) throws java.io.IOException
respond in interface Handlerrespond in class ChainHandlerrequest - The HTTP request.true if one of the Handlers returns
true, false otherwise.java.io.IOException - if one of the Handlers throws an
IOException while responding.