1 /** 2 * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 * SPDX-License-Identifier: Apache-2.0. 4 */ 5 6 #pragma once 7 #include <aws/lexv2-models/LexModelsV2_EXPORTS.h> 8 #include <aws/lexv2-models/model/PromptSpecification.h> 9 #include <aws/lexv2-models/model/ResponseSpecification.h> 10 #include <utility> 11 12 namespace Aws 13 { 14 namespace Utils 15 { 16 namespace Json 17 { 18 class JsonValue; 19 class JsonView; 20 } // namespace Json 21 } // namespace Utils 22 namespace LexModelsV2 23 { 24 namespace Model 25 { 26 27 /** 28 * <p>Provides a prompt for making sure that the user is ready for the intent to be 29 * fulfilled.</p><p><h3>See Also:</h3> <a 30 * href="http://docs.aws.amazon.com/goto/WebAPI/models.lex.v2-2020-08-07/IntentConfirmationSetting">AWS 31 * API Reference</a></p> 32 */ 33 class AWS_LEXMODELSV2_API IntentConfirmationSetting 34 { 35 public: 36 IntentConfirmationSetting(); 37 IntentConfirmationSetting(Aws::Utils::Json::JsonView jsonValue); 38 IntentConfirmationSetting& operator=(Aws::Utils::Json::JsonView jsonValue); 39 Aws::Utils::Json::JsonValue Jsonize() const; 40 41 42 /** 43 * <p>Prompts the user to confirm the intent. This question should have a yes or no 44 * answer.</p> <p>Amazon Lex uses this prompt to ensure that the user acknowledges 45 * that the intent is ready for fulfillment. For example, with the 46 * <code>OrderPizza</code> intent, you might want to confirm that the order is 47 * correct before placing it. For other intents, such as intents that simply 48 * respond to user questions, you might not need to ask the user for confirmation 49 * before providing the information. </p> 50 */ GetPromptSpecification()51 inline const PromptSpecification& GetPromptSpecification() const{ return m_promptSpecification; } 52 53 /** 54 * <p>Prompts the user to confirm the intent. This question should have a yes or no 55 * answer.</p> <p>Amazon Lex uses this prompt to ensure that the user acknowledges 56 * that the intent is ready for fulfillment. For example, with the 57 * <code>OrderPizza</code> intent, you might want to confirm that the order is 58 * correct before placing it. For other intents, such as intents that simply 59 * respond to user questions, you might not need to ask the user for confirmation 60 * before providing the information. </p> 61 */ PromptSpecificationHasBeenSet()62 inline bool PromptSpecificationHasBeenSet() const { return m_promptSpecificationHasBeenSet; } 63 64 /** 65 * <p>Prompts the user to confirm the intent. This question should have a yes or no 66 * answer.</p> <p>Amazon Lex uses this prompt to ensure that the user acknowledges 67 * that the intent is ready for fulfillment. For example, with the 68 * <code>OrderPizza</code> intent, you might want to confirm that the order is 69 * correct before placing it. For other intents, such as intents that simply 70 * respond to user questions, you might not need to ask the user for confirmation 71 * before providing the information. </p> 72 */ SetPromptSpecification(const PromptSpecification & value)73 inline void SetPromptSpecification(const PromptSpecification& value) { m_promptSpecificationHasBeenSet = true; m_promptSpecification = value; } 74 75 /** 76 * <p>Prompts the user to confirm the intent. This question should have a yes or no 77 * answer.</p> <p>Amazon Lex uses this prompt to ensure that the user acknowledges 78 * that the intent is ready for fulfillment. For example, with the 79 * <code>OrderPizza</code> intent, you might want to confirm that the order is 80 * correct before placing it. For other intents, such as intents that simply 81 * respond to user questions, you might not need to ask the user for confirmation 82 * before providing the information. </p> 83 */ SetPromptSpecification(PromptSpecification && value)84 inline void SetPromptSpecification(PromptSpecification&& value) { m_promptSpecificationHasBeenSet = true; m_promptSpecification = std::move(value); } 85 86 /** 87 * <p>Prompts the user to confirm the intent. This question should have a yes or no 88 * answer.</p> <p>Amazon Lex uses this prompt to ensure that the user acknowledges 89 * that the intent is ready for fulfillment. For example, with the 90 * <code>OrderPizza</code> intent, you might want to confirm that the order is 91 * correct before placing it. For other intents, such as intents that simply 92 * respond to user questions, you might not need to ask the user for confirmation 93 * before providing the information. </p> 94 */ WithPromptSpecification(const PromptSpecification & value)95 inline IntentConfirmationSetting& WithPromptSpecification(const PromptSpecification& value) { SetPromptSpecification(value); return *this;} 96 97 /** 98 * <p>Prompts the user to confirm the intent. This question should have a yes or no 99 * answer.</p> <p>Amazon Lex uses this prompt to ensure that the user acknowledges 100 * that the intent is ready for fulfillment. For example, with the 101 * <code>OrderPizza</code> intent, you might want to confirm that the order is 102 * correct before placing it. For other intents, such as intents that simply 103 * respond to user questions, you might not need to ask the user for confirmation 104 * before providing the information. </p> 105 */ WithPromptSpecification(PromptSpecification && value)106 inline IntentConfirmationSetting& WithPromptSpecification(PromptSpecification&& value) { SetPromptSpecification(std::move(value)); return *this;} 107 108 109 /** 110 * <p>When the user answers "no" to the question defined in 111 * <code>promptSpecification</code>, Amazon Lex responds with this response to 112 * acknowledge that the intent was canceled. </p> 113 */ GetDeclinationResponse()114 inline const ResponseSpecification& GetDeclinationResponse() const{ return m_declinationResponse; } 115 116 /** 117 * <p>When the user answers "no" to the question defined in 118 * <code>promptSpecification</code>, Amazon Lex responds with this response to 119 * acknowledge that the intent was canceled. </p> 120 */ DeclinationResponseHasBeenSet()121 inline bool DeclinationResponseHasBeenSet() const { return m_declinationResponseHasBeenSet; } 122 123 /** 124 * <p>When the user answers "no" to the question defined in 125 * <code>promptSpecification</code>, Amazon Lex responds with this response to 126 * acknowledge that the intent was canceled. </p> 127 */ SetDeclinationResponse(const ResponseSpecification & value)128 inline void SetDeclinationResponse(const ResponseSpecification& value) { m_declinationResponseHasBeenSet = true; m_declinationResponse = value; } 129 130 /** 131 * <p>When the user answers "no" to the question defined in 132 * <code>promptSpecification</code>, Amazon Lex responds with this response to 133 * acknowledge that the intent was canceled. </p> 134 */ SetDeclinationResponse(ResponseSpecification && value)135 inline void SetDeclinationResponse(ResponseSpecification&& value) { m_declinationResponseHasBeenSet = true; m_declinationResponse = std::move(value); } 136 137 /** 138 * <p>When the user answers "no" to the question defined in 139 * <code>promptSpecification</code>, Amazon Lex responds with this response to 140 * acknowledge that the intent was canceled. </p> 141 */ WithDeclinationResponse(const ResponseSpecification & value)142 inline IntentConfirmationSetting& WithDeclinationResponse(const ResponseSpecification& value) { SetDeclinationResponse(value); return *this;} 143 144 /** 145 * <p>When the user answers "no" to the question defined in 146 * <code>promptSpecification</code>, Amazon Lex responds with this response to 147 * acknowledge that the intent was canceled. </p> 148 */ WithDeclinationResponse(ResponseSpecification && value)149 inline IntentConfirmationSetting& WithDeclinationResponse(ResponseSpecification&& value) { SetDeclinationResponse(std::move(value)); return *this;} 150 151 152 /** 153 * <p>Specifies whether the intent's confirmation is sent to the user. When this 154 * field is false, confirmation and declination responses aren't sent. If the 155 * <code>active</code> field isn't specified, the default is true.</p> 156 */ GetActive()157 inline bool GetActive() const{ return m_active; } 158 159 /** 160 * <p>Specifies whether the intent's confirmation is sent to the user. When this 161 * field is false, confirmation and declination responses aren't sent. If the 162 * <code>active</code> field isn't specified, the default is true.</p> 163 */ ActiveHasBeenSet()164 inline bool ActiveHasBeenSet() const { return m_activeHasBeenSet; } 165 166 /** 167 * <p>Specifies whether the intent's confirmation is sent to the user. When this 168 * field is false, confirmation and declination responses aren't sent. If the 169 * <code>active</code> field isn't specified, the default is true.</p> 170 */ SetActive(bool value)171 inline void SetActive(bool value) { m_activeHasBeenSet = true; m_active = value; } 172 173 /** 174 * <p>Specifies whether the intent's confirmation is sent to the user. When this 175 * field is false, confirmation and declination responses aren't sent. If the 176 * <code>active</code> field isn't specified, the default is true.</p> 177 */ WithActive(bool value)178 inline IntentConfirmationSetting& WithActive(bool value) { SetActive(value); return *this;} 179 180 private: 181 182 PromptSpecification m_promptSpecification; 183 bool m_promptSpecificationHasBeenSet; 184 185 ResponseSpecification m_declinationResponse; 186 bool m_declinationResponseHasBeenSet; 187 188 bool m_active; 189 bool m_activeHasBeenSet; 190 }; 191 192 } // namespace Model 193 } // namespace LexModelsV2 194 } // namespace Aws 195