public abstract class AbstractTransferService extends AbstractServerObject<ServerContext> implements LocalCancellableTask, Executable
AbstractTransferJob and performs all requested file transfers.| Constructor and Description |
|---|
AbstractTransferService(ServerContext serverCtx,
TransferServiceTask trTask,
AbstractTransferJob job) |
| Modifier and Type | Method and Description |
|---|---|
void |
cancel()
Cancels the running task.
|
void |
downloadFileData() |
abstract void |
execute()
Contains the code to be executed.
|
FileDataType |
getFileDataType() |
long |
getRealFileSize() |
java.io.File |
getServerFile() |
protected java.lang.String |
getServerFileInfo() |
TaskId |
getTaskId()
Returns the unique identifier for this task.
|
ServerTransferConnection |
getTransferConnection() |
AbstractTransferJob |
getTransferJob() |
boolean |
isTransferZipped() |
boolean |
wasCancelled()
Tells whether ever an attempt has been made to cancel this task.
|
boolean |
wasFoundZippedOnServer() |
checkPermission, getServerConfig, getServerContext, getStatisticManager, toStringgetApplicationContext, getLogChannel, isLogDebug, isLogVerbose, logDebug, logDump, logError, logError, logFatal, logInfo, logVerbose, logWarning, setLogChannelconfigureDumpHeadlineLength, configureDumpMaxElementsPrinted, copyDumpStringValues, copyToStringValues, createDumpHeader, toDumpString, toDumpString, toStringpublic AbstractTransferService(ServerContext serverCtx, TransferServiceTask trTask, AbstractTransferJob job)
public abstract void execute()
throws java.lang.Exception
Executableexecute in interface Executablejava.lang.Exceptionpublic final long getRealFileSize()
public final FileDataType getFileDataType()
public final ServerTransferConnection getTransferConnection()
public final java.io.File getServerFile()
public AbstractTransferJob getTransferJob()
public final TaskId getTaskId()
TaskIdHolderTaskId.getTaskId in interface TaskIdHolderpublic final void cancel()
LocalCancellableTaskCancellableTask.wasCancelled() will return true. Actually this call cancels the
task's current Future and enforces a CancellationException to be thrown.cancel in interface LocalCancellableTaskpublic final boolean wasCancelled()
CancellableTaskwasCancelled in interface CancellableTaskpublic final boolean isTransferZipped()
public final boolean wasFoundZippedOnServer()
public final void downloadFileData()
throws java.io.IOException
java.io.IOExceptionprotected java.lang.String getServerFileInfo()
Copyright © 2014 EsprIT-Systems. All Rights Reserved.