HttpHeader object, which represents HTTP request message.
HttpHeader, HttpResponsePacket
| Modifier and Type | Class and Description |
|---|---|
| public static class | HttpRequestPacket.
HttpRequestPacket message builder. |
| Modifier and Type | Field and Description |
|---|---|
| private static final AttributeBuilder | |
| protected final Map | attributes
The attributes associated with this Request, keyed by attribute name.
|
| private final DataChunk | authTypeC
Authentication type. |
| private Connection | |
| private boolean | |
| protected final DataChunk | |
| private String | |
| protected final DataChunk | |
| protected int | |
| private final DataChunk | |
| private final transient AttributeHolder | notesHolder
Internal notes associated with this request by Catalina components and event listeners. |
| protected Method | |
| private final DataChunk | |
| public static final String | READ_ONLY_ATTR_PREFIX
Prefix for all service/read-only attributes, that once added could not be removed. |
| protected final DataChunk | |
| protected final DataChunk | |
| protected int | |
| private final DataChunk | |
| private final RequestURIRef | |
| private boolean | |
| private HttpResponsePacket | |
| private final DataChunk | |
| private int | |
| protected DataChunk |
| Access | Constructor and Description |
|---|---|
| protected |
| Modifier and Type | Method and Description |
|---|---|
| public DataChunk | |
| public static HttpRequestPacket. | |
| public static < the E> NoteNote type. | Returns: theNote.the name)Note name.Create a named |
| protected void | |
| public Object | getAttribute(final String
Name of the request attribute to return name)Returns: the specified request attribute if it exists; otherwise, return |
| public Set | getAttributeNames()
Returns: read-only |
| public Connection | |
| public String | getLocalAddress()
Returns: a |
| public String | |
| public String | getLocalName()
Returns: a |
| public int | getLocalPort()
Returns: the Internet Protocol (IP) port number of the interface on which the request was received. |
| public Method | |
| public DataChunk | Returns: the HTTP request method asDataChunk (avoiding creation of a String object). The result format is
"GET|POST...".Get the HTTP request method as |
| public < the E> ENote type. | |
| public Set | Returns: aSet containing the String names of all note bindings that exist for this request.Return a |
| public String | |
| public String | Returns: the query string that is contained in the request URL after the path. This method returns null if the URL does not have a query string.Returns the query string that is contained in the request URL after the path. |
| public DataChunk | Returns: the query string that is contained in the request URL after the path. This method returns null if the URL does not have a query string. The result is represented asDataChunk (avoiding creation of a String object).Returns the query string that is contained in the request URL after the path. |
| public String | getRemoteAddress()
Returns: the Internet Protocol (IP) address of the client or last proxy that sent the request. |
| public String | getRemoteHost()
Returns: a |
| public int | getRemotePort()
Returns: the Internet Protocol (IP) source port of the client or last proxy that sent the request. |
| public String | |
| public RequestURIRef | Returns: the request URL of the HTTP request asRequestURIRef (avoiding creation of a String object).Returns the request URL of the HTTP request as |
| public HttpResponsePacket | |
| public int | getServerPort()
Returns: Returns the integer value of the Internet Protocol (IP) port as specified in the |
| public boolean | Returns: true if this request is a HEAD request, otherwise returns false.Returns |
| public final boolean | isRequest()
Implements abstract org. Returns true, if the current HttpHeader represent HTTP request message, or false otherwise. |
| public DataChunk | |
| public DataChunk | |
| private void | |
| public DataChunk | remoteAddr()
Returns: the |
| public DataChunk | remoteHost()
Returns: a |
| public DataChunk | |
| public void | removeAttribute(final String
Name of the request attribute to remove name)Remove the specified request attribute if it exists. |
| public < the E> ENote type. | Returns: the old value associated with theNote, that was removedNote value to be removedRemove the |
| protected void | requiresAcknowledgement(boolean
true if expectation processing is required.Allows consumers of this request to be notified if the user-agent requires acknowledgment of an expectation (i.e., the Expect header). |
| public boolean | |
| protected void | |
| public DataChunk | Returns: the buffer holding the server name, if anyReturn the buffer holding the server name, if any. |
| protected DataChunk | Returns: the buffer holding the server nameReturn the buffer holding the server name, if any. |
| public void | setAttribute(final String
Name of the request attribute to set name, final Object The associated value value)Set the specified request attribute to the specified value. |
| public void | |
| public void | setLocalHost(String
the host name of the server servicing this request. host)Set the host name of the server servicing this request. |
| public void | setLocalPort(int
the port on which the request was received port)Sets the Internet Protocol (IP) port number of the interface on which the request was received. |
| public void | |
| public void | |
| public < the E> voidNote type. | |
| public void | |
| public void | setRemotePort(int
the source port of the client port)Sets the Internet Protocol (IP) source port of the client or last proxy that sent the request. |
| public void | |
| protected void | |
| public void | setServerPort(int
the port as specified in the serverPort)Host request headerSets the Internet Protocol (IP) port specified in the |
| public String |
| ATTR_BUILDER | back to summary |
|---|---|
| private static final AttributeBuilder ATTR_BUILDER | |
| attributes | back to summary |
|---|---|
| protected final Map<String, Object> attributes Hides org. The attributes associated with this Request, keyed by attribute name. | |
| authTypeC | back to summary |
|---|---|
| private final DataChunk authTypeC Authentication type. | |
| connection | back to summary |
|---|---|
| private Connection<L> connection | |
| hostHeaderParsed | back to summary |
|---|---|
| private boolean hostHeaderParsed | |
| localAddressC | back to summary |
|---|---|
| protected final DataChunk localAddressC | |
| localHost | back to summary |
|---|---|
| private String localHost | |
| localNameC | back to summary |
|---|---|
| protected final DataChunk localNameC | |
| localPort | back to summary |
|---|---|
| protected int localPort | |
| methodC | back to summary |
|---|---|
| private final DataChunk methodC | |
| notesHolder | back to summary |
|---|---|
| private final transient AttributeHolder notesHolder Internal notes associated with this request by Catalina components and event listeners. | |
| parsedMethod | back to summary |
|---|---|
| protected Method parsedMethod | |
| queryC | back to summary |
|---|---|
| private final DataChunk queryC | |
| READ_ONLY_ATTR_PREFIX | back to summary |
|---|---|
| public static final String READ_ONLY_ATTR_PREFIX Prefix for all service/read-only attributes, that once added could not be removed. The attributes with this prefix
will not be listed in the | |
| remoteAddressC | back to summary |
|---|---|
| protected final DataChunk remoteAddressC | |
| remoteHostC | back to summary |
|---|---|
| protected final DataChunk remoteHostC | |
| remotePort | back to summary |
|---|---|
| protected int remotePort | |
| remoteUserC | back to summary |
|---|---|
| private final DataChunk remoteUserC | |
| requestURIRef | back to summary |
|---|---|
| private final RequestURIRef requestURIRef | |
| requiresAcknowledgement | back to summary |
|---|---|
| private boolean requiresAcknowledgement | |
| response | back to summary |
|---|---|
| private HttpResponsePacket response | |
| serverNameC | back to summary |
|---|---|
| private final DataChunk serverNameC | |
| serverPort | back to summary |
|---|---|
| private int serverPort | |
| unparsedHostC | back to summary |
|---|---|
| protected DataChunk unparsedHostC | |
| HttpRequestPacket | back to summary |
|---|---|
| protected HttpRequestPacket() | |
| authType | back to summary |
|---|---|
public DataChunk authType()
| |
| builder | back to summary |
|---|---|
| public static HttpRequestPacket. Returns
| |
| createNote | back to summary |
|---|---|
| public static <E> Note Create a named | |
| doParseHostHeader | back to summary |
|---|---|
| protected void doParseHostHeader() | |
| getAttribute | back to summary |
|---|---|
| public Object getAttribute(final String name) | |
| getAttributeNames | back to summary |
|---|---|
| public Set | |
| getConnection | back to summary |
|---|---|
public Connection
| |
| getLocalAddress | back to summary |
|---|---|
public String getLocalAddress()
| |
| getLocalHost | back to summary |
|---|---|
public String getLocalHost()
| |
| getLocalName | back to summary |
|---|---|
public String getLocalName()
| |
| getLocalPort | back to summary |
|---|---|
public int getLocalPort()
| |
| getMethod | back to summary |
|---|---|
| public Method getMethod() Get the HTTP request method.
| |
| getMethodDC | back to summary |
|---|---|
| public DataChunk getMethodDC() Get the HTTP request method as | |
| getNote | back to summary |
|---|---|
| public <E> E getNote(final Note<E> note) Return the | |
| getNoteNames | back to summary |
|---|---|
| public Set Return a | |
| getProtocolRequestId | back to summary |
|---|---|
public String getProtocolRequestId()
| |
| getQueryString | back to summary |
|---|---|
| public String getQueryString() Returns the query string that is contained in the request URL after the path. This method returns null if the URL does not have a query string.
| |
| getQueryStringDC | back to summary |
|---|---|
| public DataChunk getQueryStringDC() Returns the query string that is contained in the request URL after the path. This method returns null if the URL
does not have a query string. The result is represented as | |
| getRemoteAddress | back to summary |
|---|---|
public String getRemoteAddress()
| |
| getRemoteHost | back to summary |
|---|---|
public String getRemoteHost()
| |
| getRemotePort | back to summary |
|---|---|
public int getRemotePort()
| |
| getRequestURI | back to summary |
|---|---|
| public String getRequestURI() Returns the request URL.
| |
| getRequestURIRef | back to summary |
|---|---|
| public RequestURIRef getRequestURIRef() Returns the request URL of the HTTP request as
| |
| getResponse | back to summary |
|---|---|
| public HttpResponsePacket getResponse() | |
| getServerPort | back to summary |
|---|---|
public int getServerPort()
| |
| isHeadRequest | back to summary |
|---|---|
| public boolean isHeadRequest() Returns
| |
| isRequest | back to summary |
|---|---|
| public final boolean isRequest() Implements abstract org. Doc from org. Returns true, if the current HttpHeader represent HTTP request message, or false otherwise.
| |
| localAddr | back to summary |
|---|---|
| public DataChunk localAddr() | |
| localName | back to summary |
|---|---|
| public DataChunk localName() | |
| parseHostHeader | back to summary |
|---|---|
| private void parseHostHeader() | |
| remoteAddr | back to summary |
|---|---|
| public DataChunk remoteAddr() | |
| remoteHost | back to summary |
|---|---|
| public DataChunk remoteHost() | |
| remoteUser | back to summary |
|---|---|
public DataChunk remoteUser()
| |
| removeAttribute | back to summary |
|---|---|
| public void removeAttribute(final String name) Remove the specified request attribute if it exists.
| |
| removeNote | back to summary |
|---|---|
| public <E> E removeNote(final Note<E> note) Remove the | |
| requiresAcknowledgement | back to summary |
|---|---|
| protected void requiresAcknowledgement(boolean requiresAcknowledgement) Allows consumers of this request to be notified if the user-agent requires acknowledgment of an expectation (i.e., the Expect header).
| |
| requiresAcknowledgement | back to summary |
|---|---|
public boolean requiresAcknowledgement()
| |
| reset | back to summary |
|---|---|
| protected void reset() Overrides org. Doc from org. Reset the internal state.
| |
| serverName | back to summary |
|---|---|
| public DataChunk serverName() Return the buffer holding the server name, if any. Use isNull() to check if there is no value set. This is the "virtual host", derived from the Host: header.
| |
| serverNameRaw | back to summary |
|---|---|
| protected DataChunk serverNameRaw() Return the buffer holding the server name, if any. Use isNull() to check if there is no value set. This is the "virtual host", derived from the Host: header.
| |
| setAttribute | back to summary |
|---|---|
| public void setAttribute(final String name, final Object value) Set the specified request attribute to the specified value. | |
| setConnection | back to summary |
|---|---|
| public void setConnection(Connection<L> connection) Sets the underlying connection used by the request. | |
| setLocalHost | back to summary |
|---|---|
| public void setLocalHost(String host) Set the host name of the server servicing this request.
| |
| setLocalPort | back to summary |
|---|---|
| public void setLocalPort(int port) Sets the Internet Protocol (IP) port number of the interface on which the request was received.
| |
| setMethod | back to summary |
|---|---|
| public void setMethod(final String method) Set the HTTP request method.
| |
| setMethod | back to summary |
|---|---|
| public void setMethod(final Method method) Set the HTTP request method.
| |
| setNote | back to summary |
|---|---|
| public <E> void setNote(final Note<E> note, final E value) Bind the | |
| setQueryString | back to summary |
|---|---|
| public void setQueryString(String query) Set the
| |
| setRemotePort | back to summary |
|---|---|
| public void setRemotePort(int port) Sets the Internet Protocol (IP) source port of the client or last proxy that sent the request.
| |
| setRequestURI | back to summary |
|---|---|
| public void setRequestURI(String requestURI) Set the request URL.
| |
| setResponse | back to summary |
|---|---|
| protected void setResponse(HttpResponsePacket response) | |
| setServerPort | back to summary |
|---|---|
| public void setServerPort(int serverPort) Sets the Internet Protocol (IP) port specified in the
| |
| toString | back to summary |
|---|---|
| public String toString() Overrides java. Doc from java. Returns a string representation of the object.
Satisfying this method's contract implies a non-
| |
| Modifier and Type | Field and Description |
|---|---|
| protected String | |
| protected Method | |
| protected String | |
| protected String | |
| protected String |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public final HttpRequestPacket | Returns: HttpRequestPacketOverrides org. Build the HttpRequestPacket message. |
| protected HttpHeader | |
| public HttpRequestPacket. | |
| public HttpRequestPacket. | |
| public HttpRequestPacket. | |
| public HttpRequestPacket. | |
| public void | |
| public HttpRequestPacket. |
| host | back to summary |
|---|---|
| protected String host | |
| method | back to summary |
|---|---|
| protected Method method | |
| methodString | back to summary |
|---|---|
| protected String methodString | |
| queryString | back to summary |
|---|---|
| protected String queryString | |
| uri | back to summary |
|---|---|
| protected String uri | |
| Builder | back to summary |
|---|---|
| public Builder() | |
| build | back to summary |
|---|---|
| public final HttpRequestPacket build() Overrides org. Build the HttpRequestPacket message.
| |
| create | back to summary |
|---|---|
| protected HttpHeader create() Implements abstract org.
| |
| host | back to summary |
|---|---|
| public HttpRequestPacket. Set the value for the Host header.
| |
| method | back to summary |
|---|---|
| public HttpRequestPacket. Set the HTTP request method.
| |
| method | back to summary |
|---|---|
| public HttpRequestPacket. Set the HTTP request method.
| |
| query | back to summary |
|---|---|
| public HttpRequestPacket. Set the
| |
| reset | back to summary |
|---|---|
| public void reset() Overrides org.
| |
| uri | back to summary |
|---|---|
| public HttpRequestPacket. Set the request URI.
| |