Class: AWSCDK::SNS::StringConditions
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::SNS::StringConditions
- Defined in:
- sns/string_conditions.rb
Overview
Conditions that can be applied to string attributes.
Instance Attribute Summary collapse
-
#allowlist ⇒ Array<String>?
readonly
Match one or more values.
-
#denylist ⇒ Array<String>?
readonly
Match any value that doesn't include any of the specified values.
-
#match_prefixes ⇒ Array<String>?
readonly
Matches values that begins with the specified prefixes.
-
#match_suffixes ⇒ Array<String>?
readonly
Matches values that end with the specified suffixes.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(allowlist: nil, denylist: nil, match_prefixes: nil, match_suffixes: nil) ⇒ StringConditions
constructor
A new instance of StringConditions.
- #to_jsii ⇒ Object
Constructor Details
#initialize(allowlist: nil, denylist: nil, match_prefixes: nil, match_suffixes: nil) ⇒ StringConditions
Returns a new instance of StringConditions.
11 12 13 14 15 16 17 18 19 20 |
# File 'sns/string_conditions.rb', line 11 def initialize(allowlist: nil, denylist: nil, match_prefixes: nil, match_suffixes: nil) @allowlist = allowlist Jsii::Type.check_type(@allowlist, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "allowlist") unless @allowlist.nil? @denylist = denylist Jsii::Type.check_type(@denylist, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "denylist") unless @denylist.nil? @match_prefixes = match_prefixes Jsii::Type.check_type(@match_prefixes, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "matchPrefixes") unless @match_prefixes.nil? @match_suffixes = match_suffixes Jsii::Type.check_type(@match_suffixes, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "matchSuffixes") unless @match_suffixes.nil? end |
Instance Attribute Details
#allowlist ⇒ Array<String>? (readonly)
Note:
Default: - None
Match one or more values.
26 27 28 |
# File 'sns/string_conditions.rb', line 26 def allowlist @allowlist end |
#denylist ⇒ Array<String>? (readonly)
Note:
Default: - None
Match any value that doesn't include any of the specified values.
31 32 33 |
# File 'sns/string_conditions.rb', line 31 def denylist @denylist end |
#match_prefixes ⇒ Array<String>? (readonly)
Note:
Default: - None
Matches values that begins with the specified prefixes.
36 37 38 |
# File 'sns/string_conditions.rb', line 36 def match_prefixes @match_prefixes end |
#match_suffixes ⇒ Array<String>? (readonly)
Note:
Default: - None
Matches values that end with the specified suffixes.
41 42 43 |
# File 'sns/string_conditions.rb', line 41 def match_suffixes @match_suffixes end |
Class Method Details
.jsii_properties ⇒ Object
43 44 45 46 47 48 49 50 |
# File 'sns/string_conditions.rb', line 43 def self.jsii_properties { :allowlist => "allowlist", :denylist => "denylist", :match_prefixes => "matchPrefixes", :match_suffixes => "matchSuffixes", } end |
Instance Method Details
#to_jsii ⇒ Object
52 53 54 55 56 57 58 59 60 61 |
# File 'sns/string_conditions.rb', line 52 def to_jsii result = {} result.merge!({ "allowlist" => @allowlist, "denylist" => @denylist, "matchPrefixes" => @match_prefixes, "matchSuffixes" => @match_suffixes, }) result.compact end |