AWS SDK for C++

AWS SDK for C++ Version 1.11.921

Loading...
Searching...
No Matches
ResourceRequirement.h
1
6#pragma once
7#include <aws/core/utils/memory/stl/AWSString.h>
8#include <aws/ecs/ECS_EXPORTS.h>
9#include <aws/ecs/model/ResourceType.h>
10#include <aws/ecs/model/SharingStrategy.h>
11
12#include <utility>
13
14namespace Aws {
15namespace Utils {
16namespace Json {
17class JsonValue;
18class JsonView;
19} // namespace Json
20} // namespace Utils
21namespace ECS {
22namespace Model {
23
37 public:
38 AWS_ECS_API ResourceRequirement() = default;
42
44
62 inline const Aws::String& GetValue() const { return m_value; }
63 inline bool ValueHasBeenSet() const { return m_valueHasBeenSet; }
64 template <typename ValueT = Aws::String>
65 void SetValue(ValueT&& value) {
66 m_valueHasBeenSet = true;
67 m_value = std::forward<ValueT>(value);
68 }
69 template <typename ValueT = Aws::String>
70 ResourceRequirement& WithValue(ValueT&& value) {
71 SetValue(std::forward<ValueT>(value));
72 return *this;
73 }
75
77
80 inline ResourceType GetType() const { return m_type; }
81 inline bool TypeHasBeenSet() const { return m_typeHasBeenSet; }
82 inline void SetType(ResourceType value) {
83 m_typeHasBeenSet = true;
84 m_type = value;
85 }
87 SetType(value);
88 return *this;
89 }
91
93
104 inline const SharingStrategy& GetSharingStrategy() const { return m_sharingStrategy; }
105 inline bool SharingStrategyHasBeenSet() const { return m_sharingStrategyHasBeenSet; }
106 template <typename SharingStrategyT = SharingStrategy>
107 void SetSharingStrategy(SharingStrategyT&& value) {
108 m_sharingStrategyHasBeenSet = true;
109 m_sharingStrategy = std::forward<SharingStrategyT>(value);
110 }
111 template <typename SharingStrategyT = SharingStrategy>
112 ResourceRequirement& WithSharingStrategy(SharingStrategyT&& value) {
113 SetSharingStrategy(std::forward<SharingStrategyT>(value));
114 return *this;
115 }
117 private:
118 Aws::String m_value;
119
121
122 SharingStrategy m_sharingStrategy;
123 bool m_valueHasBeenSet = false;
124 bool m_typeHasBeenSet = false;
125 bool m_sharingStrategyHasBeenSet = false;
126};
127
128} // namespace Model
129} // namespace ECS
130} // namespace Aws
AWS_ECS_API ResourceRequirement()=default
ResourceRequirement & WithValue(ValueT &&value)
AWS_ECS_API ResourceRequirement & operator=(Aws::Utils::Json::JsonView jsonValue)
const SharingStrategy & GetSharingStrategy() const
ResourceRequirement & WithSharingStrategy(SharingStrategyT &&value)
ResourceRequirement & WithType(ResourceType value)
AWS_ECS_API ResourceRequirement(Aws::Utils::Json::JsonView jsonValue)
AWS_ECS_API Aws::Utils::Json::JsonValue Jsonize() const
const Aws::String & GetValue() const
void SetSharingStrategy(SharingStrategyT &&value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Aws::Utils::Json::JsonValue JsonValue