AWS SDK for C++

AWS SDK for C++ Version 1.11.743

Loading...
Searching...
No Matches
LinuxParameters.h
1
6#pragma once
7#include <aws/core/utils/memory/stl/AWSVector.h>
8#include <aws/ecs/ECS_EXPORTS.h>
9#include <aws/ecs/model/Device.h>
10#include <aws/ecs/model/KernelCapabilities.h>
11#include <aws/ecs/model/Tmpfs.h>
12
13#include <utility>
14
15namespace Aws {
16namespace Utils {
17namespace Json {
18class JsonValue;
19class JsonView;
20} // namespace Json
21} // namespace Utils
22namespace ECS {
23namespace Model {
24
34 public:
35 AWS_ECS_API LinuxParameters() = default;
39
41
48 inline const KernelCapabilities& GetCapabilities() const { return m_capabilities; }
49 inline bool CapabilitiesHasBeenSet() const { return m_capabilitiesHasBeenSet; }
50 template <typename CapabilitiesT = KernelCapabilities>
51 void SetCapabilities(CapabilitiesT&& value) {
52 m_capabilitiesHasBeenSet = true;
53 m_capabilities = std::forward<CapabilitiesT>(value);
54 }
55 template <typename CapabilitiesT = KernelCapabilities>
56 LinuxParameters& WithCapabilities(CapabilitiesT&& value) {
57 SetCapabilities(std::forward<CapabilitiesT>(value));
58 return *this;
59 }
61
63
70 inline const Aws::Vector<Device>& GetDevices() const { return m_devices; }
71 inline bool DevicesHasBeenSet() const { return m_devicesHasBeenSet; }
72 template <typename DevicesT = Aws::Vector<Device>>
73 void SetDevices(DevicesT&& value) {
74 m_devicesHasBeenSet = true;
75 m_devices = std::forward<DevicesT>(value);
76 }
77 template <typename DevicesT = Aws::Vector<Device>>
78 LinuxParameters& WithDevices(DevicesT&& value) {
79 SetDevices(std::forward<DevicesT>(value));
80 return *this;
81 }
82 template <typename DevicesT = Device>
83 LinuxParameters& AddDevices(DevicesT&& value) {
84 m_devicesHasBeenSet = true;
85 m_devices.emplace_back(std::forward<DevicesT>(value));
86 return *this;
87 }
89
91
99 inline bool GetInitProcessEnabled() const { return m_initProcessEnabled; }
100 inline bool InitProcessEnabledHasBeenSet() const { return m_initProcessEnabledHasBeenSet; }
101 inline void SetInitProcessEnabled(bool value) {
102 m_initProcessEnabledHasBeenSet = true;
103 m_initProcessEnabled = value;
104 }
107 return *this;
108 }
110
112
118 inline int GetSharedMemorySize() const { return m_sharedMemorySize; }
119 inline bool SharedMemorySizeHasBeenSet() const { return m_sharedMemorySizeHasBeenSet; }
120 inline void SetSharedMemorySize(int value) {
121 m_sharedMemorySizeHasBeenSet = true;
122 m_sharedMemorySize = value;
123 }
125 SetSharedMemorySize(value);
126 return *this;
127 }
129
131
137 inline const Aws::Vector<Tmpfs>& GetTmpfs() const { return m_tmpfs; }
138 inline bool TmpfsHasBeenSet() const { return m_tmpfsHasBeenSet; }
139 template <typename TmpfsT = Aws::Vector<Tmpfs>>
140 void SetTmpfs(TmpfsT&& value) {
141 m_tmpfsHasBeenSet = true;
142 m_tmpfs = std::forward<TmpfsT>(value);
143 }
144 template <typename TmpfsT = Aws::Vector<Tmpfs>>
145 LinuxParameters& WithTmpfs(TmpfsT&& value) {
146 SetTmpfs(std::forward<TmpfsT>(value));
147 return *this;
148 }
149 template <typename TmpfsT = Tmpfs>
150 LinuxParameters& AddTmpfs(TmpfsT&& value) {
151 m_tmpfsHasBeenSet = true;
152 m_tmpfs.emplace_back(std::forward<TmpfsT>(value));
153 return *this;
154 }
156
158
172 inline int GetMaxSwap() const { return m_maxSwap; }
173 inline bool MaxSwapHasBeenSet() const { return m_maxSwapHasBeenSet; }
174 inline void SetMaxSwap(int value) {
175 m_maxSwapHasBeenSet = true;
176 m_maxSwap = value;
177 }
178 inline LinuxParameters& WithMaxSwap(int value) {
179 SetMaxSwap(value);
180 return *this;
181 }
183
185
199 inline int GetSwappiness() const { return m_swappiness; }
200 inline bool SwappinessHasBeenSet() const { return m_swappinessHasBeenSet; }
201 inline void SetSwappiness(int value) {
202 m_swappinessHasBeenSet = true;
203 m_swappiness = value;
204 }
205 inline LinuxParameters& WithSwappiness(int value) {
206 SetSwappiness(value);
207 return *this;
208 }
210 private:
211 KernelCapabilities m_capabilities;
212
213 Aws::Vector<Device> m_devices;
214
215 bool m_initProcessEnabled{false};
216
217 int m_sharedMemorySize{0};
218
219 Aws::Vector<Tmpfs> m_tmpfs;
220
221 int m_maxSwap{0};
222
223 int m_swappiness{0};
224 bool m_capabilitiesHasBeenSet = false;
225 bool m_devicesHasBeenSet = false;
226 bool m_initProcessEnabledHasBeenSet = false;
227 bool m_sharedMemorySizeHasBeenSet = false;
228 bool m_tmpfsHasBeenSet = false;
229 bool m_maxSwapHasBeenSet = false;
230 bool m_swappinessHasBeenSet = false;
231};
232
233} // namespace Model
234} // namespace ECS
235} // namespace Aws
LinuxParameters & WithTmpfs(TmpfsT &&value)
LinuxParameters & WithCapabilities(CapabilitiesT &&value)
const KernelCapabilities & GetCapabilities() const
LinuxParameters & AddTmpfs(TmpfsT &&value)
void SetDevices(DevicesT &&value)
AWS_ECS_API Aws::Utils::Json::JsonValue Jsonize() const
LinuxParameters & WithSharedMemorySize(int value)
LinuxParameters & WithDevices(DevicesT &&value)
AWS_ECS_API LinuxParameters()=default
LinuxParameters & WithSwappiness(int value)
LinuxParameters & AddDevices(DevicesT &&value)
AWS_ECS_API LinuxParameters(Aws::Utils::Json::JsonView jsonValue)
AWS_ECS_API LinuxParameters & operator=(Aws::Utils::Json::JsonView jsonValue)
const Aws::Vector< Device > & GetDevices() const
void SetCapabilities(CapabilitiesT &&value)
const Aws::Vector< Tmpfs > & GetTmpfs() const
LinuxParameters & WithInitProcessEnabled(bool value)
LinuxParameters & WithMaxSwap(int value)
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue