GPUdb C++ API  Version 7.2.2.4
admin_add_host.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 __ADMIN_ADD_HOST_H__
7 #define __ADMIN_ADD_HOST_H__
8 
9 namespace gpudb
10 {
19  {
24  hostAddress(std::string()),
25  options(std::map<std::string, std::string>())
26  {
27  }
28 
121  AdminAddHostRequest(const std::string& hostAddress_, const std::map<std::string, std::string>& options_):
122  hostAddress( hostAddress_ ),
123  options( options_ )
124  {
125  }
126 
132  std::string hostAddress;
133 
194  std::map<std::string, std::string> options;
195  };
196 } // end namespace gpudb
197 
198 namespace avro
199 {
200  template<> struct codec_traits<gpudb::AdminAddHostRequest>
201  {
202  static void encode(Encoder& e, const gpudb::AdminAddHostRequest& v)
203  {
204  ::avro::encode(e, v.hostAddress);
205  ::avro::encode(e, v.options);
206  }
207 
208  static void decode(Decoder& d, gpudb::AdminAddHostRequest& v)
209  {
210  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
211  {
212  const std::vector<size_t> fo = rd->fieldOrder();
213 
214  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
215  {
216  switch (*it)
217  {
218  case 0:
219  ::avro::decode(d, v.hostAddress);
220  break;
221 
222  case 1:
223  ::avro::decode(d, v.options);
224  break;
225 
226  default:
227  break;
228  }
229  }
230  }
231  else
232  {
233  ::avro::decode(d, v.hostAddress);
234  ::avro::decode(d, v.options);
235  }
236  }
237  };
238 } // end namespace avro
239 
240 namespace gpudb
241 {
248  {
253  addedHost(std::string()),
254  info(std::map<std::string, std::string>())
255  {
256  }
257 
264  std::string addedHost;
265 
269  std::map<std::string, std::string> info;
270  };
271 } // end namespace gpudb
272 
273 namespace avro
274 {
275  template<> struct codec_traits<gpudb::AdminAddHostResponse>
276  {
277  static void encode(Encoder& e, const gpudb::AdminAddHostResponse& v)
278  {
279  ::avro::encode(e, v.addedHost);
280  ::avro::encode(e, v.info);
281  }
282 
283  static void decode(Decoder& d, gpudb::AdminAddHostResponse& v)
284  {
285  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
286  {
287  const std::vector<size_t> fo = rd->fieldOrder();
288 
289  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
290  {
291  switch (*it)
292  {
293  case 0:
294  ::avro::decode(d, v.addedHost);
295  break;
296 
297  case 1:
298  ::avro::decode(d, v.info);
299  break;
300 
301  default:
302  break;
303  }
304  }
305  }
306  else
307  {
308  ::avro::decode(d, v.addedHost);
309  ::avro::decode(d, v.info);
310  }
311  }
312  };
313 } // end namespace avro
314 
315 #endif // __ADMIN_ADD_HOST_H__
std::map< std::string, std::string > info
Additional information.
std::map< std::string, std::string > options
Optional parameters.
AdminAddHostRequest()
Constructs an AdminAddHostRequest object with default parameters.
AdminAddHostResponse()
Constructs an AdminAddHostResponse object with default parameters.
A set of parameters for GPUdb::adminAddHost.
std::string addedHost
Identifier for the newly added host, of the format 'hostN' where N is the integer identifier of that ...
AdminAddHostRequest(const std::string &hostAddress_, const std::map< std::string, std::string > &options_)
Constructs an AdminAddHostRequest object with the specified parameters.
A set of results returned by GPUdb::adminAddHost.
std::string hostAddress
IP address of the host that will be added to the cluster.