AWS SDK for C++

AWS SDK for C++ Version 1.11.440

Loading...
Searching...
No Matches
Update.h
1
6#pragma once
7#include <aws/dynamodb/DynamoDB_EXPORTS.h>
8#include <aws/core/utils/memory/stl/AWSMap.h>
9#include <aws/core/utils/memory/stl/AWSString.h>
10#include <aws/dynamodb/model/ReturnValuesOnConditionCheckFailure.h>
11#include <aws/dynamodb/model/AttributeValue.h>
12#include <utility>
13
14namespace Aws
15{
16namespace Utils
17{
18namespace Json
19{
20 class JsonValue;
21 class JsonView;
22} // namespace Json
23} // namespace Utils
24namespace DynamoDB
25{
26namespace Model
27{
28
35 class Update
36 {
37 public:
38 AWS_DYNAMODB_API Update();
39 AWS_DYNAMODB_API Update(Aws::Utils::Json::JsonView jsonValue);
40 AWS_DYNAMODB_API Update& operator=(Aws::Utils::Json::JsonView jsonValue);
41 AWS_DYNAMODB_API Aws::Utils::Json::JsonValue Jsonize() const;
42
43
45
49 inline const Aws::Map<Aws::String, AttributeValue>& GetKey() const{ return m_key; }
50 inline bool KeyHasBeenSet() const { return m_keyHasBeenSet; }
51 inline void SetKey(const Aws::Map<Aws::String, AttributeValue>& value) { m_keyHasBeenSet = true; m_key = value; }
52 inline void SetKey(Aws::Map<Aws::String, AttributeValue>&& value) { m_keyHasBeenSet = true; m_key = std::move(value); }
53 inline Update& WithKey(const Aws::Map<Aws::String, AttributeValue>& value) { SetKey(value); return *this;}
54 inline Update& WithKey(Aws::Map<Aws::String, AttributeValue>&& value) { SetKey(std::move(value)); return *this;}
55 inline Update& AddKey(const Aws::String& key, const AttributeValue& value) { m_keyHasBeenSet = true; m_key.emplace(key, value); return *this; }
56 inline Update& AddKey(Aws::String&& key, const AttributeValue& value) { m_keyHasBeenSet = true; m_key.emplace(std::move(key), value); return *this; }
57 inline Update& AddKey(const Aws::String& key, AttributeValue&& value) { m_keyHasBeenSet = true; m_key.emplace(key, std::move(value)); return *this; }
58 inline Update& AddKey(Aws::String&& key, AttributeValue&& value) { m_keyHasBeenSet = true; m_key.emplace(std::move(key), std::move(value)); return *this; }
59 inline Update& AddKey(const char* key, AttributeValue&& value) { m_keyHasBeenSet = true; m_key.emplace(key, std::move(value)); return *this; }
60 inline Update& AddKey(const char* key, const AttributeValue& value) { m_keyHasBeenSet = true; m_key.emplace(key, value); return *this; }
62
64
68 inline const Aws::String& GetUpdateExpression() const{ return m_updateExpression; }
69 inline bool UpdateExpressionHasBeenSet() const { return m_updateExpressionHasBeenSet; }
70 inline void SetUpdateExpression(const Aws::String& value) { m_updateExpressionHasBeenSet = true; m_updateExpression = value; }
71 inline void SetUpdateExpression(Aws::String&& value) { m_updateExpressionHasBeenSet = true; m_updateExpression = std::move(value); }
72 inline void SetUpdateExpression(const char* value) { m_updateExpressionHasBeenSet = true; m_updateExpression.assign(value); }
73 inline Update& WithUpdateExpression(const Aws::String& value) { SetUpdateExpression(value); return *this;}
74 inline Update& WithUpdateExpression(Aws::String&& value) { SetUpdateExpression(std::move(value)); return *this;}
75 inline Update& WithUpdateExpression(const char* value) { SetUpdateExpression(value); return *this;}
77
79
83 inline const Aws::String& GetTableName() const{ return m_tableName; }
84 inline bool TableNameHasBeenSet() const { return m_tableNameHasBeenSet; }
85 inline void SetTableName(const Aws::String& value) { m_tableNameHasBeenSet = true; m_tableName = value; }
86 inline void SetTableName(Aws::String&& value) { m_tableNameHasBeenSet = true; m_tableName = std::move(value); }
87 inline void SetTableName(const char* value) { m_tableNameHasBeenSet = true; m_tableName.assign(value); }
88 inline Update& WithTableName(const Aws::String& value) { SetTableName(value); return *this;}
89 inline Update& WithTableName(Aws::String&& value) { SetTableName(std::move(value)); return *this;}
90 inline Update& WithTableName(const char* value) { SetTableName(value); return *this;}
92
94
98 inline const Aws::String& GetConditionExpression() const{ return m_conditionExpression; }
99 inline bool ConditionExpressionHasBeenSet() const { return m_conditionExpressionHasBeenSet; }
100 inline void SetConditionExpression(const Aws::String& value) { m_conditionExpressionHasBeenSet = true; m_conditionExpression = value; }
101 inline void SetConditionExpression(Aws::String&& value) { m_conditionExpressionHasBeenSet = true; m_conditionExpression = std::move(value); }
102 inline void SetConditionExpression(const char* value) { m_conditionExpressionHasBeenSet = true; m_conditionExpression.assign(value); }
103 inline Update& WithConditionExpression(const Aws::String& value) { SetConditionExpression(value); return *this;}
104 inline Update& WithConditionExpression(Aws::String&& value) { SetConditionExpression(std::move(value)); return *this;}
105 inline Update& WithConditionExpression(const char* value) { SetConditionExpression(value); return *this;}
107
109
112 inline const Aws::Map<Aws::String, Aws::String>& GetExpressionAttributeNames() const{ return m_expressionAttributeNames; }
113 inline bool ExpressionAttributeNamesHasBeenSet() const { return m_expressionAttributeNamesHasBeenSet; }
114 inline void SetExpressionAttributeNames(const Aws::Map<Aws::String, Aws::String>& value) { m_expressionAttributeNamesHasBeenSet = true; m_expressionAttributeNames = value; }
115 inline void SetExpressionAttributeNames(Aws::Map<Aws::String, Aws::String>&& value) { m_expressionAttributeNamesHasBeenSet = true; m_expressionAttributeNames = std::move(value); }
118 inline Update& AddExpressionAttributeNames(const Aws::String& key, const Aws::String& value) { m_expressionAttributeNamesHasBeenSet = true; m_expressionAttributeNames.emplace(key, value); return *this; }
119 inline Update& AddExpressionAttributeNames(Aws::String&& key, const Aws::String& value) { m_expressionAttributeNamesHasBeenSet = true; m_expressionAttributeNames.emplace(std::move(key), value); return *this; }
120 inline Update& AddExpressionAttributeNames(const Aws::String& key, Aws::String&& value) { m_expressionAttributeNamesHasBeenSet = true; m_expressionAttributeNames.emplace(key, std::move(value)); return *this; }
121 inline Update& AddExpressionAttributeNames(Aws::String&& key, Aws::String&& value) { m_expressionAttributeNamesHasBeenSet = true; m_expressionAttributeNames.emplace(std::move(key), std::move(value)); return *this; }
122 inline Update& AddExpressionAttributeNames(const char* key, Aws::String&& value) { m_expressionAttributeNamesHasBeenSet = true; m_expressionAttributeNames.emplace(key, std::move(value)); return *this; }
123 inline Update& AddExpressionAttributeNames(Aws::String&& key, const char* value) { m_expressionAttributeNamesHasBeenSet = true; m_expressionAttributeNames.emplace(std::move(key), value); return *this; }
124 inline Update& AddExpressionAttributeNames(const char* key, const char* value) { m_expressionAttributeNamesHasBeenSet = true; m_expressionAttributeNames.emplace(key, value); return *this; }
126
128
131 inline const Aws::Map<Aws::String, AttributeValue>& GetExpressionAttributeValues() const{ return m_expressionAttributeValues; }
132 inline bool ExpressionAttributeValuesHasBeenSet() const { return m_expressionAttributeValuesHasBeenSet; }
133 inline void SetExpressionAttributeValues(const Aws::Map<Aws::String, AttributeValue>& value) { m_expressionAttributeValuesHasBeenSet = true; m_expressionAttributeValues = value; }
134 inline void SetExpressionAttributeValues(Aws::Map<Aws::String, AttributeValue>&& value) { m_expressionAttributeValuesHasBeenSet = true; m_expressionAttributeValues = std::move(value); }
137 inline Update& AddExpressionAttributeValues(const Aws::String& key, const AttributeValue& value) { m_expressionAttributeValuesHasBeenSet = true; m_expressionAttributeValues.emplace(key, value); return *this; }
138 inline Update& AddExpressionAttributeValues(Aws::String&& key, const AttributeValue& value) { m_expressionAttributeValuesHasBeenSet = true; m_expressionAttributeValues.emplace(std::move(key), value); return *this; }
139 inline Update& AddExpressionAttributeValues(const Aws::String& key, AttributeValue&& value) { m_expressionAttributeValuesHasBeenSet = true; m_expressionAttributeValues.emplace(key, std::move(value)); return *this; }
140 inline Update& AddExpressionAttributeValues(Aws::String&& key, AttributeValue&& value) { m_expressionAttributeValuesHasBeenSet = true; m_expressionAttributeValues.emplace(std::move(key), std::move(value)); return *this; }
141 inline Update& AddExpressionAttributeValues(const char* key, AttributeValue&& value) { m_expressionAttributeValuesHasBeenSet = true; m_expressionAttributeValues.emplace(key, std::move(value)); return *this; }
142 inline Update& AddExpressionAttributeValues(const char* key, const AttributeValue& value) { m_expressionAttributeValuesHasBeenSet = true; m_expressionAttributeValues.emplace(key, value); return *this; }
144
146
152 inline const ReturnValuesOnConditionCheckFailure& GetReturnValuesOnConditionCheckFailure() const{ return m_returnValuesOnConditionCheckFailure; }
153 inline bool ReturnValuesOnConditionCheckFailureHasBeenSet() const { return m_returnValuesOnConditionCheckFailureHasBeenSet; }
154 inline void SetReturnValuesOnConditionCheckFailure(const ReturnValuesOnConditionCheckFailure& value) { m_returnValuesOnConditionCheckFailureHasBeenSet = true; m_returnValuesOnConditionCheckFailure = value; }
155 inline void SetReturnValuesOnConditionCheckFailure(ReturnValuesOnConditionCheckFailure&& value) { m_returnValuesOnConditionCheckFailureHasBeenSet = true; m_returnValuesOnConditionCheckFailure = std::move(value); }
159 private:
160
162 bool m_keyHasBeenSet = false;
163
164 Aws::String m_updateExpression;
165 bool m_updateExpressionHasBeenSet = false;
166
167 Aws::String m_tableName;
168 bool m_tableNameHasBeenSet = false;
169
170 Aws::String m_conditionExpression;
171 bool m_conditionExpressionHasBeenSet = false;
172
173 Aws::Map<Aws::String, Aws::String> m_expressionAttributeNames;
174 bool m_expressionAttributeNamesHasBeenSet = false;
175
176 Aws::Map<Aws::String, AttributeValue> m_expressionAttributeValues;
177 bool m_expressionAttributeValuesHasBeenSet = false;
178
179 ReturnValuesOnConditionCheckFailure m_returnValuesOnConditionCheckFailure;
180 bool m_returnValuesOnConditionCheckFailureHasBeenSet = false;
181 };
182
183} // namespace Model
184} // namespace DynamoDB
185} // namespace Aws
http://docs.aws.amazon.com/amazondynamodb/latest/APIReference/API_AttributeValue.html
Update & AddExpressionAttributeNames(const Aws::String &key, Aws::String &&value)
Definition Update.h:120
void SetExpressionAttributeNames(Aws::Map< Aws::String, Aws::String > &&value)
Definition Update.h:115
Update & WithReturnValuesOnConditionCheckFailure(const ReturnValuesOnConditionCheckFailure &value)
Definition Update.h:156
const Aws::Map< Aws::String, AttributeValue > & GetKey() const
Definition Update.h:49
void SetExpressionAttributeValues(Aws::Map< Aws::String, AttributeValue > &&value)
Definition Update.h:134
Update & AddExpressionAttributeNames(Aws::String &&key, const Aws::String &value)
Definition Update.h:119
const Aws::String & GetConditionExpression() const
Definition Update.h:98
void SetReturnValuesOnConditionCheckFailure(const ReturnValuesOnConditionCheckFailure &value)
Definition Update.h:154
Update & AddExpressionAttributeNames(const char *key, Aws::String &&value)
Definition Update.h:122
void SetConditionExpression(const Aws::String &value)
Definition Update.h:100
Update & AddExpressionAttributeValues(const char *key, const AttributeValue &value)
Definition Update.h:142
Update & AddExpressionAttributeNames(const char *key, const char *value)
Definition Update.h:124
Update & AddExpressionAttributeValues(const char *key, AttributeValue &&value)
Definition Update.h:141
Update & WithConditionExpression(const Aws::String &value)
Definition Update.h:103
void SetKey(const Aws::Map< Aws::String, AttributeValue > &value)
Definition Update.h:51
Update & WithExpressionAttributeNames(const Aws::Map< Aws::String, Aws::String > &value)
Definition Update.h:116
void SetTableName(const char *value)
Definition Update.h:87
bool TableNameHasBeenSet() const
Definition Update.h:84
const Aws::String & GetTableName() const
Definition Update.h:83
void SetConditionExpression(Aws::String &&value)
Definition Update.h:101
Update & AddExpressionAttributeValues(Aws::String &&key, const AttributeValue &value)
Definition Update.h:138
Update & AddKey(Aws::String &&key, const AttributeValue &value)
Definition Update.h:56
Update & AddKey(const Aws::String &key, const AttributeValue &value)
Definition Update.h:55
void SetExpressionAttributeValues(const Aws::Map< Aws::String, AttributeValue > &value)
Definition Update.h:133
Update & WithTableName(const char *value)
Definition Update.h:90
Update & WithKey(const Aws::Map< Aws::String, AttributeValue > &value)
Definition Update.h:53
Update & AddKey(const char *key, const AttributeValue &value)
Definition Update.h:60
Update & AddKey(const char *key, AttributeValue &&value)
Definition Update.h:59
Update & AddExpressionAttributeValues(const Aws::String &key, const AttributeValue &value)
Definition Update.h:137
bool KeyHasBeenSet() const
Definition Update.h:50
AWS_DYNAMODB_API Update()
void SetConditionExpression(const char *value)
Definition Update.h:102
AWS_DYNAMODB_API Update & operator=(Aws::Utils::Json::JsonView jsonValue)
Update & AddKey(Aws::String &&key, AttributeValue &&value)
Definition Update.h:58
const Aws::Map< Aws::String, Aws::String > & GetExpressionAttributeNames() const
Definition Update.h:112
Update & WithExpressionAttributeValues(const Aws::Map< Aws::String, AttributeValue > &value)
Definition Update.h:135
bool ExpressionAttributeValuesHasBeenSet() const
Definition Update.h:132
Update & WithUpdateExpression(const Aws::String &value)
Definition Update.h:73
void SetReturnValuesOnConditionCheckFailure(ReturnValuesOnConditionCheckFailure &&value)
Definition Update.h:155
const ReturnValuesOnConditionCheckFailure & GetReturnValuesOnConditionCheckFailure() const
Definition Update.h:152
bool ConditionExpressionHasBeenSet() const
Definition Update.h:99
Update & WithConditionExpression(const char *value)
Definition Update.h:105
void SetUpdateExpression(Aws::String &&value)
Definition Update.h:71
const Aws::Map< Aws::String, AttributeValue > & GetExpressionAttributeValues() const
Definition Update.h:131
Update & WithUpdateExpression(Aws::String &&value)
Definition Update.h:74
Update & AddExpressionAttributeNames(Aws::String &&key, Aws::String &&value)
Definition Update.h:121
void SetKey(Aws::Map< Aws::String, AttributeValue > &&value)
Definition Update.h:52
Update & WithKey(Aws::Map< Aws::String, AttributeValue > &&value)
Definition Update.h:54
Update & WithReturnValuesOnConditionCheckFailure(ReturnValuesOnConditionCheckFailure &&value)
Definition Update.h:157
Update & WithExpressionAttributeValues(Aws::Map< Aws::String, AttributeValue > &&value)
Definition Update.h:136
Update & AddExpressionAttributeNames(const Aws::String &key, const Aws::String &value)
Definition Update.h:118
Update & WithExpressionAttributeNames(Aws::Map< Aws::String, Aws::String > &&value)
Definition Update.h:117
Update & AddExpressionAttributeValues(const Aws::String &key, AttributeValue &&value)
Definition Update.h:139
void SetUpdateExpression(const char *value)
Definition Update.h:72
bool ReturnValuesOnConditionCheckFailureHasBeenSet() const
Definition Update.h:153
AWS_DYNAMODB_API Update(Aws::Utils::Json::JsonView jsonValue)
Update & WithTableName(const Aws::String &value)
Definition Update.h:88
Update & WithConditionExpression(Aws::String &&value)
Definition Update.h:104
AWS_DYNAMODB_API Aws::Utils::Json::JsonValue Jsonize() const
Update & WithUpdateExpression(const char *value)
Definition Update.h:75
void SetUpdateExpression(const Aws::String &value)
Definition Update.h:70
const Aws::String & GetUpdateExpression() const
Definition Update.h:68
Update & WithTableName(Aws::String &&value)
Definition Update.h:89
void SetTableName(Aws::String &&value)
Definition Update.h:86
bool ExpressionAttributeNamesHasBeenSet() const
Definition Update.h:113
Update & AddKey(const Aws::String &key, AttributeValue &&value)
Definition Update.h:57
bool UpdateExpressionHasBeenSet() const
Definition Update.h:69
Update & AddExpressionAttributeValues(Aws::String &&key, AttributeValue &&value)
Definition Update.h:140
Update & AddExpressionAttributeNames(Aws::String &&key, const char *value)
Definition Update.h:123
void SetExpressionAttributeNames(const Aws::Map< Aws::String, Aws::String > &value)
Definition Update.h:114
void SetTableName(const Aws::String &value)
Definition Update.h:85
std::map< K, V, std::less< K >, Aws::Allocator< std::pair< const K, V > > > Map
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Aws::Utils::Json::JsonValue JsonValue