AWS SDK for C++

AWS SDK for C++ Version 1.11.717

Loading...
Searching...
No Matches
CreateTaskRequest.h
1
6#pragma once
7#include <aws/core/utils/UUID.h>
8#include <aws/core/utils/memory/stl/AWSMap.h>
9#include <aws/core/utils/memory/stl/AWSString.h>
10#include <aws/core/utils/memory/stl/AWSVector.h>
11#include <aws/snow-device-management/SnowDeviceManagementRequest.h>
12#include <aws/snow-device-management/SnowDeviceManagement_EXPORTS.h>
13#include <aws/snow-device-management/model/Command.h>
14
15#include <utility>
16
17namespace Aws {
18namespace SnowDeviceManagement {
19namespace Model {
20
24 public:
25 AWS_SNOWDEVICEMANAGEMENT_API CreateTaskRequest() = default;
26
27 // Service request name is the Operation name which will send this request out,
28 // each operation should has unique request name, so that we can get operation's name from this request.
29 // Note: this is not true for response, multiple operations may have the same response name,
30 // so we can not get operation's name from response.
31 inline virtual const char* GetServiceRequestName() const override { return "CreateTask"; }
32
33 AWS_SNOWDEVICEMANAGEMENT_API Aws::String SerializePayload() const override;
34
36
40 inline const Aws::String& GetClientToken() const { return m_clientToken; }
41 inline bool ClientTokenHasBeenSet() const { return m_clientTokenHasBeenSet; }
42 template <typename ClientTokenT = Aws::String>
43 void SetClientToken(ClientTokenT&& value) {
44 m_clientTokenHasBeenSet = true;
45 m_clientToken = std::forward<ClientTokenT>(value);
46 }
47 template <typename ClientTokenT = Aws::String>
48 CreateTaskRequest& WithClientToken(ClientTokenT&& value) {
49 SetClientToken(std::forward<ClientTokenT>(value));
50 return *this;
51 }
53
55
59 inline const Command& GetCommand() const { return m_command; }
60 inline bool CommandHasBeenSet() const { return m_commandHasBeenSet; }
61 template <typename CommandT = Command>
62 void SetCommand(CommandT&& value) {
63 m_commandHasBeenSet = true;
64 m_command = std::forward<CommandT>(value);
65 }
66 template <typename CommandT = Command>
67 CreateTaskRequest& WithCommand(CommandT&& value) {
68 SetCommand(std::forward<CommandT>(value));
69 return *this;
70 }
72
74
77 inline const Aws::String& GetDescription() const { return m_description; }
78 inline bool DescriptionHasBeenSet() const { return m_descriptionHasBeenSet; }
79 template <typename DescriptionT = Aws::String>
80 void SetDescription(DescriptionT&& value) {
81 m_descriptionHasBeenSet = true;
82 m_description = std::forward<DescriptionT>(value);
83 }
84 template <typename DescriptionT = Aws::String>
85 CreateTaskRequest& WithDescription(DescriptionT&& value) {
86 SetDescription(std::forward<DescriptionT>(value));
87 return *this;
88 }
90
92
97 inline const Aws::Map<Aws::String, Aws::String>& GetTags() const { return m_tags; }
98 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
99 template <typename TagsT = Aws::Map<Aws::String, Aws::String>>
100 void SetTags(TagsT&& value) {
101 m_tagsHasBeenSet = true;
102 m_tags = std::forward<TagsT>(value);
103 }
104 template <typename TagsT = Aws::Map<Aws::String, Aws::String>>
105 CreateTaskRequest& WithTags(TagsT&& value) {
106 SetTags(std::forward<TagsT>(value));
107 return *this;
108 }
109 template <typename TagsKeyT = Aws::String, typename TagsValueT = Aws::String>
110 CreateTaskRequest& AddTags(TagsKeyT&& key, TagsValueT&& value) {
111 m_tagsHasBeenSet = true;
112 m_tags.emplace(std::forward<TagsKeyT>(key), std::forward<TagsValueT>(value));
113 return *this;
114 }
116
118
121 inline const Aws::Vector<Aws::String>& GetTargets() const { return m_targets; }
122 inline bool TargetsHasBeenSet() const { return m_targetsHasBeenSet; }
123 template <typename TargetsT = Aws::Vector<Aws::String>>
124 void SetTargets(TargetsT&& value) {
125 m_targetsHasBeenSet = true;
126 m_targets = std::forward<TargetsT>(value);
127 }
128 template <typename TargetsT = Aws::Vector<Aws::String>>
129 CreateTaskRequest& WithTargets(TargetsT&& value) {
130 SetTargets(std::forward<TargetsT>(value));
131 return *this;
132 }
133 template <typename TargetsT = Aws::String>
134 CreateTaskRequest& AddTargets(TargetsT&& value) {
135 m_targetsHasBeenSet = true;
136 m_targets.emplace_back(std::forward<TargetsT>(value));
137 return *this;
138 }
140 private:
142
143 Command m_command;
144
145 Aws::String m_description;
146
148
149 Aws::Vector<Aws::String> m_targets;
150 bool m_clientTokenHasBeenSet = true;
151 bool m_commandHasBeenSet = false;
152 bool m_descriptionHasBeenSet = false;
153 bool m_tagsHasBeenSet = false;
154 bool m_targetsHasBeenSet = false;
155};
156
157} // namespace Model
158} // namespace SnowDeviceManagement
159} // namespace Aws
CreateTaskRequest & AddTags(TagsKeyT &&key, TagsValueT &&value)
const Aws::Map< Aws::String, Aws::String > & GetTags() const
CreateTaskRequest & AddTargets(TargetsT &&value)
AWS_SNOWDEVICEMANAGEMENT_API Aws::String SerializePayload() const override
CreateTaskRequest & WithTargets(TargetsT &&value)
AWS_SNOWDEVICEMANAGEMENT_API CreateTaskRequest()=default
CreateTaskRequest & WithDescription(DescriptionT &&value)
const Aws::Vector< Aws::String > & GetTargets() const
CreateTaskRequest & WithCommand(CommandT &&value)
CreateTaskRequest & WithClientToken(ClientTokenT &&value)
virtual const char * GetServiceRequestName() const override
static Aws::Utils::UUID PseudoRandomUUID()
std::map< K, V, std::less< K >, Aws::Allocator< std::pair< const K, V > > > Map
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector