org.apache.catalina.core
Class ApplicationPart
java.lang.Object
org.apache.catalina.core.ApplicationPart
- All Implemented Interfaces:
- Part
public class ApplicationPart
- extends Object
- implements Part
Adaptor to allow FileItem
objects generated by the package renamed
commons-upload to be used by the Servlet 3.0 upload API that expects
Part
s.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ApplicationPart
public ApplicationPart(FileItem fileItem,
MultipartConfigElement mce)
delete
public void delete()
throws IOException
- Specified by:
delete
in interface Part
- Throws:
IOException
getContentType
public String getContentType()
- Specified by:
getContentType
in interface Part
getHeader
public String getHeader(String name)
- Description copied from interface:
javax.servlet.http.Part
- Obtains the value of the specified mime header for the part.
- Specified by:
getHeader
in interface Part
- Parameters:
name
- Header name
- Returns:
- The header value or
null
if the header is not
present
getHeaderNames
public Collection<String> getHeaderNames()
- Specified by:
getHeaderNames
in interface Part
getHeaders
public Collection<String> getHeaders(String name)
- Specified by:
getHeaders
in interface Part
getInputStream
public InputStream getInputStream()
throws IOException
- Specified by:
getInputStream
in interface Part
- Throws:
IOException
getName
public String getName()
- Specified by:
getName
in interface Part
getSize
public long getSize()
- Specified by:
getSize
in interface Part
write
public void write(String fileName)
throws IOException
- Specified by:
write
in interface Part
- Throws:
IOException
getString
public String getString(String encoding)
throws UnsupportedEncodingException
- Throws:
UnsupportedEncodingException
getFilename
public String getFilename()
Copyright © 2000-2012 Apache Software Foundation. All Rights Reserved.