/** * 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 LakeFormation { namespace Model { /** */ class GrantPermissionsRequest : public LakeFormationRequest { public: AWS_LAKEFORMATION_API GrantPermissionsRequest(); // 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 "GrantPermissions"; } AWS_LAKEFORMATION_API Aws::String SerializePayload() const override; /** *

The identifier for the Data Catalog. By default, the account ID. The Data * Catalog is the persistent metadata store. It contains database definitions, * table definitions, and other control information to manage your Lake Formation * environment.

*/ inline const Aws::String& GetCatalogId() const{ return m_catalogId; } /** *

The identifier for the Data Catalog. By default, the account ID. The Data * Catalog is the persistent metadata store. It contains database definitions, * table definitions, and other control information to manage your Lake Formation * environment.

*/ inline bool CatalogIdHasBeenSet() const { return m_catalogIdHasBeenSet; } /** *

The identifier for the Data Catalog. By default, the account ID. The Data * Catalog is the persistent metadata store. It contains database definitions, * table definitions, and other control information to manage your Lake Formation * environment.

*/ inline void SetCatalogId(const Aws::String& value) { m_catalogIdHasBeenSet = true; m_catalogId = value; } /** *

The identifier for the Data Catalog. By default, the account ID. The Data * Catalog is the persistent metadata store. It contains database definitions, * table definitions, and other control information to manage your Lake Formation * environment.

*/ inline void SetCatalogId(Aws::String&& value) { m_catalogIdHasBeenSet = true; m_catalogId = std::move(value); } /** *

The identifier for the Data Catalog. By default, the account ID. The Data * Catalog is the persistent metadata store. It contains database definitions, * table definitions, and other control information to manage your Lake Formation * environment.

*/ inline void SetCatalogId(const char* value) { m_catalogIdHasBeenSet = true; m_catalogId.assign(value); } /** *

The identifier for the Data Catalog. By default, the account ID. The Data * Catalog is the persistent metadata store. It contains database definitions, * table definitions, and other control information to manage your Lake Formation * environment.

*/ inline GrantPermissionsRequest& WithCatalogId(const Aws::String& value) { SetCatalogId(value); return *this;} /** *

The identifier for the Data Catalog. By default, the account ID. The Data * Catalog is the persistent metadata store. It contains database definitions, * table definitions, and other control information to manage your Lake Formation * environment.

*/ inline GrantPermissionsRequest& WithCatalogId(Aws::String&& value) { SetCatalogId(std::move(value)); return *this;} /** *

The identifier for the Data Catalog. By default, the account ID. The Data * Catalog is the persistent metadata store. It contains database definitions, * table definitions, and other control information to manage your Lake Formation * environment.

*/ inline GrantPermissionsRequest& WithCatalogId(const char* value) { SetCatalogId(value); return *this;} /** *

The principal to be granted the permissions on the resource. Supported * principals are IAM users or IAM roles, and they are defined by their principal * type and their ARN.

Note that if you define a resource with a particular * ARN, then later delete, and recreate a resource with that same ARN, the resource * maintains the permissions already granted.

*/ inline const DataLakePrincipal& GetPrincipal() const{ return m_principal; } /** *

The principal to be granted the permissions on the resource. Supported * principals are IAM users or IAM roles, and they are defined by their principal * type and their ARN.

Note that if you define a resource with a particular * ARN, then later delete, and recreate a resource with that same ARN, the resource * maintains the permissions already granted.

*/ inline bool PrincipalHasBeenSet() const { return m_principalHasBeenSet; } /** *

The principal to be granted the permissions on the resource. Supported * principals are IAM users or IAM roles, and they are defined by their principal * type and their ARN.

Note that if you define a resource with a particular * ARN, then later delete, and recreate a resource with that same ARN, the resource * maintains the permissions already granted.

*/ inline void SetPrincipal(const DataLakePrincipal& value) { m_principalHasBeenSet = true; m_principal = value; } /** *

The principal to be granted the permissions on the resource. Supported * principals are IAM users or IAM roles, and they are defined by their principal * type and their ARN.

Note that if you define a resource with a particular * ARN, then later delete, and recreate a resource with that same ARN, the resource * maintains the permissions already granted.

*/ inline void SetPrincipal(DataLakePrincipal&& value) { m_principalHasBeenSet = true; m_principal = std::move(value); } /** *

The principal to be granted the permissions on the resource. Supported * principals are IAM users or IAM roles, and they are defined by their principal * type and their ARN.

Note that if you define a resource with a particular * ARN, then later delete, and recreate a resource with that same ARN, the resource * maintains the permissions already granted.

*/ inline GrantPermissionsRequest& WithPrincipal(const DataLakePrincipal& value) { SetPrincipal(value); return *this;} /** *

The principal to be granted the permissions on the resource. Supported * principals are IAM users or IAM roles, and they are defined by their principal * type and their ARN.

Note that if you define a resource with a particular * ARN, then later delete, and recreate a resource with that same ARN, the resource * maintains the permissions already granted.

*/ inline GrantPermissionsRequest& WithPrincipal(DataLakePrincipal&& value) { SetPrincipal(std::move(value)); return *this;} /** *

The resource to which permissions are to be granted. Resources in Lake * Formation are the Data Catalog, databases, and tables.

*/ inline const Resource& GetResource() const{ return m_resource; } /** *

The resource to which permissions are to be granted. Resources in Lake * Formation are the Data Catalog, databases, and tables.

*/ inline bool ResourceHasBeenSet() const { return m_resourceHasBeenSet; } /** *

The resource to which permissions are to be granted. Resources in Lake * Formation are the Data Catalog, databases, and tables.

*/ inline void SetResource(const Resource& value) { m_resourceHasBeenSet = true; m_resource = value; } /** *

The resource to which permissions are to be granted. Resources in Lake * Formation are the Data Catalog, databases, and tables.

*/ inline void SetResource(Resource&& value) { m_resourceHasBeenSet = true; m_resource = std::move(value); } /** *

The resource to which permissions are to be granted. Resources in Lake * Formation are the Data Catalog, databases, and tables.

*/ inline GrantPermissionsRequest& WithResource(const Resource& value) { SetResource(value); return *this;} /** *

The resource to which permissions are to be granted. Resources in Lake * Formation are the Data Catalog, databases, and tables.

*/ inline GrantPermissionsRequest& WithResource(Resource&& value) { SetResource(std::move(value)); return *this;} /** *

The permissions granted to the principal on the resource. Lake Formation * defines privileges to grant and revoke access to metadata in the Data Catalog * and data organized in underlying data storage such as Amazon S3. Lake Formation * requires that each principal be authorized to perform a specific task on Lake * Formation resources.

*/ inline const Aws::Vector& GetPermissions() const{ return m_permissions; } /** *

The permissions granted to the principal on the resource. Lake Formation * defines privileges to grant and revoke access to metadata in the Data Catalog * and data organized in underlying data storage such as Amazon S3. Lake Formation * requires that each principal be authorized to perform a specific task on Lake * Formation resources.

*/ inline bool PermissionsHasBeenSet() const { return m_permissionsHasBeenSet; } /** *

The permissions granted to the principal on the resource. Lake Formation * defines privileges to grant and revoke access to metadata in the Data Catalog * and data organized in underlying data storage such as Amazon S3. Lake Formation * requires that each principal be authorized to perform a specific task on Lake * Formation resources.

*/ inline void SetPermissions(const Aws::Vector& value) { m_permissionsHasBeenSet = true; m_permissions = value; } /** *

The permissions granted to the principal on the resource. Lake Formation * defines privileges to grant and revoke access to metadata in the Data Catalog * and data organized in underlying data storage such as Amazon S3. Lake Formation * requires that each principal be authorized to perform a specific task on Lake * Formation resources.

*/ inline void SetPermissions(Aws::Vector&& value) { m_permissionsHasBeenSet = true; m_permissions = std::move(value); } /** *

The permissions granted to the principal on the resource. Lake Formation * defines privileges to grant and revoke access to metadata in the Data Catalog * and data organized in underlying data storage such as Amazon S3. Lake Formation * requires that each principal be authorized to perform a specific task on Lake * Formation resources.

*/ inline GrantPermissionsRequest& WithPermissions(const Aws::Vector& value) { SetPermissions(value); return *this;} /** *

The permissions granted to the principal on the resource. Lake Formation * defines privileges to grant and revoke access to metadata in the Data Catalog * and data organized in underlying data storage such as Amazon S3. Lake Formation * requires that each principal be authorized to perform a specific task on Lake * Formation resources.

*/ inline GrantPermissionsRequest& WithPermissions(Aws::Vector&& value) { SetPermissions(std::move(value)); return *this;} /** *

The permissions granted to the principal on the resource. Lake Formation * defines privileges to grant and revoke access to metadata in the Data Catalog * and data organized in underlying data storage such as Amazon S3. Lake Formation * requires that each principal be authorized to perform a specific task on Lake * Formation resources.

*/ inline GrantPermissionsRequest& AddPermissions(const Permission& value) { m_permissionsHasBeenSet = true; m_permissions.push_back(value); return *this; } /** *

The permissions granted to the principal on the resource. Lake Formation * defines privileges to grant and revoke access to metadata in the Data Catalog * and data organized in underlying data storage such as Amazon S3. Lake Formation * requires that each principal be authorized to perform a specific task on Lake * Formation resources.

*/ inline GrantPermissionsRequest& AddPermissions(Permission&& value) { m_permissionsHasBeenSet = true; m_permissions.push_back(std::move(value)); return *this; } /** *

Indicates a list of the granted permissions that the principal may pass to * other users. These permissions may only be a subset of the permissions granted * in the Privileges.

*/ inline const Aws::Vector& GetPermissionsWithGrantOption() const{ return m_permissionsWithGrantOption; } /** *

Indicates a list of the granted permissions that the principal may pass to * other users. These permissions may only be a subset of the permissions granted * in the Privileges.

*/ inline bool PermissionsWithGrantOptionHasBeenSet() const { return m_permissionsWithGrantOptionHasBeenSet; } /** *

Indicates a list of the granted permissions that the principal may pass to * other users. These permissions may only be a subset of the permissions granted * in the Privileges.

*/ inline void SetPermissionsWithGrantOption(const Aws::Vector& value) { m_permissionsWithGrantOptionHasBeenSet = true; m_permissionsWithGrantOption = value; } /** *

Indicates a list of the granted permissions that the principal may pass to * other users. These permissions may only be a subset of the permissions granted * in the Privileges.

*/ inline void SetPermissionsWithGrantOption(Aws::Vector&& value) { m_permissionsWithGrantOptionHasBeenSet = true; m_permissionsWithGrantOption = std::move(value); } /** *

Indicates a list of the granted permissions that the principal may pass to * other users. These permissions may only be a subset of the permissions granted * in the Privileges.

*/ inline GrantPermissionsRequest& WithPermissionsWithGrantOption(const Aws::Vector& value) { SetPermissionsWithGrantOption(value); return *this;} /** *

Indicates a list of the granted permissions that the principal may pass to * other users. These permissions may only be a subset of the permissions granted * in the Privileges.

*/ inline GrantPermissionsRequest& WithPermissionsWithGrantOption(Aws::Vector&& value) { SetPermissionsWithGrantOption(std::move(value)); return *this;} /** *

Indicates a list of the granted permissions that the principal may pass to * other users. These permissions may only be a subset of the permissions granted * in the Privileges.

*/ inline GrantPermissionsRequest& AddPermissionsWithGrantOption(const Permission& value) { m_permissionsWithGrantOptionHasBeenSet = true; m_permissionsWithGrantOption.push_back(value); return *this; } /** *

Indicates a list of the granted permissions that the principal may pass to * other users. These permissions may only be a subset of the permissions granted * in the Privileges.

*/ inline GrantPermissionsRequest& AddPermissionsWithGrantOption(Permission&& value) { m_permissionsWithGrantOptionHasBeenSet = true; m_permissionsWithGrantOption.push_back(std::move(value)); return *this; } private: Aws::String m_catalogId; bool m_catalogIdHasBeenSet = false; DataLakePrincipal m_principal; bool m_principalHasBeenSet = false; Resource m_resource; bool m_resourceHasBeenSet = false; Aws::Vector m_permissions; bool m_permissionsHasBeenSet = false; Aws::Vector m_permissionsWithGrantOption; bool m_permissionsWithGrantOptionHasBeenSet = false; }; } // namespace Model } // namespace LakeFormation } // namespace Aws