public abstract class MultipleFileTransfer<T extends Transfer> extends AbstractTransfer
Transfer.TransferState
Modifier and Type | Field and Description |
---|---|
protected Collection<? extends T> |
subTransfers |
listenerChain, monitor, state, stateChangeListeners
Modifier and Type | Method and Description |
---|---|
void |
collateFinalState()
Set the state based on the states of all file downloads.
|
void |
setState(Transfer.TransferState state)
Override this method so that TransferState updates are also sent out to the
progress listener chain in forms of ProgressEvent.
|
addProgressListener, addProgressListener, addStateChangeListener, fireProgressEvent, getDescription, getMonitor, getProgress, getState, isDone, notifyStateChangeListeners, removeProgressListener, removeProgressListener, removeStateChangeListener, rethrowExecutionException, setMonitor, unwrapExecutionException, waitForCompletion, waitForException
protected final Collection<? extends T extends Transfer> subTransfers
public void collateFinalState()
A single failed sub-transfer makes the entire transfer failed. If there are no failed sub-transfers, a single canceled sub-transfer makes the entire transfer canceled. Otherwise, we consider ourselves Completed.
public void setState(Transfer.TransferState state)
setState
in class AbstractTransfer
Copyright © 2022. All rights reserved.