Class: AWSCDK::SQS::CfnQueuePolicyProps

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
sqs/cfn_queue_policy_props.rb

Overview

Properties for defining a CfnQueuePolicy.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(policy_document:, queues:) ⇒ CfnQueuePolicyProps

Returns a new instance of CfnQueuePolicyProps.

Parameters:

  • policy_document (Object)

    A policy document that contains the permissions for the specified Amazon SQS queues.

  • queues (Array<String>)

    The URLs of the queues to which you want to add the policy.



11
12
13
14
15
16
# File 'sqs/cfn_queue_policy_props.rb', line 11

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

Instance Attribute Details

#policy_documentObject (readonly)

A policy document that contains the permissions for the specified Amazon SQS queues.

For more information about Amazon SQS policies, see Using custom policies with the Amazon SQS access policy language in the Amazon SQS Developer Guide .



24
25
26
# File 'sqs/cfn_queue_policy_props.rb', line 24

def policy_document
  @policy_document
end

#queuesArray<String> (readonly)

The URLs of the queues 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::SQS::Queue](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-sqs-queue.html) resource.



31
32
33
# File 'sqs/cfn_queue_policy_props.rb', line 31

def queues
  @queues
end

Class Method Details

.jsii_propertiesObject



33
34
35
36
37
38
# File 'sqs/cfn_queue_policy_props.rb', line 33

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

Instance Method Details

#to_jsiiObject



40
41
42
43
44
45
46
47
# File 'sqs/cfn_queue_policy_props.rb', line 40

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