public class RequestPartServletServerHttpRequest extends ServletServerHttpRequest
ServerHttpRequest implementation that accesses one part of a multipart
request. If using MultipartResolver configuration the part is accessed
through a MultipartFile. Or if using Servlet 3.0 multipart processing
the part is accessed through ServletRequest.getPart.FORM_CHARSET, FORM_CONTENT_TYPE| Constructor and Description |
|---|
RequestPartServletServerHttpRequest(HttpServletRequest request,
String requestPartName)
Create a new
RequestPartServletServerHttpRequest instance. |
| Modifier and Type | Method and Description |
|---|---|
InputStream |
getBody()
Return the body of the message as an input stream.
|
HttpHeaders |
getHeaders()
Return the headers of this message.
|
getAsyncRequestControl, getLocalAddress, getMethod, getMethodValue, getPrincipal, getRemoteAddress, getServletRequest, getURIpublic RequestPartServletServerHttpRequest(HttpServletRequest request, String requestPartName) throws MissingServletRequestPartException
RequestPartServletServerHttpRequest instance.request - the current servlet requestrequestPartName - the name of the part to adapt to the ServerHttpRequest contractMissingServletRequestPartException - if the request part cannot be foundMultipartException - if MultipartHttpServletRequest cannot be initializedpublic HttpHeaders getHeaders()
HttpMessagegetHeaders in interface HttpMessagegetHeaders in class ServletServerHttpRequestnull)public InputStream getBody() throws IOException
HttpInputMessagegetBody in interface HttpInputMessagegetBody in class ServletServerHttpRequestnull)IOException - in case of I/O errors