AWS SDK for C++  0.14.3
AWS SDK for C++
GetItemResult.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
21 
22 namespace Aws
23 {
24 template<typename RESULT_TYPE>
25 class AmazonWebServiceResult;
26 
27 namespace Utils
28 {
29 namespace Json
30 {
31  class JsonValue;
32 } // namespace Json
33 } // namespace Utils
34 namespace DynamoDB
35 {
36 namespace Model
37 {
42  {
43  public:
44  GetItemResult();
47 
52  inline const Aws::Map<Aws::String, AttributeValue>& GetItem() const{ return m_item; }
53 
58  inline void SetItem(const Aws::Map<Aws::String, AttributeValue>& value) { m_item = value; }
59 
64  inline void SetItem(Aws::Map<Aws::String, AttributeValue>&& value) { m_item = value; }
65 
70  inline GetItemResult& WithItem(const Aws::Map<Aws::String, AttributeValue>& value) { SetItem(value); return *this;}
71 
76  inline GetItemResult& WithItem(Aws::Map<Aws::String, AttributeValue>&& value) { SetItem(value); return *this;}
77 
82  inline GetItemResult& AddItem(const Aws::String& key, const AttributeValue& value) { m_item[key] = value; return *this; }
83 
88  inline GetItemResult& AddItem(Aws::String&& key, const AttributeValue& value) { m_item[key] = value; return *this; }
89 
94  inline GetItemResult& AddItem(const Aws::String& key, AttributeValue&& value) { m_item[key] = value; return *this; }
95 
100  inline GetItemResult& AddItem(Aws::String&& key, AttributeValue&& value) { m_item[key] = value; return *this; }
101 
106  inline GetItemResult& AddItem(const char* key, AttributeValue&& value) { m_item[key] = value; return *this; }
107 
112  inline GetItemResult& AddItem(const char* key, const AttributeValue& value) { m_item[key] = value; return *this; }
113 
114 
115  inline const ConsumedCapacity& GetConsumedCapacity() const{ return m_consumedCapacity; }
116 
117 
118  inline void SetConsumedCapacity(const ConsumedCapacity& value) { m_consumedCapacity = value; }
119 
120 
121  inline void SetConsumedCapacity(ConsumedCapacity&& value) { m_consumedCapacity = value; }
122 
123 
124  inline GetItemResult& WithConsumedCapacity(const ConsumedCapacity& value) { SetConsumedCapacity(value); return *this;}
125 
126 
127  inline GetItemResult& WithConsumedCapacity(ConsumedCapacity&& value) { SetConsumedCapacity(value); return *this;}
128 
129  private:
131  ConsumedCapacity m_consumedCapacity;
132  };
133 
134 } // namespace Model
135 } // namespace DynamoDB
136 } // namespace Aws
GetItemResult & AddItem(const Aws::String &key, AttributeValue &&value)
Definition: GetItemResult.h:94
std::map< K, V, std::less< K >, Aws::Allocator< std::pair< const K, V > > > Map
Definition: AWSMap.h:28
void SetConsumedCapacity(ConsumedCapacity &&value)
#define AWS_DYNAMODB_API
GetItemResult & WithItem(Aws::Map< Aws::String, AttributeValue > &&value)
Definition: GetItemResult.h:76
GetItemResult & AddItem(Aws::String &&key, AttributeValue &&value)
GetItemResult & WithItem(const Aws::Map< Aws::String, AttributeValue > &value)
Definition: GetItemResult.h:70
GetItemResult & AddItem(const Aws::String &key, const AttributeValue &value)
Definition: GetItemResult.h:82
GetItemResult & AddItem(const char *key, AttributeValue &&value)
const ConsumedCapacity & GetConsumedCapacity() const
GetItemResult & AddItem(Aws::String &&key, const AttributeValue &value)
Definition: GetItemResult.h:88
GetItemResult & WithConsumedCapacity(const ConsumedCapacity &value)
void SetItem(Aws::Map< Aws::String, AttributeValue > &&value)
Definition: GetItemResult.h:64
http://docs.aws.amazon.com/amazondynamodb/latest/APIReference/API_AttributeValue.html ...
const Aws::Map< Aws::String, AttributeValue > & GetItem() const
Definition: GetItemResult.h:52
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Definition: AWSString.h:97
void SetConsumedCapacity(const ConsumedCapacity &value)
GetItemResult & WithConsumedCapacity(ConsumedCapacity &&value)
void SetItem(const Aws::Map< Aws::String, AttributeValue > &value)
Definition: GetItemResult.h:58
GetItemResult & AddItem(const char *key, const AttributeValue &value)
JSON (JavaScript Object Notation).