AWS SDK for C++

AWS SDK for C++ Version 1.11.607

Loading...
Searching...
No Matches
EcsTaskProperties.h
1
6#pragma once
7#include <aws/batch/Batch_EXPORTS.h>
8#include <aws/core/utils/memory/stl/AWSVector.h>
9#include <aws/batch/model/EphemeralStorage.h>
10#include <aws/core/utils/memory/stl/AWSString.h>
11#include <aws/batch/model/NetworkConfiguration.h>
12#include <aws/batch/model/RuntimePlatform.h>
13#include <aws/batch/model/TaskContainerProperties.h>
14#include <aws/batch/model/Volume.h>
15#include <utility>
16
17namespace Aws
18{
19namespace Utils
20{
21namespace Json
22{
23 class JsonValue;
24 class JsonView;
25} // namespace Json
26} // namespace Utils
27namespace Batch
28{
29namespace Model
30{
31
41 {
42 public:
43 AWS_BATCH_API EcsTaskProperties() = default;
46 AWS_BATCH_API Aws::Utils::Json::JsonValue Jsonize() const;
47
48
50
53 inline const Aws::Vector<TaskContainerProperties>& GetContainers() const { return m_containers; }
54 inline bool ContainersHasBeenSet() const { return m_containersHasBeenSet; }
55 template<typename ContainersT = Aws::Vector<TaskContainerProperties>>
56 void SetContainers(ContainersT&& value) { m_containersHasBeenSet = true; m_containers = std::forward<ContainersT>(value); }
57 template<typename ContainersT = Aws::Vector<TaskContainerProperties>>
58 EcsTaskProperties& WithContainers(ContainersT&& value) { SetContainers(std::forward<ContainersT>(value)); return *this;}
59 template<typename ContainersT = TaskContainerProperties>
60 EcsTaskProperties& AddContainers(ContainersT&& value) { m_containersHasBeenSet = true; m_containers.emplace_back(std::forward<ContainersT>(value)); return *this; }
62
64
69 inline const EphemeralStorage& GetEphemeralStorage() const { return m_ephemeralStorage; }
70 inline bool EphemeralStorageHasBeenSet() const { return m_ephemeralStorageHasBeenSet; }
71 template<typename EphemeralStorageT = EphemeralStorage>
72 void SetEphemeralStorage(EphemeralStorageT&& value) { m_ephemeralStorageHasBeenSet = true; m_ephemeralStorage = std::forward<EphemeralStorageT>(value); }
73 template<typename EphemeralStorageT = EphemeralStorage>
74 EcsTaskProperties& WithEphemeralStorage(EphemeralStorageT&& value) { SetEphemeralStorage(std::forward<EphemeralStorageT>(value)); return *this;}
76
78
85 inline const Aws::String& GetExecutionRoleArn() const { return m_executionRoleArn; }
86 inline bool ExecutionRoleArnHasBeenSet() const { return m_executionRoleArnHasBeenSet; }
87 template<typename ExecutionRoleArnT = Aws::String>
88 void SetExecutionRoleArn(ExecutionRoleArnT&& value) { m_executionRoleArnHasBeenSet = true; m_executionRoleArn = std::forward<ExecutionRoleArnT>(value); }
89 template<typename ExecutionRoleArnT = Aws::String>
90 EcsTaskProperties& WithExecutionRoleArn(ExecutionRoleArnT&& value) { SetExecutionRoleArn(std::forward<ExecutionRoleArnT>(value)); return *this;}
92
94
104 inline const Aws::String& GetPlatformVersion() const { return m_platformVersion; }
105 inline bool PlatformVersionHasBeenSet() const { return m_platformVersionHasBeenSet; }
106 template<typename PlatformVersionT = Aws::String>
107 void SetPlatformVersion(PlatformVersionT&& value) { m_platformVersionHasBeenSet = true; m_platformVersion = std::forward<PlatformVersionT>(value); }
108 template<typename PlatformVersionT = Aws::String>
109 EcsTaskProperties& WithPlatformVersion(PlatformVersionT&& value) { SetPlatformVersion(std::forward<PlatformVersionT>(value)); return *this;}
111
113
128 inline const Aws::String& GetIpcMode() const { return m_ipcMode; }
129 inline bool IpcModeHasBeenSet() const { return m_ipcModeHasBeenSet; }
130 template<typename IpcModeT = Aws::String>
131 void SetIpcMode(IpcModeT&& value) { m_ipcModeHasBeenSet = true; m_ipcMode = std::forward<IpcModeT>(value); }
132 template<typename IpcModeT = Aws::String>
133 EcsTaskProperties& WithIpcMode(IpcModeT&& value) { SetIpcMode(std::forward<IpcModeT>(value)); return *this;}
135
137
143 inline const Aws::String& GetTaskRoleArn() const { return m_taskRoleArn; }
144 inline bool TaskRoleArnHasBeenSet() const { return m_taskRoleArnHasBeenSet; }
145 template<typename TaskRoleArnT = Aws::String>
146 void SetTaskRoleArn(TaskRoleArnT&& value) { m_taskRoleArnHasBeenSet = true; m_taskRoleArn = std::forward<TaskRoleArnT>(value); }
147 template<typename TaskRoleArnT = Aws::String>
148 EcsTaskProperties& WithTaskRoleArn(TaskRoleArnT&& value) { SetTaskRoleArn(std::forward<TaskRoleArnT>(value)); return *this;}
150
152
166 inline const Aws::String& GetPidMode() const { return m_pidMode; }
167 inline bool PidModeHasBeenSet() const { return m_pidModeHasBeenSet; }
168 template<typename PidModeT = Aws::String>
169 void SetPidMode(PidModeT&& value) { m_pidModeHasBeenSet = true; m_pidMode = std::forward<PidModeT>(value); }
170 template<typename PidModeT = Aws::String>
171 EcsTaskProperties& WithPidMode(PidModeT&& value) { SetPidMode(std::forward<PidModeT>(value)); return *this;}
173
175
180 inline const NetworkConfiguration& GetNetworkConfiguration() const { return m_networkConfiguration; }
181 inline bool NetworkConfigurationHasBeenSet() const { return m_networkConfigurationHasBeenSet; }
182 template<typename NetworkConfigurationT = NetworkConfiguration>
183 void SetNetworkConfiguration(NetworkConfigurationT&& value) { m_networkConfigurationHasBeenSet = true; m_networkConfiguration = std::forward<NetworkConfigurationT>(value); }
184 template<typename NetworkConfigurationT = NetworkConfiguration>
185 EcsTaskProperties& WithNetworkConfiguration(NetworkConfigurationT&& value) { SetNetworkConfiguration(std::forward<NetworkConfigurationT>(value)); return *this;}
187
189
193 inline const RuntimePlatform& GetRuntimePlatform() const { return m_runtimePlatform; }
194 inline bool RuntimePlatformHasBeenSet() const { return m_runtimePlatformHasBeenSet; }
195 template<typename RuntimePlatformT = RuntimePlatform>
196 void SetRuntimePlatform(RuntimePlatformT&& value) { m_runtimePlatformHasBeenSet = true; m_runtimePlatform = std::forward<RuntimePlatformT>(value); }
197 template<typename RuntimePlatformT = RuntimePlatform>
198 EcsTaskProperties& WithRuntimePlatform(RuntimePlatformT&& value) { SetRuntimePlatform(std::forward<RuntimePlatformT>(value)); return *this;}
200
202
205 inline const Aws::Vector<Volume>& GetVolumes() const { return m_volumes; }
206 inline bool VolumesHasBeenSet() const { return m_volumesHasBeenSet; }
207 template<typename VolumesT = Aws::Vector<Volume>>
208 void SetVolumes(VolumesT&& value) { m_volumesHasBeenSet = true; m_volumes = std::forward<VolumesT>(value); }
209 template<typename VolumesT = Aws::Vector<Volume>>
210 EcsTaskProperties& WithVolumes(VolumesT&& value) { SetVolumes(std::forward<VolumesT>(value)); return *this;}
211 template<typename VolumesT = Volume>
212 EcsTaskProperties& AddVolumes(VolumesT&& value) { m_volumesHasBeenSet = true; m_volumes.emplace_back(std::forward<VolumesT>(value)); return *this; }
214
216
221 inline bool GetEnableExecuteCommand() const { return m_enableExecuteCommand; }
222 inline bool EnableExecuteCommandHasBeenSet() const { return m_enableExecuteCommandHasBeenSet; }
223 inline void SetEnableExecuteCommand(bool value) { m_enableExecuteCommandHasBeenSet = true; m_enableExecuteCommand = value; }
224 inline EcsTaskProperties& WithEnableExecuteCommand(bool value) { SetEnableExecuteCommand(value); return *this;}
226 private:
227
229 bool m_containersHasBeenSet = false;
230
231 EphemeralStorage m_ephemeralStorage;
232 bool m_ephemeralStorageHasBeenSet = false;
233
234 Aws::String m_executionRoleArn;
235 bool m_executionRoleArnHasBeenSet = false;
236
237 Aws::String m_platformVersion;
238 bool m_platformVersionHasBeenSet = false;
239
240 Aws::String m_ipcMode;
241 bool m_ipcModeHasBeenSet = false;
242
243 Aws::String m_taskRoleArn;
244 bool m_taskRoleArnHasBeenSet = false;
245
246 Aws::String m_pidMode;
247 bool m_pidModeHasBeenSet = false;
248
249 NetworkConfiguration m_networkConfiguration;
250 bool m_networkConfigurationHasBeenSet = false;
251
252 RuntimePlatform m_runtimePlatform;
253 bool m_runtimePlatformHasBeenSet = false;
254
255 Aws::Vector<Volume> m_volumes;
256 bool m_volumesHasBeenSet = false;
257
258 bool m_enableExecuteCommand{false};
259 bool m_enableExecuteCommandHasBeenSet = false;
260 };
261
262} // namespace Model
263} // namespace Batch
264} // namespace Aws
void SetPlatformVersion(PlatformVersionT &&value)
void SetExecutionRoleArn(ExecutionRoleArnT &&value)
EcsTaskProperties & WithTaskRoleArn(TaskRoleArnT &&value)
const NetworkConfiguration & GetNetworkConfiguration() const
EcsTaskProperties & WithContainers(ContainersT &&value)
void SetRuntimePlatform(RuntimePlatformT &&value)
void SetContainers(ContainersT &&value)
EcsTaskProperties & WithNetworkConfiguration(NetworkConfigurationT &&value)
const Aws::Vector< TaskContainerProperties > & GetContainers() const
const Aws::Vector< Volume > & GetVolumes() const
const RuntimePlatform & GetRuntimePlatform() const
EcsTaskProperties & WithRuntimePlatform(RuntimePlatformT &&value)
EcsTaskProperties & AddContainers(ContainersT &&value)
AWS_BATCH_API EcsTaskProperties(Aws::Utils::Json::JsonView jsonValue)
AWS_BATCH_API EcsTaskProperties & operator=(Aws::Utils::Json::JsonView jsonValue)
EcsTaskProperties & WithEphemeralStorage(EphemeralStorageT &&value)
void SetNetworkConfiguration(NetworkConfigurationT &&value)
EcsTaskProperties & WithIpcMode(IpcModeT &&value)
const Aws::String & GetTaskRoleArn() const
void SetTaskRoleArn(TaskRoleArnT &&value)
EcsTaskProperties & AddVolumes(VolumesT &&value)
EcsTaskProperties & WithEnableExecuteCommand(bool value)
const Aws::String & GetPidMode() const
EcsTaskProperties & WithVolumes(VolumesT &&value)
EcsTaskProperties & WithPidMode(PidModeT &&value)
EcsTaskProperties & WithPlatformVersion(PlatformVersionT &&value)
const Aws::String & GetExecutionRoleArn() const
AWS_BATCH_API Aws::Utils::Json::JsonValue Jsonize() const
const EphemeralStorage & GetEphemeralStorage() const
const Aws::String & GetPlatformVersion() const
EcsTaskProperties & WithExecutionRoleArn(ExecutionRoleArnT &&value)
void SetEphemeralStorage(EphemeralStorageT &&value)
AWS_BATCH_API EcsTaskProperties()=default
const Aws::String & GetIpcMode() const
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue