AWS SDK for C++

AWS SDK for C++ Version 1.11.612

Loading...
Searching...
No Matches
TableCreationParameters.h
1
6#pragma once
7#include <aws/dynamodb/DynamoDB_EXPORTS.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/core/utils/memory/stl/AWSVector.h>
10#include <aws/dynamodb/model/BillingMode.h>
11#include <aws/dynamodb/model/ProvisionedThroughput.h>
12#include <aws/dynamodb/model/OnDemandThroughput.h>
13#include <aws/dynamodb/model/SSESpecification.h>
14#include <aws/dynamodb/model/AttributeDefinition.h>
15#include <aws/dynamodb/model/KeySchemaElement.h>
16#include <aws/dynamodb/model/GlobalSecondaryIndex.h>
17#include <utility>
18
19namespace Aws
20{
21namespace Utils
22{
23namespace Json
24{
25 class JsonValue;
26 class JsonView;
27} // namespace Json
28} // namespace Utils
29namespace DynamoDB
30{
31namespace Model
32{
33
41 {
42 public:
43 AWS_DYNAMODB_API TableCreationParameters() = default;
46 AWS_DYNAMODB_API Aws::Utils::Json::JsonValue Jsonize() const;
47
48
50
53 inline const Aws::String& GetTableName() const { return m_tableName; }
54 inline bool TableNameHasBeenSet() const { return m_tableNameHasBeenSet; }
55 template<typename TableNameT = Aws::String>
56 void SetTableName(TableNameT&& value) { m_tableNameHasBeenSet = true; m_tableName = std::forward<TableNameT>(value); }
57 template<typename TableNameT = Aws::String>
58 TableCreationParameters& WithTableName(TableNameT&& value) { SetTableName(std::forward<TableNameT>(value)); return *this;}
60
62
65 inline const Aws::Vector<AttributeDefinition>& GetAttributeDefinitions() const { return m_attributeDefinitions; }
66 inline bool AttributeDefinitionsHasBeenSet() const { return m_attributeDefinitionsHasBeenSet; }
67 template<typename AttributeDefinitionsT = Aws::Vector<AttributeDefinition>>
68 void SetAttributeDefinitions(AttributeDefinitionsT&& value) { m_attributeDefinitionsHasBeenSet = true; m_attributeDefinitions = std::forward<AttributeDefinitionsT>(value); }
69 template<typename AttributeDefinitionsT = Aws::Vector<AttributeDefinition>>
70 TableCreationParameters& WithAttributeDefinitions(AttributeDefinitionsT&& value) { SetAttributeDefinitions(std::forward<AttributeDefinitionsT>(value)); return *this;}
71 template<typename AttributeDefinitionsT = AttributeDefinition>
72 TableCreationParameters& AddAttributeDefinitions(AttributeDefinitionsT&& value) { m_attributeDefinitionsHasBeenSet = true; m_attributeDefinitions.emplace_back(std::forward<AttributeDefinitionsT>(value)); return *this; }
74
76
80 inline const Aws::Vector<KeySchemaElement>& GetKeySchema() const { return m_keySchema; }
81 inline bool KeySchemaHasBeenSet() const { return m_keySchemaHasBeenSet; }
82 template<typename KeySchemaT = Aws::Vector<KeySchemaElement>>
83 void SetKeySchema(KeySchemaT&& value) { m_keySchemaHasBeenSet = true; m_keySchema = std::forward<KeySchemaT>(value); }
84 template<typename KeySchemaT = Aws::Vector<KeySchemaElement>>
85 TableCreationParameters& WithKeySchema(KeySchemaT&& value) { SetKeySchema(std::forward<KeySchemaT>(value)); return *this;}
86 template<typename KeySchemaT = KeySchemaElement>
87 TableCreationParameters& AddKeySchema(KeySchemaT&& value) { m_keySchemaHasBeenSet = true; m_keySchema.emplace_back(std::forward<KeySchemaT>(value)); return *this; }
89
91
95 inline BillingMode GetBillingMode() const { return m_billingMode; }
96 inline bool BillingModeHasBeenSet() const { return m_billingModeHasBeenSet; }
97 inline void SetBillingMode(BillingMode value) { m_billingModeHasBeenSet = true; m_billingMode = value; }
98 inline TableCreationParameters& WithBillingMode(BillingMode value) { SetBillingMode(value); return *this;}
100
102
103 inline const ProvisionedThroughput& GetProvisionedThroughput() const { return m_provisionedThroughput; }
104 inline bool ProvisionedThroughputHasBeenSet() const { return m_provisionedThroughputHasBeenSet; }
105 template<typename ProvisionedThroughputT = ProvisionedThroughput>
106 void SetProvisionedThroughput(ProvisionedThroughputT&& value) { m_provisionedThroughputHasBeenSet = true; m_provisionedThroughput = std::forward<ProvisionedThroughputT>(value); }
107 template<typename ProvisionedThroughputT = ProvisionedThroughput>
108 TableCreationParameters& WithProvisionedThroughput(ProvisionedThroughputT&& value) { SetProvisionedThroughput(std::forward<ProvisionedThroughputT>(value)); return *this;}
110
112
113 inline const OnDemandThroughput& GetOnDemandThroughput() const { return m_onDemandThroughput; }
114 inline bool OnDemandThroughputHasBeenSet() const { return m_onDemandThroughputHasBeenSet; }
115 template<typename OnDemandThroughputT = OnDemandThroughput>
116 void SetOnDemandThroughput(OnDemandThroughputT&& value) { m_onDemandThroughputHasBeenSet = true; m_onDemandThroughput = std::forward<OnDemandThroughputT>(value); }
117 template<typename OnDemandThroughputT = OnDemandThroughput>
118 TableCreationParameters& WithOnDemandThroughput(OnDemandThroughputT&& value) { SetOnDemandThroughput(std::forward<OnDemandThroughputT>(value)); return *this;}
120
122
123 inline const SSESpecification& GetSSESpecification() const { return m_sSESpecification; }
124 inline bool SSESpecificationHasBeenSet() const { return m_sSESpecificationHasBeenSet; }
125 template<typename SSESpecificationT = SSESpecification>
126 void SetSSESpecification(SSESpecificationT&& value) { m_sSESpecificationHasBeenSet = true; m_sSESpecification = std::forward<SSESpecificationT>(value); }
127 template<typename SSESpecificationT = SSESpecification>
128 TableCreationParameters& WithSSESpecification(SSESpecificationT&& value) { SetSSESpecification(std::forward<SSESpecificationT>(value)); return *this;}
130
132
136 inline const Aws::Vector<GlobalSecondaryIndex>& GetGlobalSecondaryIndexes() const { return m_globalSecondaryIndexes; }
137 inline bool GlobalSecondaryIndexesHasBeenSet() const { return m_globalSecondaryIndexesHasBeenSet; }
138 template<typename GlobalSecondaryIndexesT = Aws::Vector<GlobalSecondaryIndex>>
139 void SetGlobalSecondaryIndexes(GlobalSecondaryIndexesT&& value) { m_globalSecondaryIndexesHasBeenSet = true; m_globalSecondaryIndexes = std::forward<GlobalSecondaryIndexesT>(value); }
140 template<typename GlobalSecondaryIndexesT = Aws::Vector<GlobalSecondaryIndex>>
141 TableCreationParameters& WithGlobalSecondaryIndexes(GlobalSecondaryIndexesT&& value) { SetGlobalSecondaryIndexes(std::forward<GlobalSecondaryIndexesT>(value)); return *this;}
142 template<typename GlobalSecondaryIndexesT = GlobalSecondaryIndex>
143 TableCreationParameters& AddGlobalSecondaryIndexes(GlobalSecondaryIndexesT&& value) { m_globalSecondaryIndexesHasBeenSet = true; m_globalSecondaryIndexes.emplace_back(std::forward<GlobalSecondaryIndexesT>(value)); return *this; }
145 private:
146
147 Aws::String m_tableName;
148 bool m_tableNameHasBeenSet = false;
149
150 Aws::Vector<AttributeDefinition> m_attributeDefinitions;
151 bool m_attributeDefinitionsHasBeenSet = false;
152
154 bool m_keySchemaHasBeenSet = false;
155
156 BillingMode m_billingMode{BillingMode::NOT_SET};
157 bool m_billingModeHasBeenSet = false;
158
159 ProvisionedThroughput m_provisionedThroughput;
160 bool m_provisionedThroughputHasBeenSet = false;
161
162 OnDemandThroughput m_onDemandThroughput;
163 bool m_onDemandThroughputHasBeenSet = false;
164
165 SSESpecification m_sSESpecification;
166 bool m_sSESpecificationHasBeenSet = false;
167
168 Aws::Vector<GlobalSecondaryIndex> m_globalSecondaryIndexes;
169 bool m_globalSecondaryIndexesHasBeenSet = false;
170 };
171
172} // namespace Model
173} // namespace DynamoDB
174} // namespace Aws
AWS_DYNAMODB_API Aws::Utils::Json::JsonValue Jsonize() const
AWS_DYNAMODB_API TableCreationParameters(Aws::Utils::Json::JsonView jsonValue)
TableCreationParameters & AddAttributeDefinitions(AttributeDefinitionsT &&value)
AWS_DYNAMODB_API TableCreationParameters()=default
void SetProvisionedThroughput(ProvisionedThroughputT &&value)
TableCreationParameters & WithAttributeDefinitions(AttributeDefinitionsT &&value)
TableCreationParameters & WithSSESpecification(SSESpecificationT &&value)
void SetAttributeDefinitions(AttributeDefinitionsT &&value)
const ProvisionedThroughput & GetProvisionedThroughput() const
const Aws::Vector< GlobalSecondaryIndex > & GetGlobalSecondaryIndexes() const
void SetGlobalSecondaryIndexes(GlobalSecondaryIndexesT &&value)
TableCreationParameters & WithOnDemandThroughput(OnDemandThroughputT &&value)
TableCreationParameters & AddKeySchema(KeySchemaT &&value)
TableCreationParameters & AddGlobalSecondaryIndexes(GlobalSecondaryIndexesT &&value)
const Aws::Vector< KeySchemaElement > & GetKeySchema() const
TableCreationParameters & WithGlobalSecondaryIndexes(GlobalSecondaryIndexesT &&value)
AWS_DYNAMODB_API TableCreationParameters & operator=(Aws::Utils::Json::JsonView jsonValue)
TableCreationParameters & WithBillingMode(BillingMode value)
TableCreationParameters & WithProvisionedThroughput(ProvisionedThroughputT &&value)
const OnDemandThroughput & GetOnDemandThroughput() const
void SetOnDemandThroughput(OnDemandThroughputT &&value)
const Aws::Vector< AttributeDefinition > & GetAttributeDefinitions() const
TableCreationParameters & WithKeySchema(KeySchemaT &&value)
TableCreationParameters & WithTableName(TableNameT &&value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue