com.obs.services.model

## 类 GetObjectRequest

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

- 直接已知子类:
    ReadFileRequest

      public class GetObjectRequest
      extends GenericRequest

  Parameters in an object download request

- - ### 构造器概要

    构造器
    构造器和说明
    `GetObjectRequest()`
    `GetObjectRequest(String bucketName, String objectKey)` Constructor
    `GetObjectRequest(String bucketName, String objectKey, String versionId)` Constructor

  - ### 方法概要

    所有方法 实例方法 具体方法
    限定符和类型 | 方法和说明
    --- | ---
    `String` | `getBucketName()` Obtain the bucket name.
    `CacheOptionEnum` | `getCacheOption()` Obtain the control option of the read-ahead cache.
    `String` | `getIfMatchTag()` Obtain the ETag verification condition for downloading the object.
    `Date` | `getIfModifiedSince()` Obtain the time condition set for downloading the object.
    `String` | `getIfNoneMatchTag()` Obtain the ETag verification condition for downloading the object.
    `Date` | `getIfUnmodifiedSince()` Obtain the time condition for downloading the object.
    `String` | `getImageProcess()` Obtain image processing parameters.
    `String` | `getObjectKey()` Obtain the object name.
    `long` | `getProgressInterval()` Obtain the callback threshold of the data transfer listener.
    `ProgressListener` | `getProgressListener()` Obtain the data transfer listener.
    `Long` | `getRangeEnd()` Obtain the end position for object download.
    `Long` | `getRangeStart()` Obtain the start position for object download.
    `ObjectRepleaceMetadata` | `getReplaceMetadata()` Obtain the request headers that need to be rewritten during object download.
    `Map<String,String>` | `getRequestParameters()`
    `SseCHeader` | `getSseCHeader()` Obtain SSE-C decryption headers.
    `long` | `getTtl()` Obtain the cache data expiration time.
    `String` | `getVersionId()` Obtain the object version ID.
    `boolean` | `isAutoUnzipResponse()` Obtain the response to whether to automatically decompress the object compressed using gzip.
    `void` | `setAutoUnzipResponse(boolean autoUnzipResponse)` Set the response to whether to automatically decompress the object compressed using gzip.
    `void` | `setBucketName(String bucketName)` Set the bucket name.
    `void` | `setCacheOption(CacheOptionEnum cacheOption)` Set the control option of the read-ahead cache.
    `void` | `setIfMatchTag(String ifMatchTag)` Set the ETag verification condition for downloading the object.
    `void` | `setIfModifiedSince(Date ifModifiedSince)` Set the time condition set for downloading the object.
    `void` | `setIfNoneMatchTag(String ifNoneMatchTag)` Set the ETag verification condition for downloading the object.
    `void` | `setIfUnmodifiedSince(Date ifUnmodifiedSince)` Set the time condition for downloading the object.
    `void` | `setImageProcess(String imageProcess)` Set image processing parameters.
    `void` | `setObjectKey(String objectKey)` Set the object name.
    `void` | `setProgressInterval(long progressInterval)` Set the callback threshold of the data transfer listener.
    `void` | `setProgressListener(ProgressListener progressListener)` Set the data transfer listener.
    `void` | `setRangeEnd(Long rangeEnd)` Set the end position for object download.
    `void` | `setRangeStart(Long rangeStart)` Set the start position for object download.
    `void` | `setReplaceMetadata(ObjectRepleaceMetadata replaceMetadata)` Set the request headers that need to be rewritten during object download.
    `void` | `setRequestParameters(Map<String,String> requestParameters)`
    `void` | `setSseCHeader(SseCHeader sseCHeader)` Set SSE-C decryption headers.
    `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`

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

    - #### GetObjectRequest

          public GetObjectRequest()

    - #### GetObjectRequest

          public GetObjectRequest(String bucketName,
                                  String objectKey)

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

    - #### GetObjectRequest

          public GetObjectRequest(String bucketName,
                                  String objectKey,
                                  String versionId)

      Constructor
      参数:
        `bucketName` - Bucket name
        `objectKey` - Object name
        `versionId` - Version ID of the object

  - ### 方法详细资料

    - #### getReplaceMetadata

          public ObjectRepleaceMetadata getReplaceMetadata()

      Obtain the request headers that need to be rewritten during object download.
      返回:
        Rewritten response headers

    - #### setReplaceMetadata

          public void setReplaceMetadata(ObjectRepleaceMetadata replaceMetadata)

      Set the request headers that need to be rewritten during object download.
      参数:
        `replaceMetadata` - Rewritten response headers

    - #### getSseCHeader

          public SseCHeader getSseCHeader()

      Obtain SSE-C decryption headers.
      返回:
        SSE-C decryption headers

    - #### setSseCHeader

          public void setSseCHeader(SseCHeader sseCHeader)

      Set SSE-C decryption headers.
      参数:
        `sseCHeader` - SSE-C decryption headers

    - #### getRangeStart

          public Long getRangeStart()

      Obtain the start position for object download.
      返回:
        Start position for object download

    - #### setRangeStart

          public void setRangeStart(Long rangeStart)

      Set the start position for object download.
      参数:
        `rangeStart` - Start position for object download

    - #### getRangeEnd

          public Long getRangeEnd()

      Obtain the end position for object download.
      返回:
        End position for object download

    - #### setRangeEnd

          public void setRangeEnd(Long rangeEnd)

      Set the end position for object download.
      参数:
        `rangeEnd` - End position for object download

    - #### 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

    - #### 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

    - #### getIfModifiedSince

          public Date getIfModifiedSince()

      Obtain the time condition 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 condition 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 condition 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 condition 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 condition 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 condition 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 condition 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 condition 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

    - #### getImageProcess

          public String getImageProcess()

      Obtain image processing parameters.
      返回:
        Image processing parameters

    - #### setImageProcess

          public void setImageProcess(String imageProcess)

      Set image processing parameters.
      参数:
        `imageProcess` - Image processing parameters

    - #### 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

    - #### getRequestParameters

          public Map<String,String> getRequestParameters()

    - #### 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

    - #### setRequestParameters

          public void setRequestParameters(Map<String,String> requestParameters)

    - #### isAutoUnzipResponse

          public boolean isAutoUnzipResponse()

      Obtain the response to whether to automatically decompress the object compressed using gzip. The default response is false, indicating that the object is not automatically decompressed.
      Description: OBS SDK uses okhttp. If Accept-Encoding is not set in a request, okhttp automatically adds the Accept-Encoding:gzip header and decompresses the object after receiving the request.
      If the Accept-Encoding header is manually set in a request, the object will not be automatically decompressed.
      返回:
      从以下版本开始:
        3.20.5
      另请参阅:
        `BridgeInterceptor`

    - #### setAutoUnzipResponse

          public void setAutoUnzipResponse(boolean autoUnzipResponse)

      Set the response to whether to automatically decompress the object compressed using gzip. The default response is false, indicating that the object is not automatically decompressed.
      Description: OBS SDK uses okhttp. If Accept-Encoding is not set in a request, okhttp automatically adds the Accept-Encoding:gzip header and decompresses the object after receiving the request.
      If the Accept-Encoding header is manually set in a request, the object will not be automatically decompressed.
      参数:
        `autoUnzipResponse` -
      从以下版本开始:
        3.20.5
      另请参阅:
        `BridgeInterceptor`

    - #### toString

          public String toString()

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

Copyright © 2021. All rights reserved.