org.apache.struts2.dispatcher.multipart
Class PellMultiPartRequest

java.lang.Object
  extended by org.apache.struts2.dispatcher.multipart.PellMultiPartRequest
All Implemented Interfaces:
org.apache.struts2.dispatcher.multipart.MultiPartRequest

public class PellMultiPartRequest
extends java.lang.Object
implements org.apache.struts2.dispatcher.multipart.MultiPartRequest

Multipart form data request adapter for Jason Pell's multipart utils package.


Constructor Summary
PellMultiPartRequest()
           
 
Method Summary
 java.lang.String[] getContentType(java.lang.String fieldName)
           
 java.util.List getErrors()
           
 java.io.File[] getFile(java.lang.String fieldName)
           
 java.lang.String[] getFileNames(java.lang.String fieldName)
           
 java.util.Enumeration getFileParameterNames()
           
 java.lang.String[] getFilesystemName(java.lang.String fieldName)
           
 java.lang.String getParameter(java.lang.String name)
           
 java.util.Enumeration getParameterNames()
           
 java.lang.String[] getParameterValues(java.lang.String name)
           
 void parse(javax.servlet.http.HttpServletRequest servletRequest, java.lang.String saveDir)
          Creates a new request wrapper to handle multi-part data using methods adapted from Jason Pell's multipart classes (see class description).
 void setDefaultEncoding(java.lang.String enc)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PellMultiPartRequest

public PellMultiPartRequest()
Method Detail

setDefaultEncoding

public void setDefaultEncoding(java.lang.String enc)

parse

public void parse(javax.servlet.http.HttpServletRequest servletRequest,
                  java.lang.String saveDir)
           throws java.io.IOException
Creates a new request wrapper to handle multi-part data using methods adapted from Jason Pell's multipart classes (see class description).

Specified by:
parse in interface org.apache.struts2.dispatcher.multipart.MultiPartRequest
Parameters:
maxSize - maximum size post allowed
saveDir - the directory to save off the file
servletRequest - the request containing the multipart
Throws:
java.io.IOException

getFileParameterNames

public java.util.Enumeration getFileParameterNames()
Specified by:
getFileParameterNames in interface org.apache.struts2.dispatcher.multipart.MultiPartRequest

getContentType

public java.lang.String[] getContentType(java.lang.String fieldName)
Specified by:
getContentType in interface org.apache.struts2.dispatcher.multipart.MultiPartRequest

getFile

public java.io.File[] getFile(java.lang.String fieldName)
Specified by:
getFile in interface org.apache.struts2.dispatcher.multipart.MultiPartRequest

getFileNames

public java.lang.String[] getFileNames(java.lang.String fieldName)
Specified by:
getFileNames in interface org.apache.struts2.dispatcher.multipart.MultiPartRequest

getFilesystemName

public java.lang.String[] getFilesystemName(java.lang.String fieldName)
Specified by:
getFilesystemName in interface org.apache.struts2.dispatcher.multipart.MultiPartRequest

getParameter

public java.lang.String getParameter(java.lang.String name)
Specified by:
getParameter in interface org.apache.struts2.dispatcher.multipart.MultiPartRequest

getParameterNames

public java.util.Enumeration getParameterNames()
Specified by:
getParameterNames in interface org.apache.struts2.dispatcher.multipart.MultiPartRequest

getParameterValues

public java.lang.String[] getParameterValues(java.lang.String name)
Specified by:
getParameterValues in interface org.apache.struts2.dispatcher.multipart.MultiPartRequest

getErrors

public java.util.List getErrors()
Specified by:
getErrors in interface org.apache.struts2.dispatcher.multipart.MultiPartRequest


Copyright © 2000-2008 Apache Software Foundation. All Rights Reserved.