java.lang.Object
cloud.piranha.http.netty.NettyHttpServerRequest
- All Implemented Interfaces:
HttpServerRequest
The Netty implementation of HTTP Server Request.
- Author:
- Manfred Riem ([email protected])
-
Constructor Summary
ConstructorDescriptionNettyHttpServerRequest(io.netty.channel.ChannelHandlerContext context, io.netty.handler.codec.http.FullHttpRequest request)
Constructor. -
Method Summary
Modifier and TypeMethodDescriptionGet the header.Returns the header names.getHeaders(String name)
Get the headers.Returns the input stream.Returns the local address.Returns the local hostname.int
Returns the local port.Returns the method.Returns the protocol.getQueryParameter(String name)
Get the query parameter.Returns the query string.Returns the remote address.Returns the remote hostname.int
Returns the remote port.Returns the request target.
-
Constructor Details
-
NettyHttpServerRequest
public NettyHttpServerRequest(io.netty.channel.ChannelHandlerContext context, io.netty.handler.codec.http.FullHttpRequest request)Constructor.- Parameters:
request
- the HTTP request.context
- the context.
-
-
Method Details
-
getHeader
Description copied from interface:HttpServerRequest
Get the header.- Specified by:
getHeader
in interfaceHttpServerRequest
- Parameters:
name
- the name of the header.- Returns:
- the value, or null.
-
getHeaderNames
Description copied from interface:HttpServerRequest
Returns the header names.- Specified by:
getHeaderNames
in interfaceHttpServerRequest
- Returns:
- the header names
-
getHeaders
Description copied from interface:HttpServerRequest
Get the headers.- Specified by:
getHeaders
in interfaceHttpServerRequest
- Parameters:
name
- the name of the header.- Returns:
- the potentially empty collection.
-
getInputStream
Description copied from interface:HttpServerRequest
Returns the input stream.- Specified by:
getInputStream
in interfaceHttpServerRequest
- Returns:
- the input stream
-
getLocalAddress
Description copied from interface:HttpServerRequest
Returns the local address.- Specified by:
getLocalAddress
in interfaceHttpServerRequest
- Returns:
- the local address
-
getLocalHostname
Description copied from interface:HttpServerRequest
Returns the local hostname.- Specified by:
getLocalHostname
in interfaceHttpServerRequest
- Returns:
- the local hostname
-
getLocalPort
public int getLocalPort()Description copied from interface:HttpServerRequest
Returns the local port.- Specified by:
getLocalPort
in interfaceHttpServerRequest
- Returns:
- the local port
-
getMethod
Description copied from interface:HttpServerRequest
Returns the method.- Specified by:
getMethod
in interfaceHttpServerRequest
- Returns:
- the method
-
getQueryParameter
Description copied from interface:HttpServerRequest
Get the query parameter.- Specified by:
getQueryParameter
in interfaceHttpServerRequest
- Parameters:
name
- the name.- Returns:
- the value, or null if not found.
-
getQueryString
Description copied from interface:HttpServerRequest
Returns the query string.- Specified by:
getQueryString
in interfaceHttpServerRequest
- Returns:
- the query string
-
getRemoteAddress
Description copied from interface:HttpServerRequest
Returns the remote address.- Specified by:
getRemoteAddress
in interfaceHttpServerRequest
- Returns:
- the remote address
-
getRemoteHostname
Description copied from interface:HttpServerRequest
Returns the remote hostname.- Specified by:
getRemoteHostname
in interfaceHttpServerRequest
- Returns:
- the remote hostname
-
getRemotePort
public int getRemotePort()Description copied from interface:HttpServerRequest
Returns the remote port.- Specified by:
getRemotePort
in interfaceHttpServerRequest
- Returns:
- the remote port
-
getRequestTarget
Description copied from interface:HttpServerRequest
Returns the request target.- Specified by:
getRequestTarget
in interfaceHttpServerRequest
- Returns:
- the request target
-
getProtocol
Description copied from interface:HttpServerRequest
Returns the protocol.- Specified by:
getProtocol
in interfaceHttpServerRequest
- Returns:
- the protocol
-