|
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.nitido.nimbox.http.UploadedFile
public class UploadedFile
This class provides an abstract representation of a file that was uploaded by through the MultipartRequestParser implementation.
| Constructor Summary | |
|---|---|
UploadedFile(java.lang.String dir,
java.lang.String fileName,
java.lang.String originalName,
java.lang.String contentType,
long size)
Class constructor |
|
| Method Summary | |
|---|---|
void |
clean()
This method is used to remove the uploaded file from the disk. |
java.io.File |
getFile()
This method returns a File pointer of the uploaded file. |
java.lang.String |
getFileName()
This method returns the name of the uploaded file. |
java.io.InputStream |
getInputStream()
This method returns a reference to InputStream for the uploaded file. |
java.lang.String |
getMimeType()
This method returns the mime type of the uploaded file. |
java.lang.String |
getOriginalFileName()
This method returns the original name of the uploaded file. |
long |
getSize()
This method returns the size of the uploaded file. |
java.lang.String |
toString()
Override java.lang.Object's toString(). |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public UploadedFile(java.lang.String dir,
java.lang.String fileName,
java.lang.String originalName,
java.lang.String contentType,
long size)
dir - The directory where the file is stored.fileName - The name of the files as stored in the given directory.originalName - The original name of the file.contentType - The mime type of the uploaded file.size - The size of the uploaded file.| Method Detail |
|---|
public java.lang.String getFileName()
public java.lang.String getOriginalFileName()
public java.lang.String getMimeType()
public long getSize()
public java.io.File getFile()
public java.io.InputStream getInputStream()
throws java.io.FileNotFoundException
java.io.FileNotFoundException - If the uploaded file no longer exists.
public void clean()
throws java.lang.SecurityException
java.lang.SecurityException - If a security manager exists and its
SecurityManager.checkDelete(java.lang.String) method denies
delete access to the filepublic java.lang.String toString()
toString in class java.lang.Object
|
Nitido NiM 2.5 Java API | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
Copyright © 1999-2009 Nitido Inc. Proprietary and Confidential. All Rights Reserved.