| java.lang.Object org.directwebremoting.io.FileTransfer
FileTransfer | public class FileTransfer (Code) | | One of the 2 ways you can receive uploaded files from a DWR enabled page is
to expose a method with a
FileTransfer parameter.
The other is to expose a method with an
InputStream parameter.
author: Lance Semmens [uklance at gmail dot com] author: Joe Walker [joe at getahead dot ltd dot uk] |
Method Summary | |
public InputStream | getInputStream() Returns an InputStream that can be used to retrieve the contents of the file. | public String | getMimeType() Returns the content type passed by the browser or null if not defined. | public String | getName() Returns the original filename in the client's file-system, as provided by
the browser (or other client software). |
FileTransfer | public FileTransfer(String name, String mimeType, InputStream inputStream)(Code) | | A ctor for the 3 things browsers tell us about the uploaded file
Parameters: name - The remote source filename Parameters: mimeType - The mime type passed in by the browser Parameters: inputStream - A means by which the data can be read |
FileTransfer | public FileTransfer(String name, String mimeType, byte[] data)(Code) | | A ctor for the 3 things browsers tell us about the uploaded file
Parameters: name - The remote source filename Parameters: mimeType - The mime type passed in by the browser Parameters: data - The data to be transfered |
getInputStream | public InputStream getInputStream()(Code) | | Returns an InputStream that can be used to retrieve the contents of the file.
An InputStream that can be used to retrieve the contents of the file. |
getMimeType | public String getMimeType()(Code) | | Returns the content type passed by the browser or null if not defined.
The content type passed by the browser or null if not defined. |
getName | public String getName()(Code) | | Returns the original filename in the client's file-system, as provided by
the browser (or other client software).
In most cases, this will be the base file name, without path information.
However, some clients, such as the Opera browser, do include path
information.
The original filename in the client's file-system. |
|
|