AWS SDK for C++

AWS SDK for C++ Version 1.11.719

Loading...
Searching...
No Matches
CoverageByTime.h
1
6#pragma once
7#include <aws/ce/CostExplorer_EXPORTS.h>
8#include <aws/ce/model/Coverage.h>
9#include <aws/ce/model/DateInterval.h>
10#include <aws/ce/model/ReservationCoverageGroup.h>
11#include <aws/core/utils/memory/stl/AWSVector.h>
12
13#include <utility>
14
15namespace Aws {
16namespace Utils {
17namespace Json {
18class JsonValue;
19class JsonView;
20} // namespace Json
21} // namespace Utils
22namespace CostExplorer {
23namespace Model {
24
32 public:
33 AWS_COSTEXPLORER_API CoverageByTime() = default;
34 AWS_COSTEXPLORER_API CoverageByTime(Aws::Utils::Json::JsonView jsonValue);
35 AWS_COSTEXPLORER_API CoverageByTime& operator=(Aws::Utils::Json::JsonView jsonValue);
36 AWS_COSTEXPLORER_API Aws::Utils::Json::JsonValue Jsonize() const;
37
39
42 inline const DateInterval& GetTimePeriod() const { return m_timePeriod; }
43 inline bool TimePeriodHasBeenSet() const { return m_timePeriodHasBeenSet; }
44 template <typename TimePeriodT = DateInterval>
45 void SetTimePeriod(TimePeriodT&& value) {
46 m_timePeriodHasBeenSet = true;
47 m_timePeriod = std::forward<TimePeriodT>(value);
48 }
49 template <typename TimePeriodT = DateInterval>
50 CoverageByTime& WithTimePeriod(TimePeriodT&& value) {
51 SetTimePeriod(std::forward<TimePeriodT>(value));
52 return *this;
53 }
55
57
60 inline const Aws::Vector<ReservationCoverageGroup>& GetGroups() const { return m_groups; }
61 inline bool GroupsHasBeenSet() const { return m_groupsHasBeenSet; }
62 template <typename GroupsT = Aws::Vector<ReservationCoverageGroup>>
63 void SetGroups(GroupsT&& value) {
64 m_groupsHasBeenSet = true;
65 m_groups = std::forward<GroupsT>(value);
66 }
67 template <typename GroupsT = Aws::Vector<ReservationCoverageGroup>>
68 CoverageByTime& WithGroups(GroupsT&& value) {
69 SetGroups(std::forward<GroupsT>(value));
70 return *this;
71 }
72 template <typename GroupsT = ReservationCoverageGroup>
73 CoverageByTime& AddGroups(GroupsT&& value) {
74 m_groupsHasBeenSet = true;
75 m_groups.emplace_back(std::forward<GroupsT>(value));
76 return *this;
77 }
79
81
84 inline const Coverage& GetTotal() const { return m_total; }
85 inline bool TotalHasBeenSet() const { return m_totalHasBeenSet; }
86 template <typename TotalT = Coverage>
87 void SetTotal(TotalT&& value) {
88 m_totalHasBeenSet = true;
89 m_total = std::forward<TotalT>(value);
90 }
91 template <typename TotalT = Coverage>
92 CoverageByTime& WithTotal(TotalT&& value) {
93 SetTotal(std::forward<TotalT>(value));
94 return *this;
95 }
97 private:
98 DateInterval m_timePeriod;
99
101
102 Coverage m_total;
103 bool m_timePeriodHasBeenSet = false;
104 bool m_groupsHasBeenSet = false;
105 bool m_totalHasBeenSet = false;
106};
107
108} // namespace Model
109} // namespace CostExplorer
110} // namespace Aws
const Aws::Vector< ReservationCoverageGroup > & GetGroups() const
CoverageByTime & AddGroups(GroupsT &&value)
const DateInterval & GetTimePeriod() const
AWS_COSTEXPLORER_API CoverageByTime & operator=(Aws::Utils::Json::JsonView jsonValue)
void SetTimePeriod(TimePeriodT &&value)
AWS_COSTEXPLORER_API CoverageByTime(Aws::Utils::Json::JsonView jsonValue)
AWS_COSTEXPLORER_API CoverageByTime()=default
AWS_COSTEXPLORER_API Aws::Utils::Json::JsonValue Jsonize() const
CoverageByTime & WithGroups(GroupsT &&value)
CoverageByTime & WithTimePeriod(TimePeriodT &&value)
CoverageByTime & WithTotal(TotalT &&value)
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue