public class LoggingFilter extends ClientFilter
| Constructor and Description |
|---|
LoggingFilter()
Create a logging filter logging the request and response to
a default JDK logger, named as the fully qualified class name of this
class.
|
LoggingFilter(java.util.logging.Logger logger)
Create a logging filter logging the request and response to
a JDK logger.
|
LoggingFilter(java.util.logging.Logger logger,
int maxEntitySize)
Create a logging filter logging the request and response to
a JDK logger.
|
LoggingFilter(java.io.PrintStream loggingStream)
Create a logging filter logging the request and response to
print stream.
|
LoggingFilter(java.io.PrintStream loggingStream,
int maxEntitySize)
Create a logging filter logging the request and response to
print stream.
|
| Modifier and Type | Method and Description |
|---|---|
ClientResponse |
handle(ClientRequest request)
Handle a HTTP request as a
ClientRequest and return the HTTP
response as a ClientResponse. |
getNextpublic LoggingFilter()
public LoggingFilter(java.util.logging.Logger logger)
logger - the logger to log requests and responses.public LoggingFilter(java.io.PrintStream loggingStream)
loggingStream - the print stream to log requests and responses.public LoggingFilter(java.util.logging.Logger logger,
int maxEntitySize)
logger - the logger to log requests and responses.maxEntitySize - maximum number of entity bytes to be logged (and buffered) - if the entity is larger,
logging filter will print (and buffer in memory) only the specified number of bytes
and print "...more..." string at the end.public LoggingFilter(java.io.PrintStream loggingStream,
int maxEntitySize)
loggingStream - the print stream to log requests and responses.maxEntitySize - maximum number of entity bytes to be logged (and buffered) - if the entity is larger,
logging filter will print (and buffer in memory) only the specified number of bytes
and print "...more..." string at the end.public ClientResponse handle(ClientRequest request) throws ClientHandlerException
ClientHandlerClientRequest and return the HTTP
response as a ClientResponse.handle in interface ClientHandlerhandle in class ClientFilterrequest - the HTTP request.ClientHandlerException - if the client
handler fails to process the request or response.Copyright © 2016 Oracle Corporation. All Rights Reserved.