Class BatchFileEntry
java.lang.Object
org.nuxeo.ecm.core.io.upload.batch.BatchFileEntry
Represents a batch file backed by the
TransientStore.
The file can be chunked or not. If it is chunked it references its chunks as TransientStore entry keys.
- Since:
- 7.4
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected Blobprotected Blobprotected Stringprotected Map<String, Serializable> protected TransientStore -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedBatchFileEntry(TransientStore transientStore, String key, boolean chunked) BatchFileEntry(TransientStore transientStore, String key, int chunkCount, String fileName, String mimeType, long fileSize) Returns a file entry that references the file chunks.BatchFileEntry(TransientStore transientStore, String key, Map<String, Serializable> params) Returns a file entry that holds the given parameters.BatchFileEntry(TransientStore transientStore, String key, Blob blob) Returns a file entry that holds the given blob, not chunked. -
Method Summary
Modifier and TypeMethodDescriptionvoidgetBlob()protected BlobgetChunk(TransientStore ts, String key) intlonggetKey()booleanbooleanprotected voidtransferTo(Blob blob, File file) Appends the given blob to the given file.
-
Field Details
-
transientStore
-
key
-
params
-
blob
-
chunkedBlob
-
-
Constructor Details
-
BatchFileEntry
Returns a file entry that holds the given blob, not chunked. -
BatchFileEntry
public BatchFileEntry(TransientStore transientStore, String key, int chunkCount, String fileName, String mimeType, long fileSize) Returns a file entry that references the file chunks. -
BatchFileEntry
Returns a file entry that holds the given parameters. -
BatchFileEntry
-
-
Method Details
-
getKey
-
getParams
-
isChunked
public boolean isChunked() -
getFileName
-
getMimeType
-
getFileSize
public long getFileSize() -
getChunkCount
public int getChunkCount() -
getChunks
-
getOrderedChunkIndexes
-
getChunkEntryKeys
-
isChunksCompleted
public boolean isChunksCompleted() -
getBlob
-
getChunk
-
transferTo
Appends the given blob to the given file.- Throws:
IOException
-
addChunk
-
beforeRemove
public void beforeRemove()
-