AWS SDK for C++

AWS SDK for C++ Version 1.11.612

Loading...
Searching...
No Matches
ECSServiceRecommendationOption.h
1
6#pragma once
7#include <aws/compute-optimizer/ComputeOptimizer_EXPORTS.h>
8#include <aws/compute-optimizer/model/SavingsOpportunity.h>
9#include <aws/compute-optimizer/model/ECSSavingsOpportunityAfterDiscounts.h>
10#include <aws/core/utils/memory/stl/AWSVector.h>
11#include <aws/compute-optimizer/model/ECSServiceProjectedUtilizationMetric.h>
12#include <aws/compute-optimizer/model/ContainerRecommendation.h>
13#include <utility>
14
15namespace Aws
16{
17namespace Utils
18{
19namespace Json
20{
21 class JsonValue;
22 class JsonView;
23} // namespace Json
24} // namespace Utils
25namespace ComputeOptimizer
26{
27namespace Model
28{
29
37 {
38 public:
39 AWS_COMPUTEOPTIMIZER_API ECSServiceRecommendationOption() = default;
42 AWS_COMPUTEOPTIMIZER_API Aws::Utils::Json::JsonValue Jsonize() const;
43
44
46
49 inline int GetMemory() const { return m_memory; }
50 inline bool MemoryHasBeenSet() const { return m_memoryHasBeenSet; }
51 inline void SetMemory(int value) { m_memoryHasBeenSet = true; m_memory = value; }
52 inline ECSServiceRecommendationOption& WithMemory(int value) { SetMemory(value); return *this;}
54
56
59 inline int GetCpu() const { return m_cpu; }
60 inline bool CpuHasBeenSet() const { return m_cpuHasBeenSet; }
61 inline void SetCpu(int value) { m_cpuHasBeenSet = true; m_cpu = value; }
62 inline ECSServiceRecommendationOption& WithCpu(int value) { SetCpu(value); return *this;}
64
66
67 inline const SavingsOpportunity& GetSavingsOpportunity() const { return m_savingsOpportunity; }
68 inline bool SavingsOpportunityHasBeenSet() const { return m_savingsOpportunityHasBeenSet; }
69 template<typename SavingsOpportunityT = SavingsOpportunity>
70 void SetSavingsOpportunity(SavingsOpportunityT&& value) { m_savingsOpportunityHasBeenSet = true; m_savingsOpportunity = std::forward<SavingsOpportunityT>(value); }
71 template<typename SavingsOpportunityT = SavingsOpportunity>
72 ECSServiceRecommendationOption& WithSavingsOpportunity(SavingsOpportunityT&& value) { SetSavingsOpportunity(std::forward<SavingsOpportunityT>(value)); return *this;}
74
76
82 inline const ECSSavingsOpportunityAfterDiscounts& GetSavingsOpportunityAfterDiscounts() const { return m_savingsOpportunityAfterDiscounts; }
83 inline bool SavingsOpportunityAfterDiscountsHasBeenSet() const { return m_savingsOpportunityAfterDiscountsHasBeenSet; }
84 template<typename SavingsOpportunityAfterDiscountsT = ECSSavingsOpportunityAfterDiscounts>
85 void SetSavingsOpportunityAfterDiscounts(SavingsOpportunityAfterDiscountsT&& value) { m_savingsOpportunityAfterDiscountsHasBeenSet = true; m_savingsOpportunityAfterDiscounts = std::forward<SavingsOpportunityAfterDiscountsT>(value); }
86 template<typename SavingsOpportunityAfterDiscountsT = ECSSavingsOpportunityAfterDiscounts>
87 ECSServiceRecommendationOption& WithSavingsOpportunityAfterDiscounts(SavingsOpportunityAfterDiscountsT&& value) { SetSavingsOpportunityAfterDiscounts(std::forward<SavingsOpportunityAfterDiscountsT>(value)); return *this;}
89
91
95 inline const Aws::Vector<ECSServiceProjectedUtilizationMetric>& GetProjectedUtilizationMetrics() const { return m_projectedUtilizationMetrics; }
96 inline bool ProjectedUtilizationMetricsHasBeenSet() const { return m_projectedUtilizationMetricsHasBeenSet; }
97 template<typename ProjectedUtilizationMetricsT = Aws::Vector<ECSServiceProjectedUtilizationMetric>>
98 void SetProjectedUtilizationMetrics(ProjectedUtilizationMetricsT&& value) { m_projectedUtilizationMetricsHasBeenSet = true; m_projectedUtilizationMetrics = std::forward<ProjectedUtilizationMetricsT>(value); }
99 template<typename ProjectedUtilizationMetricsT = Aws::Vector<ECSServiceProjectedUtilizationMetric>>
100 ECSServiceRecommendationOption& WithProjectedUtilizationMetrics(ProjectedUtilizationMetricsT&& value) { SetProjectedUtilizationMetrics(std::forward<ProjectedUtilizationMetricsT>(value)); return *this;}
101 template<typename ProjectedUtilizationMetricsT = ECSServiceProjectedUtilizationMetric>
102 ECSServiceRecommendationOption& AddProjectedUtilizationMetrics(ProjectedUtilizationMetricsT&& value) { m_projectedUtilizationMetricsHasBeenSet = true; m_projectedUtilizationMetrics.emplace_back(std::forward<ProjectedUtilizationMetricsT>(value)); return *this; }
104
106
110 inline const Aws::Vector<ContainerRecommendation>& GetContainerRecommendations() const { return m_containerRecommendations; }
111 inline bool ContainerRecommendationsHasBeenSet() const { return m_containerRecommendationsHasBeenSet; }
112 template<typename ContainerRecommendationsT = Aws::Vector<ContainerRecommendation>>
113 void SetContainerRecommendations(ContainerRecommendationsT&& value) { m_containerRecommendationsHasBeenSet = true; m_containerRecommendations = std::forward<ContainerRecommendationsT>(value); }
114 template<typename ContainerRecommendationsT = Aws::Vector<ContainerRecommendation>>
115 ECSServiceRecommendationOption& WithContainerRecommendations(ContainerRecommendationsT&& value) { SetContainerRecommendations(std::forward<ContainerRecommendationsT>(value)); return *this;}
116 template<typename ContainerRecommendationsT = ContainerRecommendation>
117 ECSServiceRecommendationOption& AddContainerRecommendations(ContainerRecommendationsT&& value) { m_containerRecommendationsHasBeenSet = true; m_containerRecommendations.emplace_back(std::forward<ContainerRecommendationsT>(value)); return *this; }
119 private:
120
121 int m_memory{0};
122 bool m_memoryHasBeenSet = false;
123
124 int m_cpu{0};
125 bool m_cpuHasBeenSet = false;
126
127 SavingsOpportunity m_savingsOpportunity;
128 bool m_savingsOpportunityHasBeenSet = false;
129
130 ECSSavingsOpportunityAfterDiscounts m_savingsOpportunityAfterDiscounts;
131 bool m_savingsOpportunityAfterDiscountsHasBeenSet = false;
132
133 Aws::Vector<ECSServiceProjectedUtilizationMetric> m_projectedUtilizationMetrics;
134 bool m_projectedUtilizationMetricsHasBeenSet = false;
135
136 Aws::Vector<ContainerRecommendation> m_containerRecommendations;
137 bool m_containerRecommendationsHasBeenSet = false;
138 };
139
140} // namespace Model
141} // namespace ComputeOptimizer
142} // namespace Aws
ECSServiceRecommendationOption & AddProjectedUtilizationMetrics(ProjectedUtilizationMetricsT &&value)
ECSServiceRecommendationOption & WithSavingsOpportunity(SavingsOpportunityT &&value)
const Aws::Vector< ECSServiceProjectedUtilizationMetric > & GetProjectedUtilizationMetrics() const
ECSServiceRecommendationOption & WithContainerRecommendations(ContainerRecommendationsT &&value)
AWS_COMPUTEOPTIMIZER_API Aws::Utils::Json::JsonValue Jsonize() const
AWS_COMPUTEOPTIMIZER_API ECSServiceRecommendationOption(Aws::Utils::Json::JsonView jsonValue)
const Aws::Vector< ContainerRecommendation > & GetContainerRecommendations() const
AWS_COMPUTEOPTIMIZER_API ECSServiceRecommendationOption & operator=(Aws::Utils::Json::JsonView jsonValue)
ECSServiceRecommendationOption & AddContainerRecommendations(ContainerRecommendationsT &&value)
ECSServiceRecommendationOption & WithSavingsOpportunityAfterDiscounts(SavingsOpportunityAfterDiscountsT &&value)
void SetSavingsOpportunityAfterDiscounts(SavingsOpportunityAfterDiscountsT &&value)
AWS_COMPUTEOPTIMIZER_API ECSServiceRecommendationOption()=default
ECSServiceRecommendationOption & WithProjectedUtilizationMetrics(ProjectedUtilizationMetricsT &&value)
const ECSSavingsOpportunityAfterDiscounts & GetSavingsOpportunityAfterDiscounts() const
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue