Class: AWSCDK::Logs::RenameKeyEntryProperty
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::Logs::RenameKeyEntryProperty
- Defined in:
- logs/rename_key_entry_property.rb
Overview
This object defines one key that will be renamed with the renameKey processor.
Instance Attribute Summary collapse
-
#key ⇒ String
readonly
The key to rename.
-
#overwrite_if_exists ⇒ Boolean?
readonly
Whether to overwrite the target key if it already exists.
-
#rename_to ⇒ String
readonly
The string to use for the new key name.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(key:, rename_to:, overwrite_if_exists: nil) ⇒ RenameKeyEntryProperty
constructor
A new instance of RenameKeyEntryProperty.
- #to_jsii ⇒ Object
Constructor Details
#initialize(key:, rename_to:, overwrite_if_exists: nil) ⇒ RenameKeyEntryProperty
Returns a new instance of RenameKeyEntryProperty.
10 11 12 13 14 15 16 17 |
# File 'logs/rename_key_entry_property.rb', line 10 def initialize(key:, rename_to:, overwrite_if_exists: nil) @key = key Jsii::Type.check_type(@key, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "key") @rename_to = rename_to Jsii::Type.check_type(@rename_to, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "renameTo") @overwrite_if_exists = overwrite_if_exists Jsii::Type.check_type(@overwrite_if_exists, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJib29sZWFuIn0=")), "overwriteIfExists") unless @overwrite_if_exists.nil? end |
Instance Attribute Details
#key ⇒ String (readonly)
The key to rename.
22 23 24 |
# File 'logs/rename_key_entry_property.rb', line 22 def key @key end |
#overwrite_if_exists ⇒ Boolean? (readonly)
Note:
Default: false
Whether to overwrite the target key if it already exists.
31 32 33 |
# File 'logs/rename_key_entry_property.rb', line 31 def overwrite_if_exists @overwrite_if_exists end |
#rename_to ⇒ String (readonly)
The string to use for the new key name.
26 27 28 |
# File 'logs/rename_key_entry_property.rb', line 26 def rename_to @rename_to end |
Class Method Details
.jsii_properties ⇒ Object
33 34 35 36 37 38 39 |
# File 'logs/rename_key_entry_property.rb', line 33 def self.jsii_properties { :key => "key", :rename_to => "renameTo", :overwrite_if_exists => "overwriteIfExists", } end |
Instance Method Details
#to_jsii ⇒ Object
41 42 43 44 45 46 47 48 49 |
# File 'logs/rename_key_entry_property.rb', line 41 def to_jsii result = {} result.merge!({ "key" => @key, "renameTo" => @rename_to, "overwriteIfExists" => @overwrite_if_exists, }) result.compact end |