GPUdb C++ API  Version 7.1.10.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
create_user_external.h
Go to the documentation of this file.
1 /*
2  * This file was autogenerated by the GPUdb 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 {
11 
20  {
21 
27  name(std::string()),
28  options(std::map<std::string, std::string>())
29  {
30  }
31 
68  CreateUserExternalRequest(const std::string& name_, const std::map<std::string, std::string>& options_):
69  name( name_ ),
70  options( options_ )
71  {
72  }
73 
74  std::string name;
75  std::map<std::string, std::string> options;
76  };
77 }
78 
79 namespace avro
80 {
81  template<> struct codec_traits<gpudb::CreateUserExternalRequest>
82  {
83  static void encode(Encoder& e, const gpudb::CreateUserExternalRequest& v)
84  {
85  ::avro::encode(e, v.name);
86  ::avro::encode(e, v.options);
87  }
88 
89  static void decode(Decoder& d, gpudb::CreateUserExternalRequest& v)
90  {
91  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
92  {
93  const std::vector<size_t> fo = rd->fieldOrder();
94 
95  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
96  {
97  switch (*it)
98  {
99  case 0:
100  ::avro::decode(d, v.name);
101  break;
102 
103  case 1:
104  ::avro::decode(d, v.options);
105  break;
106 
107  default:
108  break;
109  }
110  }
111  }
112  else
113  {
114  ::avro::decode(d, v.name);
115  ::avro::decode(d, v.options);
116  }
117  }
118  };
119 }
120 
121 namespace gpudb
122 {
123 
132  {
133 
139  name(std::string()),
140  info(std::map<std::string, std::string>())
141  {
142  }
143 
144  std::string name;
145  std::map<std::string, std::string> info;
146  };
147 }
148 
149 namespace avro
150 {
151  template<> struct codec_traits<gpudb::CreateUserExternalResponse>
152  {
153  static void encode(Encoder& e, const gpudb::CreateUserExternalResponse& v)
154  {
155  ::avro::encode(e, v.name);
156  ::avro::encode(e, v.info);
157  }
158 
159  static void decode(Decoder& d, gpudb::CreateUserExternalResponse& v)
160  {
161  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
162  {
163  const std::vector<size_t> fo = rd->fieldOrder();
164 
165  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
166  {
167  switch (*it)
168  {
169  case 0:
170  ::avro::decode(d, v.name);
171  break;
172 
173  case 1:
174  ::avro::decode(d, v.info);
175  break;
176 
177  default:
178  break;
179  }
180  }
181  }
182  else
183  {
184  ::avro::decode(d, v.name);
185  ::avro::decode(d, v.info);
186  }
187  }
188  };
189 }
190 
191 #endif
A set of output parameters for const.
std::map< std::string, std::string > options
CreateUserExternalRequest()
Constructs a CreateUserExternalRequest object with default parameter values.
CreateUserExternalResponse()
Constructs a CreateUserExternalResponse object with default parameter values.
A set of input parameters for const.
CreateUserExternalRequest(const std::string &name_, const std::map< std::string, std::string > &options_)
Constructs a CreateUserExternalRequest object with the specified parameters.
std::map< std::string, std::string > info