/** * 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 Utils { namespace Json { class JsonValue; class JsonView; } // namespace Json } // namespace Utils namespace RAM { namespace Model { /** *

Describes a resource associated with a resource share in RAM.

See * Also:

AWS API * Reference

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

The Amazon * Resource Name (ARN) of the resource.

*/ inline const Aws::String& GetArn() const{ return m_arn; } /** *

The Amazon * Resource Name (ARN) of the resource.

*/ inline bool ArnHasBeenSet() const { return m_arnHasBeenSet; } /** *

The Amazon * Resource Name (ARN) of the resource.

*/ inline void SetArn(const Aws::String& value) { m_arnHasBeenSet = true; m_arn = value; } /** *

The Amazon * Resource Name (ARN) of the resource.

*/ inline void SetArn(Aws::String&& value) { m_arnHasBeenSet = true; m_arn = std::move(value); } /** *

The Amazon * Resource Name (ARN) of the resource.

*/ inline void SetArn(const char* value) { m_arnHasBeenSet = true; m_arn.assign(value); } /** *

The Amazon * Resource Name (ARN) of the resource.

*/ inline Resource& WithArn(const Aws::String& value) { SetArn(value); return *this;} /** *

The Amazon * Resource Name (ARN) of the resource.

*/ inline Resource& WithArn(Aws::String&& value) { SetArn(std::move(value)); return *this;} /** *

The Amazon * Resource Name (ARN) of the resource.

*/ inline Resource& WithArn(const char* value) { SetArn(value); return *this;} /** *

The resource type. This takes the form of: * service-code:resource-code, and is case-insensitive. * For example, an Amazon EC2 Subnet would be represented by the string * ec2:subnet.

*/ inline const Aws::String& GetType() const{ return m_type; } /** *

The resource type. This takes the form of: * service-code:resource-code, and is case-insensitive. * For example, an Amazon EC2 Subnet would be represented by the string * ec2:subnet.

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

The resource type. This takes the form of: * service-code:resource-code, and is case-insensitive. * For example, an Amazon EC2 Subnet would be represented by the string * ec2:subnet.

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

The resource type. This takes the form of: * service-code:resource-code, and is case-insensitive. * For example, an Amazon EC2 Subnet would be represented by the string * ec2:subnet.

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

The resource type. This takes the form of: * service-code:resource-code, and is case-insensitive. * For example, an Amazon EC2 Subnet would be represented by the string * ec2:subnet.

*/ inline void SetType(const char* value) { m_typeHasBeenSet = true; m_type.assign(value); } /** *

The resource type. This takes the form of: * service-code:resource-code, and is case-insensitive. * For example, an Amazon EC2 Subnet would be represented by the string * ec2:subnet.

*/ inline Resource& WithType(const Aws::String& value) { SetType(value); return *this;} /** *

The resource type. This takes the form of: * service-code:resource-code, and is case-insensitive. * For example, an Amazon EC2 Subnet would be represented by the string * ec2:subnet.

*/ inline Resource& WithType(Aws::String&& value) { SetType(std::move(value)); return *this;} /** *

The resource type. This takes the form of: * service-code:resource-code, and is case-insensitive. * For example, an Amazon EC2 Subnet would be represented by the string * ec2:subnet.

*/ inline Resource& WithType(const char* value) { SetType(value); return *this;} /** *

The Amazon * Resource Name (ARN) of the resource share this resource is associated * with.

*/ inline const Aws::String& GetResourceShareArn() const{ return m_resourceShareArn; } /** *

The Amazon * Resource Name (ARN) of the resource share this resource is associated * with.

*/ inline bool ResourceShareArnHasBeenSet() const { return m_resourceShareArnHasBeenSet; } /** *

The Amazon * Resource Name (ARN) of the resource share this resource is associated * with.

*/ inline void SetResourceShareArn(const Aws::String& value) { m_resourceShareArnHasBeenSet = true; m_resourceShareArn = value; } /** *

The Amazon * Resource Name (ARN) of the resource share this resource is associated * with.

*/ inline void SetResourceShareArn(Aws::String&& value) { m_resourceShareArnHasBeenSet = true; m_resourceShareArn = std::move(value); } /** *

The Amazon * Resource Name (ARN) of the resource share this resource is associated * with.

*/ inline void SetResourceShareArn(const char* value) { m_resourceShareArnHasBeenSet = true; m_resourceShareArn.assign(value); } /** *

The Amazon * Resource Name (ARN) of the resource share this resource is associated * with.

*/ inline Resource& WithResourceShareArn(const Aws::String& value) { SetResourceShareArn(value); return *this;} /** *

The Amazon * Resource Name (ARN) of the resource share this resource is associated * with.

*/ inline Resource& WithResourceShareArn(Aws::String&& value) { SetResourceShareArn(std::move(value)); return *this;} /** *

The Amazon * Resource Name (ARN) of the resource share this resource is associated * with.

*/ inline Resource& WithResourceShareArn(const char* value) { SetResourceShareArn(value); return *this;} /** *

The Amazon * Resource Name (ARN) of the resource group. This value is available only if * the resource is part of a resource group.

*/ inline const Aws::String& GetResourceGroupArn() const{ return m_resourceGroupArn; } /** *

The Amazon * Resource Name (ARN) of the resource group. This value is available only if * the resource is part of a resource group.

*/ inline bool ResourceGroupArnHasBeenSet() const { return m_resourceGroupArnHasBeenSet; } /** *

The Amazon * Resource Name (ARN) of the resource group. This value is available only if * the resource is part of a resource group.

*/ inline void SetResourceGroupArn(const Aws::String& value) { m_resourceGroupArnHasBeenSet = true; m_resourceGroupArn = value; } /** *

The Amazon * Resource Name (ARN) of the resource group. This value is available only if * the resource is part of a resource group.

*/ inline void SetResourceGroupArn(Aws::String&& value) { m_resourceGroupArnHasBeenSet = true; m_resourceGroupArn = std::move(value); } /** *

The Amazon * Resource Name (ARN) of the resource group. This value is available only if * the resource is part of a resource group.

*/ inline void SetResourceGroupArn(const char* value) { m_resourceGroupArnHasBeenSet = true; m_resourceGroupArn.assign(value); } /** *

The Amazon * Resource Name (ARN) of the resource group. This value is available only if * the resource is part of a resource group.

*/ inline Resource& WithResourceGroupArn(const Aws::String& value) { SetResourceGroupArn(value); return *this;} /** *

The Amazon * Resource Name (ARN) of the resource group. This value is available only if * the resource is part of a resource group.

*/ inline Resource& WithResourceGroupArn(Aws::String&& value) { SetResourceGroupArn(std::move(value)); return *this;} /** *

The Amazon * Resource Name (ARN) of the resource group. This value is available only if * the resource is part of a resource group.

*/ inline Resource& WithResourceGroupArn(const char* value) { SetResourceGroupArn(value); return *this;} /** *

The current status of the resource.

*/ inline const ResourceStatus& GetStatus() const{ return m_status; } /** *

The current status of the resource.

*/ inline bool StatusHasBeenSet() const { return m_statusHasBeenSet; } /** *

The current status of the resource.

*/ inline void SetStatus(const ResourceStatus& value) { m_statusHasBeenSet = true; m_status = value; } /** *

The current status of the resource.

*/ inline void SetStatus(ResourceStatus&& value) { m_statusHasBeenSet = true; m_status = std::move(value); } /** *

The current status of the resource.

*/ inline Resource& WithStatus(const ResourceStatus& value) { SetStatus(value); return *this;} /** *

The current status of the resource.

*/ inline Resource& WithStatus(ResourceStatus&& value) { SetStatus(std::move(value)); return *this;} /** *

A message about the status of the resource.

*/ inline const Aws::String& GetStatusMessage() const{ return m_statusMessage; } /** *

A message about the status of the resource.

*/ inline bool StatusMessageHasBeenSet() const { return m_statusMessageHasBeenSet; } /** *

A message about the status of the resource.

*/ inline void SetStatusMessage(const Aws::String& value) { m_statusMessageHasBeenSet = true; m_statusMessage = value; } /** *

A message about the status of the resource.

*/ inline void SetStatusMessage(Aws::String&& value) { m_statusMessageHasBeenSet = true; m_statusMessage = std::move(value); } /** *

A message about the status of the resource.

*/ inline void SetStatusMessage(const char* value) { m_statusMessageHasBeenSet = true; m_statusMessage.assign(value); } /** *

A message about the status of the resource.

*/ inline Resource& WithStatusMessage(const Aws::String& value) { SetStatusMessage(value); return *this;} /** *

A message about the status of the resource.

*/ inline Resource& WithStatusMessage(Aws::String&& value) { SetStatusMessage(std::move(value)); return *this;} /** *

A message about the status of the resource.

*/ inline Resource& WithStatusMessage(const char* value) { SetStatusMessage(value); return *this;} /** *

The date and time when the resource was associated with the resource * share.

*/ inline const Aws::Utils::DateTime& GetCreationTime() const{ return m_creationTime; } /** *

The date and time when the resource was associated with the resource * share.

*/ inline bool CreationTimeHasBeenSet() const { return m_creationTimeHasBeenSet; } /** *

The date and time when the resource was associated with the resource * share.

*/ inline void SetCreationTime(const Aws::Utils::DateTime& value) { m_creationTimeHasBeenSet = true; m_creationTime = value; } /** *

The date and time when the resource was associated with the resource * share.

*/ inline void SetCreationTime(Aws::Utils::DateTime&& value) { m_creationTimeHasBeenSet = true; m_creationTime = std::move(value); } /** *

The date and time when the resource was associated with the resource * share.

*/ inline Resource& WithCreationTime(const Aws::Utils::DateTime& value) { SetCreationTime(value); return *this;} /** *

The date and time when the resource was associated with the resource * share.

*/ inline Resource& WithCreationTime(Aws::Utils::DateTime&& value) { SetCreationTime(std::move(value)); return *this;} /** *

The date an time when the association between the resource and the resource * share was last updated.

*/ inline const Aws::Utils::DateTime& GetLastUpdatedTime() const{ return m_lastUpdatedTime; } /** *

The date an time when the association between the resource and the resource * share was last updated.

*/ inline bool LastUpdatedTimeHasBeenSet() const { return m_lastUpdatedTimeHasBeenSet; } /** *

The date an time when the association between the resource and the resource * share was last updated.

*/ inline void SetLastUpdatedTime(const Aws::Utils::DateTime& value) { m_lastUpdatedTimeHasBeenSet = true; m_lastUpdatedTime = value; } /** *

The date an time when the association between the resource and the resource * share was last updated.

*/ inline void SetLastUpdatedTime(Aws::Utils::DateTime&& value) { m_lastUpdatedTimeHasBeenSet = true; m_lastUpdatedTime = std::move(value); } /** *

The date an time when the association between the resource and the resource * share was last updated.

*/ inline Resource& WithLastUpdatedTime(const Aws::Utils::DateTime& value) { SetLastUpdatedTime(value); return *this;} /** *

The date an time when the association between the resource and the resource * share was last updated.

*/ inline Resource& WithLastUpdatedTime(Aws::Utils::DateTime&& value) { SetLastUpdatedTime(std::move(value)); return *this;} /** *

Specifies the scope of visibility of this resource:

  • * REGIONAL – The resource can be accessed only by using requests that * target the Amazon Web Services Region in which the resource exists.

  • *
  • GLOBAL – The resource can be accessed from any Amazon Web * Services Region.

*/ inline const ResourceRegionScope& GetResourceRegionScope() const{ return m_resourceRegionScope; } /** *

Specifies the scope of visibility of this resource:

  • * REGIONAL – The resource can be accessed only by using requests that * target the Amazon Web Services Region in which the resource exists.

  • *
  • GLOBAL – The resource can be accessed from any Amazon Web * Services Region.

*/ inline bool ResourceRegionScopeHasBeenSet() const { return m_resourceRegionScopeHasBeenSet; } /** *

Specifies the scope of visibility of this resource:

  • * REGIONAL – The resource can be accessed only by using requests that * target the Amazon Web Services Region in which the resource exists.

  • *
  • GLOBAL – The resource can be accessed from any Amazon Web * Services Region.

*/ inline void SetResourceRegionScope(const ResourceRegionScope& value) { m_resourceRegionScopeHasBeenSet = true; m_resourceRegionScope = value; } /** *

Specifies the scope of visibility of this resource:

  • * REGIONAL – The resource can be accessed only by using requests that * target the Amazon Web Services Region in which the resource exists.

  • *
  • GLOBAL – The resource can be accessed from any Amazon Web * Services Region.

*/ inline void SetResourceRegionScope(ResourceRegionScope&& value) { m_resourceRegionScopeHasBeenSet = true; m_resourceRegionScope = std::move(value); } /** *

Specifies the scope of visibility of this resource:

  • * REGIONAL – The resource can be accessed only by using requests that * target the Amazon Web Services Region in which the resource exists.

  • *
  • GLOBAL – The resource can be accessed from any Amazon Web * Services Region.

*/ inline Resource& WithResourceRegionScope(const ResourceRegionScope& value) { SetResourceRegionScope(value); return *this;} /** *

Specifies the scope of visibility of this resource:

  • * REGIONAL – The resource can be accessed only by using requests that * target the Amazon Web Services Region in which the resource exists.

  • *
  • GLOBAL – The resource can be accessed from any Amazon Web * Services Region.

*/ inline Resource& WithResourceRegionScope(ResourceRegionScope&& value) { SetResourceRegionScope(std::move(value)); return *this;} private: Aws::String m_arn; bool m_arnHasBeenSet = false; Aws::String m_type; bool m_typeHasBeenSet = false; Aws::String m_resourceShareArn; bool m_resourceShareArnHasBeenSet = false; Aws::String m_resourceGroupArn; bool m_resourceGroupArnHasBeenSet = false; ResourceStatus m_status; bool m_statusHasBeenSet = false; Aws::String m_statusMessage; bool m_statusMessageHasBeenSet = false; Aws::Utils::DateTime m_creationTime; bool m_creationTimeHasBeenSet = false; Aws::Utils::DateTime m_lastUpdatedTime; bool m_lastUpdatedTimeHasBeenSet = false; ResourceRegionScope m_resourceRegionScope; bool m_resourceRegionScopeHasBeenSet = false; }; } // namespace Model } // namespace RAM } // namespace Aws