AWS SDK for C++

AWS SDK for C++ Version 1.11.716

Loading...
Searching...
No Matches
Entity.h
1
6#pragma once
7#include <aws/core/utils/memory/stl/AWSMap.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/logs/CloudWatchLogs_EXPORTS.h>
10
11#include <utility>
12
13namespace Aws {
14namespace Utils {
15namespace Json {
16class JsonValue;
17class JsonView;
18} // namespace Json
19} // namespace Utils
20namespace CloudWatchLogs {
21namespace Model {
22
29class Entity {
30 public:
31 AWS_CLOUDWATCHLOGS_API Entity() = default;
32 AWS_CLOUDWATCHLOGS_API Entity(Aws::Utils::Json::JsonView jsonValue);
33 AWS_CLOUDWATCHLOGS_API Entity& operator=(Aws::Utils::Json::JsonView jsonValue);
34 AWS_CLOUDWATCHLOGS_API Aws::Utils::Json::JsonValue Jsonize() const;
35
37
48 inline const Aws::Map<Aws::String, Aws::String>& GetKeyAttributes() const { return m_keyAttributes; }
49 inline bool KeyAttributesHasBeenSet() const { return m_keyAttributesHasBeenSet; }
50 template <typename KeyAttributesT = Aws::Map<Aws::String, Aws::String>>
51 void SetKeyAttributes(KeyAttributesT&& value) {
52 m_keyAttributesHasBeenSet = true;
53 m_keyAttributes = std::forward<KeyAttributesT>(value);
54 }
55 template <typename KeyAttributesT = Aws::Map<Aws::String, Aws::String>>
56 Entity& WithKeyAttributes(KeyAttributesT&& value) {
57 SetKeyAttributes(std::forward<KeyAttributesT>(value));
58 return *this;
59 }
60 template <typename KeyAttributesKeyT = Aws::String, typename KeyAttributesValueT = Aws::String>
61 Entity& AddKeyAttributes(KeyAttributesKeyT&& key, KeyAttributesValueT&& value) {
62 m_keyAttributesHasBeenSet = true;
63 m_keyAttributes.emplace(std::forward<KeyAttributesKeyT>(key), std::forward<KeyAttributesValueT>(value));
64 return *this;
65 }
67
69
77 inline const Aws::Map<Aws::String, Aws::String>& GetAttributes() const { return m_attributes; }
78 inline bool AttributesHasBeenSet() const { return m_attributesHasBeenSet; }
79 template <typename AttributesT = Aws::Map<Aws::String, Aws::String>>
80 void SetAttributes(AttributesT&& value) {
81 m_attributesHasBeenSet = true;
82 m_attributes = std::forward<AttributesT>(value);
83 }
84 template <typename AttributesT = Aws::Map<Aws::String, Aws::String>>
85 Entity& WithAttributes(AttributesT&& value) {
86 SetAttributes(std::forward<AttributesT>(value));
87 return *this;
88 }
89 template <typename AttributesKeyT = Aws::String, typename AttributesValueT = Aws::String>
90 Entity& AddAttributes(AttributesKeyT&& key, AttributesValueT&& value) {
91 m_attributesHasBeenSet = true;
92 m_attributes.emplace(std::forward<AttributesKeyT>(key), std::forward<AttributesValueT>(value));
93 return *this;
94 }
96 private:
98
100 bool m_keyAttributesHasBeenSet = false;
101 bool m_attributesHasBeenSet = false;
102};
103
104} // namespace Model
105} // namespace CloudWatchLogs
106} // namespace Aws
Entity & AddAttributes(AttributesKeyT &&key, AttributesValueT &&value)
Definition Entity.h:90
AWS_CLOUDWATCHLOGS_API Entity & operator=(Aws::Utils::Json::JsonView jsonValue)
bool KeyAttributesHasBeenSet() const
Definition Entity.h:49
Entity & WithKeyAttributes(KeyAttributesT &&value)
Definition Entity.h:56
AWS_CLOUDWATCHLOGS_API Entity()=default
const Aws::Map< Aws::String, Aws::String > & GetAttributes() const
Definition Entity.h:77
AWS_CLOUDWATCHLOGS_API Entity(Aws::Utils::Json::JsonView jsonValue)
AWS_CLOUDWATCHLOGS_API Aws::Utils::Json::JsonValue Jsonize() const
Entity & AddKeyAttributes(KeyAttributesKeyT &&key, KeyAttributesValueT &&value)
Definition Entity.h:61
void SetKeyAttributes(KeyAttributesT &&value)
Definition Entity.h:51
Entity & WithAttributes(AttributesT &&value)
Definition Entity.h:85
const Aws::Map< Aws::String, Aws::String > & GetKeyAttributes() const
Definition Entity.h:48
void SetAttributes(AttributesT &&value)
Definition Entity.h:80
std::map< K, V, std::less< K >, Aws::Allocator< std::pair< const K, V > > > Map
Aws::Utils::Json::JsonValue JsonValue