/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include #include namespace Aws { namespace RAM { namespace Model { /** */ class AWS_RAM_API CreateResourceShareRequest : public RAMRequest { public: CreateResourceShareRequest(); // 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 "CreateResourceShare"; } Aws::String SerializePayload() const override; /** *

The name of the resource share.

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

The name of the resource share.

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

The name of the resource share.

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

The name of the resource share.

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

The name of the resource share.

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

The name of the resource share.

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

The name of the resource share.

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

The name of the resource share.

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

The Amazon Resource Names (ARN) of the resources to associate with the * resource share.

*/ inline const Aws::Vector& GetResourceArns() const{ return m_resourceArns; } /** *

The Amazon Resource Names (ARN) of the resources to associate with the * resource share.

*/ inline bool ResourceArnsHasBeenSet() const { return m_resourceArnsHasBeenSet; } /** *

The Amazon Resource Names (ARN) of the resources to associate with the * resource share.

*/ inline void SetResourceArns(const Aws::Vector& value) { m_resourceArnsHasBeenSet = true; m_resourceArns = value; } /** *

The Amazon Resource Names (ARN) of the resources to associate with the * resource share.

*/ inline void SetResourceArns(Aws::Vector&& value) { m_resourceArnsHasBeenSet = true; m_resourceArns = std::move(value); } /** *

The Amazon Resource Names (ARN) of the resources to associate with the * resource share.

*/ inline CreateResourceShareRequest& WithResourceArns(const Aws::Vector& value) { SetResourceArns(value); return *this;} /** *

The Amazon Resource Names (ARN) of the resources to associate with the * resource share.

*/ inline CreateResourceShareRequest& WithResourceArns(Aws::Vector&& value) { SetResourceArns(std::move(value)); return *this;} /** *

The Amazon Resource Names (ARN) of the resources to associate with the * resource share.

*/ inline CreateResourceShareRequest& AddResourceArns(const Aws::String& value) { m_resourceArnsHasBeenSet = true; m_resourceArns.push_back(value); return *this; } /** *

The Amazon Resource Names (ARN) of the resources to associate with the * resource share.

*/ inline CreateResourceShareRequest& AddResourceArns(Aws::String&& value) { m_resourceArnsHasBeenSet = true; m_resourceArns.push_back(std::move(value)); return *this; } /** *

The Amazon Resource Names (ARN) of the resources to associate with the * resource share.

*/ inline CreateResourceShareRequest& AddResourceArns(const char* value) { m_resourceArnsHasBeenSet = true; m_resourceArns.push_back(value); return *this; } /** *

The principals to associate with the resource share. The possible values are * IDs of AWS accounts, the ARN of an OU or organization from AWS * Organizations.

*/ inline const Aws::Vector& GetPrincipals() const{ return m_principals; } /** *

The principals to associate with the resource share. The possible values are * IDs of AWS accounts, the ARN of an OU or organization from AWS * Organizations.

*/ inline bool PrincipalsHasBeenSet() const { return m_principalsHasBeenSet; } /** *

The principals to associate with the resource share. The possible values are * IDs of AWS accounts, the ARN of an OU or organization from AWS * Organizations.

*/ inline void SetPrincipals(const Aws::Vector& value) { m_principalsHasBeenSet = true; m_principals = value; } /** *

The principals to associate with the resource share. The possible values are * IDs of AWS accounts, the ARN of an OU or organization from AWS * Organizations.

*/ inline void SetPrincipals(Aws::Vector&& value) { m_principalsHasBeenSet = true; m_principals = std::move(value); } /** *

The principals to associate with the resource share. The possible values are * IDs of AWS accounts, the ARN of an OU or organization from AWS * Organizations.

*/ inline CreateResourceShareRequest& WithPrincipals(const Aws::Vector& value) { SetPrincipals(value); return *this;} /** *

The principals to associate with the resource share. The possible values are * IDs of AWS accounts, the ARN of an OU or organization from AWS * Organizations.

*/ inline CreateResourceShareRequest& WithPrincipals(Aws::Vector&& value) { SetPrincipals(std::move(value)); return *this;} /** *

The principals to associate with the resource share. The possible values are * IDs of AWS accounts, the ARN of an OU or organization from AWS * Organizations.

*/ inline CreateResourceShareRequest& AddPrincipals(const Aws::String& value) { m_principalsHasBeenSet = true; m_principals.push_back(value); return *this; } /** *

The principals to associate with the resource share. The possible values are * IDs of AWS accounts, the ARN of an OU or organization from AWS * Organizations.

*/ inline CreateResourceShareRequest& AddPrincipals(Aws::String&& value) { m_principalsHasBeenSet = true; m_principals.push_back(std::move(value)); return *this; } /** *

The principals to associate with the resource share. The possible values are * IDs of AWS accounts, the ARN of an OU or organization from AWS * Organizations.

*/ inline CreateResourceShareRequest& AddPrincipals(const char* value) { m_principalsHasBeenSet = true; m_principals.push_back(value); return *this; } /** *

One or more tags.

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

One or more tags.

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

One or more tags.

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

One or more tags.

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

One or more tags.

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

One or more tags.

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

One or more tags.

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

One or more tags.

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

Indicates whether principals outside your AWS organization can be associated * with a resource share.

*/ inline bool GetAllowExternalPrincipals() const{ return m_allowExternalPrincipals; } /** *

Indicates whether principals outside your AWS organization can be associated * with a resource share.

*/ inline bool AllowExternalPrincipalsHasBeenSet() const { return m_allowExternalPrincipalsHasBeenSet; } /** *

Indicates whether principals outside your AWS organization can be associated * with a resource share.

*/ inline void SetAllowExternalPrincipals(bool value) { m_allowExternalPrincipalsHasBeenSet = true; m_allowExternalPrincipals = value; } /** *

Indicates whether principals outside your AWS organization can be associated * with a resource share.

*/ inline CreateResourceShareRequest& WithAllowExternalPrincipals(bool value) { SetAllowExternalPrincipals(value); return *this;} /** *

A unique, case-sensitive identifier that you provide to ensure the * idempotency of the request.

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

A unique, case-sensitive identifier that you provide to ensure the * idempotency of the request.

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

A unique, case-sensitive identifier that you provide to ensure the * idempotency of the request.

*/ 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.

