public class BucketAccelerateConfiguration extends Object implements Serializable, S3RequesterChargedResult
Constructor and Description |
---|
BucketAccelerateConfiguration(BucketAccelerateStatus status)
Creates a new bucket accelerate configuration object with the specified status.
|
BucketAccelerateConfiguration(String status)
Creates a new bucket accelerate configuration object with the specified status.
|
Modifier and Type | Method and Description |
---|---|
String |
getStatus() |
boolean |
isAccelerateEnabled()
A convenience method that returns whether the bucket is enabled accelerate mode.
|
boolean |
isRequesterCharged()
Returns true if the user has enabled Requester Pays option when
conducting this operation from Requester Pays Bucket; else false.
|
void |
setRequesterCharged(boolean isRequesterCharged)
Used for conducting this operation from a Requester Pays Bucket.
|
void |
setStatus(BucketAccelerateStatus status)
Sets the desired bucket accelerate status for this configuration object.
|
void |
setStatus(String status)
Sets the desired bucket accelerate status for this configuration object.
|
BucketAccelerateConfiguration |
withStatus(BucketAccelerateStatus status) |
BucketAccelerateConfiguration |
withStatus(String status)
Fluent setter method for
setStatus(String) |
public BucketAccelerateConfiguration(String status)
status
- The desired bucket accelerate status for the new configuration object. See
BucketAccelerateStatus
for a list of valid values.public BucketAccelerateConfiguration(BucketAccelerateStatus status)
status
- The desired bucket accelerate status for the new configuration object. See
BucketAccelerateStatus
for a list of valid values.public String getStatus()
public void setStatus(String status)
status
- The desired bucket accelerate status for this configuration object. See
BucketAccelerateStatus
for a list of valid values.public void setStatus(BucketAccelerateStatus status)
status
- The desired bucket accelerate status for this configuration object. See
BucketAccelerateStatus
for a list of valid values.public BucketAccelerateConfiguration withStatus(String status)
setStatus(String)
BucketAccelerateConfiguration
object so that additional method calls may
be chained together.setStatus(String)
public BucketAccelerateConfiguration withStatus(BucketAccelerateStatus status)
public boolean isAccelerateEnabled()
BucketAccelerateStatus.Enabled
status.public boolean isRequesterCharged()
S3RequesterChargedResult
If a bucket is enabled for Requester Pays, then any attempt of operation from it without Requester Pays enabled will result in a 403 error and the bucket owner will be charged for the request.
Enabling Requester Pays disables the ability to have anonymous access to this bucket
isRequesterCharged
in interface S3RequesterChargedResult
public void setRequesterCharged(boolean isRequesterCharged)
S3RequesterChargedResult
If a bucket is enabled for Requester Pays, then any attempt of operation from it without Requester Pays enabled will result in a 403 error and the bucket owner will be charged for the request.
setRequesterCharged
in interface S3RequesterChargedResult
isRequesterCharged
- Indicates requester is charged for this operation.