Class: AWSCDK::IoTEvents::CfnAlarmModel::AssetPropertyVariantProperty
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::IoTEvents::CfnAlarmModel::AssetPropertyVariantProperty
- Defined in:
- io_t_events/cfn_alarm_model.rb
Overview
A structure that contains an asset property value.
For more information, see Variant in the AWS IoT SiteWise API Reference .
You must use expressions for all parameters in AssetPropertyVariant . The expressions accept literals, operators, functions, references, and substitution templates.
Examples - For literal values, the expressions must contain single quotes. For example, the value for the integer_value parameter can be '100' .
- For references, you must specify either variables or parameters. For example, the value for the
boolean_valueparameter can be$variable.offline. - For a substitution template, you must use
${}, and the template must be in single quotes. A substitution template can also contain a combination of literals, operators, functions, references, and substitution templates.
In the following example, the value for the double_value parameter uses a substitution template.
'${$input.TemperatureInput.sensorData.temperature * 6 / 5 + 32}'
For more information, see Expressions in the AWS IoT Events Developer Guide .
You must specify one of the following value types, depending on the data_type of the specified asset property. For more information, see AssetProperty in the AWS IoT SiteWise API Reference .
Instance Attribute Summary collapse
-
#boolean_value ⇒ String?
readonly
The asset property value is a Boolean value that must be
'TRUE'or'FALSE'. -
#double_value ⇒ String?
readonly
The asset property value is a double.
-
#integer_value ⇒ String?
readonly
The asset property value is an integer.
-
#string_value ⇒ String?
readonly
The asset property value is a string.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(boolean_value: nil, double_value: nil, integer_value: nil, string_value: nil) ⇒ AssetPropertyVariantProperty
constructor
A new instance of AssetPropertyVariantProperty.
- #to_jsii ⇒ Object
Constructor Details
#initialize(boolean_value: nil, double_value: nil, integer_value: nil, string_value: nil) ⇒ AssetPropertyVariantProperty
Returns a new instance of AssetPropertyVariantProperty.
1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 |
# File 'io_t_events/cfn_alarm_model.rb', line 1096 def initialize(boolean_value: nil, double_value: nil, integer_value: nil, string_value: nil) @boolean_value = boolean_value Jsii::Type.check_type(@boolean_value, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "booleanValue") unless @boolean_value.nil? @double_value = double_value Jsii::Type.check_type(@double_value, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "doubleValue") unless @double_value.nil? @integer_value = integer_value Jsii::Type.check_type(@integer_value, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "integerValue") unless @integer_value.nil? @string_value = string_value Jsii::Type.check_type(@string_value, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "stringValue") unless @string_value.nil? end |
Instance Attribute Details
#boolean_value ⇒ String? (readonly)
The asset property value is a Boolean value that must be 'TRUE' or 'FALSE' .
You must use an expression, and the evaluated result should be a Boolean value.
1113 1114 1115 |
# File 'io_t_events/cfn_alarm_model.rb', line 1113 def boolean_value @boolean_value end |
#double_value ⇒ String? (readonly)
The asset property value is a double.
You must use an expression, and the evaluated result should be a double.
1120 1121 1122 |
# File 'io_t_events/cfn_alarm_model.rb', line 1120 def double_value @double_value end |
#integer_value ⇒ String? (readonly)
The asset property value is an integer.
You must use an expression, and the evaluated result should be an integer.
1127 1128 1129 |
# File 'io_t_events/cfn_alarm_model.rb', line 1127 def integer_value @integer_value end |
#string_value ⇒ String? (readonly)
The asset property value is a string.
You must use an expression, and the evaluated result should be a string.
1134 1135 1136 |
# File 'io_t_events/cfn_alarm_model.rb', line 1134 def string_value @string_value end |
Class Method Details
.jsii_properties ⇒ Object
1136 1137 1138 1139 1140 1141 1142 1143 |
# File 'io_t_events/cfn_alarm_model.rb', line 1136 def self.jsii_properties { :boolean_value => "booleanValue", :double_value => "doubleValue", :integer_value => "integerValue", :string_value => "stringValue", } end |
Instance Method Details
#to_jsii ⇒ Object
1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 |
# File 'io_t_events/cfn_alarm_model.rb', line 1145 def to_jsii result = {} result.merge!({ "booleanValue" => @boolean_value, "doubleValue" => @double_value, "integerValue" => @integer_value, "stringValue" => @string_value, }) result.compact end |