AWS SDK for C++

AWS SDK for C++ Version 1.11.612

Loading...
Searching...
No Matches
CreateJobRequest.h
1
6#pragma once
7#include <aws/iot/IoT_EXPORTS.h>
8#include <aws/iot/IoTRequest.h>
9#include <aws/core/utils/memory/stl/AWSString.h>
10#include <aws/core/utils/memory/stl/AWSVector.h>
11#include <aws/iot/model/PresignedUrlConfig.h>
12#include <aws/iot/model/TargetSelection.h>
13#include <aws/iot/model/JobExecutionsRolloutConfig.h>
14#include <aws/iot/model/AbortConfig.h>
15#include <aws/iot/model/TimeoutConfig.h>
16#include <aws/iot/model/JobExecutionsRetryConfig.h>
17#include <aws/core/utils/memory/stl/AWSMap.h>
18#include <aws/iot/model/SchedulingConfig.h>
19#include <aws/iot/model/Tag.h>
20#include <utility>
21
22namespace Aws
23{
24namespace IoT
25{
26namespace Model
27{
28
32 {
33 public:
34 AWS_IOT_API CreateJobRequest() = default;
35
36 // Service request name is the Operation name which will send this request out,
37 // each operation should has unique request name, so that we can get operation's name from this request.
38 // Note: this is not true for response, multiple operations may have the same response name,
39 // so we can not get operation's name from response.
40 inline virtual const char* GetServiceRequestName() const override { return "CreateJob"; }
41
42 AWS_IOT_API Aws::String SerializePayload() const override;
43
44
46
50 inline const Aws::String& GetJobId() const { return m_jobId; }
51 inline bool JobIdHasBeenSet() const { return m_jobIdHasBeenSet; }
52 template<typename JobIdT = Aws::String>
53 void SetJobId(JobIdT&& value) { m_jobIdHasBeenSet = true; m_jobId = std::forward<JobIdT>(value); }
54 template<typename JobIdT = Aws::String>
55 CreateJobRequest& WithJobId(JobIdT&& value) { SetJobId(std::forward<JobIdT>(value)); return *this;}
57
59
62 inline const Aws::Vector<Aws::String>& GetTargets() const { return m_targets; }
63 inline bool TargetsHasBeenSet() const { return m_targetsHasBeenSet; }
64 template<typename TargetsT = Aws::Vector<Aws::String>>
65 void SetTargets(TargetsT&& value) { m_targetsHasBeenSet = true; m_targets = std::forward<TargetsT>(value); }
66 template<typename TargetsT = Aws::Vector<Aws::String>>
67 CreateJobRequest& WithTargets(TargetsT&& value) { SetTargets(std::forward<TargetsT>(value)); return *this;}
68 template<typename TargetsT = Aws::String>
69 CreateJobRequest& AddTargets(TargetsT&& value) { m_targetsHasBeenSet = true; m_targets.emplace_back(std::forward<TargetsT>(value)); return *this; }
71
73
82 inline const Aws::String& GetDocumentSource() const { return m_documentSource; }
83 inline bool DocumentSourceHasBeenSet() const { return m_documentSourceHasBeenSet; }
84 template<typename DocumentSourceT = Aws::String>
85 void SetDocumentSource(DocumentSourceT&& value) { m_documentSourceHasBeenSet = true; m_documentSource = std::forward<DocumentSourceT>(value); }
86 template<typename DocumentSourceT = Aws::String>
87 CreateJobRequest& WithDocumentSource(DocumentSourceT&& value) { SetDocumentSource(std::forward<DocumentSourceT>(value)); return *this;}
89
91
95 inline const Aws::String& GetDocument() const { return m_document; }
96 inline bool DocumentHasBeenSet() const { return m_documentHasBeenSet; }
97 template<typename DocumentT = Aws::String>
98 void SetDocument(DocumentT&& value) { m_documentHasBeenSet = true; m_document = std::forward<DocumentT>(value); }
99 template<typename DocumentT = Aws::String>
100 CreateJobRequest& WithDocument(DocumentT&& value) { SetDocument(std::forward<DocumentT>(value)); return *this;}
102
104
107 inline const Aws::String& GetDescription() const { return m_description; }
108 inline bool DescriptionHasBeenSet() const { return m_descriptionHasBeenSet; }
109 template<typename DescriptionT = Aws::String>
110 void SetDescription(DescriptionT&& value) { m_descriptionHasBeenSet = true; m_description = std::forward<DescriptionT>(value); }
111 template<typename DescriptionT = Aws::String>
112 CreateJobRequest& WithDescription(DescriptionT&& value) { SetDescription(std::forward<DescriptionT>(value)); return *this;}
114
116
119 inline const PresignedUrlConfig& GetPresignedUrlConfig() const { return m_presignedUrlConfig; }
120 inline bool PresignedUrlConfigHasBeenSet() const { return m_presignedUrlConfigHasBeenSet; }
121 template<typename PresignedUrlConfigT = PresignedUrlConfig>
122 void SetPresignedUrlConfig(PresignedUrlConfigT&& value) { m_presignedUrlConfigHasBeenSet = true; m_presignedUrlConfig = std::forward<PresignedUrlConfigT>(value); }
123 template<typename PresignedUrlConfigT = PresignedUrlConfig>
124 CreateJobRequest& WithPresignedUrlConfig(PresignedUrlConfigT&& value) { SetPresignedUrlConfig(std::forward<PresignedUrlConfigT>(value)); return *this;}
126
128
139 inline TargetSelection GetTargetSelection() const { return m_targetSelection; }
140 inline bool TargetSelectionHasBeenSet() const { return m_targetSelectionHasBeenSet; }
141 inline void SetTargetSelection(TargetSelection value) { m_targetSelectionHasBeenSet = true; m_targetSelection = value; }
144
146
149 inline const JobExecutionsRolloutConfig& GetJobExecutionsRolloutConfig() const { return m_jobExecutionsRolloutConfig; }
150 inline bool JobExecutionsRolloutConfigHasBeenSet() const { return m_jobExecutionsRolloutConfigHasBeenSet; }
151 template<typename JobExecutionsRolloutConfigT = JobExecutionsRolloutConfig>
152 void SetJobExecutionsRolloutConfig(JobExecutionsRolloutConfigT&& value) { m_jobExecutionsRolloutConfigHasBeenSet = true; m_jobExecutionsRolloutConfig = std::forward<JobExecutionsRolloutConfigT>(value); }
153 template<typename JobExecutionsRolloutConfigT = JobExecutionsRolloutConfig>
154 CreateJobRequest& WithJobExecutionsRolloutConfig(JobExecutionsRolloutConfigT&& value) { SetJobExecutionsRolloutConfig(std::forward<JobExecutionsRolloutConfigT>(value)); return *this;}
156
158
161 inline const AbortConfig& GetAbortConfig() const { return m_abortConfig; }
162 inline bool AbortConfigHasBeenSet() const { return m_abortConfigHasBeenSet; }
163 template<typename AbortConfigT = AbortConfig>
164 void SetAbortConfig(AbortConfigT&& value) { m_abortConfigHasBeenSet = true; m_abortConfig = std::forward<AbortConfigT>(value); }
165 template<typename AbortConfigT = AbortConfig>
166 CreateJobRequest& WithAbortConfig(AbortConfigT&& value) { SetAbortConfig(std::forward<AbortConfigT>(value)); return *this;}
168
170
177 inline const TimeoutConfig& GetTimeoutConfig() const { return m_timeoutConfig; }
178 inline bool TimeoutConfigHasBeenSet() const { return m_timeoutConfigHasBeenSet; }
179 template<typename TimeoutConfigT = TimeoutConfig>
180 void SetTimeoutConfig(TimeoutConfigT&& value) { m_timeoutConfigHasBeenSet = true; m_timeoutConfig = std::forward<TimeoutConfigT>(value); }
181 template<typename TimeoutConfigT = TimeoutConfig>
182 CreateJobRequest& WithTimeoutConfig(TimeoutConfigT&& value) { SetTimeoutConfig(std::forward<TimeoutConfigT>(value)); return *this;}
184
186
189 inline const Aws::Vector<Tag>& GetTags() const { return m_tags; }
190 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
191 template<typename TagsT = Aws::Vector<Tag>>
192 void SetTags(TagsT&& value) { m_tagsHasBeenSet = true; m_tags = std::forward<TagsT>(value); }
193 template<typename TagsT = Aws::Vector<Tag>>
194 CreateJobRequest& WithTags(TagsT&& value) { SetTags(std::forward<TagsT>(value)); return *this;}
195 template<typename TagsT = Tag>
196 CreateJobRequest& AddTags(TagsT&& value) { m_tagsHasBeenSet = true; m_tags.emplace_back(std::forward<TagsT>(value)); return *this; }
198
200
211 inline const Aws::String& GetNamespaceId() const { return m_namespaceId; }
212 inline bool NamespaceIdHasBeenSet() const { return m_namespaceIdHasBeenSet; }
213 template<typename NamespaceIdT = Aws::String>
214 void SetNamespaceId(NamespaceIdT&& value) { m_namespaceIdHasBeenSet = true; m_namespaceId = std::forward<NamespaceIdT>(value); }
215 template<typename NamespaceIdT = Aws::String>
216 CreateJobRequest& WithNamespaceId(NamespaceIdT&& value) { SetNamespaceId(std::forward<NamespaceIdT>(value)); return *this;}
218
220
223 inline const Aws::String& GetJobTemplateArn() const { return m_jobTemplateArn; }
224 inline bool JobTemplateArnHasBeenSet() const { return m_jobTemplateArnHasBeenSet; }
225 template<typename JobTemplateArnT = Aws::String>
226 void SetJobTemplateArn(JobTemplateArnT&& value) { m_jobTemplateArnHasBeenSet = true; m_jobTemplateArn = std::forward<JobTemplateArnT>(value); }
227 template<typename JobTemplateArnT = Aws::String>
228 CreateJobRequest& WithJobTemplateArn(JobTemplateArnT&& value) { SetJobTemplateArn(std::forward<JobTemplateArnT>(value)); return *this;}
230
232
235 inline const JobExecutionsRetryConfig& GetJobExecutionsRetryConfig() const { return m_jobExecutionsRetryConfig; }
236 inline bool JobExecutionsRetryConfigHasBeenSet() const { return m_jobExecutionsRetryConfigHasBeenSet; }
237 template<typename JobExecutionsRetryConfigT = JobExecutionsRetryConfig>
238 void SetJobExecutionsRetryConfig(JobExecutionsRetryConfigT&& value) { m_jobExecutionsRetryConfigHasBeenSet = true; m_jobExecutionsRetryConfig = std::forward<JobExecutionsRetryConfigT>(value); }
239 template<typename JobExecutionsRetryConfigT = JobExecutionsRetryConfig>
240 CreateJobRequest& WithJobExecutionsRetryConfig(JobExecutionsRetryConfigT&& value) { SetJobExecutionsRetryConfig(std::forward<JobExecutionsRetryConfigT>(value)); return *this;}
242
244
251 inline const Aws::Map<Aws::String, Aws::String>& GetDocumentParameters() const { return m_documentParameters; }
252 inline bool DocumentParametersHasBeenSet() const { return m_documentParametersHasBeenSet; }
253 template<typename DocumentParametersT = Aws::Map<Aws::String, Aws::String>>
254 void SetDocumentParameters(DocumentParametersT&& value) { m_documentParametersHasBeenSet = true; m_documentParameters = std::forward<DocumentParametersT>(value); }
255 template<typename DocumentParametersT = Aws::Map<Aws::String, Aws::String>>
256 CreateJobRequest& WithDocumentParameters(DocumentParametersT&& value) { SetDocumentParameters(std::forward<DocumentParametersT>(value)); return *this;}
257 template<typename DocumentParametersKeyT = Aws::String, typename DocumentParametersValueT = Aws::String>
258 CreateJobRequest& AddDocumentParameters(DocumentParametersKeyT&& key, DocumentParametersValueT&& value) {
259 m_documentParametersHasBeenSet = true; m_documentParameters.emplace(std::forward<DocumentParametersKeyT>(key), std::forward<DocumentParametersValueT>(value)); return *this;
260 }
262
264
268 inline const SchedulingConfig& GetSchedulingConfig() const { return m_schedulingConfig; }
269 inline bool SchedulingConfigHasBeenSet() const { return m_schedulingConfigHasBeenSet; }
270 template<typename SchedulingConfigT = SchedulingConfig>
271 void SetSchedulingConfig(SchedulingConfigT&& value) { m_schedulingConfigHasBeenSet = true; m_schedulingConfig = std::forward<SchedulingConfigT>(value); }
272 template<typename SchedulingConfigT = SchedulingConfig>
273 CreateJobRequest& WithSchedulingConfig(SchedulingConfigT&& value) { SetSchedulingConfig(std::forward<SchedulingConfigT>(value)); return *this;}
275
277
286 inline const Aws::Vector<Aws::String>& GetDestinationPackageVersions() const { return m_destinationPackageVersions; }
287 inline bool DestinationPackageVersionsHasBeenSet() const { return m_destinationPackageVersionsHasBeenSet; }
288 template<typename DestinationPackageVersionsT = Aws::Vector<Aws::String>>
289 void SetDestinationPackageVersions(DestinationPackageVersionsT&& value) { m_destinationPackageVersionsHasBeenSet = true; m_destinationPackageVersions = std::forward<DestinationPackageVersionsT>(value); }
290 template<typename DestinationPackageVersionsT = Aws::Vector<Aws::String>>
291 CreateJobRequest& WithDestinationPackageVersions(DestinationPackageVersionsT&& value) { SetDestinationPackageVersions(std::forward<DestinationPackageVersionsT>(value)); return *this;}
292 template<typename DestinationPackageVersionsT = Aws::String>
293 CreateJobRequest& AddDestinationPackageVersions(DestinationPackageVersionsT&& value) { m_destinationPackageVersionsHasBeenSet = true; m_destinationPackageVersions.emplace_back(std::forward<DestinationPackageVersionsT>(value)); return *this; }
295 private:
296
297 Aws::String m_jobId;
298 bool m_jobIdHasBeenSet = false;
299
300 Aws::Vector<Aws::String> m_targets;
301 bool m_targetsHasBeenSet = false;
302
303 Aws::String m_documentSource;
304 bool m_documentSourceHasBeenSet = false;
305
306 Aws::String m_document;
307 bool m_documentHasBeenSet = false;
308
309 Aws::String m_description;
310 bool m_descriptionHasBeenSet = false;
311
312 PresignedUrlConfig m_presignedUrlConfig;
313 bool m_presignedUrlConfigHasBeenSet = false;
314
315 TargetSelection m_targetSelection{TargetSelection::NOT_SET};
316 bool m_targetSelectionHasBeenSet = false;
317
318 JobExecutionsRolloutConfig m_jobExecutionsRolloutConfig;
319 bool m_jobExecutionsRolloutConfigHasBeenSet = false;
320
321 AbortConfig m_abortConfig;
322 bool m_abortConfigHasBeenSet = false;
323
324 TimeoutConfig m_timeoutConfig;
325 bool m_timeoutConfigHasBeenSet = false;
326
327 Aws::Vector<Tag> m_tags;
328 bool m_tagsHasBeenSet = false;
329
330 Aws::String m_namespaceId;
331 bool m_namespaceIdHasBeenSet = false;
332
333 Aws::String m_jobTemplateArn;
334 bool m_jobTemplateArnHasBeenSet = false;
335
336 JobExecutionsRetryConfig m_jobExecutionsRetryConfig;
337 bool m_jobExecutionsRetryConfigHasBeenSet = false;
338
339 Aws::Map<Aws::String, Aws::String> m_documentParameters;
340 bool m_documentParametersHasBeenSet = false;
341
342 SchedulingConfig m_schedulingConfig;
343 bool m_schedulingConfigHasBeenSet = false;
344
345 Aws::Vector<Aws::String> m_destinationPackageVersions;
346 bool m_destinationPackageVersionsHasBeenSet = false;
347 };
348
349} // namespace Model
350} // namespace IoT
351} // namespace Aws
void SetJobExecutionsRolloutConfig(JobExecutionsRolloutConfigT &&value)
AWS_IOT_API CreateJobRequest()=default
CreateJobRequest & WithDocumentSource(DocumentSourceT &&value)
const Aws::String & GetNamespaceId() const
void SetPresignedUrlConfig(PresignedUrlConfigT &&value)
const TimeoutConfig & GetTimeoutConfig() const
CreateJobRequest & WithDescription(DescriptionT &&value)
CreateJobRequest & AddDocumentParameters(DocumentParametersKeyT &&key, DocumentParametersValueT &&value)
void SetNamespaceId(NamespaceIdT &&value)
void SetSchedulingConfig(SchedulingConfigT &&value)
CreateJobRequest & WithDocumentParameters(DocumentParametersT &&value)
const PresignedUrlConfig & GetPresignedUrlConfig() const
CreateJobRequest & WithJobId(JobIdT &&value)
const Aws::String & GetDocumentSource() const
CreateJobRequest & WithAbortConfig(AbortConfigT &&value)
CreateJobRequest & WithNamespaceId(NamespaceIdT &&value)
void SetTimeoutConfig(TimeoutConfigT &&value)
void SetDestinationPackageVersions(DestinationPackageVersionsT &&value)
CreateJobRequest & WithDocument(DocumentT &&value)
CreateJobRequest & WithTargetSelection(TargetSelection value)
const Aws::String & GetDescription() const
const JobExecutionsRolloutConfig & GetJobExecutionsRolloutConfig() const
void SetAbortConfig(AbortConfigT &&value)
void SetJobTemplateArn(JobTemplateArnT &&value)
AWS_IOT_API Aws::String SerializePayload() const override
CreateJobRequest & WithJobTemplateArn(JobTemplateArnT &&value)
const Aws::Vector< Aws::String > & GetDestinationPackageVersions() const
void SetDocumentSource(DocumentSourceT &&value)
const Aws::String & GetDocument() const
CreateJobRequest & WithJobExecutionsRetryConfig(JobExecutionsRetryConfigT &&value)
CreateJobRequest & WithTimeoutConfig(TimeoutConfigT &&value)
const SchedulingConfig & GetSchedulingConfig() const
virtual const char * GetServiceRequestName() const override
CreateJobRequest & AddDestinationPackageVersions(DestinationPackageVersionsT &&value)
const Aws::Map< Aws::String, Aws::String > & GetDocumentParameters() const
void SetDocument(DocumentT &&value)
const AbortConfig & GetAbortConfig() const
void SetDocumentParameters(DocumentParametersT &&value)
CreateJobRequest & AddTargets(TargetsT &&value)
CreateJobRequest & WithTags(TagsT &&value)
CreateJobRequest & WithSchedulingConfig(SchedulingConfigT &&value)
const JobExecutionsRetryConfig & GetJobExecutionsRetryConfig() const
TargetSelection GetTargetSelection() const
void SetDescription(DescriptionT &&value)
CreateJobRequest & WithDestinationPackageVersions(DestinationPackageVersionsT &&value)
void SetJobExecutionsRetryConfig(JobExecutionsRetryConfigT &&value)
void SetTargetSelection(TargetSelection value)
const Aws::String & GetJobId() const
const Aws::String & GetJobTemplateArn() const
CreateJobRequest & WithJobExecutionsRolloutConfig(JobExecutionsRolloutConfigT &&value)
const Aws::Vector< Aws::String > & GetTargets() const
CreateJobRequest & WithTargets(TargetsT &&value)
void SetTargets(TargetsT &&value)
CreateJobRequest & AddTags(TagsT &&value)
CreateJobRequest & WithPresignedUrlConfig(PresignedUrlConfigT &&value)
const Aws::Vector< Tag > & GetTags() const
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