public class FetchObjectRequest extends GenericObjectRequest
All FetchObjectRequest must specify a sourceUrl and mode, along with a destination bucket and key.
| Modifier and Type | Field and Description |
|---|---|
static String |
MODE_ASYNC |
static String |
MODE_SYNC |
trafficLimitBitPS| Constructor and Description |
|---|
FetchObjectRequest(String bucketName,
String key,
String sourceUrl)
Constructs a new FetchObjectRequest with only basic options.
|
| Modifier and Type | Method and Description |
|---|---|
String |
getCallbackAddress() |
String |
getMode()
Gets the mode of this fetching job.
|
String |
getReferer() |
String |
getSourceUrl()
Gets the url string of the sourceUrl to be fetched.
|
String |
getStorageClass()
Gets the storageClass of the input file which is to be fetched to Baidu Bos.
|
String |
getUserAgent() |
void |
setCallbackAddress(String callbackAddress) |
void |
setMode(String mode)
Sets the mode of this fetching job.
|
void |
setReferer(String referer) |
void |
setSourceUrl(String sourceUrl)
Sets the url string of the sourceUrl to be fetched.
|
void |
setStorageClass(String storageClass)
Sets the storageClass of the input file which is to be fetched to Baidu Bos.
|
void |
setUserAgent(String userAgent) |
FetchObjectRequest |
withBucketName(String bucketName)
Sets the name of the destination bucket which will contain the new,
fetched object and returns this object, enabling additional method calls
to be chained together.
|
FetchObjectRequest |
withKey(String key)
Sets the destination bucket key under which the new, fetched object
will be stored and returns this object, enabling additional method calls
can be chained together.
|
FetchObjectRequest |
withMode(String mode)
Sets the mode of this fetching job, enabling additional method calls to be chained together.
|
FetchObjectRequest |
withRequestCredentials(BceCredentials credentials) |
FetchObjectRequest |
withSourceUrl(String sourceUrl)
Sets the url string of the sourceUrl to be fetched,
and returns this object, enabling additional method calls to be chained together.
|
FetchObjectRequest |
withStorageClass(String storageClass)
Sets the storageClass of the input file which is to be fetched to Baidu Bos.
|
getKey, setKeygetBucketName, setBucketNamegetRequestCredentials, setRequestCredentialspublic static final String MODE_SYNC
public static final String MODE_ASYNC
public FetchObjectRequest(String bucketName, String key, String sourceUrl)
bucketName - The name of the Bos bucket to which the new object will be fetched.key - The destination bucket key under which the new object will be fetched.sourceUrl - The name of the Bos bucket containing the object to fetch.public String getSourceUrl()
public void setSourceUrl(String sourceUrl)
sourceUrl - The url string of the sourceUrl to be fetched.public FetchObjectRequest withSourceUrl(String sourceUrl)
sourceUrl - The url string of the sourceUrl to be fetched.FetchObjectRequest instance,
enabling additional method calls to be chained together.public String getMode()
public void setMode(String mode)
mode - The mode of this fetching job.public FetchObjectRequest withMode(String mode)
mode - The mode of this fetching job.FetchObjectRequest instance, enabling additional method calls to be chained together.public FetchObjectRequest withRequestCredentials(BceCredentials credentials)
withRequestCredentials in class AbstractBceRequestpublic FetchObjectRequest withBucketName(String bucketName)
withBucketName in class GenericBucketRequestbucketName - The name of the destination bucket which will contain the new object of fetching job.FetchObjectRequest, enabling additional method calls to be chained together.public FetchObjectRequest withKey(String key)
withKey in class GenericObjectRequestkey - The destination bucket key under which the new, fetched object will be stored.FetchObjectRequest, enabling additional method calls to be chained together.public String getStorageClass()
public void setStorageClass(String storageClass)
storageClass - The storageClass is an identification that distinguish between infrequent access bos
and standard bos.public FetchObjectRequest withStorageClass(String storageClass)
storageClass - The StorageClass is an identification that distinguish between infrequent access bos
and standard bos.public String getCallbackAddress()
public void setCallbackAddress(String callbackAddress)
public String getReferer()
public void setReferer(String referer)
public String getUserAgent()
public void setUserAgent(String userAgent)
Copyright © 2024. All rights reserved.