/** * 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 VPCLattice { namespace Model { /** */ class CreateTargetGroupRequest : public VPCLatticeRequest { public: AWS_VPCLATTICE_API CreateTargetGroupRequest(); // 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 "CreateTargetGroup"; } AWS_VPCLATTICE_API Aws::String SerializePayload() const override; /** *

A unique, case-sensitive identifier that you provide to ensure the * idempotency of the request. If you retry a request that completed successfully * using the same client token and parameters, the retry succeeds without * performing any actions. If the parameters aren't identical, the retry fails.

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

A unique, case-sensitive identifier that you provide to ensure the * idempotency of the request. If you retry a request that completed successfully * using the same client token and parameters, the retry succeeds without * performing any actions. If the parameters aren't identical, the retry fails.

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

A unique, case-sensitive identifier that you provide to ensure the * idempotency of the request. If you retry a request that completed successfully * using the same client token and parameters, the retry succeeds without * performing any actions. If the parameters aren't identical, the retry fails.

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

A unique, case-sensitive identifier that you provide to ensure the * idempotency of the request. If you retry a request that completed successfully * using the same client token and parameters, the retry succeeds without * performing any actions. If the parameters aren't identical, the retry fails.

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

A unique, case-sensitive identifier that you provide to ensure the * idempotency of the request. If you retry a request that completed successfully * using the same client token and parameters, the retry succeeds without * performing any actions. If the parameters aren't identical, the retry fails.

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

A unique, case-sensitive identifier that you provide to ensure the * idempotency of the request. If you retry a request that completed successfully * using the same client token and parameters, the retry succeeds without * performing any actions. If the parameters aren't identical, the retry fails.

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

A unique, case-sensitive identifier that you provide to ensure the * idempotency of the request. If you retry a request that completed successfully * using the same client token and parameters, the retry succeeds without * performing any actions. If the parameters aren't identical, the retry fails.

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

A unique, case-sensitive identifier that you provide to ensure the * idempotency of the request. If you retry a request that completed successfully * using the same client token and parameters, the retry succeeds without * performing any actions. If the parameters aren't identical, the retry fails.

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

The target group configuration. If type is set to * LAMBDA, this parameter doesn't apply.

*/ inline const TargetGroupConfig& GetConfig() const{ return m_config; } /** *

The target group configuration. If type is set to * LAMBDA, this parameter doesn't apply.

*/ inline bool ConfigHasBeenSet() const { return m_configHasBeenSet; } /** *

The target group configuration. If type is set to * LAMBDA, this parameter doesn't apply.

*/ inline void SetConfig(const TargetGroupConfig& value) { m_configHasBeenSet = true; m_config = value; } /** *

The target group configuration. If type is set to * LAMBDA, this parameter doesn't apply.

*/ inline void SetConfig(TargetGroupConfig&& value) { m_configHasBeenSet = true; m_config = std::move(value); } /** *

The target group configuration. If type is set to * LAMBDA, this parameter doesn't apply.

*/ inline CreateTargetGroupRequest& WithConfig(const TargetGroupConfig& value) { SetConfig(value); return *this;} /** *

The target group configuration. If type is set to * LAMBDA, this parameter doesn't apply.

*/ inline CreateTargetGroupRequest& WithConfig(TargetGroupConfig&& value) { SetConfig(std::move(value)); return *this;} /** *

The name of the target group. The name must be unique within the account. The * valid characters are a-z, 0-9, and hyphens (-). You can't use a hyphen as the * first or last character, or immediately after another hyphen.

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

The name of the target group. The name must be unique within the account. The * valid characters are a-z, 0-9, and hyphens (-). You can't use a hyphen as the * first or last character, or immediately after another hyphen.

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

The name of the target group. The name must be unique within the account. The * valid characters are a-z, 0-9, and hyphens (-). You can't use a hyphen as the * first or last character, or immediately after another hyphen.

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

The name of the target group. The name must be unique within the account. The * valid characters are a-z, 0-9, and hyphens (-). You can't use a hyphen as the * first or last character, or immediately after another hyphen.

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

The name of the target group. The name must be unique within the account. The * valid characters are a-z, 0-9, and hyphens (-). You can't use a hyphen as the * first or last character, or immediately after another hyphen.

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

The name of the target group. The name must be unique within the account. The * valid characters are a-z, 0-9, and hyphens (-). You can't use a hyphen as the * first or last character, or immediately after another hyphen.

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

The name of the target group. The name must be unique within the account. The * valid characters are a-z, 0-9, and hyphens (-). You can't use a hyphen as the * first or last character, or immediately after another hyphen.

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

The name of the target group. The name must be unique within the account. The * valid characters are a-z, 0-9, and hyphens (-). You can't use a hyphen as the * first or last character, or immediately after another hyphen.

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

The tags for the target group.

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

The tags for the target group.

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

The tags for the target group.

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

The tags for the target group.

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

The tags for the target group.

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

The tags for the target group.

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

The tags for the target group.

*/ inline CreateTargetGroupRequest& AddTags(const Aws::String& key, const Aws::String& value) { m_tagsHasBeenSet = true; m_tags.emplace(key, value); return *this; } /** *

The tags for the target group.

*/ inline CreateTargetGroupRequest& AddTags(Aws::String&& key, const Aws::String& value) { m_tagsHasBeenSet = true; m_tags.emplace(std::move(key), value); return *this; } /** *

The tags for the target group.

*/ inline CreateTargetGroupRequest& AddTags(const Aws::String& key, Aws::String&& value) { m_tagsHasBeenSet = true; m_tags.emplace(key, std::move(value)); return *this; } /** *

The tags for the target group.

*/ inline CreateTargetGroupRequest& AddTags(Aws::String&& key, Aws::String&& value) { m_tagsHasBeenSet = true; m_tags.emplace(std::move(key), std::move(value)); return *this; } /** *

The tags for the target group.

*/ inline CreateTargetGroupRequest& AddTags(const char* key, Aws::String&& value) { m_tagsHasBeenSet = true; m_tags.emplace(key, std::move(value)); return *this; } /** *

The tags for the target group.

*/ inline CreateTargetGroupRequest& AddTags(Aws::String&& key, const char* value) { m_tagsHasBeenSet = true; m_tags.emplace(std::move(key), value); return *this; } /** *

The tags for the target group.

*/ inline CreateTargetGroupRequest& AddTags(const char* key, const char* value) { m_tagsHasBeenSet = true; m_tags.emplace(key, value); return *this; } /** *

The type of target group.

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

The type of target group.

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

The type of target group.

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

The type of target group.

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

The type of target group.

*/ inline CreateTargetGroupRequest& WithType(const TargetGroupType& value) { SetType(value); return *this;} /** *

The type of target group.

*/ inline CreateTargetGroupRequest& WithType(TargetGroupType&& value) { SetType(std::move(value)); return *this;} private: Aws::String m_clientToken; bool m_clientTokenHasBeenSet = false; TargetGroupConfig m_config; bool m_configHasBeenSet = false; Aws::String m_name; bool m_nameHasBeenSet = false; Aws::Map m_tags; bool m_tagsHasBeenSet = false; TargetGroupType m_type; bool m_typeHasBeenSet = false; }; } // namespace Model } // namespace VPCLattice } // namespace Aws