Class: AWSCDK::Lex::CfnBot::SlotProperty
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::Lex::CfnBot::SlotProperty
- Defined in:
- lex/cfn_bot.rb
Overview
Specifies the definition of a slot.
Amazon Lex elicits slot values from uses to fulfill the user's intent.
Instance Attribute Summary collapse
-
#description ⇒ String?
readonly
The description of the slot.
-
#multiple_values_setting ⇒ AWSCDK::IResolvable, ...
readonly
Indicates whether a slot can return multiple values.
-
#name ⇒ String
readonly
The name given to the slot.
-
#obfuscation_setting ⇒ AWSCDK::IResolvable, ...
readonly
Determines whether the contents of the slot are obfuscated in Amazon CloudWatch Logs logs.
-
#slot_type_name ⇒ String
readonly
The name of the slot type that this slot is based on.
- #sub_slot_setting ⇒ AWSCDK::IResolvable, ... readonly
-
#value_elicitation_setting ⇒ AWSCDK::IResolvable, AWSCDK::Lex::CfnBot::SlotValueElicitationSettingProperty
readonly
Determines the slot resolution strategy that Amazon Lex uses to return slot type values.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(name:, slot_type_name:, value_elicitation_setting:, description: nil, multiple_values_setting: nil, obfuscation_setting: nil, sub_slot_setting: nil) ⇒ SlotProperty
constructor
A new instance of SlotProperty.
- #to_jsii ⇒ Object
Constructor Details
#initialize(name:, slot_type_name:, value_elicitation_setting:, description: nil, multiple_values_setting: nil, obfuscation_setting: nil, sub_slot_setting: nil) ⇒ SlotProperty
Returns a new instance of SlotProperty.
5457 5458 5459 5460 5461 5462 5463 5464 5465 5466 5467 5468 5469 5470 5471 5472 |
# File 'lex/cfn_bot.rb', line 5457 def initialize(name:, slot_type_name:, value_elicitation_setting:, description: nil, multiple_values_setting: nil, obfuscation_setting: nil, sub_slot_setting: nil) @name = name Jsii::Type.check_type(@name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "name") @slot_type_name = slot_type_name Jsii::Type.check_type(@slot_type_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "slotTypeName") @value_elicitation_setting = value_elicitation_setting.is_a?(Hash) ? ::AWSCDK::Lex::CfnBot::SlotValueElicitationSettingProperty.new(**value_elicitation_setting.transform_keys(&:to_sym)) : value_elicitation_setting Jsii::Type.check_type(@value_elicitation_setting, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19sZXguQ2ZuQm90LlNsb3RWYWx1ZUVsaWNpdGF0aW9uU2V0dGluZ1Byb3BlcnR5In1dfX0=")), "valueElicitationSetting") @description = description Jsii::Type.check_type(@description, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "description") unless @description.nil? @multiple_values_setting = multiple_values_setting.is_a?(Hash) ? ::AWSCDK::Lex::CfnBot::MultipleValuesSettingProperty.new(**multiple_values_setting.transform_keys(&:to_sym)) : multiple_values_setting Jsii::Type.check_type(@multiple_values_setting, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19sZXguQ2ZuQm90Lk11bHRpcGxlVmFsdWVzU2V0dGluZ1Byb3BlcnR5In1dfX0=")), "multipleValuesSetting") unless @multiple_values_setting.nil? @obfuscation_setting = obfuscation_setting.is_a?(Hash) ? ::AWSCDK::Lex::CfnBot::ObfuscationSettingProperty.new(**obfuscation_setting.transform_keys(&:to_sym)) : obfuscation_setting Jsii::Type.check_type(@obfuscation_setting, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19sZXguQ2ZuQm90Lk9iZnVzY2F0aW9uU2V0dGluZ1Byb3BlcnR5In1dfX0=")), "obfuscationSetting") unless @obfuscation_setting.nil? @sub_slot_setting = sub_slot_setting.is_a?(Hash) ? ::AWSCDK::Lex::CfnBot::SubSlotSettingProperty.new(**sub_slot_setting.transform_keys(&:to_sym)) : sub_slot_setting Jsii::Type.check_type(@sub_slot_setting, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19sZXguQ2ZuQm90LlN1YlNsb3RTZXR0aW5nUHJvcGVydHkifV19fQ==")), "subSlotSetting") unless @sub_slot_setting.nil? end |
Instance Attribute Details
#description ⇒ String? (readonly)
The description of the slot.
5502 5503 5504 |
# File 'lex/cfn_bot.rb', line 5502 def description @description end |
#multiple_values_setting ⇒ AWSCDK::IResolvable, ... (readonly)
Indicates whether a slot can return multiple values.
5507 5508 5509 |
# File 'lex/cfn_bot.rb', line 5507 def multiple_values_setting @multiple_values_setting end |
#name ⇒ String (readonly)
The name given to the slot.
5478 5479 5480 |
# File 'lex/cfn_bot.rb', line 5478 def name @name end |
#obfuscation_setting ⇒ AWSCDK::IResolvable, ... (readonly)
Determines whether the contents of the slot are obfuscated in Amazon CloudWatch Logs logs.
Use obfuscated slots to protect information such as personally identifiable information (PII) in logs.
5514 5515 5516 |
# File 'lex/cfn_bot.rb', line 5514 def obfuscation_setting @obfuscation_setting end |
#slot_type_name ⇒ String (readonly)
The name of the slot type that this slot is based on.
The slot type defines the acceptable values for the slot.
5485 5486 5487 |
# File 'lex/cfn_bot.rb', line 5485 def slot_type_name @slot_type_name end |
#sub_slot_setting ⇒ AWSCDK::IResolvable, ... (readonly)
5517 5518 5519 |
# File 'lex/cfn_bot.rb', line 5517 def sub_slot_setting @sub_slot_setting end |
#value_elicitation_setting ⇒ AWSCDK::IResolvable, AWSCDK::Lex::CfnBot::SlotValueElicitationSettingProperty (readonly)
Determines the slot resolution strategy that Amazon Lex uses to return slot type values.
The field can be set to one of the following values:
- ORIGINAL_VALUE - Returns the value entered by the user, if the user value is similar to a slot value.
- TOP_RESOLUTION - If there is a resolution list for the slot, return the first value in the resolution list as the slot type value. If there is no resolution list, null is returned.
If you don't specify the value_selection_strategy , the default is ORIGINAL_VALUE .
5497 5498 5499 |
# File 'lex/cfn_bot.rb', line 5497 def value_elicitation_setting @value_elicitation_setting end |
Class Method Details
.jsii_properties ⇒ Object
5519 5520 5521 5522 5523 5524 5525 5526 5527 5528 5529 |
# File 'lex/cfn_bot.rb', line 5519 def self.jsii_properties { :name => "name", :slot_type_name => "slotTypeName", :value_elicitation_setting => "valueElicitationSetting", :description => "description", :multiple_values_setting => "multipleValuesSetting", :obfuscation_setting => "obfuscationSetting", :sub_slot_setting => "subSlotSetting", } end |
Instance Method Details
#to_jsii ⇒ Object
5531 5532 5533 5534 5535 5536 5537 5538 5539 5540 5541 5542 5543 |
# File 'lex/cfn_bot.rb', line 5531 def to_jsii result = {} result.merge!({ "name" => @name, "slotTypeName" => @slot_type_name, "valueElicitationSetting" => @value_elicitation_setting, "description" => @description, "multipleValuesSetting" => @multiple_values_setting, "obfuscationSetting" => @obfuscation_setting, "subSlotSetting" => @sub_slot_setting, }) result.compact end |