GPUdb C++ API  Version 7.1.10.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
create_materialized_view.h
Go to the documentation of this file.
1 /*
2  * This file was autogenerated by the GPUdb schema processor.
3  *
4  * DO NOT EDIT DIRECTLY.
5  */
6 #ifndef __CREATE_MATERIALIZED_VIEW_H__
7 #define __CREATE_MATERIALIZED_VIEW_H__
8 
9 namespace gpudb
10 {
11 
30  {
31 
37  tableName(std::string()),
38  options(std::map<std::string, std::string>())
39  {
40  }
41 
141  CreateMaterializedViewRequest(const std::string& tableName_, const std::map<std::string, std::string>& options_):
142  tableName( tableName_ ),
143  options( options_ )
144  {
145  }
146 
147  std::string tableName;
148  std::map<std::string, std::string> options;
149  };
150 }
151 
152 namespace avro
153 {
154  template<> struct codec_traits<gpudb::CreateMaterializedViewRequest>
155  {
156  static void encode(Encoder& e, const gpudb::CreateMaterializedViewRequest& v)
157  {
158  ::avro::encode(e, v.tableName);
159  ::avro::encode(e, v.options);
160  }
161 
162  static void decode(Decoder& d, gpudb::CreateMaterializedViewRequest& v)
163  {
164  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
165  {
166  const std::vector<size_t> fo = rd->fieldOrder();
167 
168  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
169  {
170  switch (*it)
171  {
172  case 0:
173  ::avro::decode(d, v.tableName);
174  break;
175 
176  case 1:
177  ::avro::decode(d, v.options);
178  break;
179 
180  default:
181  break;
182  }
183  }
184  }
185  else
186  {
187  ::avro::decode(d, v.tableName);
188  ::avro::decode(d, v.options);
189  }
190  }
191  };
192 }
193 
194 namespace gpudb
195 {
196 
215  {
216 
222  tableName(std::string()),
223  viewId(std::string()),
224  info(std::map<std::string, std::string>())
225  {
226  }
227 
228  std::string tableName;
229  std::string viewId;
230  std::map<std::string, std::string> info;
231  };
232 }
233 
234 namespace avro
235 {
236  template<> struct codec_traits<gpudb::CreateMaterializedViewResponse>
237  {
238  static void encode(Encoder& e, const gpudb::CreateMaterializedViewResponse& v)
239  {
240  ::avro::encode(e, v.tableName);
241  ::avro::encode(e, v.viewId);
242  ::avro::encode(e, v.info);
243  }
244 
245  static void decode(Decoder& d, gpudb::CreateMaterializedViewResponse& v)
246  {
247  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
248  {
249  const std::vector<size_t> fo = rd->fieldOrder();
250 
251  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
252  {
253  switch (*it)
254  {
255  case 0:
256  ::avro::decode(d, v.tableName);
257  break;
258 
259  case 1:
260  ::avro::decode(d, v.viewId);
261  break;
262 
263  case 2:
264  ::avro::decode(d, v.info);
265  break;
266 
267  default:
268  break;
269  }
270  }
271  }
272  else
273  {
274  ::avro::decode(d, v.tableName);
275  ::avro::decode(d, v.viewId);
276  ::avro::decode(d, v.info);
277  }
278  }
279  };
280 }
281 
282 #endif
CreateMaterializedViewRequest()
Constructs a CreateMaterializedViewRequest object with default parameter values.
A set of output parameters for const.
A set of input parameters for const.
CreateMaterializedViewResponse()
Constructs a CreateMaterializedViewResponse object with default parameter values. ...
CreateMaterializedViewRequest(const std::string &tableName_, const std::map< std::string, std::string > &options_)
Constructs a CreateMaterializedViewRequest object with the specified parameters.
std::map< std::string, std::string > options
std::map< std::string, std::string > info