|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--de.opus5.servlet.UploadedFile
Abstract base class for Uploaded files. Descendants must implement getInputStream() and getOutputStream(). You should set the filesize.
Constructor Summary | |
UploadedFile(java.lang.String paraname,
java.lang.String filename)
Create a new UploadedFile |
Method Summary | |
java.lang.String |
getContentType()
Retruns file's contentType |
java.io.File |
getFile()
Classes extending UploadedFile can override this method and return the appropriate file object. |
java.lang.String |
getFormParameterName()
returns the name of the file upload form field. |
abstract java.io.InputStream |
getInputStream()
Returns an InputStream for reading the filedata. |
java.lang.String |
getName()
Returns the file's name. |
abstract java.io.OutputStream |
getOutputStream()
Returns an OutputStream for reading the filedata. |
int |
getSize()
Returns the file's size. |
void |
setContentType(java.lang.String ct)
set file's contentType |
void |
setSize(int size)
set file's size |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Constructor Detail |
public UploadedFile(java.lang.String paraname, java.lang.String filename)
paraname
- the form field namefilename
- the file's namesize
- the file's size in bytesMethod Detail |
public java.lang.String getContentType()
public java.io.File getFile()
public java.lang.String getFormParameterName()
public abstract java.io.InputStream getInputStream() throws java.io.IOException
public java.lang.String getName()
public abstract java.io.OutputStream getOutputStream() throws java.io.IOException
public int getSize()
public void setContentType(java.lang.String ct)
contentType
- public void setSize(int size)
filesize
-
|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |