|
Return to www.inductionframework.org | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.acciente.commons.htmlform.FileHandle
public class FileHandle
This class is a facade to isolate the fileupload implementation from the multi-part parser used.
Constructor Summary | |
---|---|
FileHandle(org.apache.commons.fileupload.FileItem oFileItem)
|
Method Summary | |
---|---|
java.lang.String |
getContentType()
Returns the content type set by the browser that uploded the file, if not content type was set null |
java.io.InputStream |
getInputStream()
Returns an input stream that may used to read the contents of the uploaded file |
java.lang.String |
getOriginFilename()
Returns the original name of the uploaded file on the system from which it originated |
long |
getSize()
Returns the size of the file in bytes |
void |
write(java.io.File oToFile)
Write out the contents of the uploaded file to the specified destination |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public FileHandle(org.apache.commons.fileupload.FileItem oFileItem)
Method Detail |
---|
public java.lang.String getContentType()
null is returned
- Returns:
- the mime type of the content
public long getSize()
public java.lang.String getOriginFilename()
public void write(java.io.File oToFile) throws java.lang.Exception
oToFile
- the file to write to
java.lang.Exception
- if an error occurspublic java.io.InputStream getInputStream() throws java.io.IOException
java.io.IOException
- if an error occurs
|
Return to www.inductionframework.org | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |