AWS SDK for C++

AWS SDK for C++ Version 1.11.900

Loading...
Searching...
No Matches
LogMetadata.h
1
6#pragma once
7#include <aws/cloudwatchomni/CloudWatchOmni_EXPORTS.h>
8#include <aws/core/utils/memory/stl/AWSMap.h>
9#include <aws/core/utils/memory/stl/AWSString.h>
10#include <aws/crt/cbor/Cbor.h>
11
12#include <utility>
13
14namespace Aws {
15namespace Utils {
16namespace Cbor {
17class CborValue;
18} // namespace Cbor
19} // namespace Utils
20namespace CloudWatchOmni {
21namespace Model {
22
32 public:
33 AWS_CLOUDWATCHOMNI_API LogMetadata() = default;
34 AWS_CLOUDWATCHOMNI_API LogMetadata(const std::shared_ptr<Aws::Crt::Cbor::CborDecoder>& decoder);
35 AWS_CLOUDWATCHOMNI_API LogMetadata& operator=(const std::shared_ptr<Aws::Crt::Cbor::CborDecoder>& decoder);
36 AWS_CLOUDWATCHOMNI_API void CborEncode(Aws::Crt::Cbor::CborEncoder& encoder) const;
37
39
40 inline const Aws::Map<Aws::String, Aws::String>& GetAttributes() const { return m_attributes; }
41 inline bool AttributesHasBeenSet() const { return m_attributesHasBeenSet; }
42 template <typename AttributesT = Aws::Map<Aws::String, Aws::String>>
43 void SetAttributes(AttributesT&& value) {
44 m_attributesHasBeenSet = true;
45 m_attributes = std::forward<AttributesT>(value);
46 }
47 template <typename AttributesT = Aws::Map<Aws::String, Aws::String>>
48 LogMetadata& WithAttributes(AttributesT&& value) {
49 SetAttributes(std::forward<AttributesT>(value));
50 return *this;
51 }
52 template <typename AttributesKeyT = Aws::String, typename AttributesValueT = Aws::String>
53 LogMetadata& AddAttributes(AttributesKeyT&& key, AttributesValueT&& value) {
54 m_attributesHasBeenSet = true;
55 m_attributes.emplace(std::forward<AttributesKeyT>(key), std::forward<AttributesValueT>(value));
56 return *this;
57 }
59 private:
61 bool m_attributesHasBeenSet = false;
62};
63
64} // namespace Model
65} // namespace CloudWatchOmni
66} // namespace Aws
void SetAttributes(AttributesT &&value)
Definition LogMetadata.h:43
AWS_CLOUDWATCHOMNI_API void CborEncode(Aws::Crt::Cbor::CborEncoder &encoder) const
AWS_CLOUDWATCHOMNI_API LogMetadata & operator=(const std::shared_ptr< Aws::Crt::Cbor::CborDecoder > &decoder)
LogMetadata & AddAttributes(AttributesKeyT &&key, AttributesValueT &&value)
Definition LogMetadata.h:53
LogMetadata & WithAttributes(AttributesT &&value)
Definition LogMetadata.h:48
AWS_CLOUDWATCHOMNI_API LogMetadata()=default
AWS_CLOUDWATCHOMNI_API LogMetadata(const std::shared_ptr< Aws::Crt::Cbor::CborDecoder > &decoder)
const Aws::Map< Aws::String, Aws::String > & GetAttributes() const
Definition LogMetadata.h:40
std::map< K, V, std::less< K >, Aws::Allocator< std::pair< const K, V > > > Map