GPUdb C++ API  Version 7.2.3.0
create_table_monitor.h
Go to the documentation of this file.
1 /*
2  * This file was autogenerated by the Kinetica schema processor.
3  *
4  * DO NOT EDIT DIRECTLY.
5  */
6 #ifndef __CREATE_TABLE_MONITOR_H__
7 #define __CREATE_TABLE_MONITOR_H__
8 
9 namespace gpudb
10 {
37  {
43  tableName(std::string()),
44  options(std::map<std::string, std::string>())
45  {
46  }
47 
210  CreateTableMonitorRequest(const std::string& tableName_, const std::map<std::string, std::string>& options_):
211  tableName( tableName_ ),
212  options( options_ )
213  {
214  }
215 
222  std::string tableName;
223 
326  std::map<std::string, std::string> options;
327  };
328 } // end namespace gpudb
329 
330 namespace avro
331 {
332  template<> struct codec_traits<gpudb::CreateTableMonitorRequest>
333  {
334  static void encode(Encoder& e, const gpudb::CreateTableMonitorRequest& v)
335  {
336  ::avro::encode(e, v.tableName);
337  ::avro::encode(e, v.options);
338  }
339 
340  static void decode(Decoder& d, gpudb::CreateTableMonitorRequest& v)
341  {
342  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
343  {
344  const std::vector<size_t> fo = rd->fieldOrder();
345 
346  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
347  {
348  switch (*it)
349  {
350  case 0:
351  ::avro::decode(d, v.tableName);
352  break;
353 
354  case 1:
355  ::avro::decode(d, v.options);
356  break;
357 
358  default:
359  break;
360  }
361  }
362  }
363  else
364  {
365  ::avro::decode(d, v.tableName);
366  ::avro::decode(d, v.options);
367  }
368  }
369  };
370 } // end namespace avro
371 
372 namespace gpudb
373 {
380  {
386  topicId(std::string()),
387  tableName(std::string()),
388  typeSchema(std::string()),
389  info(std::map<std::string, std::string>())
390  {
391  }
392 
396  std::string topicId;
397 
402  std::string tableName;
403 
408  std::string typeSchema;
409 
440  std::map<std::string, std::string> info;
441  };
442 } // end namespace gpudb
443 
444 namespace avro
445 {
446  template<> struct codec_traits<gpudb::CreateTableMonitorResponse>
447  {
448  static void encode(Encoder& e, const gpudb::CreateTableMonitorResponse& v)
449  {
450  ::avro::encode(e, v.topicId);
451  ::avro::encode(e, v.tableName);
452  ::avro::encode(e, v.typeSchema);
453  ::avro::encode(e, v.info);
454  }
455 
456  static void decode(Decoder& d, gpudb::CreateTableMonitorResponse& v)
457  {
458  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
459  {
460  const std::vector<size_t> fo = rd->fieldOrder();
461 
462  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
463  {
464  switch (*it)
465  {
466  case 0:
467  ::avro::decode(d, v.topicId);
468  break;
469 
470  case 1:
471  ::avro::decode(d, v.tableName);
472  break;
473 
474  case 2:
475  ::avro::decode(d, v.typeSchema);
476  break;
477 
478  case 3:
479  ::avro::decode(d, v.info);
480  break;
481 
482  default:
483  break;
484  }
485  }
486  }
487  else
488  {
489  ::avro::decode(d, v.topicId);
490  ::avro::decode(d, v.tableName);
491  ::avro::decode(d, v.typeSchema);
492  ::avro::decode(d, v.info);
493  }
494  }
495  };
496 } // end namespace avro
497 
498 #endif // __CREATE_TABLE_MONITOR_H__
std::map< std::string, std::string > options
Optional parameters.
A set of results returned by GPUdb::createTableMonitor.
std::string tableName
Value of tableName.
std::string topicId
The ZMQ topic ID to subscribe to for table events.
std::string tableName
Name of the table to monitor, in [ schema_name. ]table_name format, using standard name resolution ru...
CreateTableMonitorResponse()
Constructs a CreateTableMonitorResponse object with default parameters.
A set of parameters for GPUdb::createTableMonitor.
CreateTableMonitorRequest()
Constructs a CreateTableMonitorRequest object with default parameters.
CreateTableMonitorRequest(const std::string &tableName_, const std::map< std::string, std::string > &options_)
Constructs a CreateTableMonitorRequest object with the specified parameters.
std::map< std::string, std::string > info
Additional information.
std::string typeSchema
JSON Avro schema of the table, for use in decoding published records.