public class ProtocolHandlers
extends java.lang.Object
A container for ProtocolHandlers accessible from HttpClient.getProtocolHandlers().
| Modifier | Constructor | Description |
|---|---|---|
protected |
ProtocolHandlers() |
| Modifier and Type | Method | Description |
|---|---|---|
void |
clear() |
Removes all protocol handlers from this container.
|
ProtocolHandler |
find(Request request,
Response response) |
Finds the first protocol handler that
accepts
the given request and response. |
ProtocolHandler |
put(ProtocolHandler protocolHandler) |
Stores the given
protocolHandler in this container. |
ProtocolHandler |
remove(java.lang.String name) |
Removes the protocol handler with the given name.
|
public ProtocolHandler put(ProtocolHandler protocolHandler)
Stores the given protocolHandler in this container.
If a protocol handler with the same name exists, it is replaced by the given one, and the existing returned.
protocolHandler - the protocol handler to storeremove(String)public ProtocolHandler remove(java.lang.String name)
Removes the protocol handler with the given name.
name - the name of the protocol handler to removeput(ProtocolHandler),
clear()public void clear()
Removes all protocol handlers from this container.
public ProtocolHandler find(Request request, Response response)
Finds the first protocol handler that
accepts
the given request and response.
request - the request to acceptresponse - the response to acceptCopyright © 1995–2018 Webtide. All rights reserved.