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

Represents the properties of a global secondary index.

See * Also:

AWS * API Reference

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

The name of the global secondary index.

*/ inline const Aws::String& GetIndexName() const{ return m_indexName; } /** *

The name of the global secondary index.

*/ inline bool IndexNameHasBeenSet() const { return m_indexNameHasBeenSet; } /** *

The name of the global secondary index.

*/ inline void SetIndexName(const Aws::String& value) { m_indexNameHasBeenSet = true; m_indexName = value; } /** *

The name of the global secondary index.

*/ inline void SetIndexName(Aws::String&& value) { m_indexNameHasBeenSet = true; m_indexName = std::move(value); } /** *

The name of the global secondary index.

*/ inline void SetIndexName(const char* value) { m_indexNameHasBeenSet = true; m_indexName.assign(value); } /** *

The name of the global secondary index.

*/ inline GlobalSecondaryIndexDescription& WithIndexName(const Aws::String& value) { SetIndexName(value); return *this;} /** *

The name of the global secondary index.

*/ inline GlobalSecondaryIndexDescription& WithIndexName(Aws::String&& value) { SetIndexName(std::move(value)); return *this;} /** *

The name of the global secondary index.

*/ inline GlobalSecondaryIndexDescription& WithIndexName(const char* value) { SetIndexName(value); return *this;} /** *

The complete key schema for a global secondary index, which consists of one * or more pairs of attribute names and key types:

  • * HASH - partition key

  • RANGE - sort * key

The partition key of an item is also known as its * hash attribute. The term "hash attribute" derives from DynamoDB's usage * of an internal hash function to evenly distribute data items across partitions, * based on their partition key values.

The sort key of an item is also * known as its range attribute. The term "range attribute" derives from the * way DynamoDB stores items with the same partition key physically close together, * in sorted order by the sort key value.

*/ inline const Aws::Vector& GetKeySchema() const{ return m_keySchema; } /** *

The complete key schema for a global secondary index, which consists of one * or more pairs of attribute names and key types:

  • * HASH - partition key

  • RANGE - sort * key

The partition key of an item is also known as its * hash attribute. The term "hash attribute" derives from DynamoDB's usage * of an internal hash function to evenly distribute data items across partitions, * based on their partition key values.

The sort key of an item is also * known as its range attribute. The term "range attribute" derives from the * way DynamoDB stores items with the same partition key physically close together, * in sorted order by the sort key value.

*/ inline bool KeySchemaHasBeenSet() const { return m_keySchemaHasBeenSet; } /** *

The complete key schema for a global secondary index, which consists of one * or more pairs of attribute names and key types:

  • * HASH - partition key

  • RANGE - sort * key

The partition key of an item is also known as its * hash attribute. The term "hash attribute" derives from DynamoDB's usage * of an internal hash function to evenly distribute data items across partitions, * based on their partition key values.

The sort key of an item is also * known as its range attribute. The term "range attribute" derives from the * way DynamoDB stores items with the same partition key physically close together, * in sorted order by the sort key value.

*/ inline void SetKeySchema(const Aws::Vector& value) { m_keySchemaHasBeenSet = true; m_keySchema = value; } /** *

The complete key schema for a global secondary index, which consists of one * or more pairs of attribute names and key types:

  • * HASH - partition key

  • RANGE - sort * key

The partition key of an item is also known as its * hash attribute. The term "hash attribute" derives from DynamoDB's usage * of an internal hash function to evenly distribute data items across partitions, * based on their partition key values.

The sort key of an item is also * known as its range attribute. The term "range attribute" derives from the * way DynamoDB stores items with the same partition key physically close together, * in sorted order by the sort key value.

*/ inline void SetKeySchema(Aws::Vector&& value) { m_keySchemaHasBeenSet = true; m_keySchema = std::move(value); } /** *

The complete key schema for a global secondary index, which consists of one * or more pairs of attribute names and key types:

  • * HASH - partition key

  • RANGE - sort * key

The partition key of an item is also known as its * hash attribute. The term "hash attribute" derives from DynamoDB's usage * of an internal hash function to evenly distribute data items across partitions, * based on their partition key values.

The sort key of an item is also * known as its range attribute. The term "range attribute" derives from the * way DynamoDB stores items with the same partition key physically close together, * in sorted order by the sort key value.

*/ inline GlobalSecondaryIndexDescription& WithKeySchema(const Aws::Vector& value) { SetKeySchema(value); return *this;} /** *

The complete key schema for a global secondary index, which consists of one * or more pairs of attribute names and key types:

  • * HASH - partition key

  • RANGE - sort * key

The partition key of an item is also known as its * hash attribute. The term "hash attribute" derives from DynamoDB's usage * of an internal hash function to evenly distribute data items across partitions, * based on their partition key values.

The sort key of an item is also * known as its range attribute. The term "range attribute" derives from the * way DynamoDB stores items with the same partition key physically close together, * in sorted order by the sort key value.

*/ inline GlobalSecondaryIndexDescription& WithKeySchema(Aws::Vector&& value) { SetKeySchema(std::move(value)); return *this;} /** *

The complete key schema for a global secondary index, which consists of one * or more pairs of attribute names and key types:

  • * HASH - partition key

  • RANGE - sort * key

The partition key of an item is also known as its * hash attribute. The term "hash attribute" derives from DynamoDB's usage * of an internal hash function to evenly distribute data items across partitions, * based on their partition key values.

The sort key of an item is also * known as its range attribute. The term "range attribute" derives from the * way DynamoDB stores items with the same partition key physically close together, * in sorted order by the sort key value.

*/ inline GlobalSecondaryIndexDescription& AddKeySchema(const KeySchemaElement& value) { m_keySchemaHasBeenSet = true; m_keySchema.push_back(value); return *this; } /** *

The complete key schema for a global secondary index, which consists of one * or more pairs of attribute names and key types:

  • * HASH - partition key

  • RANGE - sort * key

The partition key of an item is also known as its * hash attribute. The term "hash attribute" derives from DynamoDB's usage * of an internal hash function to evenly distribute data items across partitions, * based on their partition key values.

The sort key of an item is also * known as its range attribute. The term "range attribute" derives from the * way DynamoDB stores items with the same partition key physically close together, * in sorted order by the sort key value.

*/ inline GlobalSecondaryIndexDescription& AddKeySchema(KeySchemaElement&& value) { m_keySchemaHasBeenSet = true; m_keySchema.push_back(std::move(value)); return *this; } /** *

Represents attributes that are copied (projected) from the table into the * global secondary index. These are in addition to the primary key attributes and * index key attributes, which are automatically projected.

*/ inline const Projection& GetProjection() const{ return m_projection; } /** *

Represents attributes that are copied (projected) from the table into the * global secondary index. These are in addition to the primary key attributes and * index key attributes, which are automatically projected.

*/ inline bool ProjectionHasBeenSet() const { return m_projectionHasBeenSet; } /** *

Represents attributes that are copied (projected) from the table into the * global secondary index. These are in addition to the primary key attributes and * index key attributes, which are automatically projected.

*/ inline void SetProjection(const Projection& value) { m_projectionHasBeenSet = true; m_projection = value; } /** *

Represents attributes that are copied (projected) from the table into the * global secondary index. These are in addition to the primary key attributes and * index key attributes, which are automatically projected.

*/ inline void SetProjection(Projection&& value) { m_projectionHasBeenSet = true; m_projection = std::move(value); } /** *

Represents attributes that are copied (projected) from the table into the * global secondary index. These are in addition to the primary key attributes and * index key attributes, which are automatically projected.

*/ inline GlobalSecondaryIndexDescription& WithProjection(const Projection& value) { SetProjection(value); return *this;} /** *

Represents attributes that are copied (projected) from the table into the * global secondary index. These are in addition to the primary key attributes and * index key attributes, which are automatically projected.

*/ inline GlobalSecondaryIndexDescription& WithProjection(Projection&& value) { SetProjection(std::move(value)); return *this;} /** *

The current state of the global secondary index:

  • * CREATING - The index is being created.

  • * UPDATING - The index is being updated.

  • * DELETING - The index is being deleted.

  • * ACTIVE - The index is ready for use.

*/ inline const IndexStatus& GetIndexStatus() const{ return m_indexStatus; } /** *

The current state of the global secondary index:

  • * CREATING - The index is being created.

  • * UPDATING - The index is being updated.

  • * DELETING - The index is being deleted.

  • * ACTIVE - The index is ready for use.

*/ inline bool IndexStatusHasBeenSet() const { return m_indexStatusHasBeenSet; } /** *

The current state of the global secondary index:

  • * CREATING - The index is being created.

  • * UPDATING - The index is being updated.

  • * DELETING - The index is being deleted.

  • * ACTIVE - The index is ready for use.

*/ inline void SetIndexStatus(const IndexStatus& value) { m_indexStatusHasBeenSet = true; m_indexStatus = value; } /** *

The current state of the global secondary index:

  • * CREATING - The index is being created.

  • * UPDATING - The index is being updated.

  • * DELETING - The index is being deleted.

  • * ACTIVE - The index is ready for use.

*/ inline void SetIndexStatus(IndexStatus&& value) { m_indexStatusHasBeenSet = true; m_indexStatus = std::move(value); } /** *

The current state of the global secondary index:

  • * CREATING - The index is being created.

  • * UPDATING - The index is being updated.

  • * DELETING - The index is being deleted.

  • * ACTIVE - The index is ready for use.

*/ inline GlobalSecondaryIndexDescription& WithIndexStatus(const IndexStatus& value) { SetIndexStatus(value); return *this;} /** *

The current state of the global secondary index:

  • * CREATING - The index is being created.

  • * UPDATING - The index is being updated.

  • * DELETING - The index is being deleted.

  • * ACTIVE - The index is ready for use.

*/ inline GlobalSecondaryIndexDescription& WithIndexStatus(IndexStatus&& value) { SetIndexStatus(std::move(value)); return *this;} /** *

Indicates whether the index is currently backfilling. Backfilling is * the process of reading items from the table and determining whether they can be * added to the index. (Not all items will qualify: For example, a partition key * cannot have any duplicate values.) If an item can be added to the index, * DynamoDB will do so. After all items have been processed, the backfilling * operation is complete and Backfilling is false.

You can * delete an index that is being created during the Backfilling phase * when IndexStatus is set to CREATING and Backfilling is * true. You can't delete the index that is being created when * IndexStatus is set to CREATING and Backfilling is * false.

For indexes that were created during a * CreateTable operation, the Backfilling attribute does * not appear in the DescribeTable output.

*/ inline bool GetBackfilling() const{ return m_backfilling; } /** *

Indicates whether the index is currently backfilling. Backfilling is * the process of reading items from the table and determining whether they can be * added to the index. (Not all items will qualify: For example, a partition key * cannot have any duplicate values.) If an item can be added to the index, * DynamoDB will do so. After all items have been processed, the backfilling * operation is complete and Backfilling is false.

You can * delete an index that is being created during the Backfilling phase * when IndexStatus is set to CREATING and Backfilling is * true. You can't delete the index that is being created when * IndexStatus is set to CREATING and Backfilling is * false.

For indexes that were created during a * CreateTable operation, the Backfilling attribute does * not appear in the DescribeTable output.

*/ inline bool BackfillingHasBeenSet() const { return m_backfillingHasBeenSet; } /** *

Indicates whether the index is currently backfilling. Backfilling is * the process of reading items from the table and determining whether they can be * added to the index. (Not all items will qualify: For example, a partition key * cannot have any duplicate values.) If an item can be added to the index, * DynamoDB will do so. After all items have been processed, the backfilling * operation is complete and Backfilling is false.

You can * delete an index that is being created during the Backfilling phase * when IndexStatus is set to CREATING and Backfilling is * true. You can't delete the index that is being created when * IndexStatus is set to CREATING and Backfilling is * false.

For indexes that were created during a * CreateTable operation, the Backfilling attribute does * not appear in the DescribeTable output.

*/ inline void SetBackfilling(bool value) { m_backfillingHasBeenSet = true; m_backfilling = value; } /** *

Indicates whether the index is currently backfilling. Backfilling is * the process of reading items from the table and determining whether they can be * added to the index. (Not all items will qualify: For example, a partition key * cannot have any duplicate values.) If an item can be added to the index, * DynamoDB will do so. After all items have been processed, the backfilling * operation is complete and Backfilling is false.

You can * delete an index that is being created during the Backfilling phase * when IndexStatus is set to CREATING and Backfilling is * true. You can't delete the index that is being created when * IndexStatus is set to CREATING and Backfilling is * false.

For indexes that were created during a * CreateTable operation, the Backfilling attribute does * not appear in the DescribeTable output.

*/ inline GlobalSecondaryIndexDescription& WithBackfilling(bool value) { SetBackfilling(value); return *this;} /** *

Represents the provisioned throughput settings for the specified global * secondary index.

For current minimum and maximum provisioned throughput * values, see Service, * Account, and Table Quotas in the Amazon DynamoDB Developer Guide.

*/ inline const ProvisionedThroughputDescription& GetProvisionedThroughput() const{ return m_provisionedThroughput; } /** *

Represents the provisioned throughput settings for the specified global * secondary index.

For current minimum and maximum provisioned throughput * values, see Service, * Account, and Table Quotas in the Amazon DynamoDB Developer Guide.

*/ inline bool ProvisionedThroughputHasBeenSet() const { return m_provisionedThroughputHasBeenSet; } /** *

Represents the provisioned throughput settings for the specified global * secondary index.

For current minimum and maximum provisioned throughput * values, see Service, * Account, and Table Quotas in the Amazon DynamoDB Developer Guide.

*/ inline void SetProvisionedThroughput(const ProvisionedThroughputDescription& value) { m_provisionedThroughputHasBeenSet = true; m_provisionedThroughput = value; } /** *

Represents the provisioned throughput settings for the specified global * secondary index.

For current minimum and maximum provisioned throughput * values, see Service, * Account, and Table Quotas in the Amazon DynamoDB Developer Guide.

*/ inline void SetProvisionedThroughput(ProvisionedThroughputDescription&& value) { m_provisionedThroughputHasBeenSet = true; m_provisionedThroughput = std::move(value); } /** *

Represents the provisioned throughput settings for the specified global * secondary index.

For current minimum and maximum provisioned throughput * values, see Service, * Account, and Table Quotas in the Amazon DynamoDB Developer Guide.

*/ inline GlobalSecondaryIndexDescription& WithProvisionedThroughput(const ProvisionedThroughputDescription& value) { SetProvisionedThroughput(value); return *this;} /** *

Represents the provisioned throughput settings for the specified global * secondary index.

For current minimum and maximum provisioned throughput * values, see Service, * Account, and Table Quotas in the Amazon DynamoDB Developer Guide.

*/ inline GlobalSecondaryIndexDescription& WithProvisionedThroughput(ProvisionedThroughputDescription&& value) { SetProvisionedThroughput(std::move(value)); return *this;} /** *

The total size of the specified index, in bytes. DynamoDB updates this value * approximately every six hours. Recent changes might not be reflected in this * value.

*/ inline long long GetIndexSizeBytes() const{ return m_indexSizeBytes; } /** *

The total size of the specified index, in bytes. DynamoDB updates this value * approximately every six hours. Recent changes might not be reflected in this * value.

*/ inline bool IndexSizeBytesHasBeenSet() const { return m_indexSizeBytesHasBeenSet; } /** *

The total size of the specified index, in bytes. DynamoDB updates this value * approximately every six hours. Recent changes might not be reflected in this * value.

*/ inline void SetIndexSizeBytes(long long value) { m_indexSizeBytesHasBeenSet = true; m_indexSizeBytes = value; } /** *

The total size of the specified index, in bytes. DynamoDB updates this value * approximately every six hours. Recent changes might not be reflected in this * value.

*/ inline GlobalSecondaryIndexDescription& WithIndexSizeBytes(long long value) { SetIndexSizeBytes(value); return *this;} /** *

The number of items in the specified index. DynamoDB updates this value * approximately every six hours. Recent changes might not be reflected in this * value.

*/ inline long long GetItemCount() const{ return m_itemCount; } /** *

The number of items in the specified index. DynamoDB updates this value * approximately every six hours. Recent changes might not be reflected in this * value.

*/ inline bool ItemCountHasBeenSet() const { return m_itemCountHasBeenSet; } /** *

The number of items in the specified index. DynamoDB updates this value * approximately every six hours. Recent changes might not be reflected in this * value.

*/ inline void SetItemCount(long long value) { m_itemCountHasBeenSet = true; m_itemCount = value; } /** *

The number of items in the specified index. DynamoDB updates this value * approximately every six hours. Recent changes might not be reflected in this * value.

*/ inline GlobalSecondaryIndexDescription& WithItemCount(long long value) { SetItemCount(value); return *this;} /** *

The Amazon Resource Name (ARN) that uniquely identifies the index.

*/ inline const Aws::String& GetIndexArn() const{ return m_indexArn; } /** *

The Amazon Resource Name (ARN) that uniquely identifies the index.

*/ inline bool IndexArnHasBeenSet() const { return m_indexArnHasBeenSet; } /** *

The Amazon Resource Name (ARN) that uniquely identifies the index.

*/ inline void SetIndexArn(const Aws::String& value) { m_indexArnHasBeenSet = true; m_indexArn = value; } /** *

The Amazon Resource Name (ARN) that uniquely identifies the index.

*/ inline void SetIndexArn(Aws::String&& value) { m_indexArnHasBeenSet = true; m_indexArn = std::move(value); } /** *

The Amazon Resource Name (ARN) that uniquely identifies the index.

*/ inline void SetIndexArn(const char* value) { m_indexArnHasBeenSet = true; m_indexArn.assign(value); } /** *

The Amazon Resource Name (ARN) that uniquely identifies the index.

*/ inline GlobalSecondaryIndexDescription& WithIndexArn(const Aws::String& value) { SetIndexArn(value); return *this;} /** *

The Amazon Resource Name (ARN) that uniquely identifies the index.

*/ inline GlobalSecondaryIndexDescription& WithIndexArn(Aws::String&& value) { SetIndexArn(std::move(value)); return *this;} /** *

The Amazon Resource Name (ARN) that uniquely identifies the index.

*/ inline GlobalSecondaryIndexDescription& WithIndexArn(const char* value) { SetIndexArn(value); return *this;} private: Aws::String m_indexName; bool m_indexNameHasBeenSet = false; Aws::Vector m_keySchema; bool m_keySchemaHasBeenSet = false; Projection m_projection; bool m_projectionHasBeenSet = false; IndexStatus m_indexStatus; bool m_indexStatusHasBeenSet = false; bool m_backfilling; bool m_backfillingHasBeenSet = false; ProvisionedThroughputDescription m_provisionedThroughput; bool m_provisionedThroughputHasBeenSet = false; long long m_indexSizeBytes; bool m_indexSizeBytesHasBeenSet = false; long long m_itemCount; bool m_itemCountHasBeenSet = false; Aws::String m_indexArn; bool m_indexArnHasBeenSet = false; }; } // namespace Model } // namespace DynamoDB } // namespace Aws