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/deadline/Deadline_EXPORTS.h>
8#include <aws/deadline/DeadlineRequest.h>
9#include <aws/core/utils/memory/stl/AWSString.h>
10#include <aws/deadline/model/JobTemplateType.h>
11#include <aws/core/utils/memory/stl/AWSMap.h>
12#include <aws/deadline/model/Attachments.h>
13#include <aws/deadline/model/CreateJobTargetTaskRunStatus.h>
14#include <aws/deadline/model/JobParameter.h>
15#include <utility>
16#include <aws/core/utils/UUID.h>
17
18namespace Aws
19{
20namespace deadline
21{
22namespace Model
23{
24
28 {
29 public:
30 AWS_DEADLINE_API CreateJobRequest() = default;
31
32 // Service request name is the Operation name which will send this request out,
33 // each operation should has unique request name, so that we can get operation's name from this request.
34 // Note: this is not true for response, multiple operations may have the same response name,
35 // so we can not get operation's name from response.
36 inline virtual const char* GetServiceRequestName() const override { return "CreateJob"; }
37
38 AWS_DEADLINE_API Aws::String SerializePayload() const override;
39
41
42
44
47 inline const Aws::String& GetFarmId() const { return m_farmId; }
48 inline bool FarmIdHasBeenSet() const { return m_farmIdHasBeenSet; }
49 template<typename FarmIdT = Aws::String>
50 void SetFarmId(FarmIdT&& value) { m_farmIdHasBeenSet = true; m_farmId = std::forward<FarmIdT>(value); }
51 template<typename FarmIdT = Aws::String>
52 CreateJobRequest& WithFarmId(FarmIdT&& value) { SetFarmId(std::forward<FarmIdT>(value)); return *this;}
54
56
59 inline const Aws::String& GetQueueId() const { return m_queueId; }
60 inline bool QueueIdHasBeenSet() const { return m_queueIdHasBeenSet; }
61 template<typename QueueIdT = Aws::String>
62 void SetQueueId(QueueIdT&& value) { m_queueIdHasBeenSet = true; m_queueId = std::forward<QueueIdT>(value); }
63 template<typename QueueIdT = Aws::String>
64 CreateJobRequest& WithQueueId(QueueIdT&& value) { SetQueueId(std::forward<QueueIdT>(value)); return *this;}
66
68
72 inline const Aws::String& GetClientToken() const { return m_clientToken; }
73 inline bool ClientTokenHasBeenSet() const { return m_clientTokenHasBeenSet; }
74 template<typename ClientTokenT = Aws::String>
75 void SetClientToken(ClientTokenT&& value) { m_clientTokenHasBeenSet = true; m_clientToken = std::forward<ClientTokenT>(value); }
76 template<typename ClientTokenT = Aws::String>
77 CreateJobRequest& WithClientToken(ClientTokenT&& value) { SetClientToken(std::forward<ClientTokenT>(value)); return *this;}
79
81
84 inline const Aws::String& GetTemplate() const { return m_template; }
85 inline bool TemplateHasBeenSet() const { return m_templateHasBeenSet; }
86 template<typename TemplateT = Aws::String>
87 void SetTemplate(TemplateT&& value) { m_templateHasBeenSet = true; m_template = std::forward<TemplateT>(value); }
88 template<typename TemplateT = Aws::String>
89 CreateJobRequest& WithTemplate(TemplateT&& value) { SetTemplate(std::forward<TemplateT>(value)); return *this;}
91
93
96 inline JobTemplateType GetTemplateType() const { return m_templateType; }
97 inline bool TemplateTypeHasBeenSet() const { return m_templateTypeHasBeenSet; }
98 inline void SetTemplateType(JobTemplateType value) { m_templateTypeHasBeenSet = true; m_templateType = value; }
99 inline CreateJobRequest& WithTemplateType(JobTemplateType value) { SetTemplateType(value); return *this;}
101
103
107 inline int GetPriority() const { return m_priority; }
108 inline bool PriorityHasBeenSet() const { return m_priorityHasBeenSet; }
109 inline void SetPriority(int value) { m_priorityHasBeenSet = true; m_priority = value; }
110 inline CreateJobRequest& WithPriority(int value) { SetPriority(value); return *this;}
112
114
117 inline const Aws::Map<Aws::String, JobParameter>& GetParameters() const { return m_parameters; }
118 inline bool ParametersHasBeenSet() const { return m_parametersHasBeenSet; }
119 template<typename ParametersT = Aws::Map<Aws::String, JobParameter>>
120 void SetParameters(ParametersT&& value) { m_parametersHasBeenSet = true; m_parameters = std::forward<ParametersT>(value); }
121 template<typename ParametersT = Aws::Map<Aws::String, JobParameter>>
122 CreateJobRequest& WithParameters(ParametersT&& value) { SetParameters(std::forward<ParametersT>(value)); return *this;}
123 template<typename ParametersKeyT = Aws::String, typename ParametersValueT = JobParameter>
124 CreateJobRequest& AddParameters(ParametersKeyT&& key, ParametersValueT&& value) {
125 m_parametersHasBeenSet = true; m_parameters.emplace(std::forward<ParametersKeyT>(key), std::forward<ParametersValueT>(value)); return *this;
126 }
128
130
134 inline const Attachments& GetAttachments() const { return m_attachments; }
135 inline bool AttachmentsHasBeenSet() const { return m_attachmentsHasBeenSet; }
136 template<typename AttachmentsT = Attachments>
137 void SetAttachments(AttachmentsT&& value) { m_attachmentsHasBeenSet = true; m_attachments = std::forward<AttachmentsT>(value); }
138 template<typename AttachmentsT = Attachments>
139 CreateJobRequest& WithAttachments(AttachmentsT&& value) { SetAttachments(std::forward<AttachmentsT>(value)); return *this;}
141
143
146 inline const Aws::String& GetStorageProfileId() const { return m_storageProfileId; }
147 inline bool StorageProfileIdHasBeenSet() const { return m_storageProfileIdHasBeenSet; }
148 template<typename StorageProfileIdT = Aws::String>
149 void SetStorageProfileId(StorageProfileIdT&& value) { m_storageProfileIdHasBeenSet = true; m_storageProfileId = std::forward<StorageProfileIdT>(value); }
150 template<typename StorageProfileIdT = Aws::String>
151 CreateJobRequest& WithStorageProfileId(StorageProfileIdT&& value) { SetStorageProfileId(std::forward<StorageProfileIdT>(value)); return *this;}
153
155
159 inline CreateJobTargetTaskRunStatus GetTargetTaskRunStatus() const { return m_targetTaskRunStatus; }
160 inline bool TargetTaskRunStatusHasBeenSet() const { return m_targetTaskRunStatusHasBeenSet; }
161 inline void SetTargetTaskRunStatus(CreateJobTargetTaskRunStatus value) { m_targetTaskRunStatusHasBeenSet = true; m_targetTaskRunStatus = value; }
164
166
170 inline int GetMaxFailedTasksCount() const { return m_maxFailedTasksCount; }
171 inline bool MaxFailedTasksCountHasBeenSet() const { return m_maxFailedTasksCountHasBeenSet; }
172 inline void SetMaxFailedTasksCount(int value) { m_maxFailedTasksCountHasBeenSet = true; m_maxFailedTasksCount = value; }
173 inline CreateJobRequest& WithMaxFailedTasksCount(int value) { SetMaxFailedTasksCount(value); return *this;}
175
177
180 inline int GetMaxRetriesPerTask() const { return m_maxRetriesPerTask; }
181 inline bool MaxRetriesPerTaskHasBeenSet() const { return m_maxRetriesPerTaskHasBeenSet; }
182 inline void SetMaxRetriesPerTask(int value) { m_maxRetriesPerTaskHasBeenSet = true; m_maxRetriesPerTask = value; }
183 inline CreateJobRequest& WithMaxRetriesPerTask(int value) { SetMaxRetriesPerTask(value); return *this;}
185
187
196 inline int GetMaxWorkerCount() const { return m_maxWorkerCount; }
197 inline bool MaxWorkerCountHasBeenSet() const { return m_maxWorkerCountHasBeenSet; }
198 inline void SetMaxWorkerCount(int value) { m_maxWorkerCountHasBeenSet = true; m_maxWorkerCount = value; }
199 inline CreateJobRequest& WithMaxWorkerCount(int value) { SetMaxWorkerCount(value); return *this;}
201
203
206 inline const Aws::String& GetSourceJobId() const { return m_sourceJobId; }
207 inline bool SourceJobIdHasBeenSet() const { return m_sourceJobIdHasBeenSet; }
208 template<typename SourceJobIdT = Aws::String>
209 void SetSourceJobId(SourceJobIdT&& value) { m_sourceJobIdHasBeenSet = true; m_sourceJobId = std::forward<SourceJobIdT>(value); }
210 template<typename SourceJobIdT = Aws::String>
211 CreateJobRequest& WithSourceJobId(SourceJobIdT&& value) { SetSourceJobId(std::forward<SourceJobIdT>(value)); return *this;}
213 private:
214
215 Aws::String m_farmId;
216 bool m_farmIdHasBeenSet = false;
217
218 Aws::String m_queueId;
219 bool m_queueIdHasBeenSet = false;
220
222 bool m_clientTokenHasBeenSet = true;
223
224 Aws::String m_template;
225 bool m_templateHasBeenSet = false;
226
228 bool m_templateTypeHasBeenSet = false;
229
230 int m_priority{0};
231 bool m_priorityHasBeenSet = false;
232
234 bool m_parametersHasBeenSet = false;
235
236 Attachments m_attachments;
237 bool m_attachmentsHasBeenSet = false;
238
239 Aws::String m_storageProfileId;
240 bool m_storageProfileIdHasBeenSet = false;
241
243 bool m_targetTaskRunStatusHasBeenSet = false;
244
245 int m_maxFailedTasksCount{0};
246 bool m_maxFailedTasksCountHasBeenSet = false;
247
248 int m_maxRetriesPerTask{0};
249 bool m_maxRetriesPerTaskHasBeenSet = false;
250
251 int m_maxWorkerCount{0};
252 bool m_maxWorkerCountHasBeenSet = false;
253
254 Aws::String m_sourceJobId;
255 bool m_sourceJobIdHasBeenSet = false;
256 };
257
258} // namespace Model
259} // namespace deadline
260} // namespace Aws
static Aws::Utils::UUID PseudoRandomUUID()
const Aws::String & GetQueueId() const
AWS_DEADLINE_API Aws::String SerializePayload() const override
CreateJobRequest & WithStorageProfileId(StorageProfileIdT &&value)
CreateJobRequest & WithMaxWorkerCount(int value)
CreateJobRequest & AddParameters(ParametersKeyT &&key, ParametersValueT &&value)
const Attachments & GetAttachments() const
CreateJobRequest & WithTemplate(TemplateT &&value)
void SetTargetTaskRunStatus(CreateJobTargetTaskRunStatus value)
CreateJobRequest & WithQueueId(QueueIdT &&value)
const Aws::Map< Aws::String, JobParameter > & GetParameters() const
void SetSourceJobId(SourceJobIdT &&value)
CreateJobRequest & WithTargetTaskRunStatus(CreateJobTargetTaskRunStatus value)
virtual const char * GetServiceRequestName() const override
CreateJobRequest & WithClientToken(ClientTokenT &&value)
const Aws::String & GetSourceJobId() const
CreateJobRequest & WithMaxRetriesPerTask(int value)
CreateJobRequest & WithSourceJobId(SourceJobIdT &&value)
const Aws::String & GetStorageProfileId() const
void SetParameters(ParametersT &&value)
CreateJobRequest & WithMaxFailedTasksCount(int value)
AWS_DEADLINE_API CreateJobRequest()=default
AWS_DEADLINE_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override
void SetAttachments(AttachmentsT &&value)
CreateJobRequest & WithPriority(int value)
CreateJobTargetTaskRunStatus GetTargetTaskRunStatus() const
void SetClientToken(ClientTokenT &&value)
const Aws::String & GetFarmId() const
const Aws::String & GetTemplate() const
void SetStorageProfileId(StorageProfileIdT &&value)
CreateJobRequest & WithAttachments(AttachmentsT &&value)
const Aws::String & GetClientToken() const
CreateJobRequest & WithFarmId(FarmIdT &&value)
CreateJobRequest & WithTemplateType(JobTemplateType value)
void SetTemplateType(JobTemplateType value)
CreateJobRequest & WithParameters(ParametersT &&value)
Aws::Map< Aws::String, Aws::String > HeaderValueCollection
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