org.hdiv.config.multipart
Class Struts2MultipartConfig
java.lang.Object
org.hdiv.config.multipart.AbstractMultipartConfig
org.hdiv.config.multipart.Struts2MultipartConfig
- All Implemented Interfaces:
- IMultipartConfig
public class Struts2MultipartConfig
- extends AbstractMultipartConfig
Class containing multipart request configuration and methods initialized from
Spring Factory.
- Author:
- Gorka Vicente
|
Method Summary |
void |
addTextParameter(RequestWrapper request,
org.apache.commons.fileupload.FileItem item)
Adds a regular text parameter to the set of text parameters for this request. |
void |
handleMultipartRequest(RequestWrapper request,
javax.servlet.ServletContext servletContext)
Parses the input stream and partitions the parsed items into a set of form
fields and a set of file items. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Struts2MultipartConfig
public Struts2MultipartConfig()
handleMultipartRequest
public void handleMultipartRequest(RequestWrapper request,
javax.servlet.ServletContext servletContext)
throws org.apache.commons.fileupload.FileUploadException,
org.apache.commons.fileupload.FileUploadBase.SizeLimitExceededException,
org.springframework.web.multipart.MaxUploadSizeExceededException
- Parses the input stream and partitions the parsed items into a set of form
fields and a set of file items.
- Parameters:
request - The multipart request wrapper.servletContext - Our ServletContext object
- Throws:
org.apache.commons.fileupload.FileUploadException - if an unrecoverable error occurs.
DiskFileUpload.SizeLimitExceededException - if size limit exceeded
org.apache.commons.fileupload.FileUploadBase.SizeLimitExceededException
org.springframework.web.multipart.MaxUploadSizeExceededException
addTextParameter
public void addTextParameter(RequestWrapper request,
org.apache.commons.fileupload.FileItem item)
- Adds a regular text parameter to the set of text parameters for this request.
Handles the case of multiple values for the same parameter by using an array
for the parameter value.
- Parameters:
request - The request in which the parameter was specified.item - The file item for the parameter to add.
Copyright © 2008 hdiv.org. All Rights Reserved.