public final class PresignedUrlDownloadConfig extends Object
TransferManager
when using presigned urlsConstructor and Description |
---|
PresignedUrlDownloadConfig() |
Modifier and Type | Method and Description |
---|---|
long |
getDownloadSizePerRequest() |
S3ProgressListener |
getS3progressListener() |
long |
getTimeoutMillis() |
boolean |
isResumeOnRetry() |
void |
setDownloadSizePerRequest(long downloadSizePerRequest) |
void |
setResumeOnRetry(boolean resumeOnRetry) |
void |
setS3progressListener(S3ProgressListener s3progressListener) |
void |
setTimeoutMillis(long timeoutMillis)
Sets the timeout, in milliseconds, for waiting for this download to complete.
|
PresignedUrlDownloadConfig |
withDownloadSizePerRequest(long downloadSizePerRequest) |
PresignedUrlDownloadConfig |
withResumeOnRetry(boolean resumeOnRetry) |
PresignedUrlDownloadConfig |
withS3progressListener(S3ProgressListener s3progressListener) |
PresignedUrlDownloadConfig |
withTimeoutMillis(long timeoutMillis)
Sets the timeout, in milliseconds, for waiting for this download to complete.
|
public S3ProgressListener getS3progressListener()
public void setS3progressListener(S3ProgressListener s3progressListener)
s3progressListener
- sets optional callback listener to get the progress of the download.public PresignedUrlDownloadConfig withS3progressListener(S3ProgressListener s3progressListener)
s3progressListener
- sets optional callback listener to get the progress of the download.public long getTimeoutMillis()
public void setTimeoutMillis(long timeoutMillis)
timeoutMillis
- Timeout, in milliseconds, for waiting for this download to complete.public PresignedUrlDownloadConfig withTimeoutMillis(long timeoutMillis)
timeoutMillis
- Timeout, in milliseconds, for waiting for this download to complete.public long getDownloadSizePerRequest()
public void setDownloadSizePerRequest(long downloadSizePerRequest)
downloadSizePerRequest
- sets the size of each request while downloading object in parallel. The default value is 5 MBpublic PresignedUrlDownloadConfig withDownloadSizePerRequest(long downloadSizePerRequest)
downloadSizePerRequest
- sets the size of each request while downloading object in parallel. The default value is 5 MBpublic boolean isResumeOnRetry()
public void setResumeOnRetry(boolean resumeOnRetry)
resumeOnRetry
- If set to true, upon an immediate retry of a failed object download,
the TransferManager
will resume the download from the current end of the file on disk.
This is a one-time retry mechanism that is different from the default retries provided by sdk.
The default value is false.
Note: This value is only valid for serial downloads and one of the following conditions is true: 1) Download range is set on the request 2) TransferManager is able to find the content-length of the object using presigned urlpublic PresignedUrlDownloadConfig withResumeOnRetry(boolean resumeOnRetry)
resumeOnRetry
- If set to true, upon an immediate retry of a failed object download,
the TransferManager
will resume the download from the current end of the file on disk.
This is a one-time retry mechanism that is different from the default retries provided by sdk.
The default value is false.
Note: This value is only valid for serial downloads and one of the following conditions is true: 1) Download range is set on the request 2) TransferManager is able to find the content-length of the object using presigned urlCopyright © 2022. All rights reserved.