org.apache.struts.upload
public class DiskMultipartRequestHandler extends Object implements MultipartRequestHandler
Deprecated: Use the Commons FileUpload based multipart handler instead. This class will be removed after Struts 1.2.
This is a MultipartRequestHandler that writes file data directly to to temporary files on disk.Field Summary | |
---|---|
protected Hashtable | allElements
A Hashtable representing all elemnents. |
protected Hashtable | fileElements
A Hashtable representing the form files uploaded. |
protected static Log | log
Commons Logging instance. |
protected ActionMapping | mapping
The ActionMapping instance used for this class. |
protected ActionServlet | servlet
The ActionServlet instance used for this class. |
protected String | tempDir
The temporary directory. |
protected Hashtable | textElements
A Hashtable representing the form text input names and values. |
Method Summary | |
---|---|
protected void | createDiskFile(MultipartElement element) |
protected void | createTextElement(HttpServletRequest request, MultipartElement element) |
void | finish()
Calls on rollback() to delete
temporary files. |
Hashtable | getAllElements() |
Hashtable | getFileElements() |
ActionMapping | getMapping() |
protected long | getMaxSize(String stringSize)
Gets the maximum post data size in bytes from the string
representation in the configuration file. |
ActionServlet | getServlet() |
Hashtable | getTextElements() |
void | handleRequest(HttpServletRequest request)
This method populates the internal hashtables with multipart request data.
|
protected void | retrieveTempDir(ModuleConfig moduleConfig)
Retrieves the temporary directory from either ActionServlet, a context
property, or a system property, in that order. |
void | rollback()
Delete all the files uploaded. |
void | setMapping(ActionMapping mapping) |
void | setServlet(ActionServlet servlet) |
rollback()
to delete
temporary files.