AWS SDK for C++

AWS SDK for C++ Version 1.11.608

Loading...
Searching...
No Matches
CreateCrossAccountAttachmentRequest.h
1
6#pragma once
7#include <aws/globalaccelerator/GlobalAccelerator_EXPORTS.h>
8#include <aws/globalaccelerator/GlobalAcceleratorRequest.h>
9#include <aws/core/utils/memory/stl/AWSString.h>
10#include <aws/core/utils/memory/stl/AWSVector.h>
11#include <aws/globalaccelerator/model/Resource.h>
12#include <aws/globalaccelerator/model/Tag.h>
13#include <utility>
14#include <aws/core/utils/UUID.h>
15
16namespace Aws
17{
18namespace GlobalAccelerator
19{
20namespace Model
21{
22
26 {
27 public:
28 AWS_GLOBALACCELERATOR_API CreateCrossAccountAttachmentRequest() = default;
29
30 // Service request name is the Operation name which will send this request out,
31 // each operation should has unique request name, so that we can get operation's name from this request.
32 // Note: this is not true for response, multiple operations may have the same response name,
33 // so we can not get operation's name from response.
34 inline virtual const char* GetServiceRequestName() const override { return "CreateCrossAccountAttachment"; }
35
36 AWS_GLOBALACCELERATOR_API Aws::String SerializePayload() const override;
37
38 AWS_GLOBALACCELERATOR_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override;
39
40
42
45 inline const Aws::String& GetName() const { return m_name; }
46 inline bool NameHasBeenSet() const { return m_nameHasBeenSet; }
47 template<typename NameT = Aws::String>
48 void SetName(NameT&& value) { m_nameHasBeenSet = true; m_name = std::forward<NameT>(value); }
49 template<typename NameT = Aws::String>
50 CreateCrossAccountAttachmentRequest& WithName(NameT&& value) { SetName(std::forward<NameT>(value)); return *this;}
52
54
59 inline const Aws::Vector<Aws::String>& GetPrincipals() const { return m_principals; }
60 inline bool PrincipalsHasBeenSet() const { return m_principalsHasBeenSet; }
61 template<typename PrincipalsT = Aws::Vector<Aws::String>>
62 void SetPrincipals(PrincipalsT&& value) { m_principalsHasBeenSet = true; m_principals = std::forward<PrincipalsT>(value); }
63 template<typename PrincipalsT = Aws::Vector<Aws::String>>
64 CreateCrossAccountAttachmentRequest& WithPrincipals(PrincipalsT&& value) { SetPrincipals(std::forward<PrincipalsT>(value)); return *this;}
65 template<typename PrincipalsT = Aws::String>
66 CreateCrossAccountAttachmentRequest& AddPrincipals(PrincipalsT&& value) { m_principalsHasBeenSet = true; m_principals.emplace_back(std::forward<PrincipalsT>(value)); return *this; }
68
70
76 inline const Aws::Vector<Resource>& GetResources() const { return m_resources; }
77 inline bool ResourcesHasBeenSet() const { return m_resourcesHasBeenSet; }
78 template<typename ResourcesT = Aws::Vector<Resource>>
79 void SetResources(ResourcesT&& value) { m_resourcesHasBeenSet = true; m_resources = std::forward<ResourcesT>(value); }
80 template<typename ResourcesT = Aws::Vector<Resource>>
81 CreateCrossAccountAttachmentRequest& WithResources(ResourcesT&& value) { SetResources(std::forward<ResourcesT>(value)); return *this;}
82 template<typename ResourcesT = Resource>
83 CreateCrossAccountAttachmentRequest& AddResources(ResourcesT&& value) { m_resourcesHasBeenSet = true; m_resources.emplace_back(std::forward<ResourcesT>(value)); return *this; }
85
87
91 inline const Aws::String& GetIdempotencyToken() const { return m_idempotencyToken; }
92 inline bool IdempotencyTokenHasBeenSet() const { return m_idempotencyTokenHasBeenSet; }
93 template<typename IdempotencyTokenT = Aws::String>
94 void SetIdempotencyToken(IdempotencyTokenT&& value) { m_idempotencyTokenHasBeenSet = true; m_idempotencyToken = std::forward<IdempotencyTokenT>(value); }
95 template<typename IdempotencyTokenT = Aws::String>
96 CreateCrossAccountAttachmentRequest& WithIdempotencyToken(IdempotencyTokenT&& value) { SetIdempotencyToken(std::forward<IdempotencyTokenT>(value)); return *this;}
98
100
105 inline const Aws::Vector<Tag>& GetTags() const { return m_tags; }
106 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
107 template<typename TagsT = Aws::Vector<Tag>>
108 void SetTags(TagsT&& value) { m_tagsHasBeenSet = true; m_tags = std::forward<TagsT>(value); }
109 template<typename TagsT = Aws::Vector<Tag>>
110 CreateCrossAccountAttachmentRequest& WithTags(TagsT&& value) { SetTags(std::forward<TagsT>(value)); return *this;}
111 template<typename TagsT = Tag>
112 CreateCrossAccountAttachmentRequest& AddTags(TagsT&& value) { m_tagsHasBeenSet = true; m_tags.emplace_back(std::forward<TagsT>(value)); return *this; }
114 private:
115
116 Aws::String m_name;
117 bool m_nameHasBeenSet = false;
118
119 Aws::Vector<Aws::String> m_principals;
120 bool m_principalsHasBeenSet = false;
121
122 Aws::Vector<Resource> m_resources;
123 bool m_resourcesHasBeenSet = false;
124
126 bool m_idempotencyTokenHasBeenSet = true;
127
128 Aws::Vector<Tag> m_tags;
129 bool m_tagsHasBeenSet = false;
130 };
131
132} // namespace Model
133} // namespace GlobalAccelerator
134} // namespace Aws
AWS_GLOBALACCELERATOR_API CreateCrossAccountAttachmentRequest()=default
CreateCrossAccountAttachmentRequest & WithPrincipals(PrincipalsT &&value)
CreateCrossAccountAttachmentRequest & WithIdempotencyToken(IdempotencyTokenT &&value)
AWS_GLOBALACCELERATOR_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override
CreateCrossAccountAttachmentRequest & AddResources(ResourcesT &&value)
CreateCrossAccountAttachmentRequest & AddPrincipals(PrincipalsT &&value)
AWS_GLOBALACCELERATOR_API Aws::String SerializePayload() const override
CreateCrossAccountAttachmentRequest & WithResources(ResourcesT &&value)
static Aws::Utils::UUID PseudoRandomUUID()
Aws::Map< Aws::String, Aws::String > HeaderValueCollection
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector