public class DefaultHttpRequest extends DefaultHttpMessage implements HttpRequest
HttpRequest
implementation.Constructor and Description |
---|
DefaultHttpRequest(HttpVersion httpVersion,
HttpMethod method,
String uri)
Creates a new instance.
|
DefaultHttpRequest(HttpVersion httpVersion,
HttpMethod method,
String uri,
boolean validateHeaders)
Creates a new instance.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object o) |
int |
hashCode() |
HttpMethod |
method()
Returns the
HttpMethod of this HttpRequest . |
HttpRequest |
setMethod(HttpMethod method)
Set the
HttpMethod of this HttpRequest . |
HttpRequest |
setProtocolVersion(HttpVersion version)
Set the protocol version of this
HttpMessage |
HttpRequest |
setUri(String uri)
Set the requested URI (or alternatively, path)
|
String |
toString() |
String |
uri()
Returns the requested URI (or alternatively, path)
|
headers, protocolVersion
decoderResult, setDecoderResult
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
headers, protocolVersion
decoderResult, setDecoderResult
public DefaultHttpRequest(HttpVersion httpVersion, HttpMethod method, String uri)
httpVersion
- the HTTP version of the requestmethod
- the HTTP getMethod of the requesturi
- the URI or path of the requestpublic DefaultHttpRequest(HttpVersion httpVersion, HttpMethod method, String uri, boolean validateHeaders)
httpVersion
- the HTTP version of the requestmethod
- the HTTP getMethod of the requesturi
- the URI or path of the requestvalidateHeaders
- validate the header names and values when adding them to the HttpHeaders
public HttpMethod method()
HttpRequest
HttpMethod
of this HttpRequest
.method
in interface HttpRequest
HttpMethod
of this HttpRequest
public String uri()
HttpRequest
uri
in interface HttpRequest
public HttpRequest setMethod(HttpMethod method)
HttpRequest
HttpMethod
of this HttpRequest
.setMethod
in interface HttpRequest
public HttpRequest setUri(String uri)
HttpRequest
setUri
in interface HttpRequest
public HttpRequest setProtocolVersion(HttpVersion version)
HttpMessage
HttpMessage
setProtocolVersion
in interface HttpMessage
setProtocolVersion
in interface HttpRequest
setProtocolVersion
in class DefaultHttpMessage
public int hashCode()
hashCode
in class DefaultHttpMessage
public boolean equals(Object o)
equals
in class DefaultHttpMessage
Copyright © 2008–2015 The Netty Project. All rights reserved.