com.obs.services.model

## 类 DownloadFileRequest

- java.lang.Object
- - com.obs.services.model.GenericRequest
  - - com.obs.services.model.DownloadFileRequest

-     public class DownloadFileRequest
      extends GenericRequest

  Parameters in a request for downloading a file

- - ### 构造器概要

    构造器
    构造器和说明
    `DownloadFileRequest(String bucketName, String objectKey)` Constructor
    `DownloadFileRequest(String bucketName, String objectKey, String downloadFile)` Constructor
    `DownloadFileRequest(String bucketName, String objectKey, String downloadFile, long partSize)` Constructor
    `DownloadFileRequest(String bucketName, String objectKey, String downloadFile, long partSize, int taskNum)` Constructor
    `DownloadFileRequest(String bucketName, String objectKey, String downloadFile, long partSize, int taskNum, boolean enableCheckpoint)` Constructor
    `DownloadFileRequest(String bucketName, String objectKey, String downloadFile, long partSize, int taskNum, boolean enableCheckpoint, String checkpointFile)` Constructor
    `DownloadFileRequest(String bucketName, String objectKey, String downloadFile, long partSize, int taskNum, boolean enableCheckpoint, String checkpointFile, String versionId)` Constructor

  - ### 方法概要

    所有方法 实例方法 具体方法
    限定符和类型 | 方法和说明
    --- | ---
    `String` | `getBucketName()` Obtain the bucket name.
    `CacheOptionEnum` | `getCacheOption()` Obtain the control option of the read-ahead cache.
    `String` | `getCheckpointFile()` File used to record download progresses in resumable mode
    `String` | `getDownloadFile()` Obtain the path to the to-be-downloaded file.
    `String` | `getIfMatchTag()` Obtain the ETag verification conditions for downloading the object.
    `Date` | `getIfModifiedSince()` Obtain the time conditions set for downloading the object.
    `String` | `getIfNoneMatchTag()` Obtain the ETag verification conditions for downloading the object.
    `Date` | `getIfUnmodifiedSince()` Obtain the time conditions for downloading the object.
    `String` | `getObjectKey()` Obtain the object name.
    `long` | `getPartSize()` Obtain the part size.
    `long` | `getProgressInterval()` Obtain the callback threshold of the data transfer listener.
    `ProgressListener` | `getProgressListener()` Obtain the data transfer listener.
    `int` | `getTaskNum()` Obtain the maximum number of threads used for processing download tasks concurrently.
    `String` | `getTempDownloadFile()` Obtain the temporary file generated during the download.
    `long` | `getTtl()` Obtain the cache data expiration time.
    `String` | `getVersionId()` Obtain the object version ID.
    `boolean` | `isEnableCheckpoint()` Identify whether the resumable mode is enabled.
    `void` | `setBucketName(String bucketName)` Set the bucket name.
    `void` | `setCacheOption(CacheOptionEnum cacheOption)` Set the control option of the read-ahead cache.
    `void` | `setCheckpointFile(String checkpointFile)` Specify a file used to record resumable download progresses.
    `void` | `setDownloadFile(String downloadFile)` Set the path to the to-be-downloaded file.
    `void` | `setEnableCheckpoint(boolean enableCheckpoint)` Specify whether to enable the resumable mode.
    `void` | `setIfMatchTag(String ifMatchTag)` Set the ETag verification conditions for downloading the object.
    `void` | `setIfModifiedSince(Date ifModifiedSince)` Set the time conditions set for downloading the object.
    `void` | `setIfNoneMatchTag(String ifNoneMatchTag)` Set the ETag verification conditions for downloading the object.
    `void` | `setIfUnmodifiedSince(Date ifUnmodifiedSince)` Set the time conditions for downloading the object.
    `void` | `setObjectKey(String objectKey)` Set the object name.
    `void` | `setPartSize(long partSize)` Set the part size.
    `void` | `setProgressInterval(long progressInterval)` Set the callback threshold of the data transfer listener.
    `void` | `setProgressListener(ProgressListener progressListener)` Set the data transfer listener.
    `void` | `setTaskNum(int taskNum)` Set the maximum number of threads used for processing download tasks concurrently.
    `void` | `setTtl(long ttl)` Set the cache data expiration time.
    `void` | `setVersionId(String versionId)` Set the version ID of the object.
    `String` | `toString()`

    - ### 从类继承的方法 com.obs.services.model.GenericRequest

      `isRequesterPays, setRequesterPays`

    - ### 从类继承的方法 java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### 构造器详细资料

    - #### DownloadFileRequest

          public DownloadFileRequest(String bucketName,
                                     String objectKey)

      Constructor
      参数:
        `bucketName` - Bucket name
        `objectKey` - Object name

    - #### DownloadFileRequest

          public DownloadFileRequest(String bucketName,
                                     String objectKey,
                                     String downloadFile)

      Constructor
      参数:
        `bucketName` - Bucket name
        `objectKey` - Object name
        `downloadFile` - Path to the to-be-downloaded file

    - #### DownloadFileRequest

          public DownloadFileRequest(String bucketName,
                                     String objectKey,
                                     String downloadFile,
                                     long partSize)

      Constructor
      参数:
        `bucketName` - Bucket name
        `objectKey` - Object name
        `downloadFile` - Path to the to-be-downloaded file
        `partSize` - Part size

    - #### DownloadFileRequest

          public DownloadFileRequest(String bucketName,
                                     String objectKey,
                                     String downloadFile,
                                     long partSize,
                                     int taskNum)

      Constructor
      参数:
        `bucketName` - Bucket name
        `objectKey` - Object name
        `downloadFile` - Path to the to-be-downloaded file
        `partSize` - Part size
        `taskNum` - Maximum number of threads used for processing download tasks concurrently

    - #### DownloadFileRequest

          public DownloadFileRequest(String bucketName,
                                     String objectKey,
                                     String downloadFile,
                                     long partSize,
                                     int taskNum,
                                     boolean enableCheckpoint)

      Constructor
      参数:
        `bucketName` - Bucket name
        `objectKey` - Object name
        `downloadFile` - Path to the to-be-downloaded file
        `partSize` - Part size
        `taskNum` - Maximum number of threads used for processing download tasks concurrently
        `enableCheckpoint` - Whether to enable the resumable mode

    - #### DownloadFileRequest

          public DownloadFileRequest(String bucketName,
                                     String objectKey,
                                     String downloadFile,
                                     long partSize,
                                     int taskNum,
                                     boolean enableCheckpoint,
                                     String checkpointFile)

      Constructor
      参数:
        `bucketName` - Bucket name
        `objectKey` - Object name
        `downloadFile` - Path to the to-be-downloaded file
        `partSize` - Part size
        `taskNum` - Maximum number of threads used for processing download tasks concurrently
        `enableCheckpoint` - Whether to enable the resumable mode
        `checkpointFile` - File used to record download progresses in resumable mode

    - #### DownloadFileRequest

          public DownloadFileRequest(String bucketName,
                                     String objectKey,
                                     String downloadFile,
                                     long partSize,
                                     int taskNum,
                                     boolean enableCheckpoint,
                                     String checkpointFile,
                                     String versionId)

      Constructor
      参数:
        `bucketName` - Bucket name
        `objectKey` - Object name
        `downloadFile` - Path to the to-be-downloaded file
        `partSize` - Part size
        `taskNum` - Maximum number of threads used for processing download tasks concurrently
        `enableCheckpoint` - Whether to enable the resumable mode
        `checkpointFile` - File used to record download progresses in resumable mode
        `versionId` - Version ID of the object

  - ### 方法详细资料

    - #### getBucketName

          public String getBucketName()

      Obtain the bucket name.
      返回:
        Bucket name

    - #### setBucketName

          public void setBucketName(String bucketName)

      Set the bucket name.
      参数:
        `bucketName` - Bucket name

    - #### getObjectKey

          public String getObjectKey()

      Obtain the object name.
      返回:
        Object name

    - #### setObjectKey

          public void setObjectKey(String objectKey)

      Set the object name.
      参数:
        `objectKey` - Object name

    - #### getDownloadFile

          public String getDownloadFile()

      Obtain the path to the to-be-downloaded file.
      返回:
        Path to the to-be-downloaded file

    - #### setDownloadFile

          public void setDownloadFile(String downloadFile)

      Set the path to the to-be-downloaded file.
      参数:
        `downloadFile` - Path to the to-be-downloaded file

    - #### getPartSize

          public long getPartSize()

      Obtain the part size.
      返回:
        Part size

    - #### setPartSize

          public void setPartSize(long partSize)

      Set the part size.
      参数:
        `partSize` - Part size

    - #### getTaskNum

          public int getTaskNum()

      Obtain the maximum number of threads used for processing download tasks concurrently.
      返回:
        Maximum number of threads used for processing download tasks concurrently

    - #### setTaskNum

          public void setTaskNum(int taskNum)

      Set the maximum number of threads used for processing download tasks concurrently.
      参数:
        `taskNum` - Maximum number of threads used for processing download tasks concurrently

    - #### isEnableCheckpoint

          public boolean isEnableCheckpoint()

      Identify whether the resumable mode is enabled.
      返回:
        Identifier specifying whether the resumable mode is enabled

    - #### setEnableCheckpoint

          public void setEnableCheckpoint(boolean enableCheckpoint)

      Specify whether to enable the resumable mode.
      参数:
        `enableCheckpoint` - Identifier specifying whether the resumable mode is enabled

    - #### getCheckpointFile

          public String getCheckpointFile()

      File used to record download progresses in resumable mode
      返回:
        File used to record the download progress

    - #### setCheckpointFile

          public void setCheckpointFile(String checkpointFile)

      Specify a file used to record resumable download progresses.
      参数:
        `checkpointFile` - File used to record the download progress

    - #### getTempDownloadFile

          public String getTempDownloadFile()

      Obtain the temporary file generated during the download.
      返回:
        Temporary file generated during the download

    - #### getIfModifiedSince

          public Date getIfModifiedSince()

      Obtain the time conditions set for downloading the object. Only when the object is modified after the point in time specified by this parameter, it will be downloaded. Otherwise, "304 Not Modified" will be returned.
      返回:
        Time condition set for downloading the object

    - #### setIfModifiedSince

          public void setIfModifiedSince(Date ifModifiedSince)

      Set the time conditions set for downloading the object. Only when the object is modified after the point in time specified by this parameter, it will be downloaded. Otherwise, "304 Not Modified" will be returned.
      参数:
        `ifModifiedSince` - Time condition set for downloading the object

    - #### getIfUnmodifiedSince

          public Date getIfUnmodifiedSince()

      Obtain the time conditions for downloading the object. Only when the object remains unchanged after the point in time specified by this parameter, it will be downloaded; otherwise, "412 Precondition Failed" will be returned.
      返回:
        Time condition set for downloading the object

    - #### setIfUnmodifiedSince

          public void setIfUnmodifiedSince(Date ifUnmodifiedSince)

      Set the time conditions for downloading the object. Only when the object remains unchanged after the point in time specified by this parameter, it will be downloaded; otherwise, "412 Precondition Failed" will be returned.
      参数:
        `ifUnmodifiedSince` - Time condition set for downloading the object

    - #### getIfMatchTag

          public String getIfMatchTag()

      Obtain the ETag verification conditions for downloading the object. Only when the ETag of the object is the same as that specified by this parameter, the object will be downloaded. Otherwise, "412 Precondition Failed" will be returned.
      返回:
        ETag verification condition set for downloading the object

    - #### setIfMatchTag

          public void setIfMatchTag(String ifMatchTag)

      Set the ETag verification conditions for downloading the object. Only when the ETag of the object is the same as that specified by this parameter, the object will be downloaded. Otherwise, "412 Precondition Failed" will be returned.
      参数:
        `ifMatchTag` - ETag verification condition set for downloading the object

    - #### getIfNoneMatchTag

          public String getIfNoneMatchTag()

      Obtain the ETag verification conditions for downloading the object. Only when the ETag of the object is different from that specified by this parameter, the object will be downloaded. Otherwise, "304 Not Modified" will be returned.
      返回:
        ETag verification condition set for downloading the object

    - #### setIfNoneMatchTag

          public void setIfNoneMatchTag(String ifNoneMatchTag)

      Set the ETag verification conditions for downloading the object. Only when the ETag of the object is different from that specified by this parameter, the object will be downloaded. Otherwise, "304 Not Modified" will be returned.
      参数:
        `ifNoneMatchTag` - ETag verification condition set for downloading the object

    - #### getVersionId

          public String getVersionId()

      Obtain the object version ID.
      返回:
        Version ID of the object

    - #### setVersionId

          public void setVersionId(String versionId)

      Set the version ID of the object.
      参数:
        `versionId` - Version ID of the object

    - #### getProgressListener

          public ProgressListener getProgressListener()

      Obtain the data transfer listener.
      返回:
        Data transfer listener

    - #### setProgressListener

          public void setProgressListener(ProgressListener progressListener)

      Set the data transfer listener.
      参数:
        `progressListener` - Data transfer listener

    - #### getProgressInterval

          public long getProgressInterval()

      Obtain the callback threshold of the data transfer listener. The default value is 100 KB.
      返回:
        Callback threshold of the data transfer listener

    - #### setProgressInterval

          public void setProgressInterval(long progressInterval)

      Set the callback threshold of the data transfer listener. The default value is 100 KB.
      参数:
        `progressInterval` - Callback threshold of the data transfer listener

    - #### getCacheOption

          public CacheOptionEnum getCacheOption()

      Obtain the control option of the read-ahead cache.
      返回:
        Control option of the read-ahead cache

    - #### setCacheOption

          public void setCacheOption(CacheOptionEnum cacheOption)

      Set the control option of the read-ahead cache.
      参数:
        `cacheOption` - Control option of the read-ahead cache

    - #### getTtl

          public long getTtl()

      Obtain the cache data expiration time.
      返回:
        Cache data expiration time

    - #### setTtl

          public void setTtl(long ttl)

      Set the cache data expiration time.
      参数:
        `ttl` - Cache data expiration time

    - #### toString

          public String toString()

      覆盖:
        `toString` 在类中 `GenericRequest`

Copyright © 2021. All rights reserved.