AWS SDK for C++  0.14.3
AWS SDK for C++
Projection.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
20 
21 namespace Aws
22 {
23 namespace Utils
24 {
25 namespace Json
26 {
27  class JsonValue;
28 } // namespace Json
29 } // namespace Utils
30 namespace DynamoDB
31 {
32 namespace Model
33 {
34 
41  {
42  public:
43  Projection();
44  Projection(const Aws::Utils::Json::JsonValue& jsonValue);
45  Projection& operator=(const Aws::Utils::Json::JsonValue& jsonValue);
46  Aws::Utils::Json::JsonValue Jsonize() const;
47 
56  inline const ProjectionType& GetProjectionType() const{ return m_projectionType; }
57 
66  inline void SetProjectionType(const ProjectionType& value) { m_projectionTypeHasBeenSet = true; m_projectionType = value; }
67 
76  inline void SetProjectionType(ProjectionType&& value) { m_projectionTypeHasBeenSet = true; m_projectionType = value; }
77 
86  inline Projection& WithProjectionType(const ProjectionType& value) { SetProjectionType(value); return *this;}
87 
96  inline Projection& WithProjectionType(ProjectionType&& value) { SetProjectionType(value); return *this;}
97 
105  inline const Aws::Vector<Aws::String>& GetNonKeyAttributes() const{ return m_nonKeyAttributes; }
106 
114  inline void SetNonKeyAttributes(const Aws::Vector<Aws::String>& value) { m_nonKeyAttributesHasBeenSet = true; m_nonKeyAttributes = value; }
115 
123  inline void SetNonKeyAttributes(Aws::Vector<Aws::String>&& value) { m_nonKeyAttributesHasBeenSet = true; m_nonKeyAttributes = value; }
124 
132  inline Projection& WithNonKeyAttributes(const Aws::Vector<Aws::String>& value) { SetNonKeyAttributes(value); return *this;}
133 
141  inline Projection& WithNonKeyAttributes(Aws::Vector<Aws::String>&& value) { SetNonKeyAttributes(value); return *this;}
142 
150  inline Projection& AddNonKeyAttributes(const Aws::String& value) { m_nonKeyAttributesHasBeenSet = true; m_nonKeyAttributes.push_back(value); return *this; }
151 
159  inline Projection& AddNonKeyAttributes(Aws::String&& value) { m_nonKeyAttributesHasBeenSet = true; m_nonKeyAttributes.push_back(value); return *this; }
160 
168  inline Projection& AddNonKeyAttributes(const char* value) { m_nonKeyAttributesHasBeenSet = true; m_nonKeyAttributes.push_back(value); return *this; }
169 
170  private:
171  ProjectionType m_projectionType;
172  bool m_projectionTypeHasBeenSet;
173  Aws::Vector<Aws::String> m_nonKeyAttributes;
174  bool m_nonKeyAttributesHasBeenSet;
175  };
176 
177 } // namespace Model
178 } // namespace DynamoDB
179 } // namespace Aws
void SetProjectionType(const ProjectionType &value)
Definition: Projection.h:66
std::vector< T, Aws::Allocator< T > > Vector
Definition: AWSVector.h:27
void SetProjectionType(ProjectionType &&value)
Definition: Projection.h:76
void SetNonKeyAttributes(const Aws::Vector< Aws::String > &value)
Definition: Projection.h:114
const Aws::Vector< Aws::String > & GetNonKeyAttributes() const
Definition: Projection.h:105
Projection & WithNonKeyAttributes(const Aws::Vector< Aws::String > &value)
Definition: Projection.h:132
#define AWS_DYNAMODB_API
Projection & AddNonKeyAttributes(Aws::String &&value)
Definition: Projection.h:159
Projection & WithProjectionType(ProjectionType &&value)
Definition: Projection.h:96
Projection & AddNonKeyAttributes(const char *value)
Definition: Projection.h:168
const ProjectionType & GetProjectionType() const
Definition: Projection.h:56
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Definition: AWSString.h:97
Projection & WithNonKeyAttributes(Aws::Vector< Aws::String > &&value)
Definition: Projection.h:141
Projection & WithProjectionType(const ProjectionType &value)
Definition: Projection.h:86
void SetNonKeyAttributes(Aws::Vector< Aws::String > &&value)
Definition: Projection.h:123
Projection & AddNonKeyAttributes(const Aws::String &value)
Definition: Projection.h:150
JSON (JavaScript Object Notation).