AWS SDK for C++  1.9.19
AWS SDK for C++
Duration.h
Go to the documentation of this file.
1 
6 #pragma once
9 #include <utility>
10 
11 namespace Aws
12 {
13 namespace Utils
14 {
15 namespace Json
16 {
17  class JsonValue;
18  class JsonView;
19 } // namespace Json
20 } // namespace Utils
21 namespace AppMesh
22 {
23 namespace Model
24 {
25 
32  {
33  public:
38 
39 
43  inline const DurationUnit& GetUnit() const{ return m_unit; }
44 
48  inline bool UnitHasBeenSet() const { return m_unitHasBeenSet; }
49 
53  inline void SetUnit(const DurationUnit& value) { m_unitHasBeenSet = true; m_unit = value; }
54 
58  inline void SetUnit(DurationUnit&& value) { m_unitHasBeenSet = true; m_unit = std::move(value); }
59 
63  inline Duration& WithUnit(const DurationUnit& value) { SetUnit(value); return *this;}
64 
68  inline Duration& WithUnit(DurationUnit&& value) { SetUnit(std::move(value)); return *this;}
69 
70 
74  inline long long GetValue() const{ return m_value; }
75 
79  inline bool ValueHasBeenSet() const { return m_valueHasBeenSet; }
80 
84  inline void SetValue(long long value) { m_valueHasBeenSet = true; m_value = value; }
85 
89  inline Duration& WithValue(long long value) { SetValue(value); return *this;}
90 
91  private:
92 
93  DurationUnit m_unit;
94  bool m_unitHasBeenSet;
95 
96  long long m_value;
97  bool m_valueHasBeenSet;
98  };
99 
100 } // namespace Model
101 } // namespace AppMesh
102 } // namespace Aws
Aws::AppMesh::Model::Duration::SetUnit
void SetUnit(const DurationUnit &value)
Definition: Duration.h:53
Aws::AppMesh::Model::Duration::GetUnit
const DurationUnit & GetUnit() const
Definition: Duration.h:43
Aws::AppMesh::Model::Duration::WithValue
Duration & WithValue(long long value)
Definition: Duration.h:89
Aws::AppMesh::Model::Duration::Duration
Duration(Aws::Utils::Json::JsonView jsonValue)
Aws::AppMesh::Model::Duration::GetValue
long long GetValue() const
Definition: Duration.h:74
Aws::AppMesh::Model::Duration::WithUnit
Duration & WithUnit(DurationUnit &&value)
Definition: Duration.h:68
Aws::AppMesh::Model::Duration::SetUnit
void SetUnit(DurationUnit &&value)
Definition: Duration.h:58
AppMesh_EXPORTS.h
Aws::AppMesh::Model::Duration::UnitHasBeenSet
bool UnitHasBeenSet() const
Definition: Duration.h:48
Aws::AppMesh::Model::Duration::WithUnit
Duration & WithUnit(const DurationUnit &value)
Definition: Duration.h:63
Aws::AppMesh::Model::Duration::Jsonize
Aws::Utils::Json::JsonValue Jsonize() const
Aws::Utils::Json::JsonView
Definition: JsonSerializer.h:222
Aws::Utils::Json::JsonValue
Definition: JsonSerializer.h:30
Aws::AppMesh::Model::Duration::SetValue
void SetValue(long long value)
Definition: Duration.h:84
Aws
Definition: AccessManagementClient.h:15
Aws::AppMesh::Model::Duration::ValueHasBeenSet
bool ValueHasBeenSet() const
Definition: Duration.h:79
Aws::AppMesh::Model::DurationUnit
DurationUnit
Definition: DurationUnit.h:17
Aws::AppMesh::Model::Duration::operator=
Duration & operator=(Aws::Utils::Json::JsonView jsonValue)
Aws::AppMesh::Model::Duration
Definition: Duration.h:32
DurationUnit.h
Aws::AppMesh::Model::Duration::Duration
Duration()
AWS_APPMESH_API
#define AWS_APPMESH_API
Definition: AppMesh_EXPORTS.h:28