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

Permission for the resource.

See Also:

AWS * API Reference

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

The Amazon Resource Name (ARN) of the principal. This can be one of the * following:

  • The ARN of an Amazon QuickSight user or group * associated with a data source or dataset. (This is common.)

  • *

    The ARN of an Amazon QuickSight user, group, or namespace associated with an * analysis, dashboard, template, or theme. (This is common.)

  • The * ARN of an Amazon Web Services account root: This is an IAM ARN rather than a * QuickSight ARN. Use this option only to share resources (templates) across * Amazon Web Services accounts. (This is less common.)

*/ inline const Aws::String& GetPrincipal() const{ return m_principal; } /** *

The Amazon Resource Name (ARN) of the principal. This can be one of the * following:

  • The ARN of an Amazon QuickSight user or group * associated with a data source or dataset. (This is common.)

  • *

    The ARN of an Amazon QuickSight user, group, or namespace associated with an * analysis, dashboard, template, or theme. (This is common.)

  • The * ARN of an Amazon Web Services account root: This is an IAM ARN rather than a * QuickSight ARN. Use this option only to share resources (templates) across * Amazon Web Services accounts. (This is less common.)

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

The Amazon Resource Name (ARN) of the principal. This can be one of the * following:

  • The ARN of an Amazon QuickSight user or group * associated with a data source or dataset. (This is common.)

  • *

    The ARN of an Amazon QuickSight user, group, or namespace associated with an * analysis, dashboard, template, or theme. (This is common.)

  • The * ARN of an Amazon Web Services account root: This is an IAM ARN rather than a * QuickSight ARN. Use this option only to share resources (templates) across * Amazon Web Services accounts. (This is less common.)

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

The Amazon Resource Name (ARN) of the principal. This can be one of the * following:

  • The ARN of an Amazon QuickSight user or group * associated with a data source or dataset. (This is common.)

  • *

    The ARN of an Amazon QuickSight user, group, or namespace associated with an * analysis, dashboard, template, or theme. (This is common.)

  • The * ARN of an Amazon Web Services account root: This is an IAM ARN rather than a * QuickSight ARN. Use this option only to share resources (templates) across * Amazon Web Services accounts. (This is less common.)

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

The Amazon Resource Name (ARN) of the principal. This can be one of the * following:

  • The ARN of an Amazon QuickSight user or group * associated with a data source or dataset. (This is common.)

  • *

    The ARN of an Amazon QuickSight user, group, or namespace associated with an * analysis, dashboard, template, or theme. (This is common.)

  • The * ARN of an Amazon Web Services account root: This is an IAM ARN rather than a * QuickSight ARN. Use this option only to share resources (templates) across * Amazon Web Services accounts. (This is less common.)

*/ inline void SetPrincipal(const char* value) { m_principalHasBeenSet = true; m_principal.assign(value); } /** *

The Amazon Resource Name (ARN) of the principal. This can be one of the * following:

  • The ARN of an Amazon QuickSight user or group * associated with a data source or dataset. (This is common.)

  • *

    The ARN of an Amazon QuickSight user, group, or namespace associated with an * analysis, dashboard, template, or theme. (This is common.)

  • The * ARN of an Amazon Web Services account root: This is an IAM ARN rather than a * QuickSight ARN. Use this option only to share resources (templates) across * Amazon Web Services accounts. (This is less common.)

*/ inline ResourcePermission& WithPrincipal(const Aws::String& value) { SetPrincipal(value); return *this;} /** *

The Amazon Resource Name (ARN) of the principal. This can be one of the * following:

  • The ARN of an Amazon QuickSight user or group * associated with a data source or dataset. (This is common.)

  • *

    The ARN of an Amazon QuickSight user, group, or namespace associated with an * analysis, dashboard, template, or theme. (This is common.)

  • The * ARN of an Amazon Web Services account root: This is an IAM ARN rather than a * QuickSight ARN. Use this option only to share resources (templates) across * Amazon Web Services accounts. (This is less common.)

*/ inline ResourcePermission& WithPrincipal(Aws::String&& value) { SetPrincipal(std::move(value)); return *this;} /** *

The Amazon Resource Name (ARN) of the principal. This can be one of the * following:

  • The ARN of an Amazon QuickSight user or group * associated with a data source or dataset. (This is common.)

  • *

    The ARN of an Amazon QuickSight user, group, or namespace associated with an * analysis, dashboard, template, or theme. (This is common.)

  • The * ARN of an Amazon Web Services account root: This is an IAM ARN rather than a * QuickSight ARN. Use this option only to share resources (templates) across * Amazon Web Services accounts. (This is less common.)

*/ inline ResourcePermission& WithPrincipal(const char* value) { SetPrincipal(value); return *this;} /** *

The IAM action to grant or revoke permissions on.

*/ inline const Aws::Vector& GetActions() const{ return m_actions; } /** *

The IAM action to grant or revoke permissions on.

*/ inline bool ActionsHasBeenSet() const { return m_actionsHasBeenSet; } /** *

The IAM action to grant or revoke permissions on.

*/ inline void SetActions(const Aws::Vector& value) { m_actionsHasBeenSet = true; m_actions = value; } /** *

The IAM action to grant or revoke permissions on.

*/ inline void SetActions(Aws::Vector&& value) { m_actionsHasBeenSet = true; m_actions = std::move(value); } /** *

The IAM action to grant or revoke permissions on.

*/ inline ResourcePermission& WithActions(const Aws::Vector& value) { SetActions(value); return *this;} /** *

The IAM action to grant or revoke permissions on.

*/ inline ResourcePermission& WithActions(Aws::Vector&& value) { SetActions(std::move(value)); return *this;} /** *

The IAM action to grant or revoke permissions on.

*/ inline ResourcePermission& AddActions(const Aws::String& value) { m_actionsHasBeenSet = true; m_actions.push_back(value); return *this; } /** *

The IAM action to grant or revoke permissions on.

*/ inline ResourcePermission& AddActions(Aws::String&& value) { m_actionsHasBeenSet = true; m_actions.push_back(std::move(value)); return *this; } /** *

The IAM action to grant or revoke permissions on.

*/ inline ResourcePermission& AddActions(const char* value) { m_actionsHasBeenSet = true; m_actions.push_back(value); return *this; } private: Aws::String m_principal; bool m_principalHasBeenSet = false; Aws::Vector m_actions; bool m_actionsHasBeenSet = false; }; } // namespace Model } // namespace QuickSight } // namespace Aws