public class DownloadImpl extends AbstractTransfer implements Download
Transfer.TransferStatelistenerChain, monitor, state, stateChangeListeners| 构造器和说明 |
|---|
DownloadImpl(String description,
TransferProgress transferProgress,
ProgressListenerChain progressListenerChain,
COSObject cosObject,
TransferStateChangeListener listener,
GetObjectRequest getObjectRequest,
File file) |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
abort()
Cancels this download.
|
void |
abortWithoutNotifyingStateChangeListener()
Cancels this download, but skip notifying the state change listeners.
|
String |
getBucketName()
The name of the bucket where the object is being downloaded from.
|
COSObject |
getCosObject() |
String |
getKey()
The key under which this object was stored in Qcloud COS.
|
ObjectMetadata |
getObjectMetadata()
Returns the ObjectMetadata for the object being downloaded.
|
PersistableDownload |
pause()
Pause the current download operation and returns the information that can
be used to resume the download at a later time.
|
void |
setCosObject(COSObject cosObject) |
void |
setState(Transfer.TransferState state)
This method is also responsible for firing COMPLETED signal to the
listeners.
|
addProgressListener, addStateChangeListener, fireProgressEvent, getDescription, getMonitor, getProgress, getState, isDone, notifyStateChangeListeners, removeProgressListener, removeStateChangeListener, rethrowExecutionException, setMonitor, unwrapExecutionException, waitForCompletion, waitForExceptionclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitaddProgressListener, getDescription, getProgress, getState, isDone, removeProgressListener, waitForCompletion, waitForExceptionpublic DownloadImpl(String description, TransferProgress transferProgress, ProgressListenerChain progressListenerChain, COSObject cosObject, TransferStateChangeListener listener, GetObjectRequest getObjectRequest, File file)
public ObjectMetadata getObjectMetadata()
getObjectMetadata 在接口中 Downloadpublic String getBucketName()
getBucketName 在接口中 Downloadpublic String getKey()
public void abort()
throws IOException
abort 在接口中 DownloadIOExceptionpublic void abortWithoutNotifyingStateChangeListener()
throws IOException
IOExceptionpublic COSObject getCosObject()
public void setCosObject(COSObject cosObject)
public void setState(Transfer.TransferState state)
setState 在类中 AbstractTransferpublic PersistableDownload pause() throws PauseException
DownloadCryptoMode#StrictAuthenticatedEncryption would result in
CosClientException as authenticity cannot be guaranteed for a range
get operation.pause 在接口中 DownloadPauseException - If any errors were encountered while trying to pause the
download.Copyright © 2022. All rights reserved.