public class BucketVersioningConfiguration extends Object implements Serializable
Modifier and Type | Field and Description |
---|---|
static String |
ENABLED
S3 bucket versioning status indicating that versioning is enabled for a bucket.
|
static String |
OFF
S3 bucket versioning status indicating that versioning is off for a bucket.
|
static String |
SUSPENDED
S3 bucket versioning status indicating that versioning is suspended for a bucket.
|
Constructor and Description |
---|
BucketVersioningConfiguration()
Creates a new bucket versioning configuration object which defaults to
OFF status. |
BucketVersioningConfiguration(String status)
Creates a new bucket versioning configuration object with the specified status.
|
Modifier and Type | Method and Description |
---|---|
String |
getStatus()
Returns the current status of versioning for this bucket versioning configuration object, indicating if versioning is enabled or not for a bucket.
|
Boolean |
isMfaDeleteEnabled()
Returns true if Multi-Factor Authentication (MFA) Delete is enabled for this bucket versioning configuration, false if it isn't enabled, and null if no information is
available about the status of MFADelete.
|
void |
setMfaDeleteEnabled(Boolean mfaDeleteEnabled)
Sets the status of Multi-Factor Authentication (MFA) Delete for a bucket.
|
void |
setStatus(String status)
Sets the desired status of versioning for this bucket versioning configuration object.
|
BucketVersioningConfiguration |
withMfaDeleteEnabled(Boolean mfaDeleteEnabled)
Sets the status of Multi-Factor Authentication (MFA) Delete for a bucket, and returns this object so that additional method calls may be chained together.
|
BucketVersioningConfiguration |
withStatus(String status)
Sets the desired status of versioning for this bucket versioning configuration object, and returns this object so that additional method calls may be chained together.
|
public static final String OFF
public static final String SUSPENDED
public static final String ENABLED
public BucketVersioningConfiguration()
OFF
status.public BucketVersioningConfiguration(String status)
public String getStatus()
public void setStatus(String status)
public BucketVersioningConfiguration withStatus(String status)
public Boolean isMfaDeleteEnabled()
public void setMfaDeleteEnabled(Boolean mfaDeleteEnabled)
mfaDeleteEnabled
- True if the Multi-Factor Authentication (MFA) Delete is being enabled enabled, false if it is being disabled.public BucketVersioningConfiguration withMfaDeleteEnabled(Boolean mfaDeleteEnabled)
mfaDeleteEnabled
- True if the Multi-Factor Authentication (MFA) Delete is being enabled enabled, false if it is being disabled.Copyright © 2010–2020. All rights reserved.