AWS SDK for C++

AWS SDK for C++ Version 1.11.440

Loading...
Searching...
No Matches
CreateTableRequest.h
1
6#pragma once
7#include <aws/dynamodb/DynamoDB_EXPORTS.h>
8#include <aws/dynamodb/DynamoDBRequest.h>
9#include <aws/core/utils/memory/stl/AWSVector.h>
10#include <aws/core/utils/memory/stl/AWSString.h>
11#include <aws/dynamodb/model/BillingMode.h>
12#include <aws/dynamodb/model/ProvisionedThroughput.h>
13#include <aws/dynamodb/model/StreamSpecification.h>
14#include <aws/dynamodb/model/SSESpecification.h>
15#include <aws/dynamodb/model/TableClass.h>
16#include <aws/dynamodb/model/OnDemandThroughput.h>
17#include <aws/dynamodb/model/AttributeDefinition.h>
18#include <aws/dynamodb/model/KeySchemaElement.h>
19#include <aws/dynamodb/model/LocalSecondaryIndex.h>
20#include <aws/dynamodb/model/GlobalSecondaryIndex.h>
21#include <aws/dynamodb/model/Tag.h>
22#include <utility>
23
24namespace Aws
25{
26namespace DynamoDB
27{
28namespace Model
29{
30
38 {
39 public:
40 AWS_DYNAMODB_API CreateTableRequest();
41
42 // Service request name is the Operation name which will send this request out,
43 // each operation should has unique request name, so that we can get operation's name from this request.
44 // Note: this is not true for response, multiple operations may have the same response name,
45 // so we can not get operation's name from response.
46 inline virtual const char* GetServiceRequestName() const override { return "CreateTable"; }
47
48 AWS_DYNAMODB_API Aws::String SerializePayload() const override;
49
51
52
54
58 inline const Aws::Vector<AttributeDefinition>& GetAttributeDefinitions() const{ return m_attributeDefinitions; }
59 inline bool AttributeDefinitionsHasBeenSet() const { return m_attributeDefinitionsHasBeenSet; }
60 inline void SetAttributeDefinitions(const Aws::Vector<AttributeDefinition>& value) { m_attributeDefinitionsHasBeenSet = true; m_attributeDefinitions = value; }
61 inline void SetAttributeDefinitions(Aws::Vector<AttributeDefinition>&& value) { m_attributeDefinitionsHasBeenSet = true; m_attributeDefinitions = std::move(value); }
64 inline CreateTableRequest& AddAttributeDefinitions(const AttributeDefinition& value) { m_attributeDefinitionsHasBeenSet = true; m_attributeDefinitions.push_back(value); return *this; }
65 inline CreateTableRequest& AddAttributeDefinitions(AttributeDefinition&& value) { m_attributeDefinitionsHasBeenSet = true; m_attributeDefinitions.push_back(std::move(value)); return *this; }
67
69
73 inline const Aws::String& GetTableName() const{ return m_tableName; }
74 inline bool TableNameHasBeenSet() const { return m_tableNameHasBeenSet; }
75 inline void SetTableName(const Aws::String& value) { m_tableNameHasBeenSet = true; m_tableName = value; }
76 inline void SetTableName(Aws::String&& value) { m_tableNameHasBeenSet = true; m_tableName = std::move(value); }
77 inline void SetTableName(const char* value) { m_tableNameHasBeenSet = true; m_tableName.assign(value); }
78 inline CreateTableRequest& WithTableName(const Aws::String& value) { SetTableName(value); return *this;}
79 inline CreateTableRequest& WithTableName(Aws::String&& value) { SetTableName(std::move(value)); return *this;}
80 inline CreateTableRequest& WithTableName(const char* value) { SetTableName(value); return *this;}
82
84
110 inline const Aws::Vector<KeySchemaElement>& GetKeySchema() const{ return m_keySchema; }
111 inline bool KeySchemaHasBeenSet() const { return m_keySchemaHasBeenSet; }
112 inline void SetKeySchema(const Aws::Vector<KeySchemaElement>& value) { m_keySchemaHasBeenSet = true; m_keySchema = value; }
113 inline void SetKeySchema(Aws::Vector<KeySchemaElement>&& value) { m_keySchemaHasBeenSet = true; m_keySchema = std::move(value); }
114 inline CreateTableRequest& WithKeySchema(const Aws::Vector<KeySchemaElement>& value) { SetKeySchema(value); return *this;}
115 inline CreateTableRequest& WithKeySchema(Aws::Vector<KeySchemaElement>&& value) { SetKeySchema(std::move(value)); return *this;}
116 inline CreateTableRequest& AddKeySchema(const KeySchemaElement& value) { m_keySchemaHasBeenSet = true; m_keySchema.push_back(value); return *this; }
117 inline CreateTableRequest& AddKeySchema(KeySchemaElement&& value) { m_keySchemaHasBeenSet = true; m_keySchema.push_back(std::move(value)); return *this; }
119
121
147 inline const Aws::Vector<LocalSecondaryIndex>& GetLocalSecondaryIndexes() const{ return m_localSecondaryIndexes; }
148 inline bool LocalSecondaryIndexesHasBeenSet() const { return m_localSecondaryIndexesHasBeenSet; }
149 inline void SetLocalSecondaryIndexes(const Aws::Vector<LocalSecondaryIndex>& value) { m_localSecondaryIndexesHasBeenSet = true; m_localSecondaryIndexes = value; }
150 inline void SetLocalSecondaryIndexes(Aws::Vector<LocalSecondaryIndex>&& value) { m_localSecondaryIndexesHasBeenSet = true; m_localSecondaryIndexes = std::move(value); }
153 inline CreateTableRequest& AddLocalSecondaryIndexes(const LocalSecondaryIndex& value) { m_localSecondaryIndexesHasBeenSet = true; m_localSecondaryIndexes.push_back(value); return *this; }
154 inline CreateTableRequest& AddLocalSecondaryIndexes(LocalSecondaryIndex&& value) { m_localSecondaryIndexesHasBeenSet = true; m_localSecondaryIndexes.push_back(std::move(value)); return *this; }
156
158
183 inline const Aws::Vector<GlobalSecondaryIndex>& GetGlobalSecondaryIndexes() const{ return m_globalSecondaryIndexes; }
184 inline bool GlobalSecondaryIndexesHasBeenSet() const { return m_globalSecondaryIndexesHasBeenSet; }
185 inline void SetGlobalSecondaryIndexes(const Aws::Vector<GlobalSecondaryIndex>& value) { m_globalSecondaryIndexesHasBeenSet = true; m_globalSecondaryIndexes = value; }
186 inline void SetGlobalSecondaryIndexes(Aws::Vector<GlobalSecondaryIndex>&& value) { m_globalSecondaryIndexesHasBeenSet = true; m_globalSecondaryIndexes = std::move(value); }
189 inline CreateTableRequest& AddGlobalSecondaryIndexes(const GlobalSecondaryIndex& value) { m_globalSecondaryIndexesHasBeenSet = true; m_globalSecondaryIndexes.push_back(value); return *this; }
190 inline CreateTableRequest& AddGlobalSecondaryIndexes(GlobalSecondaryIndex&& value) { m_globalSecondaryIndexesHasBeenSet = true; m_globalSecondaryIndexes.push_back(std::move(value)); return *this; }
192
194
206 inline const BillingMode& GetBillingMode() const{ return m_billingMode; }
207 inline bool BillingModeHasBeenSet() const { return m_billingModeHasBeenSet; }
208 inline void SetBillingMode(const BillingMode& value) { m_billingModeHasBeenSet = true; m_billingMode = value; }
209 inline void SetBillingMode(BillingMode&& value) { m_billingModeHasBeenSet = true; m_billingMode = std::move(value); }
210 inline CreateTableRequest& WithBillingMode(const BillingMode& value) { SetBillingMode(value); return *this;}
211 inline CreateTableRequest& WithBillingMode(BillingMode&& value) { SetBillingMode(std::move(value)); return *this;}
213
215
225 inline const ProvisionedThroughput& GetProvisionedThroughput() const{ return m_provisionedThroughput; }
226 inline bool ProvisionedThroughputHasBeenSet() const { return m_provisionedThroughputHasBeenSet; }
227 inline void SetProvisionedThroughput(const ProvisionedThroughput& value) { m_provisionedThroughputHasBeenSet = true; m_provisionedThroughput = value; }
228 inline void SetProvisionedThroughput(ProvisionedThroughput&& value) { m_provisionedThroughputHasBeenSet = true; m_provisionedThroughput = std::move(value); }
232
234
249 inline const StreamSpecification& GetStreamSpecification() const{ return m_streamSpecification; }
250 inline bool StreamSpecificationHasBeenSet() const { return m_streamSpecificationHasBeenSet; }
251 inline void SetStreamSpecification(const StreamSpecification& value) { m_streamSpecificationHasBeenSet = true; m_streamSpecification = value; }
252 inline void SetStreamSpecification(StreamSpecification&& value) { m_streamSpecificationHasBeenSet = true; m_streamSpecification = std::move(value); }
256
258
261 inline const SSESpecification& GetSSESpecification() const{ return m_sSESpecification; }
262 inline bool SSESpecificationHasBeenSet() const { return m_sSESpecificationHasBeenSet; }
263 inline void SetSSESpecification(const SSESpecification& value) { m_sSESpecificationHasBeenSet = true; m_sSESpecification = value; }
264 inline void SetSSESpecification(SSESpecification&& value) { m_sSESpecificationHasBeenSet = true; m_sSESpecification = std::move(value); }
266 inline CreateTableRequest& WithSSESpecification(SSESpecification&& value) { SetSSESpecification(std::move(value)); return *this;}
268
270
275 inline const Aws::Vector<Tag>& GetTags() const{ return m_tags; }
276 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
277 inline void SetTags(const Aws::Vector<Tag>& value) { m_tagsHasBeenSet = true; m_tags = value; }
278 inline void SetTags(Aws::Vector<Tag>&& value) { m_tagsHasBeenSet = true; m_tags = std::move(value); }
279 inline CreateTableRequest& WithTags(const Aws::Vector<Tag>& value) { SetTags(value); return *this;}
280 inline CreateTableRequest& WithTags(Aws::Vector<Tag>&& value) { SetTags(std::move(value)); return *this;}
281 inline CreateTableRequest& AddTags(const Tag& value) { m_tagsHasBeenSet = true; m_tags.push_back(value); return *this; }
282 inline CreateTableRequest& AddTags(Tag&& value) { m_tagsHasBeenSet = true; m_tags.push_back(std::move(value)); return *this; }
284
286
290 inline const TableClass& GetTableClass() const{ return m_tableClass; }
291 inline bool TableClassHasBeenSet() const { return m_tableClassHasBeenSet; }
292 inline void SetTableClass(const TableClass& value) { m_tableClassHasBeenSet = true; m_tableClass = value; }
293 inline void SetTableClass(TableClass&& value) { m_tableClassHasBeenSet = true; m_tableClass = std::move(value); }
294 inline CreateTableRequest& WithTableClass(const TableClass& value) { SetTableClass(value); return *this;}
295 inline CreateTableRequest& WithTableClass(TableClass&& value) { SetTableClass(std::move(value)); return *this;}
297
299
303 inline bool GetDeletionProtectionEnabled() const{ return m_deletionProtectionEnabled; }
304 inline bool DeletionProtectionEnabledHasBeenSet() const { return m_deletionProtectionEnabledHasBeenSet; }
305 inline void SetDeletionProtectionEnabled(bool value) { m_deletionProtectionEnabledHasBeenSet = true; m_deletionProtectionEnabled = value; }
308
310
323 inline const Aws::String& GetResourcePolicy() const{ return m_resourcePolicy; }
324 inline bool ResourcePolicyHasBeenSet() const { return m_resourcePolicyHasBeenSet; }
325 inline void SetResourcePolicy(const Aws::String& value) { m_resourcePolicyHasBeenSet = true; m_resourcePolicy = value; }
326 inline void SetResourcePolicy(Aws::String&& value) { m_resourcePolicyHasBeenSet = true; m_resourcePolicy = std::move(value); }
327 inline void SetResourcePolicy(const char* value) { m_resourcePolicyHasBeenSet = true; m_resourcePolicy.assign(value); }
328 inline CreateTableRequest& WithResourcePolicy(const Aws::String& value) { SetResourcePolicy(value); return *this;}
329 inline CreateTableRequest& WithResourcePolicy(Aws::String&& value) { SetResourcePolicy(std::move(value)); return *this;}
330 inline CreateTableRequest& WithResourcePolicy(const char* value) { SetResourcePolicy(value); return *this;}
332
334
340 inline const OnDemandThroughput& GetOnDemandThroughput() const{ return m_onDemandThroughput; }
341 inline bool OnDemandThroughputHasBeenSet() const { return m_onDemandThroughputHasBeenSet; }
342 inline void SetOnDemandThroughput(const OnDemandThroughput& value) { m_onDemandThroughputHasBeenSet = true; m_onDemandThroughput = value; }
343 inline void SetOnDemandThroughput(OnDemandThroughput&& value) { m_onDemandThroughputHasBeenSet = true; m_onDemandThroughput = std::move(value); }
345 inline CreateTableRequest& WithOnDemandThroughput(OnDemandThroughput&& value) { SetOnDemandThroughput(std::move(value)); return *this;}
347 private:
348
349 Aws::Vector<AttributeDefinition> m_attributeDefinitions;
350 bool m_attributeDefinitionsHasBeenSet = false;
351
352 Aws::String m_tableName;
353 bool m_tableNameHasBeenSet = false;
354
356 bool m_keySchemaHasBeenSet = false;
357
358 Aws::Vector<LocalSecondaryIndex> m_localSecondaryIndexes;
359 bool m_localSecondaryIndexesHasBeenSet = false;
360
361 Aws::Vector<GlobalSecondaryIndex> m_globalSecondaryIndexes;
362 bool m_globalSecondaryIndexesHasBeenSet = false;
363
364 BillingMode m_billingMode;
365 bool m_billingModeHasBeenSet = false;
366
367 ProvisionedThroughput m_provisionedThroughput;
368 bool m_provisionedThroughputHasBeenSet = false;
369
370 StreamSpecification m_streamSpecification;
371 bool m_streamSpecificationHasBeenSet = false;
372
373 SSESpecification m_sSESpecification;
374 bool m_sSESpecificationHasBeenSet = false;
375
376 Aws::Vector<Tag> m_tags;
377 bool m_tagsHasBeenSet = false;
378
379 TableClass m_tableClass;
380 bool m_tableClassHasBeenSet = false;
381
382 bool m_deletionProtectionEnabled;
383 bool m_deletionProtectionEnabledHasBeenSet = false;
384
385 Aws::String m_resourcePolicy;
386 bool m_resourcePolicyHasBeenSet = false;
387
388 OnDemandThroughput m_onDemandThroughput;
389 bool m_onDemandThroughputHasBeenSet = false;
390 };
391
392} // namespace Model
393} // namespace DynamoDB
394} // namespace Aws
const Aws::Vector< GlobalSecondaryIndex > & GetGlobalSecondaryIndexes() const
CreateTableRequest & AddKeySchema(KeySchemaElement &&value)
CreateTableRequest & WithGlobalSecondaryIndexes(Aws::Vector< GlobalSecondaryIndex > &&value)
CreateTableRequest & AddAttributeDefinitions(const AttributeDefinition &value)
void SetGlobalSecondaryIndexes(Aws::Vector< GlobalSecondaryIndex > &&value)
void SetSSESpecification(const SSESpecification &value)
CreateTableRequest & WithSSESpecification(SSESpecification &&value)
CreateTableRequest & WithOnDemandThroughput(OnDemandThroughput &&value)
CreateTableRequest & WithProvisionedThroughput(ProvisionedThroughput &&value)
CreateTableRequest & WithStreamSpecification(StreamSpecification &&value)
CreateTableRequest & WithResourcePolicy(Aws::String &&value)
CreateTableRequest & WithTableClass(TableClass &&value)
void SetResourcePolicy(const Aws::String &value)
CreateTableRequest & WithTableClass(const TableClass &value)
CreateTableRequest & WithTableName(Aws::String &&value)
CreateTableRequest & WithAttributeDefinitions(Aws::Vector< AttributeDefinition > &&value)
CreateTableRequest & WithDeletionProtectionEnabled(bool value)
CreateTableRequest & AddLocalSecondaryIndexes(LocalSecondaryIndex &&value)
void SetTableClass(const TableClass &value)
CreateTableRequest & WithKeySchema(const Aws::Vector< KeySchemaElement > &value)
CreateTableRequest & WithTableName(const Aws::String &value)
CreateTableRequest & AddKeySchema(const KeySchemaElement &value)
CreateTableRequest & WithResourcePolicy(const char *value)
CreateTableRequest & AddGlobalSecondaryIndexes(GlobalSecondaryIndex &&value)
void SetTableName(const Aws::String &value)
void SetGlobalSecondaryIndexes(const Aws::Vector< GlobalSecondaryIndex > &value)
void SetLocalSecondaryIndexes(Aws::Vector< LocalSecondaryIndex > &&value)
void SetSSESpecification(SSESpecification &&value)
CreateTableRequest & WithAttributeDefinitions(const Aws::Vector< AttributeDefinition > &value)
CreateTableRequest & WithTags(const Aws::Vector< Tag > &value)
CreateTableRequest & AddTags(const Tag &value)
void SetTags(const Aws::Vector< Tag > &value)
const Aws::Vector< AttributeDefinition > & GetAttributeDefinitions() const
const Aws::Vector< Tag > & GetTags() const
CreateTableRequest & WithLocalSecondaryIndexes(Aws::Vector< LocalSecondaryIndex > &&value)
CreateTableRequest & WithOnDemandThroughput(const OnDemandThroughput &value)
virtual const char * GetServiceRequestName() const override
CreateTableRequest & WithStreamSpecification(const StreamSpecification &value)
void SetOnDemandThroughput(const OnDemandThroughput &value)
CreateTableRequest & WithSSESpecification(const SSESpecification &value)
void SetProvisionedThroughput(const ProvisionedThroughput &value)
const SSESpecification & GetSSESpecification() const
void SetOnDemandThroughput(OnDemandThroughput &&value)
void SetTags(Aws::Vector< Tag > &&value)
void SetKeySchema(const Aws::Vector< KeySchemaElement > &value)
CreateTableRequest & WithTableName(const char *value)
void SetLocalSecondaryIndexes(const Aws::Vector< LocalSecondaryIndex > &value)
CreateTableRequest & WithProvisionedThroughput(const ProvisionedThroughput &value)
void SetKeySchema(Aws::Vector< KeySchemaElement > &&value)
CreateTableRequest & AddTags(Tag &&value)
CreateTableRequest & WithGlobalSecondaryIndexes(const Aws::Vector< GlobalSecondaryIndex > &value)
CreateTableRequest & WithKeySchema(Aws::Vector< KeySchemaElement > &&value)
const Aws::String & GetResourcePolicy() const
void SetStreamSpecification(StreamSpecification &&value)
CreateTableRequest & WithBillingMode(const BillingMode &value)
CreateTableRequest & WithTags(Aws::Vector< Tag > &&value)
CreateTableRequest & WithResourcePolicy(const Aws::String &value)
AWS_DYNAMODB_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override
CreateTableRequest & WithBillingMode(BillingMode &&value)
void SetStreamSpecification(const StreamSpecification &value)
const Aws::Vector< KeySchemaElement > & GetKeySchema() const
const OnDemandThroughput & GetOnDemandThroughput() const
void SetProvisionedThroughput(ProvisionedThroughput &&value)
void SetBillingMode(const BillingMode &value)
const StreamSpecification & GetStreamSpecification() const
AWS_DYNAMODB_API Aws::String SerializePayload() const override
CreateTableRequest & AddLocalSecondaryIndexes(const LocalSecondaryIndex &value)
CreateTableRequest & WithLocalSecondaryIndexes(const Aws::Vector< LocalSecondaryIndex > &value)
const Aws::Vector< LocalSecondaryIndex > & GetLocalSecondaryIndexes() const
CreateTableRequest & AddAttributeDefinitions(AttributeDefinition &&value)
void SetAttributeDefinitions(Aws::Vector< AttributeDefinition > &&value)
void SetAttributeDefinitions(const Aws::Vector< AttributeDefinition > &value)
CreateTableRequest & AddGlobalSecondaryIndexes(const GlobalSecondaryIndex &value)
const ProvisionedThroughput & GetProvisionedThroughput() const
Aws::Map< Aws::String, Aws::String > HeaderValueCollection
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector