|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.apache.tapestry.multipart.UploadPart
Portion of a multi-part request representing an uploaded file.
Constructor Summary | |
UploadPart(org.apache.commons.fileupload.FileItem fileItem)
|
Method Summary | |
void |
cleanup()
Deletes the external content file, if one exists. |
String |
getContentType()
Returns the MIME type specified when the file was uploaded. |
String |
getFileName()
Leverages File to convert the full file path and extract
the name. |
String |
getFilePath()
Returns the complete path, as reported by the client browser. |
InputStream |
getStream()
Returns an input stream of the content of the file. |
static UploadPart |
newInstance(String path,
String name,
String contentType,
int requestSize,
int threshold)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public UploadPart(org.apache.commons.fileupload.FileItem fileItem)
Method Detail |
public static UploadPart newInstance(String path, String name, String contentType, int requestSize, int threshold)
public String getContentType()
IUploadFile
getContentType
in interface IUploadFile
public String getFileName()
File
to convert the full file path and extract
the name.
getFileName
in interface IUploadFile
public String getFilePath()
IUploadFile
getFilePath
in interface IUploadFile
public InputStream getStream()
IUploadFile
As of release 1.0.8, this will be a a ByteArrayInputStream
,
but that, too, may change (a future implementation may upload the stream
to a temporary file and return an input stream from that).
getStream
in interface IUploadFile
public void cleanup()
cleanup
in interface IPart
cleanup()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |