public class HttpRequestImpl extends Object
| 限定符和类型 | 方法和说明 |
|---|---|
org.smartboot.socket.util.Attachment |
getAttachment()
获取附件对象
|
String |
getCharacterEncoding() |
int |
getContentLength() |
String |
getContentType() |
Cookie[] |
getCookies()
获取Cookie
|
String |
getHeader(String headName)
获取指定名称的Http Header值
|
Collection<String> |
getHeaderNames() |
Collection<String> |
getHeaders(String name) |
InputStream |
getInputStream() |
InetSocketAddress |
getLocalAddress() |
Locale |
getLocale() |
Enumeration<Locale> |
getLocales() |
String |
getMethod()
Returns the name of the HTTP method with which this
request was made, for example, GET, POST, or PUT.
|
String |
getParameter(String name) |
Map<String,String[]> |
getParameters() |
String[] |
getParameterValues(String name) |
String |
getProtocol() |
String |
getQueryString() |
String |
getRemoteAddr()
Returns the Internet Protocol (IP) address of the client
or last proxy that sent the request.
|
InetSocketAddress |
getRemoteAddress() |
String |
getRemoteHost()
Returns the fully qualified name of the client
or the last proxy that sent the request.
|
Request |
getRequest() |
String |
getRequestURI() |
String |
getRequestURL() |
org.smartboot.http.server.impl.HttpResponseImpl |
getResponse() |
String |
getScheme() |
boolean |
isKeepAlive() |
boolean |
isSecure()
是否启动安全通信
|
void |
reset() |
void |
setAttachment(org.smartboot.socket.util.Attachment attachment)
存放附件,支持任意类型
|
void |
setKeepAlive(boolean keepAlive) |
public final org.smartboot.http.server.impl.HttpResponseImpl getResponse()
public boolean isKeepAlive()
public void setKeepAlive(boolean keepAlive)
public InputStream getInputStream() throws IOException
IOExceptionpublic void reset()
public final String getHeader(String headName)
HttpRequestgetHeader 在接口中 HttpRequestpublic final Collection<String> getHeaders(String name)
getHeaders 在接口中 HttpRequestpublic final Collection<String> getHeaderNames()
getHeaderNames 在接口中 HttpRequestpublic final String getRequestURI()
getRequestURI 在接口中 HttpRequestpublic final String getProtocol()
getProtocol 在接口中 HttpRequestpublic final String getMethod()
HttpRequestgetMethod 在接口中 HttpRequestString
specifying the name
of the method with which
this request was madepublic final String getScheme()
getScheme 在接口中 HttpRequestpublic final String getRequestURL()
getRequestURL 在接口中 HttpRequestpublic final String getQueryString()
getQueryString 在接口中 HttpRequestpublic final String getContentType()
getContentType 在接口中 HttpRequestpublic final int getContentLength()
getContentLength 在接口中 HttpRequestpublic final String getParameter(String name)
getParameter 在接口中 HttpRequestpublic final Map<String,String[]> getParameters()
getParameters 在接口中 HttpRequestpublic final String[] getParameterValues(String name)
getParameterValues 在接口中 HttpRequestpublic final String getRemoteAddr()
HttpRequestREMOTE_ADDR.getRemoteAddr 在接口中 HttpRequestString containing the
IP address of the client that sent the requestpublic final InetSocketAddress getRemoteAddress()
getRemoteAddress 在接口中 HttpRequestpublic final InetSocketAddress getLocalAddress()
getLocalAddress 在接口中 HttpRequestpublic final String getRemoteHost()
HttpRequestREMOTE_HOST.getRemoteHost 在接口中 HttpRequestString containing the fully
qualified name of the clientpublic final Locale getLocale()
getLocale 在接口中 HttpRequestpublic final Enumeration<Locale> getLocales()
getLocales 在接口中 HttpRequestpublic final String getCharacterEncoding()
getCharacterEncoding 在接口中 HttpRequestpublic final Request getRequest()
public Cookie[] getCookies()
HttpRequestgetCookies 在接口中 HttpRequestpublic org.smartboot.socket.util.Attachment getAttachment()
HttpRequestgetAttachment 在接口中 HttpRequestpublic void setAttachment(org.smartboot.socket.util.Attachment attachment)
HttpRequestsetAttachment 在接口中 HttpRequestattachment - 附件对象public final boolean isSecure()
HttpRequestisSecure 在接口中 HttpRequestCopyright © 2024. All rights reserved.