AWS SDK for C++

AWS SDK for C++ Version 1.11.607

Loading...
Searching...
No Matches
DataSource.h
1
6#pragma once
7#include <aws/appsync/AppSync_EXPORTS.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/appsync/model/DataSourceType.h>
10#include <aws/appsync/model/DynamodbDataSourceConfig.h>
11#include <aws/appsync/model/LambdaDataSourceConfig.h>
12#include <aws/appsync/model/ElasticsearchDataSourceConfig.h>
13#include <aws/appsync/model/OpenSearchServiceDataSourceConfig.h>
14#include <aws/appsync/model/HttpDataSourceConfig.h>
15#include <aws/appsync/model/RelationalDatabaseDataSourceConfig.h>
16#include <aws/appsync/model/EventBridgeDataSourceConfig.h>
17#include <aws/appsync/model/DataSourceLevelMetricsConfig.h>
18#include <utility>
19
20namespace Aws
21{
22namespace Utils
23{
24namespace Json
25{
26 class JsonValue;
27 class JsonView;
28} // namespace Json
29} // namespace Utils
30namespace AppSync
31{
32namespace Model
33{
34
41 {
42 public:
43 AWS_APPSYNC_API DataSource() = default;
44 AWS_APPSYNC_API DataSource(Aws::Utils::Json::JsonView jsonValue);
45 AWS_APPSYNC_API DataSource& operator=(Aws::Utils::Json::JsonView jsonValue);
46 AWS_APPSYNC_API Aws::Utils::Json::JsonValue Jsonize() const;
47
48
50
53 inline const Aws::String& GetDataSourceArn() const { return m_dataSourceArn; }
54 inline bool DataSourceArnHasBeenSet() const { return m_dataSourceArnHasBeenSet; }
55 template<typename DataSourceArnT = Aws::String>
56 void SetDataSourceArn(DataSourceArnT&& value) { m_dataSourceArnHasBeenSet = true; m_dataSourceArn = std::forward<DataSourceArnT>(value); }
57 template<typename DataSourceArnT = Aws::String>
58 DataSource& WithDataSourceArn(DataSourceArnT&& value) { SetDataSourceArn(std::forward<DataSourceArnT>(value)); return *this;}
60
62
65 inline const Aws::String& GetName() const { return m_name; }
66 inline bool NameHasBeenSet() const { return m_nameHasBeenSet; }
67 template<typename NameT = Aws::String>
68 void SetName(NameT&& value) { m_nameHasBeenSet = true; m_name = std::forward<NameT>(value); }
69 template<typename NameT = Aws::String>
70 DataSource& WithName(NameT&& value) { SetName(std::forward<NameT>(value)); return *this;}
72
74
77 inline const Aws::String& GetDescription() const { return m_description; }
78 inline bool DescriptionHasBeenSet() const { return m_descriptionHasBeenSet; }
79 template<typename DescriptionT = Aws::String>
80 void SetDescription(DescriptionT&& value) { m_descriptionHasBeenSet = true; m_description = std::forward<DescriptionT>(value); }
81 template<typename DescriptionT = Aws::String>
82 DataSource& WithDescription(DescriptionT&& value) { SetDescription(std::forward<DescriptionT>(value)); return *this;}
84
86
103 inline DataSourceType GetType() const { return m_type; }
104 inline bool TypeHasBeenSet() const { return m_typeHasBeenSet; }
105 inline void SetType(DataSourceType value) { m_typeHasBeenSet = true; m_type = value; }
106 inline DataSource& WithType(DataSourceType value) { SetType(value); return *this;}
108
110
115 inline const Aws::String& GetServiceRoleArn() const { return m_serviceRoleArn; }
116 inline bool ServiceRoleArnHasBeenSet() const { return m_serviceRoleArnHasBeenSet; }
117 template<typename ServiceRoleArnT = Aws::String>
118 void SetServiceRoleArn(ServiceRoleArnT&& value) { m_serviceRoleArnHasBeenSet = true; m_serviceRoleArn = std::forward<ServiceRoleArnT>(value); }
119 template<typename ServiceRoleArnT = Aws::String>
120 DataSource& WithServiceRoleArn(ServiceRoleArnT&& value) { SetServiceRoleArn(std::forward<ServiceRoleArnT>(value)); return *this;}
122
124
127 inline const DynamodbDataSourceConfig& GetDynamodbConfig() const { return m_dynamodbConfig; }
128 inline bool DynamodbConfigHasBeenSet() const { return m_dynamodbConfigHasBeenSet; }
129 template<typename DynamodbConfigT = DynamodbDataSourceConfig>
130 void SetDynamodbConfig(DynamodbConfigT&& value) { m_dynamodbConfigHasBeenSet = true; m_dynamodbConfig = std::forward<DynamodbConfigT>(value); }
131 template<typename DynamodbConfigT = DynamodbDataSourceConfig>
132 DataSource& WithDynamodbConfig(DynamodbConfigT&& value) { SetDynamodbConfig(std::forward<DynamodbConfigT>(value)); return *this;}
134
136
139 inline const LambdaDataSourceConfig& GetLambdaConfig() const { return m_lambdaConfig; }
140 inline bool LambdaConfigHasBeenSet() const { return m_lambdaConfigHasBeenSet; }
141 template<typename LambdaConfigT = LambdaDataSourceConfig>
142 void SetLambdaConfig(LambdaConfigT&& value) { m_lambdaConfigHasBeenSet = true; m_lambdaConfig = std::forward<LambdaConfigT>(value); }
143 template<typename LambdaConfigT = LambdaDataSourceConfig>
144 DataSource& WithLambdaConfig(LambdaConfigT&& value) { SetLambdaConfig(std::forward<LambdaConfigT>(value)); return *this;}
146
148
151 inline const ElasticsearchDataSourceConfig& GetElasticsearchConfig() const { return m_elasticsearchConfig; }
152 inline bool ElasticsearchConfigHasBeenSet() const { return m_elasticsearchConfigHasBeenSet; }
153 template<typename ElasticsearchConfigT = ElasticsearchDataSourceConfig>
154 void SetElasticsearchConfig(ElasticsearchConfigT&& value) { m_elasticsearchConfigHasBeenSet = true; m_elasticsearchConfig = std::forward<ElasticsearchConfigT>(value); }
155 template<typename ElasticsearchConfigT = ElasticsearchDataSourceConfig>
156 DataSource& WithElasticsearchConfig(ElasticsearchConfigT&& value) { SetElasticsearchConfig(std::forward<ElasticsearchConfigT>(value)); return *this;}
158
160
163 inline const OpenSearchServiceDataSourceConfig& GetOpenSearchServiceConfig() const { return m_openSearchServiceConfig; }
164 inline bool OpenSearchServiceConfigHasBeenSet() const { return m_openSearchServiceConfigHasBeenSet; }
165 template<typename OpenSearchServiceConfigT = OpenSearchServiceDataSourceConfig>
166 void SetOpenSearchServiceConfig(OpenSearchServiceConfigT&& value) { m_openSearchServiceConfigHasBeenSet = true; m_openSearchServiceConfig = std::forward<OpenSearchServiceConfigT>(value); }
167 template<typename OpenSearchServiceConfigT = OpenSearchServiceDataSourceConfig>
168 DataSource& WithOpenSearchServiceConfig(OpenSearchServiceConfigT&& value) { SetOpenSearchServiceConfig(std::forward<OpenSearchServiceConfigT>(value)); return *this;}
170
172
175 inline const HttpDataSourceConfig& GetHttpConfig() const { return m_httpConfig; }
176 inline bool HttpConfigHasBeenSet() const { return m_httpConfigHasBeenSet; }
177 template<typename HttpConfigT = HttpDataSourceConfig>
178 void SetHttpConfig(HttpConfigT&& value) { m_httpConfigHasBeenSet = true; m_httpConfig = std::forward<HttpConfigT>(value); }
179 template<typename HttpConfigT = HttpDataSourceConfig>
180 DataSource& WithHttpConfig(HttpConfigT&& value) { SetHttpConfig(std::forward<HttpConfigT>(value)); return *this;}
182
184
187 inline const RelationalDatabaseDataSourceConfig& GetRelationalDatabaseConfig() const { return m_relationalDatabaseConfig; }
188 inline bool RelationalDatabaseConfigHasBeenSet() const { return m_relationalDatabaseConfigHasBeenSet; }
189 template<typename RelationalDatabaseConfigT = RelationalDatabaseDataSourceConfig>
190 void SetRelationalDatabaseConfig(RelationalDatabaseConfigT&& value) { m_relationalDatabaseConfigHasBeenSet = true; m_relationalDatabaseConfig = std::forward<RelationalDatabaseConfigT>(value); }
191 template<typename RelationalDatabaseConfigT = RelationalDatabaseDataSourceConfig>
192 DataSource& WithRelationalDatabaseConfig(RelationalDatabaseConfigT&& value) { SetRelationalDatabaseConfig(std::forward<RelationalDatabaseConfigT>(value)); return *this;}
194
196
199 inline const EventBridgeDataSourceConfig& GetEventBridgeConfig() const { return m_eventBridgeConfig; }
200 inline bool EventBridgeConfigHasBeenSet() const { return m_eventBridgeConfigHasBeenSet; }
201 template<typename EventBridgeConfigT = EventBridgeDataSourceConfig>
202 void SetEventBridgeConfig(EventBridgeConfigT&& value) { m_eventBridgeConfigHasBeenSet = true; m_eventBridgeConfig = std::forward<EventBridgeConfigT>(value); }
203 template<typename EventBridgeConfigT = EventBridgeDataSourceConfig>
204 DataSource& WithEventBridgeConfig(EventBridgeConfigT&& value) { SetEventBridgeConfig(std::forward<EventBridgeConfigT>(value)); return *this;}
206
208
219 inline DataSourceLevelMetricsConfig GetMetricsConfig() const { return m_metricsConfig; }
220 inline bool MetricsConfigHasBeenSet() const { return m_metricsConfigHasBeenSet; }
221 inline void SetMetricsConfig(DataSourceLevelMetricsConfig value) { m_metricsConfigHasBeenSet = true; m_metricsConfig = value; }
224 private:
225
226 Aws::String m_dataSourceArn;
227 bool m_dataSourceArnHasBeenSet = false;
228
229 Aws::String m_name;
230 bool m_nameHasBeenSet = false;
231
232 Aws::String m_description;
233 bool m_descriptionHasBeenSet = false;
234
236 bool m_typeHasBeenSet = false;
237
238 Aws::String m_serviceRoleArn;
239 bool m_serviceRoleArnHasBeenSet = false;
240
241 DynamodbDataSourceConfig m_dynamodbConfig;
242 bool m_dynamodbConfigHasBeenSet = false;
243
244 LambdaDataSourceConfig m_lambdaConfig;
245 bool m_lambdaConfigHasBeenSet = false;
246
247 ElasticsearchDataSourceConfig m_elasticsearchConfig;
248 bool m_elasticsearchConfigHasBeenSet = false;
249
250 OpenSearchServiceDataSourceConfig m_openSearchServiceConfig;
251 bool m_openSearchServiceConfigHasBeenSet = false;
252
253 HttpDataSourceConfig m_httpConfig;
254 bool m_httpConfigHasBeenSet = false;
255
256 RelationalDatabaseDataSourceConfig m_relationalDatabaseConfig;
257 bool m_relationalDatabaseConfigHasBeenSet = false;
258
259 EventBridgeDataSourceConfig m_eventBridgeConfig;
260 bool m_eventBridgeConfigHasBeenSet = false;
261
263 bool m_metricsConfigHasBeenSet = false;
264 };
265
266} // namespace Model
267} // namespace AppSync
268} // namespace Aws
DataSource & WithType(DataSourceType value)
Definition DataSource.h:106
DataSource & WithOpenSearchServiceConfig(OpenSearchServiceConfigT &&value)
Definition DataSource.h:168
void SetRelationalDatabaseConfig(RelationalDatabaseConfigT &&value)
Definition DataSource.h:190
const LambdaDataSourceConfig & GetLambdaConfig() const
Definition DataSource.h:139
void SetDataSourceArn(DataSourceArnT &&value)
Definition DataSource.h:56
const ElasticsearchDataSourceConfig & GetElasticsearchConfig() const
Definition DataSource.h:151
void SetDescription(DescriptionT &&value)
Definition DataSource.h:80
void SetHttpConfig(HttpConfigT &&value)
Definition DataSource.h:178
bool RelationalDatabaseConfigHasBeenSet() const
Definition DataSource.h:188
DataSource & WithLambdaConfig(LambdaConfigT &&value)
Definition DataSource.h:144
const DynamodbDataSourceConfig & GetDynamodbConfig() const
Definition DataSource.h:127
const Aws::String & GetDescription() const
Definition DataSource.h:77
DataSource & WithDataSourceArn(DataSourceArnT &&value)
Definition DataSource.h:58
AWS_APPSYNC_API DataSource()=default
void SetDynamodbConfig(DynamodbConfigT &&value)
Definition DataSource.h:130
bool ElasticsearchConfigHasBeenSet() const
Definition DataSource.h:152
void SetLambdaConfig(LambdaConfigT &&value)
Definition DataSource.h:142
DataSource & WithRelationalDatabaseConfig(RelationalDatabaseConfigT &&value)
Definition DataSource.h:192
AWS_APPSYNC_API DataSource & operator=(Aws::Utils::Json::JsonView jsonValue)
bool EventBridgeConfigHasBeenSet() const
Definition DataSource.h:200
void SetServiceRoleArn(ServiceRoleArnT &&value)
Definition DataSource.h:118
AWS_APPSYNC_API DataSource(Aws::Utils::Json::JsonView jsonValue)
const Aws::String & GetDataSourceArn() const
Definition DataSource.h:53
DataSource & WithServiceRoleArn(ServiceRoleArnT &&value)
Definition DataSource.h:120
void SetOpenSearchServiceConfig(OpenSearchServiceConfigT &&value)
Definition DataSource.h:166
void SetMetricsConfig(DataSourceLevelMetricsConfig value)
Definition DataSource.h:221
DataSourceLevelMetricsConfig GetMetricsConfig() const
Definition DataSource.h:219
const OpenSearchServiceDataSourceConfig & GetOpenSearchServiceConfig() const
Definition DataSource.h:163
DataSource & WithDescription(DescriptionT &&value)
Definition DataSource.h:82
void SetElasticsearchConfig(ElasticsearchConfigT &&value)
Definition DataSource.h:154
void SetEventBridgeConfig(EventBridgeConfigT &&value)
Definition DataSource.h:202
DataSourceType GetType() const
Definition DataSource.h:103
AWS_APPSYNC_API Aws::Utils::Json::JsonValue Jsonize() const
const Aws::String & GetServiceRoleArn() const
Definition DataSource.h:115
bool OpenSearchServiceConfigHasBeenSet() const
Definition DataSource.h:164
DataSource & WithMetricsConfig(DataSourceLevelMetricsConfig value)
Definition DataSource.h:222
void SetType(DataSourceType value)
Definition DataSource.h:105
DataSource & WithName(NameT &&value)
Definition DataSource.h:70
const EventBridgeDataSourceConfig & GetEventBridgeConfig() const
Definition DataSource.h:199
const RelationalDatabaseDataSourceConfig & GetRelationalDatabaseConfig() const
Definition DataSource.h:187
DataSource & WithElasticsearchConfig(ElasticsearchConfigT &&value)
Definition DataSource.h:156
const Aws::String & GetName() const
Definition DataSource.h:65
DataSource & WithEventBridgeConfig(EventBridgeConfigT &&value)
Definition DataSource.h:204
DataSource & WithHttpConfig(HttpConfigT &&value)
Definition DataSource.h:180
DataSource & WithDynamodbConfig(DynamodbConfigT &&value)
Definition DataSource.h:132
const HttpDataSourceConfig & GetHttpConfig() const
Definition DataSource.h:175
void SetName(NameT &&value)
Definition DataSource.h:68
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Aws::Utils::Json::JsonValue JsonValue