GPUdb C++ API  Version 7.2.2.4
create_user_external.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_USER_EXTERNAL_H__
7 #define __CREATE_USER_EXTERNAL_H__
8 
9 namespace gpudb
10 {
20  {
26  name(std::string()),
27  options(std::map<std::string, std::string>())
28  {
29  }
30 
102  CreateUserExternalRequest(const std::string& name_, const std::map<std::string, std::string>& options_):
103  name( name_ ),
104  options( options_ )
105  {
106  }
107 
113  std::string name;
114 
160  std::map<std::string, std::string> options;
161  };
162 } // end namespace gpudb
163 
164 namespace avro
165 {
166  template<> struct codec_traits<gpudb::CreateUserExternalRequest>
167  {
168  static void encode(Encoder& e, const gpudb::CreateUserExternalRequest& v)
169  {
170  ::avro::encode(e, v.name);
171  ::avro::encode(e, v.options);
172  }
173 
174  static void decode(Decoder& d, gpudb::CreateUserExternalRequest& v)
175  {
176  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
177  {
178  const std::vector<size_t> fo = rd->fieldOrder();
179 
180  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
181  {
182  switch (*it)
183  {
184  case 0:
185  ::avro::decode(d, v.name);
186  break;
187 
188  case 1:
189  ::avro::decode(d, v.options);
190  break;
191 
192  default:
193  break;
194  }
195  }
196  }
197  else
198  {
199  ::avro::decode(d, v.name);
200  ::avro::decode(d, v.options);
201  }
202  }
203  };
204 } // end namespace avro
205 
206 namespace gpudb
207 {
214  {
220  name(std::string()),
221  info(std::map<std::string, std::string>())
222  {
223  }
224 
228  std::string name;
229 
233  std::map<std::string, std::string> info;
234  };
235 } // end namespace gpudb
236 
237 namespace avro
238 {
239  template<> struct codec_traits<gpudb::CreateUserExternalResponse>
240  {
241  static void encode(Encoder& e, const gpudb::CreateUserExternalResponse& v)
242  {
243  ::avro::encode(e, v.name);
244  ::avro::encode(e, v.info);
245  }
246 
247  static void decode(Decoder& d, gpudb::CreateUserExternalResponse& v)
248  {
249  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
250  {
251  const std::vector<size_t> fo = rd->fieldOrder();
252 
253  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
254  {
255  switch (*it)
256  {
257  case 0:
258  ::avro::decode(d, v.name);
259  break;
260 
261  case 1:
262  ::avro::decode(d, v.info);
263  break;
264 
265  default:
266  break;
267  }
268  }
269  }
270  else
271  {
272  ::avro::decode(d, v.name);
273  ::avro::decode(d, v.info);
274  }
275  }
276  };
277 } // end namespace avro
278 
279 #endif // __CREATE_USER_EXTERNAL_H__
A set of results returned by GPUdb::createUserExternal.
std::map< std::string, std::string > options
Optional parameters.
CreateUserExternalRequest()
Constructs a CreateUserExternalRequest object with default parameters.
CreateUserExternalResponse()
Constructs a CreateUserExternalResponse object with default parameters.
A set of parameters for GPUdb::createUserExternal.
CreateUserExternalRequest(const std::string &name_, const std::map< std::string, std::string > &options_)
Constructs a CreateUserExternalRequest object with the specified parameters.
std::string name
Name of the user to be created.
std::map< std::string, std::string > info
Additional information.