AWS SDK for C++

AWS SDK for C++ Version 1.11.941

Loading...
Searching...
No Matches
CostCover.h
1
6#pragma once
7#include <aws/appmonetization/AppMonetization_EXPORTS.h>
8#include <aws/appmonetization/model/Price.h>
9
10#include <utility>
11
12namespace Aws {
13namespace Utils {
14namespace Json {
15class JsonValue;
16class JsonView;
17} // namespace Json
18} // namespace Utils
19namespace AppMonetization {
20namespace Model {
21
28class CostCover {
29 public:
30 AWS_APPMONETIZATION_API CostCover() = default;
31 AWS_APPMONETIZATION_API CostCover(Aws::Utils::Json::JsonView jsonValue);
32 AWS_APPMONETIZATION_API CostCover& operator=(Aws::Utils::Json::JsonView jsonValue);
33 AWS_APPMONETIZATION_API Aws::Utils::Json::JsonValue Jsonize() const;
34
36
39 inline double GetMargin() const { return m_margin; }
40 inline bool MarginHasBeenSet() const { return m_marginHasBeenSet; }
41 inline void SetMargin(double value) {
42 m_marginHasBeenSet = true;
43 m_margin = value;
44 }
45 inline CostCover& WithMargin(double value) {
46 SetMargin(value);
47 return *this;
48 }
50
52
55 inline const Price& GetPrice() const { return m_price; }
56 inline bool PriceHasBeenSet() const { return m_priceHasBeenSet; }
57 template <typename PriceT = Price>
58 void SetPrice(PriceT&& value) {
59 m_priceHasBeenSet = true;
60 m_price = std::forward<PriceT>(value);
61 }
62 template <typename PriceT = Price>
63 CostCover& WithPrice(PriceT&& value) {
64 SetPrice(std::forward<PriceT>(value));
65 return *this;
66 }
68 private:
69 double m_margin{0.0};
70
71 Price m_price;
72 bool m_marginHasBeenSet = false;
73 bool m_priceHasBeenSet = false;
74};
75
76} // namespace Model
77} // namespace AppMonetization
78} // namespace Aws
AWS_APPMONETIZATION_API Aws::Utils::Json::JsonValue Jsonize() const
CostCover & WithPrice(PriceT &&value)
Definition CostCover.h:63
AWS_APPMONETIZATION_API CostCover(Aws::Utils::Json::JsonView jsonValue)
AWS_APPMONETIZATION_API CostCover & operator=(Aws::Utils::Json::JsonView jsonValue)
AWS_APPMONETIZATION_API CostCover()=default
CostCover & WithMargin(double value)
Definition CostCover.h:45
Aws::Utils::Json::JsonValue JsonValue