com.atlassian.confluence.setup.webwork
Class JakartaMultiPartRequest
java.lang.Object
com.opensymphony.webwork.dispatcher.multipart.MultiPartRequest
com.atlassian.confluence.setup.webwork.JakartaMultiPartRequest
public class JakartaMultiPartRequest
- extends com.opensymphony.webwork.dispatcher.multipart.MultiPartRequest
Multipart form data request adapter for Jakarta's file upload package.
This class has been imported from Webwork 2.1.5 and been modified to:
- support the latest Jakarta Commons Fileupload API
- mimmick the way the Pell multipart library reports excess upload size, an IO exception is thrown to be collected
by the
MultiPartRequestWrapper. The format of the message is
unfortunately relied upon by our error reporting mechanisms and needs to be preserved between the implementations.
- Author:
- Bruce Ritchie
- See Also:
GeneralUtil.getUploadFileTooLargeMessage(String)
| Fields inherited from class com.opensymphony.webwork.dispatcher.multipart.MultiPartRequest |
log |
|
Constructor Summary |
JakartaMultiPartRequest(javax.servlet.http.HttpServletRequest servletRequest,
String saveDir,
int maxSize)
Creates a new request wrapper to handle multi-part data using methods adapted from Jason Pell's
multipart classes (see class description). |
| Methods inherited from class com.opensymphony.webwork.dispatcher.multipart.MultiPartRequest |
isMultiPart |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
JakartaMultiPartRequest
public JakartaMultiPartRequest(javax.servlet.http.HttpServletRequest servletRequest,
String saveDir,
int maxSize)
throws IOException
- Creates a new request wrapper to handle multi-part data using methods adapted from Jason Pell's
multipart classes (see class description).
- Parameters:
maxSize - maximum size post allowedsaveDir - the directory to save off the fileservletRequest - the request containing the multipart
- Throws:
IOException - is thrown if encoding fails.
getFileParameterNames
public Enumeration getFileParameterNames()
- Specified by:
getFileParameterNames in class com.opensymphony.webwork.dispatcher.multipart.MultiPartRequest
getContentType
public String[] getContentType(String fieldName)
- Specified by:
getContentType in class com.opensymphony.webwork.dispatcher.multipart.MultiPartRequest
getFile
public File[] getFile(String fieldName)
- Specified by:
getFile in class com.opensymphony.webwork.dispatcher.multipart.MultiPartRequest
getFileNames
public String[] getFileNames(String fieldName)
- Specified by:
getFileNames in class com.opensymphony.webwork.dispatcher.multipart.MultiPartRequest
getFilesystemName
public String[] getFilesystemName(String fieldName)
- Specified by:
getFilesystemName in class com.opensymphony.webwork.dispatcher.multipart.MultiPartRequest
getParameter
public String getParameter(String name)
- Specified by:
getParameter in class com.opensymphony.webwork.dispatcher.multipart.MultiPartRequest
getParameterNames
public Enumeration getParameterNames()
- Specified by:
getParameterNames in class com.opensymphony.webwork.dispatcher.multipart.MultiPartRequest
getParameterValues
public String[] getParameterValues(String name)
- Specified by:
getParameterValues in class com.opensymphony.webwork.dispatcher.multipart.MultiPartRequest
getErrors
public List getErrors()
Copyright © 2003-2011 Atlassian. All Rights Reserved.