|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface MultipartUploadSPI
This interface allows pluggable selection of the library to be used to parse
the HttpServletRequest.
Custom MultipartUploadSPI implementations may be configured by calling
System.setProperty(MultipartUploadSPI.SYSTEM_PROPERTY_NAME, "com.example.CustomMultipartUploadSPI")
from within an application entry point. The given fully qualified implementation class
must implement a public default (no argument) constructor.
| Field Summary | |
|---|---|
static java.lang.String |
SYSTEM_PROPERTY_NAME
|
| Method Summary | |
|---|---|
java.io.File |
getDiskCacheLocation()
Gets the directory to be used for storing file uploads that exceed the memory cache threshold. |
int |
getFileUploadSizeLimit()
Gets the maximum size, in bytes, of file uploads to be accepted. |
int |
getMemoryCacheThreshold()
Gets the size, in bytes, that the file upload must exceed before being cached to disk. |
boolean |
supportsDiskCaching()
Implementations return true if they support caching the
uploaded file to disk. |
boolean |
supportsFileUploadSizeLimit()
Implementations return true if they support limiting the
size of the upload. |
void |
updateComponent(Connection conn,
UploadSelect uploadSelect)
Implementations use the information from the HttpServletRequest in the Connection to call the fileUpload() method of the
UploadSelect component. |
| Methods inherited from interface nextapp.echo2.webrender.WebRenderAction.MultipartRequestWrapper |
|---|
getWrappedRequest |
| Field Detail |
|---|
static final java.lang.String SYSTEM_PROPERTY_NAME
| Method Detail |
|---|
boolean supportsDiskCaching()
true if they support caching the
uploaded file to disk. Implementations that return true
must not throw UnsupportedOperationExceptions for the
methods setMemoryCacheThreshold() and
setDiskCacheLocation().
boolean supportsFileUploadSizeLimit()
true if they support limiting the
size of the upload. Implementations that return true must
not throw an UnsupportedOperationException for the method
setFileUploadSizeLimit().
void updateComponent(Connection conn,
UploadSelect uploadSelect)
throws java.io.IOException,
ServletException
fileUpload() method of the
UploadSelect component.
conn - provides access to the HttpServletRequestuploadSelect - component to be updated with the file upload
information
java.io.IOException - if the Connection or the HttpServletRequest throws
an IOException during the operation
ServletException - if Connection or the HttpServletRequest throws
an IOException during the operation
int getMemoryCacheThreshold()
throws java.lang.UnsupportedOperationException
UnsupportedOperationException.
java.lang.UnsupportedOperationException - if this implementation does not
support disk caching
java.io.File getDiskCacheLocation()
throws java.io.IOException,
java.lang.UnsupportedOperationException
java.io.IOException - if the directory does not exist or the File throws
an IOException during this operation
java.lang.UnsupportedOperationException - if this implementation does not
support disk caching
int getFileUploadSizeLimit()
throws java.lang.UnsupportedOperationException
java.lang.UnsupportedOperationException - if this implementation does not
support limiting file upload sizes
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||