GPUdb C++ API  Version 7.2.2.4
drop_datasource.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 __DROP_DATASOURCE_H__
7 #define __DROP_DATASOURCE_H__
8 
9 namespace gpudb
10 {
21  {
26  name(std::string()),
27  options(std::map<std::string, std::string>())
28  {
29  }
30 
40  DropDatasourceRequest(const std::string& name_, const std::map<std::string, std::string>& options_):
41  name( name_ ),
42  options( options_ )
43  {
44  }
45 
50  std::string name;
51 
55  std::map<std::string, std::string> options;
56  };
57 } // end namespace gpudb
58 
59 namespace avro
60 {
61  template<> struct codec_traits<gpudb::DropDatasourceRequest>
62  {
63  static void encode(Encoder& e, const gpudb::DropDatasourceRequest& v)
64  {
65  ::avro::encode(e, v.name);
66  ::avro::encode(e, v.options);
67  }
68 
69  static void decode(Decoder& d, gpudb::DropDatasourceRequest& v)
70  {
71  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
72  {
73  const std::vector<size_t> fo = rd->fieldOrder();
74 
75  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
76  {
77  switch (*it)
78  {
79  case 0:
80  ::avro::decode(d, v.name);
81  break;
82 
83  case 1:
84  ::avro::decode(d, v.options);
85  break;
86 
87  default:
88  break;
89  }
90  }
91  }
92  else
93  {
94  ::avro::decode(d, v.name);
95  ::avro::decode(d, v.options);
96  }
97  }
98  };
99 } // end namespace avro
100 
101 namespace gpudb
102 {
109  {
114  name(std::string()),
115  info(std::map<std::string, std::string>())
116  {
117  }
118 
122  std::string name;
123 
127  std::map<std::string, std::string> info;
128  };
129 } // end namespace gpudb
130 
131 namespace avro
132 {
133  template<> struct codec_traits<gpudb::DropDatasourceResponse>
134  {
135  static void encode(Encoder& e, const gpudb::DropDatasourceResponse& v)
136  {
137  ::avro::encode(e, v.name);
138  ::avro::encode(e, v.info);
139  }
140 
141  static void decode(Decoder& d, gpudb::DropDatasourceResponse& v)
142  {
143  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
144  {
145  const std::vector<size_t> fo = rd->fieldOrder();
146 
147  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
148  {
149  switch (*it)
150  {
151  case 0:
152  ::avro::decode(d, v.name);
153  break;
154 
155  case 1:
156  ::avro::decode(d, v.info);
157  break;
158 
159  default:
160  break;
161  }
162  }
163  }
164  else
165  {
166  ::avro::decode(d, v.name);
167  ::avro::decode(d, v.info);
168  }
169  }
170  };
171 } // end namespace avro
172 
173 #endif // __DROP_DATASOURCE_H__
std::map< std::string, std::string > options
Optional parameters.
DropDatasourceRequest()
Constructs a DropDatasourceRequest object with default parameters.
DropDatasourceResponse()
Constructs a DropDatasourceResponse object with default parameters.
A set of results returned by GPUdb::dropDatasource.
A set of parameters for GPUdb::dropDatasource.
std::map< std::string, std::string > info
Additional information.
std::string name
Name of the data source to be dropped.
DropDatasourceRequest(const std::string &name_, const std::map< std::string, std::string > &options_)
Constructs a DropDatasourceRequest object with the specified parameters.
std::string name
Value of name.