Class: AWSCDK::SMSVoice::CfnResourcePolicyProps

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
sms_voice/cfn_resource_policy_props.rb

Overview

Properties for defining a CfnResourcePolicy.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(policy_document:, resource_arn:) ⇒ CfnResourcePolicyProps

Returns a new instance of CfnResourcePolicyProps.

Parameters:

  • policy_document (Object)

    The JSON formatted resource-based policy to attach.

  • resource_arn (String)

    The Amazon Resource Name (ARN) of the End User Messaging resource attached to the resource-based policy.



11
12
13
14
15
16
# File 'sms_voice/cfn_resource_policy_props.rb', line 11

def initialize(policy_document:, resource_arn:)
  @policy_document = policy_document
  Jsii::Type.check_type(@policy_document, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJhbnkifQ==")), "policyDocument")
  @resource_arn = resource_arn
  Jsii::Type.check_type(@resource_arn, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "resourceArn")
end

Instance Attribute Details

#policy_documentObject (readonly)

The JSON formatted resource-based policy to attach.



22
23
24
# File 'sms_voice/cfn_resource_policy_props.rb', line 22

def policy_document
  @policy_document
end

#resource_arnString (readonly)

The Amazon Resource Name (ARN) of the End User Messaging resource attached to the resource-based policy.



27
28
29
# File 'sms_voice/cfn_resource_policy_props.rb', line 27

def resource_arn
  @resource_arn
end

Class Method Details

.jsii_propertiesObject



29
30
31
32
33
34
# File 'sms_voice/cfn_resource_policy_props.rb', line 29

def self.jsii_properties
  {
    :policy_document => "policyDocument",
    :resource_arn => "resourceArn",
  }
end

Instance Method Details

#to_jsiiObject



36
37
38
39
40
41
42
43
# File 'sms_voice/cfn_resource_policy_props.rb', line 36

def to_jsii
  result = {}
  result.merge!({
    "policyDocument" => @policy_document,
    "resourceArn" => @resource_arn,
  })
  result.compact
end