Package org.eclipse.ecf.filetransfer
Class FileTransferJob
java.lang.Object
org.eclipse.core.runtime.PlatformObject
org.eclipse.core.internal.jobs.InternalJob
org.eclipse.core.runtime.jobs.Job
org.eclipse.ecf.filetransfer.FileTransferJob
- All Implemented Interfaces:
Comparable<org.eclipse.core.internal.jobs.InternalJob>
,org.eclipse.core.runtime.IAdaptable
public class FileTransferJob
extends org.eclipse.core.runtime.jobs.Job
Job
subclass for executing file transfers. This class should
be subclassed to create a customized Job
for passing to
an incoming or outgoing file transfer. For example, to use a custom
job for doing a file transfer retrieval via IIncomingFileTransferReceiveStartEvent.receive(java.io.File, FileTransferJob)
:
class MyFileTransferJob extends FileTransferJob { public MyFileTransferJob(String name) { super(name); } public boolean belongsTo(Object o) { // insert own logic to decide whether // this file transfer job should be part // of a group // } } MyFileTransferJob myJob = new MyFileTransferJob("myname"); incomingfiletransfer = event.receive(outputstream,myJob);
- Since:
- 2.0
-
Field Summary
Fields inherited from class org.eclipse.core.runtime.jobs.Job
ASYNC_FINISH, BUILD, DECORATE, INTERACTIVE, LONG, NONE, RUNNING, SHORT, SLEEPING, WAITING
Fields inherited from class org.eclipse.core.internal.jobs.InternalJob
manager
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected void
protected final org.eclipse.core.runtime.IStatus
run
(org.eclipse.core.runtime.IProgressMonitor mntr) final void
setFileTransfer
(IFileTransfer fileTransfer) final void
setFileTransferRunnable
(IFileTransferRunnable fileTransferRunnable) Methods inherited from class org.eclipse.core.runtime.jobs.Job
addJobChangeListener, belongsTo, cancel, create, create, createSystem, createSystem, done, getJobGroup, getJobManager, getName, getPriority, getProperty, getResult, getRule, getState, getThread, isBlocking, isSystem, isUser, join, join, removeJobChangeListener, schedule, schedule, setJobGroup, setName, setPriority, setProgressGroup, setProperty, setRule, setSystem, setThread, setUser, shouldRun, shouldSchedule, sleep, toString, wakeUp, wakeUp, yieldRule
Methods inherited from class org.eclipse.core.internal.jobs.InternalJob
compareTo
Methods inherited from class org.eclipse.core.runtime.PlatformObject
getAdapter
-
Constructor Details
-
FileTransferJob
- Parameters:
name
- the name for this file transfer job. Should not benull
.
-
-
Method Details
-
setFileTransferRunnable
-
setFileTransfer
- Parameters:
fileTransfer
- file transfer instance- Since:
- 3.0
-
run
protected final org.eclipse.core.runtime.IStatus run(org.eclipse.core.runtime.IProgressMonitor mntr) - Specified by:
run
in classorg.eclipse.core.runtime.jobs.Job
-
canceling
protected void canceling()- Overrides:
canceling
in classorg.eclipse.core.runtime.jobs.Job
-