/** * 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 #include namespace Aws { namespace OpenSearchServerless { namespace Model { /** */ class CreateCollectionRequest : public OpenSearchServerlessRequest { public: AWS_OPENSEARCHSERVERLESS_API CreateCollectionRequest(); // Service request name is the Operation name which will send this request out, // each operation should has unique request name, so that we can get operation's name from this request. // Note: this is not true for response, multiple operations may have the same response name, // so we can not get operation's name from response. inline virtual const char* GetServiceRequestName() const override { return "CreateCollection"; } AWS_OPENSEARCHSERVERLESS_API Aws::String SerializePayload() const override; AWS_OPENSEARCHSERVERLESS_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override; /** *

Unique, case-sensitive identifier to ensure idempotency of the request.

*/ inline const Aws::String& GetClientToken() const{ return m_clientToken; } /** *

Unique, case-sensitive identifier to ensure idempotency of the request.

*/ inline bool ClientTokenHasBeenSet() const { return m_clientTokenHasBeenSet; } /** *

Unique, case-sensitive identifier to ensure idempotency of the request.

*/ inline void SetClientToken(const Aws::String& value) { m_clientTokenHasBeenSet = true; m_clientToken = value; } /** *

Unique, case-sensitive identifier to ensure idempotency of the request.

*/ inline void SetClientToken(Aws::String&& value) { m_clientTokenHasBeenSet = true; m_clientToken = std::move(value); } /** *

Unique, case-sensitive identifier to ensure idempotency of the request.

*/ inline void SetClientToken(const char* value) { m_clientTokenHasBeenSet = true; m_clientToken.assign(value); } /** *

Unique, case-sensitive identifier to ensure idempotency of the request.

*/ inline CreateCollectionRequest& WithClientToken(const Aws::String& value) { SetClientToken(value); return *this;} /** *

Unique, case-sensitive identifier to ensure idempotency of the request.

*/ inline CreateCollectionRequest& WithClientToken(Aws::String&& value) { SetClientToken(std::move(value)); return *this;} /** *

Unique, case-sensitive identifier to ensure idempotency of the request.

*/ inline CreateCollectionRequest& WithClientToken(const char* value) { SetClientToken(value); return *this;} /** *

Description of the collection.

*/ inline const Aws::String& GetDescription() const{ return m_description; } /** *

Description of the collection.

*/ inline bool DescriptionHasBeenSet() const { return m_descriptionHasBeenSet; } /** *

Description of the collection.

*/ inline void SetDescription(const Aws::String& value) { m_descriptionHasBeenSet = true; m_description = value; } /** *

Description of the collection.

*/ inline void SetDescription(Aws::String&& value) { m_descriptionHasBeenSet = true; m_description = std::move(value); } /** *

Description of the collection.

*/ inline void SetDescription(const char* value) { m_descriptionHasBeenSet = true; m_description.assign(value); } /** *

Description of the collection.

*/ inline CreateCollectionRequest& WithDescription(const Aws::String& value) { SetDescription(value); return *this;} /** *

Description of the collection.

*/ inline CreateCollectionRequest& WithDescription(Aws::String&& value) { SetDescription(std::move(value)); return *this;} /** *

Description of the collection.

*/ inline CreateCollectionRequest& WithDescription(const char* value) { SetDescription(value); return *this;} /** *

Name of the collection.

*/ inline const Aws::String& GetName() const{ return m_name; } /** *

Name of the collection.

*/ inline bool NameHasBeenSet() const { return m_nameHasBeenSet; } /** *

Name of the collection.

*/ inline void SetName(const Aws::String& value) { m_nameHasBeenSet = true; m_name = value; } /** *

Name of the collection.

*/ inline void SetName(Aws::String&& value) { m_nameHasBeenSet = true; m_name = std::move(value); } /** *

Name of the collection.

*/ inline void SetName(const char* value) { m_nameHasBeenSet = true; m_name.assign(value); } /** *

Name of the collection.

*/ inline CreateCollectionRequest& WithName(const Aws::String& value) { SetName(value); return *this;} /** *

Name of the collection.

*/ inline CreateCollectionRequest& WithName(Aws::String&& value) { SetName(std::move(value)); return *this;} /** *

Name of the collection.

*/ inline CreateCollectionRequest& WithName(const char* value) { SetName(value); return *this;} /** *

An arbitrary set of tags (key–value pairs) to associate with the OpenSearch * Serverless collection.

*/ inline const Aws::Vector& GetTags() const{ return m_tags; } /** *

An arbitrary set of tags (key–value pairs) to associate with the OpenSearch * Serverless collection.

*/ inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; } /** *

An arbitrary set of tags (key–value pairs) to associate with the OpenSearch * Serverless collection.

*/ inline void SetTags(const Aws::Vector& value) { m_tagsHasBeenSet = true; m_tags = value; } /** *

An arbitrary set of tags (key–value pairs) to associate with the OpenSearch * Serverless collection.

*/ inline void SetTags(Aws::Vector&& value) { m_tagsHasBeenSet = true; m_tags = std::move(value); } /** *

An arbitrary set of tags (key–value pairs) to associate with the OpenSearch * Serverless collection.

*/ inline CreateCollectionRequest& WithTags(const Aws::Vector& value) { SetTags(value); return *this;} /** *

An arbitrary set of tags (key–value pairs) to associate with the OpenSearch * Serverless collection.

*/ inline CreateCollectionRequest& WithTags(Aws::Vector&& value) { SetTags(std::move(value)); return *this;} /** *

An arbitrary set of tags (key–value pairs) to associate with the OpenSearch * Serverless collection.

*/ inline CreateCollectionRequest& AddTags(const Tag& value) { m_tagsHasBeenSet = true; m_tags.push_back(value); return *this; } /** *

An arbitrary set of tags (key–value pairs) to associate with the OpenSearch * Serverless collection.

*/ inline CreateCollectionRequest& AddTags(Tag&& value) { m_tagsHasBeenSet = true; m_tags.push_back(std::move(value)); return *this; } /** *

The type of collection.

*/ inline const CollectionType& GetType() const{ return m_type; } /** *

The type of collection.

*/ inline bool TypeHasBeenSet() const { return m_typeHasBeenSet; } /** *

The type of collection.

*/ inline void SetType(const CollectionType& value) { m_typeHasBeenSet = true; m_type = value; } /** *

The type of collection.

*/ inline void SetType(CollectionType&& value) { m_typeHasBeenSet = true; m_type = std::move(value); } /** *

The type of collection.

*/ inline CreateCollectionRequest& WithType(const CollectionType& value) { SetType(value); return *this;} /** *

The type of collection.

*/ inline CreateCollectionRequest& WithType(CollectionType&& value) { SetType(std::move(value)); return *this;} private: Aws::String m_clientToken; bool m_clientTokenHasBeenSet = false; Aws::String m_description; bool m_descriptionHasBeenSet = false; Aws::String m_name; bool m_nameHasBeenSet = false; Aws::Vector m_tags; bool m_tagsHasBeenSet = false; CollectionType m_type; bool m_typeHasBeenSet = false; }; } // namespace Model } // namespace OpenSearchServerless } // namespace Aws