AWS SDK for C++  0.14.3
AWS SDK for C++
PutItemResult.h
Go to the documentation of this file.
1 /*
2 * Copyright 2010-2016 Amazon.com, Inc. or its affiliates. All Rights Reserved.
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License").
5 * You may not use this file except in compliance with the License.
6 * A copy of the License is located at
7 *
8 * http://aws.amazon.com/apache2.0
9 *
10 * or in the "license" file accompanying this file. This file is distributed
11 * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
12 * express or implied. See the License for the specific language governing
13 * permissions and limitations under the License.
14 */
15 #pragma once
22 
23 namespace Aws
24 {
25 template<typename RESULT_TYPE>
26 class AmazonWebServiceResult;
27 
28 namespace Utils
29 {
30 namespace Json
31 {
32  class JsonValue;
33 } // namespace Json
34 } // namespace Utils
35 namespace DynamoDB
36 {
37 namespace Model
38 {
43  {
44  public:
45  PutItemResult();
48 
54  inline const Aws::Map<Aws::String, AttributeValue>& GetAttributes() const{ return m_attributes; }
55 
61  inline void SetAttributes(const Aws::Map<Aws::String, AttributeValue>& value) { m_attributes = value; }
62 
68  inline void SetAttributes(Aws::Map<Aws::String, AttributeValue>&& value) { m_attributes = value; }
69 
75  inline PutItemResult& WithAttributes(const Aws::Map<Aws::String, AttributeValue>& value) { SetAttributes(value); return *this;}
76 
82  inline PutItemResult& WithAttributes(Aws::Map<Aws::String, AttributeValue>&& value) { SetAttributes(value); return *this;}
83 
89  inline PutItemResult& AddAttributes(const Aws::String& key, const AttributeValue& value) { m_attributes[key] = value; return *this; }
90 
96  inline PutItemResult& AddAttributes(Aws::String&& key, const AttributeValue& value) { m_attributes[key] = value; return *this; }
97 
103  inline PutItemResult& AddAttributes(const Aws::String& key, AttributeValue&& value) { m_attributes[key] = value; return *this; }
104 
110  inline PutItemResult& AddAttributes(Aws::String&& key, AttributeValue&& value) { m_attributes[key] = value; return *this; }
111 
117  inline PutItemResult& AddAttributes(const char* key, AttributeValue&& value) { m_attributes[key] = value; return *this; }
118 
124  inline PutItemResult& AddAttributes(const char* key, const AttributeValue& value) { m_attributes[key] = value; return *this; }
125 
126 
127  inline const ConsumedCapacity& GetConsumedCapacity() const{ return m_consumedCapacity; }
128 
129 
130  inline void SetConsumedCapacity(const ConsumedCapacity& value) { m_consumedCapacity = value; }
131 
132 
133  inline void SetConsumedCapacity(ConsumedCapacity&& value) { m_consumedCapacity = value; }
134 
135 
136  inline PutItemResult& WithConsumedCapacity(const ConsumedCapacity& value) { SetConsumedCapacity(value); return *this;}
137 
138 
139  inline PutItemResult& WithConsumedCapacity(ConsumedCapacity&& value) { SetConsumedCapacity(value); return *this;}
140 
157  inline const ItemCollectionMetrics& GetItemCollectionMetrics() const{ return m_itemCollectionMetrics; }
158 
175  inline void SetItemCollectionMetrics(const ItemCollectionMetrics& value) { m_itemCollectionMetrics = value; }
176 
193  inline void SetItemCollectionMetrics(ItemCollectionMetrics&& value) { m_itemCollectionMetrics = value; }
194 
211  inline PutItemResult& WithItemCollectionMetrics(const ItemCollectionMetrics& value) { SetItemCollectionMetrics(value); return *this;}
212 
229  inline PutItemResult& WithItemCollectionMetrics(ItemCollectionMetrics&& value) { SetItemCollectionMetrics(value); return *this;}
230 
231  private:
233  ConsumedCapacity m_consumedCapacity;
234  ItemCollectionMetrics m_itemCollectionMetrics;
235  };
236 
237 } // namespace Model
238 } // namespace DynamoDB
239 } // namespace Aws
void SetConsumedCapacity(ConsumedCapacity &&value)
PutItemResult & AddAttributes(const Aws::String &key, const AttributeValue &value)
Definition: PutItemResult.h:89
PutItemResult & WithAttributes(const Aws::Map< Aws::String, AttributeValue > &value)
Definition: PutItemResult.h:75
const ConsumedCapacity & GetConsumedCapacity() const
void SetItemCollectionMetrics(const ItemCollectionMetrics &value)
std::map< K, V, std::less< K >, Aws::Allocator< std::pair< const K, V > > > Map
Definition: AWSMap.h:28
PutItemResult & WithConsumedCapacity(const ConsumedCapacity &value)
void SetConsumedCapacity(const ConsumedCapacity &value)
void SetAttributes(Aws::Map< Aws::String, AttributeValue > &&value)
Definition: PutItemResult.h:68
PutItemResult & AddAttributes(const char *key, const AttributeValue &value)
#define AWS_DYNAMODB_API
PutItemResult & AddAttributes(Aws::String &&key, const AttributeValue &value)
Definition: PutItemResult.h:96
const ItemCollectionMetrics & GetItemCollectionMetrics() const
PutItemResult & AddAttributes(Aws::String &&key, AttributeValue &&value)
void SetItemCollectionMetrics(ItemCollectionMetrics &&value)
void SetAttributes(const Aws::Map< Aws::String, AttributeValue > &value)
Definition: PutItemResult.h:61
http://docs.aws.amazon.com/amazondynamodb/latest/APIReference/API_AttributeValue.html ...
PutItemResult & WithAttributes(Aws::Map< Aws::String, AttributeValue > &&value)
Definition: PutItemResult.h:82
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Definition: AWSString.h:97
PutItemResult & WithItemCollectionMetrics(ItemCollectionMetrics &&value)
PutItemResult & AddAttributes(const Aws::String &key, AttributeValue &&value)
PutItemResult & WithConsumedCapacity(ConsumedCapacity &&value)
PutItemResult & WithItemCollectionMetrics(const ItemCollectionMetrics &value)
PutItemResult & AddAttributes(const char *key, AttributeValue &&value)
JSON (JavaScript Object Notation).
const Aws::Map< Aws::String, AttributeValue > & GetAttributes() const
Definition: PutItemResult.h:54