GPUdb C++ API  Version 7.2.2.4
create_table.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_H__
7 #define __CREATE_TABLE_H__
8 
9 namespace gpudb
10 {
32  {
37  tableName(std::string()),
38  typeId(std::string()),
39  options(std::map<std::string, std::string>())
40  {
41  }
42 
403  CreateTableRequest(const std::string& tableName_, const std::string& typeId_, const std::map<std::string, std::string>& options_):
404  tableName( tableName_ ),
405  typeId( typeId_ ),
406  options( options_ )
407  {
408  }
409 
421  std::string tableName;
422 
427  std::string typeId;
428 
670  std::map<std::string, std::string> options;
671  };
672 } // end namespace gpudb
673 
674 namespace avro
675 {
676  template<> struct codec_traits<gpudb::CreateTableRequest>
677  {
678  static void encode(Encoder& e, const gpudb::CreateTableRequest& v)
679  {
680  ::avro::encode(e, v.tableName);
681  ::avro::encode(e, v.typeId);
682  ::avro::encode(e, v.options);
683  }
684 
685  static void decode(Decoder& d, gpudb::CreateTableRequest& v)
686  {
687  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
688  {
689  const std::vector<size_t> fo = rd->fieldOrder();
690 
691  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
692  {
693  switch (*it)
694  {
695  case 0:
696  ::avro::decode(d, v.tableName);
697  break;
698 
699  case 1:
700  ::avro::decode(d, v.typeId);
701  break;
702 
703  case 2:
704  ::avro::decode(d, v.options);
705  break;
706 
707  default:
708  break;
709  }
710  }
711  }
712  else
713  {
714  ::avro::decode(d, v.tableName);
715  ::avro::decode(d, v.typeId);
716  ::avro::decode(d, v.options);
717  }
718  }
719  };
720 } // end namespace avro
721 
722 namespace gpudb
723 {
730  {
735  tableName(std::string()),
736  typeId(std::string()),
737  isCollection(bool()),
738  info(std::map<std::string, std::string>())
739  {
740  }
741 
745  std::string tableName;
746 
750  std::string typeId;
751 
757 
767  std::map<std::string, std::string> info;
768  };
769 } // end namespace gpudb
770 
771 namespace avro
772 {
773  template<> struct codec_traits<gpudb::CreateTableResponse>
774  {
775  static void encode(Encoder& e, const gpudb::CreateTableResponse& v)
776  {
777  ::avro::encode(e, v.tableName);
778  ::avro::encode(e, v.typeId);
779  ::avro::encode(e, v.isCollection);
780  ::avro::encode(e, v.info);
781  }
782 
783  static void decode(Decoder& d, gpudb::CreateTableResponse& v)
784  {
785  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
786  {
787  const std::vector<size_t> fo = rd->fieldOrder();
788 
789  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
790  {
791  switch (*it)
792  {
793  case 0:
794  ::avro::decode(d, v.tableName);
795  break;
796 
797  case 1:
798  ::avro::decode(d, v.typeId);
799  break;
800 
801  case 2:
802  ::avro::decode(d, v.isCollection);
803  break;
804 
805  case 3:
806  ::avro::decode(d, v.info);
807  break;
808 
809  default:
810  break;
811  }
812  }
813  }
814  else
815  {
816  ::avro::decode(d, v.tableName);
817  ::avro::decode(d, v.typeId);
818  ::avro::decode(d, v.isCollection);
819  ::avro::decode(d, v.info);
820  }
821  }
822  };
823 } // end namespace avro
824 
825 #endif // __CREATE_TABLE_H__
std::string tableName
Name of the table to be created, in [ schema_name. ]table_name format, using standard name resolution...
Definition: create_table.h:421
std::string typeId
Value of typeId.
Definition: create_table.h:750
std::string tableName
Value of tableName.
Definition: create_table.h:745
std::map< std::string, std::string > info
Additional information.
Definition: create_table.h:767
std::string typeId
ID of a currently registered type.
Definition: create_table.h:427
CreateTableRequest()
Constructs a CreateTableRequest object with default parameters.
Definition: create_table.h:36
bool isCollection
[DEPRECATED–this will always return false] Indicates if the created entity is a schema.
Definition: create_table.h:756
A set of parameters for GPUdb::createTable.
Definition: create_table.h:31
CreateTableRequest(const std::string &tableName_, const std::string &typeId_, const std::map< std::string, std::string > &options_)
Constructs a CreateTableRequest object with the specified parameters.
Definition: create_table.h:403
CreateTableResponse()
Constructs a CreateTableResponse object with default parameters.
Definition: create_table.h:734
A set of results returned by GPUdb::createTable.
Definition: create_table.h:729
std::map< std::string, std::string > options
Optional parameters.
Definition: create_table.h:670