public class NettyHttpRequest extends HttpRequest
RestRequest.Methodheaders| Constructor and Description |
|---|
NettyHttpRequest(org.jboss.netty.handler.codec.http.HttpRequest request,
org.jboss.netty.channel.Channel channel) |
| Modifier and Type | Method and Description |
|---|---|
BytesReference |
content() |
org.jboss.netty.channel.Channel |
getChannel() |
SocketAddress |
getLocalAddress()
Returns the local address where this request channel is bound to.
|
SocketAddress |
getRemoteAddress()
Returns the remote address where this rest request channel is "connected to".
|
boolean |
hasContent() |
boolean |
hasParam(String key) |
String |
header(String name) |
Iterable<Map.Entry<String,String>> |
headers() |
RestRequest.Method |
method() |
String |
param(String key) |
String |
param(String key,
String defaultValue) |
Map<String,String> |
params() |
String |
rawPath()
The non decoded, raw path provided.
|
org.jboss.netty.handler.codec.http.HttpRequest |
request() |
String |
uri()
The uri of the rest request, with the query string.
|
paramAsBoolean, paramAsBoolean, paramAsFloat, paramAsInt, paramAsLong, paramAsSize, paramAsStringArray, paramAsStringArrayOrEmptyIfAll, paramAsTime, pathcontextSize, copyContextAndHeadersFrom, copyContextFrom, copyHeadersFrom, getContext, getFromContext, getFromContext, getHeader, getHeaders, hasHeader, hasInContext, isContextEmpty, putAllInContext, putHeader, putInContextpublic NettyHttpRequest(org.jboss.netty.handler.codec.http.HttpRequest request,
org.jboss.netty.channel.Channel channel)
public org.jboss.netty.handler.codec.http.HttpRequest request()
public RestRequest.Method method()
method in class RestRequestpublic String uri()
RestRequesturi in class RestRequestpublic String rawPath()
RestRequestrawPath in class RestRequestpublic Map<String,String> params()
params in class RestRequestpublic boolean hasContent()
hasContent in class RestRequestpublic BytesReference content()
content in class RestRequestpublic SocketAddress getRemoteAddress()
SocketAddress is supposed to be down-cast into more
concrete type such as InetSocketAddress to retrieve
the detailed information.getRemoteAddress in class RestRequestpublic SocketAddress getLocalAddress()
SocketAddress is supposed to be down-cast into more concrete
type such as InetSocketAddress to retrieve the detailed
information.getLocalAddress in class RestRequestpublic org.jboss.netty.channel.Channel getChannel()
public String header(String name)
header in class RestRequestpublic Iterable<Map.Entry<String,String>> headers()
headers in class RestRequestpublic boolean hasParam(String key)
hasParam in class RestRequestpublic String param(String key)
param in interface ToXContent.Paramsparam in class RestRequestCopyright © 2009–2016. All rights reserved.