Class: AWSCDK::SNS::NumericConditions
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::SNS::NumericConditions
- Defined in:
- sns/numeric_conditions.rb
Overview
Conditions that can be applied to numeric attributes.
Instance Attribute Summary collapse
-
#allowlist ⇒ Array<Numeric>?
readonly
Match one or more values.
-
#between ⇒ AWSCDK::SNS::BetweenCondition?
readonly
Match values that are between the specified values.
-
#between_strict ⇒ AWSCDK::SNS::BetweenCondition?
readonly
Match values that are strictly between the specified values.
-
#greater_than ⇒ Numeric?
readonly
Match values that are greater than the specified value.
-
#greater_than_or_equal_to ⇒ Numeric?
readonly
Match values that are greater than or equal to the specified value.
-
#less_than ⇒ Numeric?
readonly
Match values that are less than the specified value.
-
#less_than_or_equal_to ⇒ Numeric?
readonly
Match values that are less than or equal to the specified value.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(allowlist: nil, between: nil, between_strict: nil, greater_than: nil, greater_than_or_equal_to: nil, less_than: nil, less_than_or_equal_to: nil) ⇒ NumericConditions
constructor
A new instance of NumericConditions.
- #to_jsii ⇒ Object
Constructor Details
#initialize(allowlist: nil, between: nil, between_strict: nil, greater_than: nil, greater_than_or_equal_to: nil, less_than: nil, less_than_or_equal_to: nil) ⇒ NumericConditions
Returns a new instance of NumericConditions.
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 |
# File 'sns/numeric_conditions.rb', line 14 def initialize(allowlist: nil, between: nil, between_strict: nil, greater_than: nil, greater_than_or_equal_to: nil, less_than: nil, less_than_or_equal_to: nil) @allowlist = allowlist Jsii::Type.check_type(@allowlist, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6Im51bWJlciJ9LCJraW5kIjoiYXJyYXkifX0=")), "allowlist") unless @allowlist.nil? @between = between.is_a?(Hash) ? ::AWSCDK::SNS::BetweenCondition.new(**between.transform_keys(&:to_sym)) : between Jsii::Type.check_type(@between, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3Nfc25zLkJldHdlZW5Db25kaXRpb24ifQ==")), "between") unless @between.nil? @between_strict = between_strict.is_a?(Hash) ? ::AWSCDK::SNS::BetweenCondition.new(**between_strict.transform_keys(&:to_sym)) : between_strict Jsii::Type.check_type(@between_strict, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3Nfc25zLkJldHdlZW5Db25kaXRpb24ifQ==")), "betweenStrict") unless @between_strict.nil? @greater_than = greater_than Jsii::Type.check_type(@greater_than, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "greaterThan") unless @greater_than.nil? @greater_than_or_equal_to = greater_than_or_equal_to Jsii::Type.check_type(@greater_than_or_equal_to, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "greaterThanOrEqualTo") unless @greater_than_or_equal_to.nil? @less_than = less_than Jsii::Type.check_type(@less_than, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "lessThan") unless @less_than.nil? @less_than_or_equal_to = less_than_or_equal_to Jsii::Type.check_type(@less_than_or_equal_to, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "lessThanOrEqualTo") unless @less_than_or_equal_to.nil? end |
Instance Attribute Details
#allowlist ⇒ Array<Numeric>? (readonly)
Default: - None
Match one or more values.
35 36 37 |
# File 'sns/numeric_conditions.rb', line 35 def allowlist @allowlist end |
#between ⇒ AWSCDK::SNS::BetweenCondition? (readonly)
Default: - None
Match values that are between the specified values.
40 41 42 |
# File 'sns/numeric_conditions.rb', line 40 def between @between end |
#between_strict ⇒ AWSCDK::SNS::BetweenCondition? (readonly)
Default: - None
Match values that are strictly between the specified values.
45 46 47 |
# File 'sns/numeric_conditions.rb', line 45 def between_strict @between_strict end |
#greater_than ⇒ Numeric? (readonly)
Default: - None
Match values that are greater than the specified value.
50 51 52 |
# File 'sns/numeric_conditions.rb', line 50 def greater_than @greater_than end |
#greater_than_or_equal_to ⇒ Numeric? (readonly)
Default: - None
Match values that are greater than or equal to the specified value.
55 56 57 |
# File 'sns/numeric_conditions.rb', line 55 def greater_than_or_equal_to @greater_than_or_equal_to end |
#less_than ⇒ Numeric? (readonly)
Default: - None
Match values that are less than the specified value.
60 61 62 |
# File 'sns/numeric_conditions.rb', line 60 def less_than @less_than end |
#less_than_or_equal_to ⇒ Numeric? (readonly)
Default: - None
Match values that are less than or equal to the specified value.
65 66 67 |
# File 'sns/numeric_conditions.rb', line 65 def less_than_or_equal_to @less_than_or_equal_to end |
Class Method Details
.jsii_properties ⇒ Object
67 68 69 70 71 72 73 74 75 76 77 |
# File 'sns/numeric_conditions.rb', line 67 def self.jsii_properties { :allowlist => "allowlist", :between => "between", :between_strict => "betweenStrict", :greater_than => "greaterThan", :greater_than_or_equal_to => "greaterThanOrEqualTo", :less_than => "lessThan", :less_than_or_equal_to => "lessThanOrEqualTo", } end |
Instance Method Details
#to_jsii ⇒ Object
79 80 81 82 83 84 85 86 87 88 89 90 91 |
# File 'sns/numeric_conditions.rb', line 79 def to_jsii result = {} result.merge!({ "allowlist" => @allowlist, "between" => @between, "betweenStrict" => @between_strict, "greaterThan" => @greater_than, "greaterThanOrEqualTo" => @greater_than_or_equal_to, "lessThan" => @less_than, "lessThanOrEqualTo" => @less_than_or_equal_to, }) result.compact end |