/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include Describes a principal.See Also:
AWS
* API Reference
The type of principal.
*/ inline const PrincipalType& GetPrincipalType() const{ return m_principalType; } /** *The type of principal.
*/ inline bool PrincipalTypeHasBeenSet() const { return m_principalTypeHasBeenSet; } /** *The type of principal.
*/ inline void SetPrincipalType(const PrincipalType& value) { m_principalTypeHasBeenSet = true; m_principalType = value; } /** *The type of principal.
*/ inline void SetPrincipalType(PrincipalType&& value) { m_principalTypeHasBeenSet = true; m_principalType = std::move(value); } /** *The type of principal.
*/ inline AllowedPrincipal& WithPrincipalType(const PrincipalType& value) { SetPrincipalType(value); return *this;} /** *The type of principal.
*/ inline AllowedPrincipal& WithPrincipalType(PrincipalType&& value) { SetPrincipalType(std::move(value)); return *this;} /** *The Amazon Resource Name (ARN) of the principal.
*/ inline const Aws::String& GetPrincipal() const{ return m_principal; } /** *The Amazon Resource Name (ARN) of the principal.
*/ inline bool PrincipalHasBeenSet() const { return m_principalHasBeenSet; } /** *The Amazon Resource Name (ARN) of the principal.
*/ inline void SetPrincipal(const Aws::String& value) { m_principalHasBeenSet = true; m_principal = value; } /** *The Amazon Resource Name (ARN) of the principal.
*/ inline void SetPrincipal(Aws::String&& value) { m_principalHasBeenSet = true; m_principal = std::move(value); } /** *The Amazon Resource Name (ARN) of the principal.
*/ inline void SetPrincipal(const char* value) { m_principalHasBeenSet = true; m_principal.assign(value); } /** *The Amazon Resource Name (ARN) of the principal.
*/ inline AllowedPrincipal& WithPrincipal(const Aws::String& value) { SetPrincipal(value); return *this;} /** *The Amazon Resource Name (ARN) of the principal.
*/ inline AllowedPrincipal& WithPrincipal(Aws::String&& value) { SetPrincipal(std::move(value)); return *this;} /** *The Amazon Resource Name (ARN) of the principal.
*/ inline AllowedPrincipal& WithPrincipal(const char* value) { SetPrincipal(value); return *this;} /** *The ID of the service permission.
*/ inline const Aws::String& GetServicePermissionId() const{ return m_servicePermissionId; } /** *The ID of the service permission.
*/ inline bool ServicePermissionIdHasBeenSet() const { return m_servicePermissionIdHasBeenSet; } /** *The ID of the service permission.
*/ inline void SetServicePermissionId(const Aws::String& value) { m_servicePermissionIdHasBeenSet = true; m_servicePermissionId = value; } /** *The ID of the service permission.
*/ inline void SetServicePermissionId(Aws::String&& value) { m_servicePermissionIdHasBeenSet = true; m_servicePermissionId = std::move(value); } /** *The ID of the service permission.
*/ inline void SetServicePermissionId(const char* value) { m_servicePermissionIdHasBeenSet = true; m_servicePermissionId.assign(value); } /** *The ID of the service permission.
*/ inline AllowedPrincipal& WithServicePermissionId(const Aws::String& value) { SetServicePermissionId(value); return *this;} /** *The ID of the service permission.
*/ inline AllowedPrincipal& WithServicePermissionId(Aws::String&& value) { SetServicePermissionId(std::move(value)); return *this;} /** *The ID of the service permission.
*/ inline AllowedPrincipal& WithServicePermissionId(const char* value) { SetServicePermissionId(value); return *this;} /** *The tags.
*/ inline const Aws::VectorThe tags.
*/ inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; } /** *The tags.
*/ inline void SetTags(const Aws::VectorThe tags.
*/ inline void SetTags(Aws::VectorThe tags.
*/ inline AllowedPrincipal& WithTags(const Aws::VectorThe tags.
*/ inline AllowedPrincipal& WithTags(Aws::VectorThe tags.
*/ inline AllowedPrincipal& AddTags(const Tag& value) { m_tagsHasBeenSet = true; m_tags.push_back(value); return *this; } /** *The tags.
*/ inline AllowedPrincipal& AddTags(Tag&& value) { m_tagsHasBeenSet = true; m_tags.push_back(std::move(value)); return *this; } /** *The ID of the service.
*/ inline const Aws::String& GetServiceId() const{ return m_serviceId; } /** *The ID of the service.
*/ inline bool ServiceIdHasBeenSet() const { return m_serviceIdHasBeenSet; } /** *The ID of the service.
*/ inline void SetServiceId(const Aws::String& value) { m_serviceIdHasBeenSet = true; m_serviceId = value; } /** *The ID of the service.
*/ inline void SetServiceId(Aws::String&& value) { m_serviceIdHasBeenSet = true; m_serviceId = std::move(value); } /** *The ID of the service.
*/ inline void SetServiceId(const char* value) { m_serviceIdHasBeenSet = true; m_serviceId.assign(value); } /** *The ID of the service.
*/ inline AllowedPrincipal& WithServiceId(const Aws::String& value) { SetServiceId(value); return *this;} /** *The ID of the service.
*/ inline AllowedPrincipal& WithServiceId(Aws::String&& value) { SetServiceId(std::move(value)); return *this;} /** *The ID of the service.
*/ inline AllowedPrincipal& WithServiceId(const char* value) { SetServiceId(value); return *this;} private: PrincipalType m_principalType; bool m_principalTypeHasBeenSet = false; Aws::String m_principal; bool m_principalHasBeenSet = false; Aws::String m_servicePermissionId; bool m_servicePermissionIdHasBeenSet = false; Aws::Vector