AWS SDK for C++

AWS SDK for C++ Version 1.11.943

Loading...
Searching...
No Matches
AccessControlEntry.h
1
6#pragma once
7#include <aws/context/Context_EXPORTS.h>
8#include <aws/context/model/AccessEffect.h>
9#include <aws/context/model/PrincipalType.h>
10#include <aws/core/utils/memory/stl/AWSString.h>
11#include <aws/crt/cbor/Cbor.h>
12
13#include <utility>
14
15namespace Aws {
16namespace Utils {
17namespace Cbor {
18class CborValue;
19} // namespace Cbor
20} // namespace Utils
21namespace Context {
22namespace Model {
23
31 public:
32 AWS_CONTEXT_API AccessControlEntry() = default;
33 AWS_CONTEXT_API AccessControlEntry(const std::shared_ptr<Aws::Crt::Cbor::CborDecoder>& decoder);
34 AWS_CONTEXT_API AccessControlEntry& operator=(const std::shared_ptr<Aws::Crt::Cbor::CborDecoder>& decoder);
35 AWS_CONTEXT_API void CborEncode(Aws::Crt::Cbor::CborEncoder& encoder) const;
36
38
43 inline AccessEffect GetAccess() const { return m_access; }
44 inline bool AccessHasBeenSet() const { return m_accessHasBeenSet; }
45 inline void SetAccess(AccessEffect value) {
46 m_accessHasBeenSet = true;
47 m_access = value;
48 }
50 SetAccess(value);
51 return *this;
52 }
54
56
60 inline const Aws::String& GetPrincipalId() const { return m_principalId; }
61 inline bool PrincipalIdHasBeenSet() const { return m_principalIdHasBeenSet; }
62 template <typename PrincipalIdT = Aws::String>
63 void SetPrincipalId(PrincipalIdT&& value) {
64 m_principalIdHasBeenSet = true;
65 m_principalId = std::forward<PrincipalIdT>(value);
66 }
67 template <typename PrincipalIdT = Aws::String>
68 AccessControlEntry& WithPrincipalId(PrincipalIdT&& value) {
69 SetPrincipalId(std::forward<PrincipalIdT>(value));
70 return *this;
71 }
73
75
81 inline PrincipalType GetPrincipalType() const { return m_principalType; }
82 inline bool PrincipalTypeHasBeenSet() const { return m_principalTypeHasBeenSet; }
83 inline void SetPrincipalType(PrincipalType value) {
84 m_principalTypeHasBeenSet = true;
85 m_principalType = value;
86 }
88 SetPrincipalType(value);
89 return *this;
90 }
92 private:
94
95 Aws::String m_principalId;
96
98 bool m_accessHasBeenSet = false;
99 bool m_principalIdHasBeenSet = false;
100 bool m_principalTypeHasBeenSet = false;
101};
102
103} // namespace Model
104} // namespace Context
105} // namespace Aws
bool AccessHasBeenSet() const
bool PrincipalTypeHasBeenSet() const
void SetPrincipalId(PrincipalIdT &&value)
bool PrincipalIdHasBeenSet() const
AWS_CONTEXT_API void CborEncode(Aws::Crt::Cbor::CborEncoder &encoder) const
void SetPrincipalType(PrincipalType value)
AWS_CONTEXT_API AccessControlEntry & operator=(const std::shared_ptr< Aws::Crt::Cbor::CborDecoder > &decoder)
PrincipalType GetPrincipalType() const
AWS_CONTEXT_API AccessControlEntry(const std::shared_ptr< Aws::Crt::Cbor::CborDecoder > &decoder)
AccessControlEntry & WithAccess(AccessEffect value)
const Aws::String & GetPrincipalId() const
void SetAccess(AccessEffect value)
AccessControlEntry & WithPrincipalId(PrincipalIdT &&value)
AWS_CONTEXT_API AccessControlEntry()=default
AccessControlEntry & WithPrincipalType(PrincipalType value)
AccessEffect GetAccess() const
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String