nextapp.echoservlet.filetransferui
Class MultipartUploadFactory
java.lang.Object
nextapp.echoservlet.filetransferui.MultipartUploadFactory
public class MultipartUploadFactory
- extends java.lang.Object
Factory for MultipartUploadSPI implementations. This class is responsible
for discovery of MultipartUploadSPI implementations and creation of
new instances on demand.
Method Summary |
static MultipartUploadSPI |
create()
Generates a new instance of the MultipartUploadSPI implementation. |
static void |
init(java.lang.Integer maxUploadSize,
java.io.File diskCacheLocation,
java.lang.Integer memoryCacheThresholdSize)
Called once to initialize the factory. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
MultipartUploadFactory
public MultipartUploadFactory()
init
public static void init(java.lang.Integer maxUploadSize,
java.io.File diskCacheLocation,
java.lang.Integer memoryCacheThresholdSize)
throws java.io.IOException
- Called once to initialize the factory.
- Parameters:
maxUploadSize
- Size, in bytes, of maximum allowable upload.
Null or negetive values allow any sized upload. A value of
zero will disable file uploading.diskCacheLocation
- Location to store uploaded files instead of
holding them in memory. If this value is null, uploads will
be stored in memory during the request processing.memoryCacheThresholdSize
- Size, in bytes, that a file upload
must exceed for it to be stored to disk. A null, negative or
zero value will force the file to always be cached to disk.
This parameter is ignored if diskCacheLocation
is
null.
- Throws:
java.io.IOException
- if the discovered MultipartUploadSPI provider
throws an IOException.
create
public static MultipartUploadSPI create()
- Generates a new instance of the MultipartUploadSPI implementation.
- Returns:
- an instance of the MultipartUploadSPI