AWS SDK for C++

AWS SDK for C++ Version 1.11.716

Loading...
Searching...
No Matches
UpdateCanaryRequest.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/synthetics/SyntheticsRequest.h>
10#include <aws/synthetics/Synthetics_EXPORTS.h>
11#include <aws/synthetics/model/ArtifactConfigInput.h>
12#include <aws/synthetics/model/BrowserConfig.h>
13#include <aws/synthetics/model/CanaryCodeInput.h>
14#include <aws/synthetics/model/CanaryRunConfigInput.h>
15#include <aws/synthetics/model/CanaryScheduleInput.h>
16#include <aws/synthetics/model/ProvisionedResourceCleanupSetting.h>
17#include <aws/synthetics/model/VisualReferenceInput.h>
18#include <aws/synthetics/model/VpcConfigInput.h>
19
20#include <utility>
21
22namespace Aws {
23namespace Synthetics {
24namespace Model {
25
29 public:
30 AWS_SYNTHETICS_API UpdateCanaryRequest() = 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 "UpdateCanary"; }
37
38 AWS_SYNTHETICS_API Aws::String SerializePayload() const override;
39
41
47 inline const Aws::String& GetName() const { return m_name; }
48 inline bool NameHasBeenSet() const { return m_nameHasBeenSet; }
49 template <typename NameT = Aws::String>
50 void SetName(NameT&& value) {
51 m_nameHasBeenSet = true;
52 m_name = std::forward<NameT>(value);
53 }
54 template <typename NameT = Aws::String>
55 UpdateCanaryRequest& WithName(NameT&& value) {
56 SetName(std::forward<NameT>(value));
57 return *this;
58 }
60
62
67 inline const CanaryCodeInput& GetCode() const { return m_code; }
68 inline bool CodeHasBeenSet() const { return m_codeHasBeenSet; }
69 template <typename CodeT = CanaryCodeInput>
70 void SetCode(CodeT&& value) {
71 m_codeHasBeenSet = true;
72 m_code = std::forward<CodeT>(value);
73 }
74 template <typename CodeT = CanaryCodeInput>
75 UpdateCanaryRequest& WithCode(CodeT&& value) {
76 SetCode(std::forward<CodeT>(value));
77 return *this;
78 }
80
82
94 inline const Aws::String& GetExecutionRoleArn() const { return m_executionRoleArn; }
95 inline bool ExecutionRoleArnHasBeenSet() const { return m_executionRoleArnHasBeenSet; }
96 template <typename ExecutionRoleArnT = Aws::String>
97 void SetExecutionRoleArn(ExecutionRoleArnT&& value) {
98 m_executionRoleArnHasBeenSet = true;
99 m_executionRoleArn = std::forward<ExecutionRoleArnT>(value);
100 }
101 template <typename ExecutionRoleArnT = Aws::String>
102 UpdateCanaryRequest& WithExecutionRoleArn(ExecutionRoleArnT&& value) {
103 SetExecutionRoleArn(std::forward<ExecutionRoleArnT>(value));
104 return *this;
105 }
107
109
115 inline const Aws::String& GetRuntimeVersion() const { return m_runtimeVersion; }
116 inline bool RuntimeVersionHasBeenSet() const { return m_runtimeVersionHasBeenSet; }
117 template <typename RuntimeVersionT = Aws::String>
118 void SetRuntimeVersion(RuntimeVersionT&& value) {
119 m_runtimeVersionHasBeenSet = true;
120 m_runtimeVersion = std::forward<RuntimeVersionT>(value);
121 }
122 template <typename RuntimeVersionT = Aws::String>
123 UpdateCanaryRequest& WithRuntimeVersion(RuntimeVersionT&& value) {
124 SetRuntimeVersion(std::forward<RuntimeVersionT>(value));
125 return *this;
126 }
128
130
134 inline const CanaryScheduleInput& GetSchedule() const { return m_schedule; }
135 inline bool ScheduleHasBeenSet() const { return m_scheduleHasBeenSet; }
136 template <typename ScheduleT = CanaryScheduleInput>
137 void SetSchedule(ScheduleT&& value) {
138 m_scheduleHasBeenSet = true;
139 m_schedule = std::forward<ScheduleT>(value);
140 }
141 template <typename ScheduleT = CanaryScheduleInput>
142 UpdateCanaryRequest& WithSchedule(ScheduleT&& value) {
143 SetSchedule(std::forward<ScheduleT>(value));
144 return *this;
145 }
147
149
156 inline const CanaryRunConfigInput& GetRunConfig() const { return m_runConfig; }
157 inline bool RunConfigHasBeenSet() const { return m_runConfigHasBeenSet; }
158 template <typename RunConfigT = CanaryRunConfigInput>
159 void SetRunConfig(RunConfigT&& value) {
160 m_runConfigHasBeenSet = true;
161 m_runConfig = std::forward<RunConfigT>(value);
162 }
163 template <typename RunConfigT = CanaryRunConfigInput>
164 UpdateCanaryRequest& WithRunConfig(RunConfigT&& value) {
165 SetRunConfig(std::forward<RunConfigT>(value));
166 return *this;
167 }
169
171
177 inline int GetSuccessRetentionPeriodInDays() const { return m_successRetentionPeriodInDays; }
178 inline bool SuccessRetentionPeriodInDaysHasBeenSet() const { return m_successRetentionPeriodInDaysHasBeenSet; }
179 inline void SetSuccessRetentionPeriodInDays(int value) {
180 m_successRetentionPeriodInDaysHasBeenSet = true;
181 m_successRetentionPeriodInDays = value;
182 }
185 return *this;
186 }
188
190
196 inline int GetFailureRetentionPeriodInDays() const { return m_failureRetentionPeriodInDays; }
197 inline bool FailureRetentionPeriodInDaysHasBeenSet() const { return m_failureRetentionPeriodInDaysHasBeenSet; }
198 inline void SetFailureRetentionPeriodInDays(int value) {
199 m_failureRetentionPeriodInDaysHasBeenSet = true;
200 m_failureRetentionPeriodInDays = value;
201 }
204 return *this;
205 }
207
209
216 inline const VpcConfigInput& GetVpcConfig() const { return m_vpcConfig; }
217 inline bool VpcConfigHasBeenSet() const { return m_vpcConfigHasBeenSet; }
218 template <typename VpcConfigT = VpcConfigInput>
219 void SetVpcConfig(VpcConfigT&& value) {
220 m_vpcConfigHasBeenSet = true;
221 m_vpcConfig = std::forward<VpcConfigT>(value);
222 }
223 template <typename VpcConfigT = VpcConfigInput>
224 UpdateCanaryRequest& WithVpcConfig(VpcConfigT&& value) {
225 SetVpcConfig(std::forward<VpcConfigT>(value));
226 return *this;
227 }
229
231
242 inline const VisualReferenceInput& GetVisualReference() const { return m_visualReference; }
243 inline bool VisualReferenceHasBeenSet() const { return m_visualReferenceHasBeenSet; }
244 template <typename VisualReferenceT = VisualReferenceInput>
245 void SetVisualReference(VisualReferenceT&& value) {
246 m_visualReferenceHasBeenSet = true;
247 m_visualReference = std::forward<VisualReferenceT>(value);
248 }
249 template <typename VisualReferenceT = VisualReferenceInput>
250 UpdateCanaryRequest& WithVisualReference(VisualReferenceT&& value) {
251 SetVisualReference(std::forward<VisualReferenceT>(value));
252 return *this;
253 }
255
257
262 inline const Aws::String& GetArtifactS3Location() const { return m_artifactS3Location; }
263 inline bool ArtifactS3LocationHasBeenSet() const { return m_artifactS3LocationHasBeenSet; }
264 template <typename ArtifactS3LocationT = Aws::String>
265 void SetArtifactS3Location(ArtifactS3LocationT&& value) {
266 m_artifactS3LocationHasBeenSet = true;
267 m_artifactS3Location = std::forward<ArtifactS3LocationT>(value);
268 }
269 template <typename ArtifactS3LocationT = Aws::String>
270 UpdateCanaryRequest& WithArtifactS3Location(ArtifactS3LocationT&& value) {
271 SetArtifactS3Location(std::forward<ArtifactS3LocationT>(value));
272 return *this;
273 }
275
277
282 inline const ArtifactConfigInput& GetArtifactConfig() const { return m_artifactConfig; }
283 inline bool ArtifactConfigHasBeenSet() const { return m_artifactConfigHasBeenSet; }
284 template <typename ArtifactConfigT = ArtifactConfigInput>
285 void SetArtifactConfig(ArtifactConfigT&& value) {
286 m_artifactConfigHasBeenSet = true;
287 m_artifactConfig = std::forward<ArtifactConfigT>(value);
288 }
289 template <typename ArtifactConfigT = ArtifactConfigInput>
290 UpdateCanaryRequest& WithArtifactConfig(ArtifactConfigT&& value) {
291 SetArtifactConfig(std::forward<ArtifactConfigT>(value));
292 return *this;
293 }
295
297
306 inline ProvisionedResourceCleanupSetting GetProvisionedResourceCleanup() const { return m_provisionedResourceCleanup; }
307 inline bool ProvisionedResourceCleanupHasBeenSet() const { return m_provisionedResourceCleanupHasBeenSet; }
309 m_provisionedResourceCleanupHasBeenSet = true;
310 m_provisionedResourceCleanup = value;
311 }
314 return *this;
315 }
317
319
326 inline const Aws::String& GetDryRunId() const { return m_dryRunId; }
327 inline bool DryRunIdHasBeenSet() const { return m_dryRunIdHasBeenSet; }
328 template <typename DryRunIdT = Aws::String>
329 void SetDryRunId(DryRunIdT&& value) {
330 m_dryRunIdHasBeenSet = true;
331 m_dryRunId = std::forward<DryRunIdT>(value);
332 }
333 template <typename DryRunIdT = Aws::String>
334 UpdateCanaryRequest& WithDryRunId(DryRunIdT&& value) {
335 SetDryRunId(std::forward<DryRunIdT>(value));
336 return *this;
337 }
339
341
361 inline const Aws::Vector<VisualReferenceInput>& GetVisualReferences() const { return m_visualReferences; }
362 inline bool VisualReferencesHasBeenSet() const { return m_visualReferencesHasBeenSet; }
363 template <typename VisualReferencesT = Aws::Vector<VisualReferenceInput>>
364 void SetVisualReferences(VisualReferencesT&& value) {
365 m_visualReferencesHasBeenSet = true;
366 m_visualReferences = std::forward<VisualReferencesT>(value);
367 }
368 template <typename VisualReferencesT = Aws::Vector<VisualReferenceInput>>
369 UpdateCanaryRequest& WithVisualReferences(VisualReferencesT&& value) {
370 SetVisualReferences(std::forward<VisualReferencesT>(value));
371 return *this;
372 }
373 template <typename VisualReferencesT = VisualReferenceInput>
374 UpdateCanaryRequest& AddVisualReferences(VisualReferencesT&& value) {
375 m_visualReferencesHasBeenSet = true;
376 m_visualReferences.emplace_back(std::forward<VisualReferencesT>(value));
377 return *this;
378 }
380
382
388 inline const Aws::Vector<BrowserConfig>& GetBrowserConfigs() const { return m_browserConfigs; }
389 inline bool BrowserConfigsHasBeenSet() const { return m_browserConfigsHasBeenSet; }
390 template <typename BrowserConfigsT = Aws::Vector<BrowserConfig>>
391 void SetBrowserConfigs(BrowserConfigsT&& value) {
392 m_browserConfigsHasBeenSet = true;
393 m_browserConfigs = std::forward<BrowserConfigsT>(value);
394 }
395 template <typename BrowserConfigsT = Aws::Vector<BrowserConfig>>
396 UpdateCanaryRequest& WithBrowserConfigs(BrowserConfigsT&& value) {
397 SetBrowserConfigs(std::forward<BrowserConfigsT>(value));
398 return *this;
399 }
400 template <typename BrowserConfigsT = BrowserConfig>
401 UpdateCanaryRequest& AddBrowserConfigs(BrowserConfigsT&& value) {
402 m_browserConfigsHasBeenSet = true;
403 m_browserConfigs.emplace_back(std::forward<BrowserConfigsT>(value));
404 return *this;
405 }
407 private:
408 Aws::String m_name;
409
410 CanaryCodeInput m_code;
411
412 Aws::String m_executionRoleArn;
413
414 Aws::String m_runtimeVersion;
415
416 CanaryScheduleInput m_schedule;
417
418 CanaryRunConfigInput m_runConfig;
419
420 int m_successRetentionPeriodInDays{0};
421
422 int m_failureRetentionPeriodInDays{0};
423
424 VpcConfigInput m_vpcConfig;
425
426 VisualReferenceInput m_visualReference;
427
428 Aws::String m_artifactS3Location;
429
430 ArtifactConfigInput m_artifactConfig;
431
433
434 Aws::String m_dryRunId;
435
436 Aws::Vector<VisualReferenceInput> m_visualReferences;
437
438 Aws::Vector<BrowserConfig> m_browserConfigs;
439 bool m_nameHasBeenSet = false;
440 bool m_codeHasBeenSet = false;
441 bool m_executionRoleArnHasBeenSet = false;
442 bool m_runtimeVersionHasBeenSet = false;
443 bool m_scheduleHasBeenSet = false;
444 bool m_runConfigHasBeenSet = false;
445 bool m_successRetentionPeriodInDaysHasBeenSet = false;
446 bool m_failureRetentionPeriodInDaysHasBeenSet = false;
447 bool m_vpcConfigHasBeenSet = false;
448 bool m_visualReferenceHasBeenSet = false;
449 bool m_artifactS3LocationHasBeenSet = false;
450 bool m_artifactConfigHasBeenSet = false;
451 bool m_provisionedResourceCleanupHasBeenSet = false;
452 bool m_dryRunIdHasBeenSet = false;
453 bool m_visualReferencesHasBeenSet = false;
454 bool m_browserConfigsHasBeenSet = false;
455};
456
457} // namespace Model
458} // namespace Synthetics
459} // namespace Aws
UpdateCanaryRequest & AddVisualReferences(VisualReferencesT &&value)
const VisualReferenceInput & GetVisualReference() const
const Aws::Vector< BrowserConfig > & GetBrowserConfigs() const
UpdateCanaryRequest & WithRunConfig(RunConfigT &&value)
const Aws::Vector< VisualReferenceInput > & GetVisualReferences() const
UpdateCanaryRequest & WithFailureRetentionPeriodInDays(int value)
AWS_SYNTHETICS_API Aws::String SerializePayload() const override
UpdateCanaryRequest & WithArtifactS3Location(ArtifactS3LocationT &&value)
void SetProvisionedResourceCleanup(ProvisionedResourceCleanupSetting value)
UpdateCanaryRequest & WithExecutionRoleArn(ExecutionRoleArnT &&value)
UpdateCanaryRequest & WithBrowserConfigs(BrowserConfigsT &&value)
UpdateCanaryRequest & WithVisualReferences(VisualReferencesT &&value)
void SetExecutionRoleArn(ExecutionRoleArnT &&value)
const CanaryScheduleInput & GetSchedule() const
const ArtifactConfigInput & GetArtifactConfig() const
UpdateCanaryRequest & AddBrowserConfigs(BrowserConfigsT &&value)
UpdateCanaryRequest & WithVisualReference(VisualReferenceT &&value)
UpdateCanaryRequest & WithName(NameT &&value)
void SetArtifactConfig(ArtifactConfigT &&value)
UpdateCanaryRequest & WithSchedule(ScheduleT &&value)
void SetVisualReference(VisualReferenceT &&value)
void SetVisualReferences(VisualReferencesT &&value)
UpdateCanaryRequest & WithRuntimeVersion(RuntimeVersionT &&value)
AWS_SYNTHETICS_API UpdateCanaryRequest()=default
const CanaryRunConfigInput & GetRunConfig() const
void SetRuntimeVersion(RuntimeVersionT &&value)
UpdateCanaryRequest & WithArtifactConfig(ArtifactConfigT &&value)
UpdateCanaryRequest & WithDryRunId(DryRunIdT &&value)
UpdateCanaryRequest & WithProvisionedResourceCleanup(ProvisionedResourceCleanupSetting value)
void SetArtifactS3Location(ArtifactS3LocationT &&value)
virtual const char * GetServiceRequestName() const override
UpdateCanaryRequest & WithCode(CodeT &&value)
ProvisionedResourceCleanupSetting GetProvisionedResourceCleanup() const
void SetBrowserConfigs(BrowserConfigsT &&value)
UpdateCanaryRequest & WithSuccessRetentionPeriodInDays(int value)
UpdateCanaryRequest & WithVpcConfig(VpcConfigT &&value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector