Class: AWSCDK::SNS::CfnTopicPolicyProps
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::SNS::CfnTopicPolicyProps
- Defined in:
- sns/cfn_topic_policy_props.rb
Overview
Properties for defining a CfnTopicPolicy.
Instance Attribute Summary collapse
-
#policy_document ⇒ Object
readonly
A policy document that contains permissions to add to the specified SNS topics.
-
#topics ⇒ Array<String>
readonly
The Amazon Resource Names (ARN) of the topics to which you want to add the policy.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(policy_document:, topics:) ⇒ CfnTopicPolicyProps
constructor
A new instance of CfnTopicPolicyProps.
- #to_jsii ⇒ Object
Constructor Details
#initialize(policy_document:, topics:) ⇒ CfnTopicPolicyProps
Returns a new instance of CfnTopicPolicyProps.
11 12 13 14 15 16 |
# File 'sns/cfn_topic_policy_props.rb', line 11 def initialize(policy_document:, topics:) @policy_document = policy_document Jsii::Type.check_type(@policy_document, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJhbnkifQ==")), "policyDocument") @topics = topics Jsii::Type.check_type(@topics, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "topics") end |
Instance Attribute Details
#policy_document ⇒ Object (readonly)
A policy document that contains permissions to add to the specified SNS topics.
22 23 24 |
# File 'sns/cfn_topic_policy_props.rb', line 22 def policy_document @policy_document end |
#topics ⇒ Array<String> (readonly)
The Amazon Resource Names (ARN) of the topics to which you want to add the policy.
You can use the [Ref](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/intrinsic-function-reference-ref.html) function to specify an [AWS::SNS::Topic](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-sns-topic.html) resource.
29 30 31 |
# File 'sns/cfn_topic_policy_props.rb', line 29 def topics @topics end |
Class Method Details
.jsii_properties ⇒ Object
31 32 33 34 35 36 |
# File 'sns/cfn_topic_policy_props.rb', line 31 def self.jsii_properties { :policy_document => "policyDocument", :topics => "topics", } end |
Instance Method Details
#to_jsii ⇒ Object
38 39 40 41 42 43 44 45 |
# File 'sns/cfn_topic_policy_props.rb', line 38 def to_jsii result = {} result.merge!({ "policyDocument" => @policy_document, "topics" => @topics, }) result.compact end |