/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include #include #include namespace Aws { namespace Utils { namespace Json { class JsonValue; class JsonView; } // namespace Json } // namespace Utils namespace LexRuntimeV2 { namespace Model { /** *

A value that Amazon Lex V2 uses to fulfill an intent.

See * Also:

AWS * API Reference

*/ class Slot { public: AWS_LEXRUNTIMEV2_API Slot(); AWS_LEXRUNTIMEV2_API Slot(Aws::Utils::Json::JsonView jsonValue); AWS_LEXRUNTIMEV2_API Slot& operator=(Aws::Utils::Json::JsonView jsonValue); AWS_LEXRUNTIMEV2_API Aws::Utils::Json::JsonValue Jsonize() const; /** *

The current value of the slot.

*/ inline const Value& GetValue() const{ return m_value; } /** *

The current value of the slot.

*/ inline bool ValueHasBeenSet() const { return m_valueHasBeenSet; } /** *

The current value of the slot.

*/ inline void SetValue(const Value& value) { m_valueHasBeenSet = true; m_value = value; } /** *

The current value of the slot.

*/ inline void SetValue(Value&& value) { m_valueHasBeenSet = true; m_value = std::move(value); } /** *

The current value of the slot.

*/ inline Slot& WithValue(const Value& value) { SetValue(value); return *this;} /** *

The current value of the slot.

*/ inline Slot& WithValue(Value&& value) { SetValue(std::move(value)); return *this;} /** *

When the shape value is List, it indicates that the * values field contains a list of slot values. When the value is * Scalar, it indicates that the value field contains a * single value.

*/ inline const Shape& GetShape() const{ return m_shape; } /** *

When the shape value is List, it indicates that the * values field contains a list of slot values. When the value is * Scalar, it indicates that the value field contains a * single value.

*/ inline bool ShapeHasBeenSet() const { return m_shapeHasBeenSet; } /** *

When the shape value is List, it indicates that the * values field contains a list of slot values. When the value is * Scalar, it indicates that the value field contains a * single value.

*/ inline void SetShape(const Shape& value) { m_shapeHasBeenSet = true; m_shape = value; } /** *

When the shape value is List, it indicates that the * values field contains a list of slot values. When the value is * Scalar, it indicates that the value field contains a * single value.

*/ inline void SetShape(Shape&& value) { m_shapeHasBeenSet = true; m_shape = std::move(value); } /** *

When the shape value is List, it indicates that the * values field contains a list of slot values. When the value is * Scalar, it indicates that the value field contains a * single value.

*/ inline Slot& WithShape(const Shape& value) { SetShape(value); return *this;} /** *

When the shape value is List, it indicates that the * values field contains a list of slot values. When the value is * Scalar, it indicates that the value field contains a * single value.

*/ inline Slot& WithShape(Shape&& value) { SetShape(std::move(value)); return *this;} /** *

A list of one or more values that the user provided for the slot. For * example, if a for a slot that elicits pizza toppings, the values might be * "pepperoni" and "pineapple."

*/ inline const Aws::Vector& GetValues() const{ return m_values; } /** *

A list of one or more values that the user provided for the slot. For * example, if a for a slot that elicits pizza toppings, the values might be * "pepperoni" and "pineapple."

*/ inline bool ValuesHasBeenSet() const { return m_valuesHasBeenSet; } /** *

A list of one or more values that the user provided for the slot. For * example, if a for a slot that elicits pizza toppings, the values might be * "pepperoni" and "pineapple."

*/ inline void SetValues(const Aws::Vector& value) { m_valuesHasBeenSet = true; m_values = value; } /** *

A list of one or more values that the user provided for the slot. For * example, if a for a slot that elicits pizza toppings, the values might be * "pepperoni" and "pineapple."

*/ inline void SetValues(Aws::Vector&& value) { m_valuesHasBeenSet = true; m_values = std::move(value); } /** *

A list of one or more values that the user provided for the slot. For * example, if a for a slot that elicits pizza toppings, the values might be * "pepperoni" and "pineapple."

*/ inline Slot& WithValues(const Aws::Vector& value) { SetValues(value); return *this;} /** *

A list of one or more values that the user provided for the slot. For * example, if a for a slot that elicits pizza toppings, the values might be * "pepperoni" and "pineapple."

*/ inline Slot& WithValues(Aws::Vector&& value) { SetValues(std::move(value)); return *this;} /** *

A list of one or more values that the user provided for the slot. For * example, if a for a slot that elicits pizza toppings, the values might be * "pepperoni" and "pineapple."

*/ inline Slot& AddValues(const Slot& value) { m_valuesHasBeenSet = true; m_values.push_back(value); return *this; } /** *

A list of one or more values that the user provided for the slot. For * example, if a for a slot that elicits pizza toppings, the values might be * "pepperoni" and "pineapple."

*/ inline Slot& AddValues(Slot&& value) { m_valuesHasBeenSet = true; m_values.push_back(std::move(value)); return *this; } /** *

The constituent sub slots of a composite slot.

*/ inline const Aws::Map& GetSubSlots() const{ return m_subSlots; } /** *

The constituent sub slots of a composite slot.

*/ inline bool SubSlotsHasBeenSet() const { return m_subSlotsHasBeenSet; } /** *

The constituent sub slots of a composite slot.

*/ inline void SetSubSlots(const Aws::Map& value) { m_subSlotsHasBeenSet = true; m_subSlots = value; } /** *

The constituent sub slots of a composite slot.

*/ inline void SetSubSlots(Aws::Map&& value) { m_subSlotsHasBeenSet = true; m_subSlots = std::move(value); } /** *

The constituent sub slots of a composite slot.

*/ inline Slot& WithSubSlots(const Aws::Map& value) { SetSubSlots(value); return *this;} /** *

The constituent sub slots of a composite slot.

*/ inline Slot& WithSubSlots(Aws::Map&& value) { SetSubSlots(std::move(value)); return *this;} /** *

The constituent sub slots of a composite slot.

*/ inline Slot& AddSubSlots(const Aws::String& key, const Slot& value) { m_subSlotsHasBeenSet = true; m_subSlots.emplace(key, value); return *this; } /** *

The constituent sub slots of a composite slot.

*/ inline Slot& AddSubSlots(Aws::String&& key, const Slot& value) { m_subSlotsHasBeenSet = true; m_subSlots.emplace(std::move(key), value); return *this; } /** *

The constituent sub slots of a composite slot.

*/ inline Slot& AddSubSlots(const Aws::String& key, Slot&& value) { m_subSlotsHasBeenSet = true; m_subSlots.emplace(key, std::move(value)); return *this; } /** *

The constituent sub slots of a composite slot.

*/ inline Slot& AddSubSlots(Aws::String&& key, Slot&& value) { m_subSlotsHasBeenSet = true; m_subSlots.emplace(std::move(key), std::move(value)); return *this; } /** *

The constituent sub slots of a composite slot.

*/ inline Slot& AddSubSlots(const char* key, Slot&& value) { m_subSlotsHasBeenSet = true; m_subSlots.emplace(key, std::move(value)); return *this; } /** *

The constituent sub slots of a composite slot.

*/ inline Slot& AddSubSlots(const char* key, const Slot& value) { m_subSlotsHasBeenSet = true; m_subSlots.emplace(key, value); return *this; } private: Value m_value; bool m_valueHasBeenSet = false; Shape m_shape; bool m_shapeHasBeenSet = false; Aws::Vector m_values; bool m_valuesHasBeenSet = false; Aws::Map m_subSlots; bool m_subSlotsHasBeenSet = false; }; } // namespace Model } // namespace LexRuntimeV2 } // namespace Aws