AWS SDK for C++

AWS SDK for C++ Version 1.11.716

Loading...
Searching...
No Matches
Datum.h
1
6#pragma once
7#include <aws/core/utils/memory/stl/AWSAllocator.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/core/utils/memory/stl/AWSVector.h>
10#include <aws/timestream-query/TimestreamQuery_EXPORTS.h>
11#include <aws/timestream-query/model/TimeSeriesDataPoint.h>
12
13#include <utility>
14
15namespace Aws {
16namespace Utils {
17namespace Json {
18class JsonValue;
19class JsonView;
20} // namespace Json
21} // namespace Utils
22namespace TimestreamQuery {
23namespace Model {
24class Row;
25class TimeSeriesDataPoint;
26
33class Datum {
34 public:
35 AWS_TIMESTREAMQUERY_API Datum() = default;
36 AWS_TIMESTREAMQUERY_API Datum(Aws::Utils::Json::JsonView jsonValue);
38 AWS_TIMESTREAMQUERY_API Aws::Utils::Json::JsonValue Jsonize() const;
39
41
45 inline const Aws::String& GetScalarValue() const { return m_scalarValue; }
46 inline bool ScalarValueHasBeenSet() const { return m_scalarValueHasBeenSet; }
47 template <typename ScalarValueT = Aws::String>
49 m_scalarValueHasBeenSet = true;
50 m_scalarValue = std::forward<ScalarValueT>(value);
51 }
52 template <typename ScalarValueT = Aws::String>
54 SetScalarValue(std::forward<ScalarValueT>(value));
55 return *this;
56 }
58
60
63 inline const Aws::Vector<TimeSeriesDataPoint>& GetTimeSeriesValue() const { return m_timeSeriesValue; }
64 inline bool TimeSeriesValueHasBeenSet() const { return m_timeSeriesValueHasBeenSet; }
65 template <typename TimeSeriesValueT = Aws::Vector<TimeSeriesDataPoint>>
67 m_timeSeriesValueHasBeenSet = true;
68 m_timeSeriesValue = std::forward<TimeSeriesValueT>(value);
69 }
70 template <typename TimeSeriesValueT = Aws::Vector<TimeSeriesDataPoint>>
72 SetTimeSeriesValue(std::forward<TimeSeriesValueT>(value));
73 return *this;
74 }
75 template <typename TimeSeriesValueT = TimeSeriesDataPoint>
77 m_timeSeriesValueHasBeenSet = true;
78 m_timeSeriesValue.emplace_back(std::forward<TimeSeriesValueT>(value));
79 return *this;
80 }
82
84
87 inline const Aws::Vector<Datum>& GetArrayValue() const { return m_arrayValue; }
88 inline bool ArrayValueHasBeenSet() const { return m_arrayValueHasBeenSet; }
89 template <typename ArrayValueT = Aws::Vector<Datum>>
90 void SetArrayValue(ArrayValueT&& value) {
91 m_arrayValueHasBeenSet = true;
92 m_arrayValue = std::forward<ArrayValueT>(value);
93 }
94 template <typename ArrayValueT = Aws::Vector<Datum>>
96 SetArrayValue(std::forward<ArrayValueT>(value));
97 return *this;
98 }
99 template <typename ArrayValueT = Datum>
101 m_arrayValueHasBeenSet = true;
102 m_arrayValue.emplace_back(std::forward<ArrayValueT>(value));
103 return *this;
104 }
106
108
111 inline const Row& GetRowValue() const { return *m_rowValue; }
112 inline bool RowValueHasBeenSet() const { return m_rowValueHasBeenSet; }
113 template <typename RowValueT = Row>
114 void SetRowValue(RowValueT&& value) {
115 m_rowValueHasBeenSet = true;
116 m_rowValue = Aws::MakeShared<Row>("Datum", std::forward<RowValueT>(value));
117 }
118 template <typename RowValueT = Row>
120 SetRowValue(std::forward<RowValueT>(value));
121 return *this;
122 }
124
126
129 inline bool GetNullValue() const { return m_nullValue; }
130 inline bool NullValueHasBeenSet() const { return m_nullValueHasBeenSet; }
131 inline void SetNullValue(bool value) {
132 m_nullValueHasBeenSet = true;
133 m_nullValue = value;
134 }
135 inline Datum& WithNullValue(bool value) {
136 SetNullValue(value);
137 return *this;
138 }
140 private:
141 Aws::String m_scalarValue;
142
143 Aws::Vector<TimeSeriesDataPoint> m_timeSeriesValue;
144
145 Aws::Vector<Datum> m_arrayValue;
146
147 std::shared_ptr<Row> m_rowValue;
148
149 bool m_nullValue{false};
150 bool m_scalarValueHasBeenSet = false;
151 bool m_timeSeriesValueHasBeenSet = false;
152 bool m_arrayValueHasBeenSet = false;
153 bool m_rowValueHasBeenSet = false;
154 bool m_nullValueHasBeenSet = false;
155};
156
157} // namespace Model
158} // namespace TimestreamQuery
159} // namespace Aws
void SetRowValue(RowValueT &&value)
Definition Datum.h:114
AWS_TIMESTREAMQUERY_API Datum & operator=(Aws::Utils::Json::JsonView jsonValue)
const Aws::String & GetScalarValue() const
Definition Datum.h:45
Datum & WithNullValue(bool value)
Definition Datum.h:135
AWS_TIMESTREAMQUERY_API Datum()=default
void SetArrayValue(ArrayValueT &&value)
Definition Datum.h:90
AWS_TIMESTREAMQUERY_API Aws::Utils::Json::JsonValue Jsonize() const
Datum & AddArrayValue(ArrayValueT &&value)
Definition Datum.h:100
Datum & WithScalarValue(ScalarValueT &&value)
Definition Datum.h:53
bool TimeSeriesValueHasBeenSet() const
Definition Datum.h:64
void SetNullValue(bool value)
Definition Datum.h:131
void SetScalarValue(ScalarValueT &&value)
Definition Datum.h:48
AWS_TIMESTREAMQUERY_API Datum(Aws::Utils::Json::JsonView jsonValue)
Datum & WithTimeSeriesValue(TimeSeriesValueT &&value)
Definition Datum.h:71
void SetTimeSeriesValue(TimeSeriesValueT &&value)
Definition Datum.h:66
const Aws::Vector< Datum > & GetArrayValue() const
Definition Datum.h:87
Datum & AddTimeSeriesValue(TimeSeriesValueT &&value)
Definition Datum.h:76
bool ScalarValueHasBeenSet() const
Definition Datum.h:46
bool ArrayValueHasBeenSet() const
Definition Datum.h:88
Datum & WithArrayValue(ArrayValueT &&value)
Definition Datum.h:95
Datum & WithRowValue(RowValueT &&value)
Definition Datum.h:119
const Aws::Vector< TimeSeriesDataPoint > & GetTimeSeriesValue() const
Definition Datum.h:63
const Row & GetRowValue() const
Definition Datum.h:111
std::shared_ptr< T > MakeShared(const char *allocationTag, ArgTypes &&... args)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue