Class CfnBucket.DefaultRetentionProperty
The container element for optionally specifying the default Object Lock retention settings for new objects placed in the specified bucket.
Inheritance
Implements
Namespace: Amazon.CDK.AWS.S3
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class DefaultRetentionProperty : Object, CfnBucket.IDefaultRetentionProperty
Syntax (vb)
Public Class DefaultRetentionProperty
Inherits Object
Implements CfnBucket.IDefaultRetentionProperty
Remarks
ExampleMetadata: fixture=_generated
Examples
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.S3;
var defaultRetentionProperty = new DefaultRetentionProperty {
Days = 123,
Mode = "mode",
Years = 123
};
Synopsis
Constructors
DefaultRetentionProperty() |
Properties
Days | The number of days that you want to specify for the default retention period. |
Mode | The default Object Lock retention mode you want to apply to new objects placed in the specified bucket. |
Years | The number of years that you want to specify for the default retention period. |
Constructors
DefaultRetentionProperty()
public DefaultRetentionProperty()
Properties
Days
The number of days that you want to specify for the default retention period.
public Nullable<double> Days { get; set; }
Property Value
System.Nullable<System.Double>
Remarks
If Object Lock is turned on, you must specify Mode
and specify either Days
or Years
.
Mode
The default Object Lock retention mode you want to apply to new objects placed in the specified bucket.
public string Mode { get; set; }
Property Value
System.String
Remarks
If Object Lock is turned on, you must specify Mode
and specify either Days
or Years
.
Years
The number of years that you want to specify for the default retention period.
public Nullable<double> Years { get; set; }
Property Value
System.Nullable<System.Double>
Remarks
If Object Lock is turned on, you must specify Mode
and specify either Days
or Years
.