AWS SDK for C++

AWS SDK for C++ Version 1.11.719

Loading...
Searching...
No Matches
CreateTaskRequest.h
1
6#pragma once
7#include <aws/core/utils/memory/stl/AWSString.h>
8#include <aws/core/utils/memory/stl/AWSVector.h>
9#include <aws/datasync/DataSyncRequest.h>
10#include <aws/datasync/DataSync_EXPORTS.h>
11#include <aws/datasync/model/FilterRule.h>
12#include <aws/datasync/model/ManifestConfig.h>
13#include <aws/datasync/model/Options.h>
14#include <aws/datasync/model/TagListEntry.h>
15#include <aws/datasync/model/TaskMode.h>
16#include <aws/datasync/model/TaskReportConfig.h>
17#include <aws/datasync/model/TaskSchedule.h>
18
19#include <utility>
20
21namespace Aws {
22namespace DataSync {
23namespace Model {
24
31 public:
32 AWS_DATASYNC_API CreateTaskRequest() = default;
33
34 // Service request name is the Operation name which will send this request out,
35 // each operation should has unique request name, so that we can get operation's name from this request.
36 // Note: this is not true for response, multiple operations may have the same response name,
37 // so we can not get operation's name from response.
38 inline virtual const char* GetServiceRequestName() const override { return "CreateTask"; }
39
40 AWS_DATASYNC_API Aws::String SerializePayload() const override;
41
43
45
48 inline const Aws::String& GetSourceLocationArn() const { return m_sourceLocationArn; }
49 inline bool SourceLocationArnHasBeenSet() const { return m_sourceLocationArnHasBeenSet; }
50 template <typename SourceLocationArnT = Aws::String>
51 void SetSourceLocationArn(SourceLocationArnT&& value) {
52 m_sourceLocationArnHasBeenSet = true;
53 m_sourceLocationArn = std::forward<SourceLocationArnT>(value);
54 }
55 template <typename SourceLocationArnT = Aws::String>
56 CreateTaskRequest& WithSourceLocationArn(SourceLocationArnT&& value) {
57 SetSourceLocationArn(std::forward<SourceLocationArnT>(value));
58 return *this;
59 }
61
63
66 inline const Aws::String& GetDestinationLocationArn() const { return m_destinationLocationArn; }
67 inline bool DestinationLocationArnHasBeenSet() const { return m_destinationLocationArnHasBeenSet; }
68 template <typename DestinationLocationArnT = Aws::String>
69 void SetDestinationLocationArn(DestinationLocationArnT&& value) {
70 m_destinationLocationArnHasBeenSet = true;
71 m_destinationLocationArn = std::forward<DestinationLocationArnT>(value);
72 }
73 template <typename DestinationLocationArnT = Aws::String>
74 CreateTaskRequest& WithDestinationLocationArn(DestinationLocationArnT&& value) {
75 SetDestinationLocationArn(std::forward<DestinationLocationArnT>(value));
76 return *this;
77 }
79
81
87 inline const Aws::String& GetCloudWatchLogGroupArn() const { return m_cloudWatchLogGroupArn; }
88 inline bool CloudWatchLogGroupArnHasBeenSet() const { return m_cloudWatchLogGroupArnHasBeenSet; }
89 template <typename CloudWatchLogGroupArnT = Aws::String>
90 void SetCloudWatchLogGroupArn(CloudWatchLogGroupArnT&& value) {
91 m_cloudWatchLogGroupArnHasBeenSet = true;
92 m_cloudWatchLogGroupArn = std::forward<CloudWatchLogGroupArnT>(value);
93 }
94 template <typename CloudWatchLogGroupArnT = Aws::String>
95 CreateTaskRequest& WithCloudWatchLogGroupArn(CloudWatchLogGroupArnT&& value) {
96 SetCloudWatchLogGroupArn(std::forward<CloudWatchLogGroupArnT>(value));
97 return *this;
98 }
100
102
105 inline const Aws::String& GetName() const { return m_name; }
106 inline bool NameHasBeenSet() const { return m_nameHasBeenSet; }
107 template <typename NameT = Aws::String>
108 void SetName(NameT&& value) {
109 m_nameHasBeenSet = true;
110 m_name = std::forward<NameT>(value);
111 }
112 template <typename NameT = Aws::String>
113 CreateTaskRequest& WithName(NameT&& value) {
114 SetName(std::forward<NameT>(value));
115 return *this;
116 }
118
120
124 inline const Options& GetOptions() const { return m_options; }
125 inline bool OptionsHasBeenSet() const { return m_optionsHasBeenSet; }
126 template <typename OptionsT = Options>
127 void SetOptions(OptionsT&& value) {
128 m_optionsHasBeenSet = true;
129 m_options = std::forward<OptionsT>(value);
130 }
131 template <typename OptionsT = Options>
132 CreateTaskRequest& WithOptions(OptionsT&& value) {
133 SetOptions(std::forward<OptionsT>(value));
134 return *this;
135 }
137
139
146 inline const Aws::Vector<FilterRule>& GetExcludes() const { return m_excludes; }
147 inline bool ExcludesHasBeenSet() const { return m_excludesHasBeenSet; }
148 template <typename ExcludesT = Aws::Vector<FilterRule>>
149 void SetExcludes(ExcludesT&& value) {
150 m_excludesHasBeenSet = true;
151 m_excludes = std::forward<ExcludesT>(value);
152 }
153 template <typename ExcludesT = Aws::Vector<FilterRule>>
154 CreateTaskRequest& WithExcludes(ExcludesT&& value) {
155 SetExcludes(std::forward<ExcludesT>(value));
156 return *this;
157 }
158 template <typename ExcludesT = FilterRule>
159 CreateTaskRequest& AddExcludes(ExcludesT&& value) {
160 m_excludesHasBeenSet = true;
161 m_excludes.emplace_back(std::forward<ExcludesT>(value));
162 return *this;
163 }
165
167
173 inline const TaskSchedule& GetSchedule() const { return m_schedule; }
174 inline bool ScheduleHasBeenSet() const { return m_scheduleHasBeenSet; }
175 template <typename ScheduleT = TaskSchedule>
176 void SetSchedule(ScheduleT&& value) {
177 m_scheduleHasBeenSet = true;
178 m_schedule = std::forward<ScheduleT>(value);
179 }
180 template <typename ScheduleT = TaskSchedule>
181 CreateTaskRequest& WithSchedule(ScheduleT&& value) {
182 SetSchedule(std::forward<ScheduleT>(value));
183 return *this;
184 }
186
188
193 inline const Aws::Vector<TagListEntry>& GetTags() const { return m_tags; }
194 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
195 template <typename TagsT = Aws::Vector<TagListEntry>>
196 void SetTags(TagsT&& value) {
197 m_tagsHasBeenSet = true;
198 m_tags = std::forward<TagsT>(value);
199 }
200 template <typename TagsT = Aws::Vector<TagListEntry>>
201 CreateTaskRequest& WithTags(TagsT&& value) {
202 SetTags(std::forward<TagsT>(value));
203 return *this;
204 }
205 template <typename TagsT = TagListEntry>
206 CreateTaskRequest& AddTags(TagsT&& value) {
207 m_tagsHasBeenSet = true;
208 m_tags.emplace_back(std::forward<TagsT>(value));
209 return *this;
210 }
212
214
221 inline const Aws::Vector<FilterRule>& GetIncludes() const { return m_includes; }
222 inline bool IncludesHasBeenSet() const { return m_includesHasBeenSet; }
223 template <typename IncludesT = Aws::Vector<FilterRule>>
224 void SetIncludes(IncludesT&& value) {
225 m_includesHasBeenSet = true;
226 m_includes = std::forward<IncludesT>(value);
227 }
228 template <typename IncludesT = Aws::Vector<FilterRule>>
229 CreateTaskRequest& WithIncludes(IncludesT&& value) {
230 SetIncludes(std::forward<IncludesT>(value));
231 return *this;
232 }
233 template <typename IncludesT = FilterRule>
234 CreateTaskRequest& AddIncludes(IncludesT&& value) {
235 m_includesHasBeenSet = true;
236 m_includes.emplace_back(std::forward<IncludesT>(value));
237 return *this;
238 }
240
242
252 inline const ManifestConfig& GetManifestConfig() const { return m_manifestConfig; }
253 inline bool ManifestConfigHasBeenSet() const { return m_manifestConfigHasBeenSet; }
254 template <typename ManifestConfigT = ManifestConfig>
255 void SetManifestConfig(ManifestConfigT&& value) {
256 m_manifestConfigHasBeenSet = true;
257 m_manifestConfig = std::forward<ManifestConfigT>(value);
258 }
259 template <typename ManifestConfigT = ManifestConfig>
260 CreateTaskRequest& WithManifestConfig(ManifestConfigT&& value) {
261 SetManifestConfig(std::forward<ManifestConfigT>(value));
262 return *this;
263 }
265
267
277 inline const TaskReportConfig& GetTaskReportConfig() const { return m_taskReportConfig; }
278 inline bool TaskReportConfigHasBeenSet() const { return m_taskReportConfigHasBeenSet; }
279 template <typename TaskReportConfigT = TaskReportConfig>
280 void SetTaskReportConfig(TaskReportConfigT&& value) {
281 m_taskReportConfigHasBeenSet = true;
282 m_taskReportConfig = std::forward<TaskReportConfigT>(value);
283 }
284 template <typename TaskReportConfigT = TaskReportConfig>
285 CreateTaskRequest& WithTaskReportConfig(TaskReportConfigT&& value) {
286 SetTaskReportConfig(std::forward<TaskReportConfigT>(value));
287 return *this;
288 }
290
292
314 inline TaskMode GetTaskMode() const { return m_taskMode; }
315 inline bool TaskModeHasBeenSet() const { return m_taskModeHasBeenSet; }
316 inline void SetTaskMode(TaskMode value) {
317 m_taskModeHasBeenSet = true;
318 m_taskMode = value;
319 }
321 SetTaskMode(value);
322 return *this;
323 }
325 private:
326 Aws::String m_sourceLocationArn;
327
328 Aws::String m_destinationLocationArn;
329
330 Aws::String m_cloudWatchLogGroupArn;
331
332 Aws::String m_name;
333
334 Options m_options;
335
336 Aws::Vector<FilterRule> m_excludes;
337
338 TaskSchedule m_schedule;
339
341
342 Aws::Vector<FilterRule> m_includes;
343
344 ManifestConfig m_manifestConfig;
345
346 TaskReportConfig m_taskReportConfig;
347
348 TaskMode m_taskMode{TaskMode::NOT_SET};
349 bool m_sourceLocationArnHasBeenSet = false;
350 bool m_destinationLocationArnHasBeenSet = false;
351 bool m_cloudWatchLogGroupArnHasBeenSet = false;
352 bool m_nameHasBeenSet = false;
353 bool m_optionsHasBeenSet = false;
354 bool m_excludesHasBeenSet = false;
355 bool m_scheduleHasBeenSet = false;
356 bool m_tagsHasBeenSet = false;
357 bool m_includesHasBeenSet = false;
358 bool m_manifestConfigHasBeenSet = false;
359 bool m_taskReportConfigHasBeenSet = false;
360 bool m_taskModeHasBeenSet = false;
361};
362
363} // namespace Model
364} // namespace DataSync
365} // namespace Aws
CreateTaskRequest & WithOptions(OptionsT &&value)
CreateTaskRequest & WithDestinationLocationArn(DestinationLocationArnT &&value)
CreateTaskRequest & WithTags(TagsT &&value)
CreateTaskRequest & WithExcludes(ExcludesT &&value)
const TaskSchedule & GetSchedule() const
CreateTaskRequest & WithTaskMode(TaskMode value)
const TaskReportConfig & GetTaskReportConfig() const
CreateTaskRequest & WithCloudWatchLogGroupArn(CloudWatchLogGroupArnT &&value)
void SetTaskReportConfig(TaskReportConfigT &&value)
void SetCloudWatchLogGroupArn(CloudWatchLogGroupArnT &&value)
AWS_DATASYNC_API CreateTaskRequest()=default
CreateTaskRequest & WithSourceLocationArn(SourceLocationArnT &&value)
CreateTaskRequest & AddTags(TagsT &&value)
const Aws::String & GetSourceLocationArn() const
void SetDestinationLocationArn(DestinationLocationArnT &&value)
AWS_DATASYNC_API Aws::String SerializePayload() const override
CreateTaskRequest & WithTaskReportConfig(TaskReportConfigT &&value)
CreateTaskRequest & AddExcludes(ExcludesT &&value)
const ManifestConfig & GetManifestConfig() const
const Aws::Vector< FilterRule > & GetIncludes() const
const Aws::Vector< FilterRule > & GetExcludes() const
void SetManifestConfig(ManifestConfigT &&value)
const Aws::Vector< TagListEntry > & GetTags() const
const Aws::String & GetDestinationLocationArn() const
CreateTaskRequest & WithName(NameT &&value)
CreateTaskRequest & WithSchedule(ScheduleT &&value)
AWS_DATASYNC_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override
CreateTaskRequest & WithManifestConfig(ManifestConfigT &&value)
virtual const char * GetServiceRequestName() const override
void SetSourceLocationArn(SourceLocationArnT &&value)
CreateTaskRequest & AddIncludes(IncludesT &&value)
const Aws::String & GetCloudWatchLogGroupArn() const
CreateTaskRequest & WithIncludes(IncludesT &&value)
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