Class: AWSCDK::SNS::TopicAttributes
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::SNS::TopicAttributes
- Defined in:
- sns/topic_attributes.rb
Overview
Represents an SNS topic defined outside of this stack.
Instance Attribute Summary collapse
-
#content_based_deduplication ⇒ Boolean?
readonly
Whether content-based deduplication is enabled.
-
#key_arn ⇒ String?
readonly
KMS encryption key, if this topic is server-side encrypted by a KMS key.
-
#topic_arn ⇒ String
readonly
The ARN of the SNS topic.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(topic_arn:, content_based_deduplication: nil, key_arn: nil) ⇒ TopicAttributes
constructor
A new instance of TopicAttributes.
- #to_jsii ⇒ Object
Constructor Details
#initialize(topic_arn:, content_based_deduplication: nil, key_arn: nil) ⇒ TopicAttributes
Returns a new instance of TopicAttributes.
10 11 12 13 14 15 16 17 |
# File 'sns/topic_attributes.rb', line 10 def initialize(topic_arn:, content_based_deduplication: nil, key_arn: nil) @topic_arn = topic_arn Jsii::Type.check_type(@topic_arn, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "topicArn") @content_based_deduplication = content_based_deduplication Jsii::Type.check_type(@content_based_deduplication, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJib29sZWFuIn0=")), "contentBasedDeduplication") unless @content_based_deduplication.nil? @key_arn = key_arn Jsii::Type.check_type(@key_arn, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "keyArn") unless @key_arn.nil? end |
Instance Attribute Details
#content_based_deduplication ⇒ Boolean? (readonly)
Note:
Default: false
Whether content-based deduplication is enabled.
Only applicable for FIFO topics.
29 30 31 |
# File 'sns/topic_attributes.rb', line 29 def content_based_deduplication @content_based_deduplication end |
#key_arn ⇒ String? (readonly)
Note:
Default: - None
KMS encryption key, if this topic is server-side encrypted by a KMS key.
34 35 36 |
# File 'sns/topic_attributes.rb', line 34 def key_arn @key_arn end |
#topic_arn ⇒ String (readonly)
The ARN of the SNS topic.
22 23 24 |
# File 'sns/topic_attributes.rb', line 22 def topic_arn @topic_arn end |
Class Method Details
.jsii_properties ⇒ Object
36 37 38 39 40 41 42 |
# File 'sns/topic_attributes.rb', line 36 def self.jsii_properties { :topic_arn => "topicArn", :content_based_deduplication => "contentBasedDeduplication", :key_arn => "keyArn", } end |
Instance Method Details
#to_jsii ⇒ Object
44 45 46 47 48 49 50 51 52 |
# File 'sns/topic_attributes.rb', line 44 def to_jsii result = {} result.merge!({ "topicArn" => @topic_arn, "contentBasedDeduplication" => @content_based_deduplication, "keyArn" => @key_arn, }) result.compact end |