GPUdb C++ API  Version 7.2.3.0
create_datasink.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_DATASINK_H__
7 #define __CREATE_DATASINK_H__
8 
9 namespace gpudb
10 {
21  {
26  name(std::string()),
27  destination(std::string()),
28  options(std::map<std::string, std::string>())
29  {
30  }
31 
330  CreateDatasinkRequest(const std::string& name_, const std::string& destination_, const std::map<std::string, std::string>& options_):
331  name( name_ ),
332  destination( destination_ ),
333  options( options_ )
334  {
335  }
336 
340  std::string name;
341 
349  std::string destination;
350 
545  std::map<std::string, std::string> options;
546  };
547 } // end namespace gpudb
548 
549 namespace avro
550 {
551  template<> struct codec_traits<gpudb::CreateDatasinkRequest>
552  {
553  static void encode(Encoder& e, const gpudb::CreateDatasinkRequest& v)
554  {
555  ::avro::encode(e, v.name);
556  ::avro::encode(e, v.destination);
557  ::avro::encode(e, v.options);
558  }
559 
560  static void decode(Decoder& d, gpudb::CreateDatasinkRequest& v)
561  {
562  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
563  {
564  const std::vector<size_t> fo = rd->fieldOrder();
565 
566  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
567  {
568  switch (*it)
569  {
570  case 0:
571  ::avro::decode(d, v.name);
572  break;
573 
574  case 1:
575  ::avro::decode(d, v.destination);
576  break;
577 
578  case 2:
579  ::avro::decode(d, v.options);
580  break;
581 
582  default:
583  break;
584  }
585  }
586  }
587  else
588  {
589  ::avro::decode(d, v.name);
590  ::avro::decode(d, v.destination);
591  ::avro::decode(d, v.options);
592  }
593  }
594  };
595 } // end namespace avro
596 
597 namespace gpudb
598 {
605  {
610  name(std::string()),
611  info(std::map<std::string, std::string>())
612  {
613  }
614 
618  std::string name;
619 
623  std::map<std::string, std::string> info;
624  };
625 } // end namespace gpudb
626 
627 namespace avro
628 {
629  template<> struct codec_traits<gpudb::CreateDatasinkResponse>
630  {
631  static void encode(Encoder& e, const gpudb::CreateDatasinkResponse& v)
632  {
633  ::avro::encode(e, v.name);
634  ::avro::encode(e, v.info);
635  }
636 
637  static void decode(Decoder& d, gpudb::CreateDatasinkResponse& v)
638  {
639  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
640  {
641  const std::vector<size_t> fo = rd->fieldOrder();
642 
643  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
644  {
645  switch (*it)
646  {
647  case 0:
648  ::avro::decode(d, v.name);
649  break;
650 
651  case 1:
652  ::avro::decode(d, v.info);
653  break;
654 
655  default:
656  break;
657  }
658  }
659  }
660  else
661  {
662  ::avro::decode(d, v.name);
663  ::avro::decode(d, v.info);
664  }
665  }
666  };
667 } // end namespace avro
668 
669 #endif // __CREATE_DATASINK_H__
CreateDatasinkRequest(const std::string &name_, const std::string &destination_, const std::map< std::string, std::string > &options_)
Constructs a CreateDatasinkRequest object with the specified parameters.
std::string name
Name of the data sink to be created.
A set of parameters for GPUdb::createDatasink.
A set of results returned by GPUdb::createDatasink.
std::string name
Value of name.
std::string destination
Destination for the output data in format 'storage_provider_type://path[:port]'.
CreateDatasinkRequest()
Constructs a CreateDatasinkRequest object with default parameters.
std::map< std::string, std::string > info
Additional information.
CreateDatasinkResponse()
Constructs a CreateDatasinkResponse object with default parameters.
std::map< std::string, std::string > options
Optional parameters.