*/ 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.

*/ 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.

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

A unique, case-sensitive identifier that you provide to ensure the * idempotency of the request.

*/ inline CreateResourceShareRequest& 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.

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

The ARNs of the permissions to associate with the resource share. If you do * not specify an ARN for the permission, AWS RAM automatically attaches the * default version of the permission for each resource type.

*/ inline const Aws::Vector& GetPermissionArns() const{ return m_permissionArns; } /** *

The ARNs of the permissions to associate with the resource share. If you do * not specify an ARN for the permission, AWS RAM automatically attaches the * default version of the permission for each resource type.

*/ inline bool PermissionArnsHasBeenSet() const { return m_permissionArnsHasBeenSet; } /** *

The ARNs of the permissions to associate with the resource share. If you do * not specify an ARN for the permission, AWS RAM automatically attaches the * default version of the permission for each resource type.

*/ inline void SetPermissionArns(const Aws::Vector& value) { m_permissionArnsHasBeenSet = true; m_permissionArns = value; } /** *

The ARNs of the permissions to associate with the resource share. If you do * not specify an ARN for the permission, AWS RAM automatically attaches the * default version of the permission for each resource type.

*/ inline void SetPermissionArns(Aws::Vector&& value) { m_permissionArnsHasBeenSet = true; m_permissionArns = std::move(value); } /** *

The ARNs of the permissions to associate with the resource share. If you do * not specify an ARN for the permission, AWS RAM automatically attaches the * default version of the permission for each resource type.

*/ inline CreateResourceShareRequest& WithPermissionArns(const Aws::Vector& value) { SetPermissionArns(value); return *this;} /** *

The ARNs of the permissions to associate with the resource share. If you do * not specify an ARN for the permission, AWS RAM automatically attaches the * default version of the permission for each resource type.

*/ inline CreateResourceShareRequest& WithPermissionArns(Aws::Vector&& value) { SetPermissionArns(std::move(value)); return *this;} /** *

The ARNs of the permissions to associate with the resource share. If you do * not specify an ARN for the permission, AWS RAM automatically attaches the * default version of the permission for each resource type.

*/ inline CreateResourceShareRequest& AddPermissionArns(const Aws::String& value) { m_permissionArnsHasBeenSet = true; m_permissionArns.push_back(value); return *this; } /** *

The ARNs of the permissions to associate with the resource share. If you do * not specify an ARN for the permission, AWS RAM automatically attaches the * default version of the permission for each resource type.

*/ inline CreateResourceShareRequest& AddPermissionArns(Aws::String&& value) { m_permissionArnsHasBeenSet = true; m_permissionArns.push_back(std::move(value)); return *this; } /** *

The ARNs of the permissions to associate with the resource share. If you do * not specify an ARN for the permission, AWS RAM automatically attaches the * default version of the permission for each resource type.

*/ inline CreateResourceShareRequest& AddPermissionArns(const char* value) { m_permissionArnsHasBeenSet = true; m_permissionArns.push_back(value); return *this; } private: Aws::String m_name; bool m_nameHasBeenSet; Aws::Vector m_resourceArns; bool m_resourceArnsHasBeenSet; Aws::Vector m_principals; bool m_principalsHasBeenSet; Aws::Vector m_tags; bool m_tagsHasBeenSet; bool m_allowExternalPrincipals; bool m_allowExternalPrincipalsHasBeenSet; Aws::String m_clientToken; bool m_clientTokenHasBeenSet; Aws::Vector m_permissionArns; bool m_permissionArnsHasBeenSet; }; } // namespace Model } // namespace RAM } // namespace Aws