public final class RequestContext extends UpgradeRequest
| Modifier and Type | Class and Description |
|---|---|
static class |
RequestContext.Builder
RequestContext builder. |
AUTHORIZATION, CLUSTER_CONNECTION_ID_HEADER, CONNECTION, ENABLE_TRACING_HEADER, HOST, ORIGIN_HEADER, RESPONSE_CODE_MESSAGE, SEC_WS_ORIGIN_HEADER, SERVER_KEY_HASH, TRACING_THRESHOLD, UPGRADE, WEBSOCKET| Modifier and Type | Method and Description |
|---|---|
String |
getHeader(String name)
Returns the header value corresponding to the name.
|
Map<String,List<String>> |
getHeaders()
Get headers.
|
Object |
getHttpSession() |
Map<String,List<String>> |
getParameterMap() |
String |
getQueryString() |
String |
getRemoteAddr()
Get the Internet Protocol (IP) address of the client or last proxy that sent the request.
|
String |
getRequestUri()
Get the undecoded request uri (up to the query string) of underlying
HTTP handshake request.
|
URI |
getRequestURI() |
Principal |
getUserPrincipal() |
boolean |
isSecure()
Indicates whether this request was made using a secure channel
(such as HTTPS).
|
boolean |
isUserInRole(String role) |
void |
lock()
Make headers and parameter map read-only.
|
public Map<String,List<String>> getHeaders()
public String getHeader(String name)
getHeader in class UpgradeRequestname - header name.List of header values iff found, null otherwise.public void lock()
public Principal getUserPrincipal()
public URI getRequestURI()
public boolean isUserInRole(String role)
public Object getHttpSession()
public String getQueryString()
public String getRequestUri()
UpgradeRequestgetRequestUri in class UpgradeRequestpublic boolean isSecure()
UpgradeRequestisSecure in class UpgradeRequestCopyright © 2012–2019 Oracle Corporation. All rights reserved.