public class FileTransferSubInterfaceImpl extends AbstractSubEmfstoreInterface
| Modifier and Type | Field and Description |
|---|---|
static String |
ATTACHMENT_FOLDER
Attachment folder for uploads and downloads.
|
static String |
FILE_NAME_DELIMITER
The delimiter that separates file attachment id, file version and file name in an uploaded file.
|
static String |
TEMP_FOLDER
tmp folder for file uploads to server.
|
| Constructor and Description |
|---|
FileTransferSubInterfaceImpl(AbstractEmfstoreInterface parentInterface) |
| Modifier and Type | Method and Description |
|---|---|
FileChunk |
downloadFileChunk(ProjectId projectId,
FileTransferInformation fileInformation)
Reads a chunk from the file linked to the fileInformation.
|
FileTransferInformation |
uploadFileChunk(ProjectId projectId,
FileChunk fileChunk)
Writes a chunk to the file linked to the fileInformation in the fileChunk.
|
execute, getResourceHelperpublic static final String TEMP_FOLDER
public static final String ATTACHMENT_FOLDER
public static final String FILE_NAME_DELIMITER
public FileTransferSubInterfaceImpl(AbstractEmfstoreInterface parentInterface) throws FatalESException
parentInterface - the parent interfaceFatalESException - if any fatal error occurspublic FileChunk downloadFileChunk(ProjectId projectId, FileTransferInformation fileInformation) throws FileTransferException, InvalidInputException
projectId - project attachment folderfileInformation - file information objectFileTransferException - if any error occurs reading the fileInvalidInputException - thrown if one of the parameters is nullpublic FileTransferInformation uploadFileChunk(ProjectId projectId, FileChunk fileChunk) throws FileTransferException, InvalidInputException
fileChunk - contains data and information about the file attachment, file version and chunk numberprojectId - project idFileTransferException - if any error occurs writing to the fileInvalidInputException - thrown if one of the parameters is nullCopyright © 2017. All rights reserved.