- All Known Implementing Classes:
DefaultHttpServerRequest
,GrizzlyHttpServerRequest
,JdkHttpRequest
,NettyHttpServerRequest
,UndertowHttpRequest
public interface HttpServerRequest
The HttpServerRequest API.
This API delivers an abstraction over the HTTP request line, the HTTP request headers and the HTTP request body.
- Author:
- Manfred Riem ([email protected])
-
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.default String
Returns the protocol.Returns the remote address.Returns the remote hostname.int
Returns the remote port.Returns the request target.boolean
isSecure()
Returns if we are secure.
-
Method Details
-
getHeader
Get the header.- Parameters:
name
- the name of the header.- Returns:
- the value, or null.
-
getHeaders
Get the headers.- Parameters:
name
- the name of the header.- Returns:
- the potentially empty collection.
-
getHeaderNames
Returns the header names.- Returns:
- the header names
-
getInputStream
InputStream getInputStream()Returns the input stream.- Returns:
- the input stream
-
getLocalAddress
String getLocalAddress()Returns the local address.- Returns:
- the local address
-
getLocalHostname
String getLocalHostname()Returns the local hostname.- Returns:
- the local hostname
-
getLocalPort
int getLocalPort()Returns the local port.- Returns:
- the local port
-
getMethod
String getMethod()Returns the method.- Returns:
- the method
-
getRemoteAddress
String getRemoteAddress()Returns the remote address.- Returns:
- the remote address
-
getRemoteHostname
String getRemoteHostname()Returns the remote hostname.- Returns:
- the remote hostname
-
getRemotePort
int getRemotePort()Returns the remote port.- Returns:
- the remote port
-
getRequestTarget
String getRequestTarget()Returns the request target.- Returns:
- the request target
-
getProtocol
Returns the protocol.- Returns:
- the protocol
-
isSecure
boolean isSecure()Returns if we are secure.- Returns:
- if we are secure
-