public final class FileRequestOptions extends RequestOptions
Constructor and Description |
---|
FileRequestOptions()
Creates an instance of the
FileRequestOptions class. |
FileRequestOptions(FileRequestOptions other)
Creates an instance of the
FileRequestOptions class by copying values from another
FileRequestOptions instance. |
Modifier and Type | Method and Description |
---|---|
protected static void |
applyDefaults(FileRequestOptions modifiedOptions)
Applies defaults to the options passed in.
|
Integer |
getConcurrentRequestCount()
Gets the concurrent number of simultaneous requests per operation.
|
Boolean |
getDisableContentMD5Validation()
Gets whether download and
FileInputStream methods should ignore the file's ContentMD5 header. |
Boolean |
getStoreFileContentMD5()
Gets whether the file's ContentMD5 header should be set on uploads.
|
Boolean |
getUseTransactionalContentMD5()
Gets whether a range PUT or GET operation will use the Content-MD5 header to enforce transactional security.
|
protected static FileRequestOptions |
populateAndApplyDefaults(FileRequestOptions options,
CloudFileClient client)
Uses the concurrent request count from the specified client if
null , sets a default value for
everything else, and sets defaults as defined in the parent class. |
protected static FileRequestOptions |
populateAndApplyDefaults(FileRequestOptions options,
CloudFileClient client,
boolean setStartTime)
Uses the concurrent request count from the specified client if
null , sets a default value for
everything else, and sets defaults as defined in the parent class. |
void |
setConcurrentRequestCount(Integer concurrentRequestCount)
Sets the concurrent number of simultaneous requests per operation.
|
void |
setDisableContentMD5Validation(Boolean disableContentMD5Validation)
Sets whether download and
FileInputStream methods should ignore the file's ContentMD5 header. |
void |
setLocationMode(LocationMode locationMode)
Sets the
LocationMode for this request. |
void |
setRequireEncryption(Boolean requireEncryption)
Encryption is not supported for files.
|
void |
setStoreFileContentMD5(Boolean storeFileContentMD5)
Sets whether the file's ContentMD5 header should be set on uploads.
|
void |
setUseTransactionalContentMD5(Boolean useTransactionalContentMD5)
Sets whether a range PUT or GET operation will use the Content-MD5 header to enforce transactional security.
|
applyBaseDefaultsInternal, getLocationMode, getMaximumExecutionTimeInMs, getOperationExpiryTimeInMs, getRetryPolicyFactory, getTimeoutIntervalInMs, populateRequestOptions, requireEncryption, setMaximumExecutionTimeInMs, setRetryPolicyFactory, setTimeoutIntervalInMs
public FileRequestOptions()
FileRequestOptions
class.public FileRequestOptions(FileRequestOptions other)
FileRequestOptions
class by copying values from another
FileRequestOptions
instance.other
- A FileRequestOptions
object which represents the file request options to copy.protected static final FileRequestOptions populateAndApplyDefaults(FileRequestOptions options, CloudFileClient client)
null
, sets a default value for
everything else, and sets defaults as defined in the parent class.options
- The input options to copy from when applying defaultsclient
- A CloudFileClient
object that represents the service client used to set the default timeout
interval and retry policy, if they are null
. Additionally, if the
concurrentRequestCount
field's value is null, it will be set to the value specified by the
cloud file client's CloudFileClient#getConcurrentRequestCount
method.protected static final FileRequestOptions populateAndApplyDefaults(FileRequestOptions options, CloudFileClient client, boolean setStartTime)
null
, sets a default value for
everything else, and sets defaults as defined in the parent class.options
- The input options to copy from when applying defaultsclient
- A CloudFileClient
object that represents the service client used to set the default timeout
interval and retry policy, if they are null
. Additionally, if the
concurrentRequestCount
field's value is null, it will be set to the value specified by the
cloud blob client's CloudFileClient#getConcurrentRequestCount
method.setStartTime
- whether to initialize the startTimeInMs field, or notprotected static void applyDefaults(FileRequestOptions modifiedOptions)
modifiedOptions
- The options to apply defaults to.public Integer getConcurrentRequestCount()
setConcurrentRequestCount(Integer)
.public Boolean getUseTransactionalContentMD5()
setUseTransactionalContentMD5(Boolean)
.public Boolean getStoreFileContentMD5()
setStoreFileContentMD5(Boolean)
.public Boolean getDisableContentMD5Validation()
FileInputStream
methods should ignore the file's ContentMD5 header. For more
information about disabling content MD5 validation defaults, see setDisableContentMD5Validation(Boolean)
.public void setConcurrentRequestCount(Integer concurrentRequestCount)
The default concurrent request count is set in the client and is by default 1, indicating no concurrency. You can
change the concurrent request count on this request by setting this property. You can also change the value on
the CloudFileClient.getDefaultRequestOptions()
object so that all subsequent requests made via the
service client will use that concurrent request count.
concurrentRequestCount
- the concurrentRequestCount to setpublic void setUseTransactionalContentMD5(Boolean useTransactionalContentMD5)
The default useTransactionalContentMD5 value is set in the client and is by default false
. You can
change the useTransactionalContentMD5 value on this request by setting this property. You can also change the
value on the CloudFileClient.getDefaultRequestOptions()
object so that all subsequent requests made via
the service client will use that useTransactionalContentMD5 value.
useTransactionalContentMD5
- the useTransactionalContentMD5 to setpublic void setStoreFileContentMD5(Boolean storeFileContentMD5)
The default storeFileContentMD5 value is set in the client and is by default true
. You can change
the storeFileContentMD5 value on this request by setting this property. You can also change the value on the
CloudFileClient.getDefaultRequestOptions()
object so that all subsequent requests made via the service
client will use that storeFileContentMD5 value.
storeFileContentMD5
- the storeFileContentMD5 to setpublic void setDisableContentMD5Validation(Boolean disableContentMD5Validation)
FileInputStream
methods should ignore the file's ContentMD5 header.
The default disableContentMD5Validation value is set in the client and is by default false
. You can
change the disableContentMD5Validation value on this request by setting this property. You can also change the
value on the CloudFileClient.getDefaultRequestOptions()
object so that all subsequent requests made via
the service client will use that disableContentMD5Validation value.
disableContentMD5Validation
- the disableContentMD5Validation to setpublic final void setLocationMode(LocationMode locationMode)
LocationMode
for this request.
The default LocationMode
is set in the client and is by default LocationMode.PRIMARY_ONLY
. You
can change the LocationMode
on this request by setting this property. You can also change the value on
the ServiceClient.getDefaultRequestOptions()
object so that all subsequent requests made via the service
client will use that LocationMode
.
setLocationMode
in class RequestOptions
locationMode
- the locationMode to setpublic void setRequireEncryption(Boolean requireEncryption)
setRequireEncryption
in class RequestOptions
requireEncryption
- A value to indicate whether all data written and read must be encrypted.Copyright © 2019. All rights reserved.