org.loom.servlet.params
Interface FileParameter

All Known Implementing Classes:
InMemoryFileParameter

public interface FileParameter

Uploaded field


Method Summary
 byte[] getBytes()
          Get the file contents as a byte array
 java.lang.String getContentType()
          Get the file content-type.
 java.lang.String getFilename()
          Get the uploaded filename.
 long getFileSize()
          Get the file size, -1 if unknown
 java.io.InputStream getStream()
          Get the file contents as an input stream.
 

Method Detail

getFilename

java.lang.String getFilename()
Get the uploaded filename. The file path, if provided by the browser, will be removed


getContentType

java.lang.String getContentType()
Get the file content-type. If the browser does not provide one, it will be guessed using MimeUtils.


getFileSize

long getFileSize()
Get the file size, -1 if unknown


getStream

java.io.InputStream getStream()
                              throws java.io.IOException
Get the file contents as an input stream.

Throws:
java.io.IOException

getBytes

byte[] getBytes()
Get the file contents as a byte array