Class: AWSCDK::S3::CfnBucket::NoncurrentVersionExpirationProperty
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::S3::CfnBucket::NoncurrentVersionExpirationProperty
- Defined in:
- s3/cfn_bucket.rb
Overview
Specifies when noncurrent object versions expire.
Upon expiration, Amazon S3 permanently deletes the noncurrent object versions. You set this lifecycle configuration action on a bucket that has versioning enabled (or suspended) to request that Amazon S3 delete noncurrent object versions at a specific period in the object's lifetime. For more information about setting a lifecycle rule configuration, see AWS::S3::Bucket Rule .
Instance Attribute Summary collapse
-
#newer_noncurrent_versions ⇒ Numeric?
readonly
Specifies how many noncurrent versions Amazon S3 will retain.
-
#noncurrent_days ⇒ Numeric
readonly
Specifies the number of days an object is noncurrent before Amazon S3 can perform the associated action.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(noncurrent_days:, newer_noncurrent_versions: nil) ⇒ NoncurrentVersionExpirationProperty
constructor
A new instance of NoncurrentVersionExpirationProperty.
- #to_jsii ⇒ Object
Constructor Details
#initialize(noncurrent_days:, newer_noncurrent_versions: nil) ⇒ NoncurrentVersionExpirationProperty
Returns a new instance of NoncurrentVersionExpirationProperty.
2572 2573 2574 2575 2576 2577 |
# File 's3/cfn_bucket.rb', line 2572 def initialize(noncurrent_days:, newer_noncurrent_versions: nil) @noncurrent_days = noncurrent_days Jsii::Type.check_type(@noncurrent_days, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "noncurrentDays") @newer_noncurrent_versions = newer_noncurrent_versions Jsii::Type.check_type(@newer_noncurrent_versions, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "newerNoncurrentVersions") unless @newer_noncurrent_versions.nil? end |
Instance Attribute Details
#newer_noncurrent_versions ⇒ Numeric? (readonly)
Specifies how many noncurrent versions Amazon S3 will retain.
If there are this many more recent noncurrent versions, Amazon S3 will take the associated action. For more information about noncurrent versions, see Lifecycle configuration elements in the Amazon S3 User Guide .
2592 2593 2594 |
# File 's3/cfn_bucket.rb', line 2592 def newer_noncurrent_versions @newer_noncurrent_versions end |
#noncurrent_days ⇒ Numeric (readonly)
Specifies the number of days an object is noncurrent before Amazon S3 can perform the associated action.
For information about the noncurrent days calculations, see How Amazon S3 Calculates When an Object Became Noncurrent in the Amazon S3 User Guide .
2585 2586 2587 |
# File 's3/cfn_bucket.rb', line 2585 def noncurrent_days @noncurrent_days end |
Class Method Details
.jsii_properties ⇒ Object
2594 2595 2596 2597 2598 2599 |
# File 's3/cfn_bucket.rb', line 2594 def self.jsii_properties { :noncurrent_days => "noncurrentDays", :newer_noncurrent_versions => "newerNoncurrentVersions", } end |
Instance Method Details
#to_jsii ⇒ Object
2601 2602 2603 2604 2605 2606 2607 2608 |
# File 's3/cfn_bucket.rb', line 2601 def to_jsii result = {} result.merge!({ "noncurrentDays" => @noncurrent_days, "newerNoncurrentVersions" => @newer_noncurrent_versions, }) result.compact end |