Class: AWSCDK::AppSync::CfnChannelNamespaceProps
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::AppSync::CfnChannelNamespaceProps
- Defined in:
- app_sync/cfn_channel_namespace_props.rb
Overview
Properties for defining a CfnChannelNamespace.
Instance Attribute Summary collapse
-
#api_id ⇒ String
readonly
The
ApiID. -
#code_handlers ⇒ String?
readonly
The event handler functions that run custom business logic to process published events and subscribe requests.
-
#code_s3_location ⇒ String?
readonly
The Amazon S3 endpoint where the code is located.
-
#handler_configs ⇒ AWSCDK::IResolvable, ...
readonly
The configuration for the
OnPublishandOnSubscribehandlers. -
#name ⇒ String
readonly
The name of the channel namespace.
-
#publish_auth_modes ⇒ AWSCDK::IResolvable, ...
readonly
The authorization mode to use for publishing messages on the channel namespace.
-
#subscribe_auth_modes ⇒ AWSCDK::IResolvable, ...
readonly
The authorization mode to use for subscribing to messages on the channel namespace.
-
#tags ⇒ Array<AWSCDK::CfnTag>?
readonly
A set of tags (key-value pairs) for this channel namespace.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(api_id:, name:, code_handlers: nil, code_s3_location: nil, handler_configs: nil, publish_auth_modes: nil, subscribe_auth_modes: nil, tags: nil) ⇒ CfnChannelNamespaceProps
constructor
A new instance of CfnChannelNamespaceProps.
- #to_jsii ⇒ Object
Constructor Details
#initialize(api_id:, name:, code_handlers: nil, code_s3_location: nil, handler_configs: nil, publish_auth_modes: nil, subscribe_auth_modes: nil, tags: nil) ⇒ CfnChannelNamespaceProps
Returns a new instance of CfnChannelNamespaceProps.
17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 |
# File 'app_sync/cfn_channel_namespace_props.rb', line 17 def initialize(api_id:, name:, code_handlers: nil, code_s3_location: nil, handler_configs: nil, publish_auth_modes: nil, subscribe_auth_modes: nil, tags: nil) @api_id = api_id Jsii::Type.check_type(@api_id, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "apiId") @name = name Jsii::Type.check_type(@name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "name") @code_handlers = code_handlers Jsii::Type.check_type(@code_handlers, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "codeHandlers") unless @code_handlers.nil? @code_s3_location = code_s3_location Jsii::Type.check_type(@code_s3_location, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "codeS3Location") unless @code_s3_location.nil? @handler_configs = handler_configs.is_a?(Hash) ? ::AWSCDK::AppSync::CfnChannelNamespace::HandlerConfigsProperty.new(**handler_configs.transform_keys(&:to_sym)) : handler_configs Jsii::Type.check_type(@handler_configs, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19hcHBzeW5jLkNmbkNoYW5uZWxOYW1lc3BhY2UuSGFuZGxlckNvbmZpZ3NQcm9wZXJ0eSJ9XX19")), "handlerConfigs") unless @handler_configs.nil? @publish_auth_modes = publish_auth_modes Jsii::Type.check_type(@publish_auth_modes, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImNvbGxlY3Rpb24iOnsiZWxlbWVudHR5cGUiOnsidW5pb24iOnsidHlwZXMiOlt7ImZxbiI6ImF3cy1jZGstbGliLklSZXNvbHZhYmxlIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfYXBwc3luYy5DZm5DaGFubmVsTmFtZXNwYWNlLkF1dGhNb2RlUHJvcGVydHkifV19fSwia2luZCI6ImFycmF5In19XX19")), "publishAuthModes") unless @publish_auth_modes.nil? @subscribe_auth_modes = subscribe_auth_modes Jsii::Type.check_type(@subscribe_auth_modes, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImNvbGxlY3Rpb24iOnsiZWxlbWVudHR5cGUiOnsidW5pb24iOnsidHlwZXMiOlt7ImZxbiI6ImF3cy1jZGstbGliLklSZXNvbHZhYmxlIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfYXBwc3luYy5DZm5DaGFubmVsTmFtZXNwYWNlLkF1dGhNb2RlUHJvcGVydHkifV19fSwia2luZCI6ImFycmF5In19XX19")), "subscribeAuthModes") unless @subscribe_auth_modes.nil? @tags = .is_a?(Array) ? .map { |jsii_v0| jsii_v0.is_a?(Hash) ? ::AWSCDK::CfnTag.new(**jsii_v0.transform_keys(&:to_sym)) : jsii_v0 } : Jsii::Type.check_type(@tags, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7ImZxbiI6ImF3cy1jZGstbGliLkNmblRhZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "tags") unless @tags.nil? end |
Instance Attribute Details
#api_id ⇒ String (readonly)
The Api ID.
40 41 42 |
# File 'app_sync/cfn_channel_namespace_props.rb', line 40 def api_id @api_id end |
#code_handlers ⇒ String? (readonly)
The event handler functions that run custom business logic to process published events and subscribe requests.
52 53 54 |
# File 'app_sync/cfn_channel_namespace_props.rb', line 52 def code_handlers @code_handlers end |
#code_s3_location ⇒ String? (readonly)
The Amazon S3 endpoint where the code is located.
57 58 59 |
# File 'app_sync/cfn_channel_namespace_props.rb', line 57 def code_s3_location @code_s3_location end |
#handler_configs ⇒ AWSCDK::IResolvable, ... (readonly)
The configuration for the OnPublish and OnSubscribe handlers.
62 63 64 |
# File 'app_sync/cfn_channel_namespace_props.rb', line 62 def handler_configs @handler_configs end |
#name ⇒ String (readonly)
The name of the channel namespace.
This name must be unique within the Api .
47 48 49 |
# File 'app_sync/cfn_channel_namespace_props.rb', line 47 def name @name end |
#publish_auth_modes ⇒ AWSCDK::IResolvable, ... (readonly)
The authorization mode to use for publishing messages on the channel namespace.
This configuration overrides the default Api authorization configuration.
69 70 71 |
# File 'app_sync/cfn_channel_namespace_props.rb', line 69 def publish_auth_modes @publish_auth_modes end |
#subscribe_auth_modes ⇒ AWSCDK::IResolvable, ... (readonly)
The authorization mode to use for subscribing to messages on the channel namespace.
This configuration overrides the default Api authorization configuration.
76 77 78 |
# File 'app_sync/cfn_channel_namespace_props.rb', line 76 def subscribe_auth_modes @subscribe_auth_modes end |
#tags ⇒ Array<AWSCDK::CfnTag>? (readonly)
A set of tags (key-value pairs) for this channel namespace.
81 82 83 |
# File 'app_sync/cfn_channel_namespace_props.rb', line 81 def @tags end |
Class Method Details
.jsii_properties ⇒ Object
83 84 85 86 87 88 89 90 91 92 93 94 |
# File 'app_sync/cfn_channel_namespace_props.rb', line 83 def self.jsii_properties { :api_id => "apiId", :name => "name", :code_handlers => "codeHandlers", :code_s3_location => "codeS3Location", :handler_configs => "handlerConfigs", :publish_auth_modes => "publishAuthModes", :subscribe_auth_modes => "subscribeAuthModes", :tags => "tags", } end |
Instance Method Details
#to_jsii ⇒ Object
96 97 98 99 100 101 102 103 104 105 106 107 108 109 |
# File 'app_sync/cfn_channel_namespace_props.rb', line 96 def to_jsii result = {} result.merge!({ "apiId" => @api_id, "name" => @name, "codeHandlers" => @code_handlers, "codeS3Location" => @code_s3_location, "handlerConfigs" => @handler_configs, "publishAuthModes" => @publish_auth_modes, "subscribeAuthModes" => @subscribe_auth_modes, "tags" => @tags, }) result.compact end |