i2p.susi.webmail
Class RequestWrapper

java.lang.Object
  extended by i2p.susi.webmail.RequestWrapper

public class RequestWrapper
extends Object

Required major changes for Jetty 6 to support change from MultiPartRequest to MultiPartFilter. See http://docs.codehaus.org/display/JETTY/File+Upload+in+jetty6 Unfortunately, Content-type not available until Jetty 8 See https://bugs.eclipse.org/bugs/show_bug.cgi?id=349110 So we could either extend and fix MultiPartFilter, and rewrite everything here, or copy MultiParRequest into our war and fix it so it compiles with Jetty 6. We do the latter. The filter would have been added in web.xml, see that file, where it's commented out.

Author:
user

Constructor Summary
RequestWrapper(HttpServletRequest httpRequest)
           
 
Method Summary
 Object getAttribute(String string)
           
 int getContentLength()
           
 String getContentType()
           
 String getContentType(String partName)
           
 String getFilename(String partName)
           
 InputStream getInputStream(String partName)
           
 String getParameter(String name)
           
 String getParameter(String name, String defaultValue)
           
 Enumeration getParameterNames()
           
 HttpSession getSession()
           
 HttpSession getSession(boolean b)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RequestWrapper

public RequestWrapper(HttpServletRequest httpRequest)
Parameters:
httpRequest -
Method Detail

getSession

public HttpSession getSession(boolean b)
Parameters:
b -

getParameter

public String getParameter(String name)
Parameters:
name - Specific parameter key
Returns:
parameter value

getSession

public HttpSession getSession()

getParameterNames

public Enumeration getParameterNames()
Returns:
List of request parameter names

getContentLength

public int getContentLength()
Returns:
The total length of the content.

getContentType

public String getContentType()
Returns:
The content type of the request.

getContentType

public String getContentType(String partName)

getAttribute

public Object getAttribute(String string)

getParameter

public String getParameter(String name,
                           String defaultValue)

getFilename

public String getFilename(String partName)

getInputStream

public InputStream getInputStream(String partName)