GPUdb C++ API  Version 7.1.10.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
revoke_permission.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 __REVOKE_PERMISSION_H__
7 #define __REVOKE_PERMISSION_H__
8 
9 namespace gpudb
10 {
11 
19  {
20 
26  principal(std::string()),
27  object(std::string()),
28  objectType(std::string()),
29  permission(std::string()),
30  options(std::map<std::string, std::string>())
31  {
32  }
33 
115  RevokePermissionRequest(const std::string& principal_, const std::string& object_, const std::string& objectType_, const std::string& permission_, const std::map<std::string, std::string>& options_):
116  principal( principal_ ),
117  object( object_ ),
118  objectType( objectType_ ),
119  permission( permission_ ),
120  options( options_ )
121  {
122  }
123 
124  std::string principal;
125  std::string object;
126  std::string objectType;
127  std::string permission;
128  std::map<std::string, std::string> options;
129  };
130 }
131 
132 namespace avro
133 {
134  template<> struct codec_traits<gpudb::RevokePermissionRequest>
135  {
136  static void encode(Encoder& e, const gpudb::RevokePermissionRequest& v)
137  {
138  ::avro::encode(e, v.principal);
139  ::avro::encode(e, v.object);
140  ::avro::encode(e, v.objectType);
141  ::avro::encode(e, v.permission);
142  ::avro::encode(e, v.options);
143  }
144 
145  static void decode(Decoder& d, gpudb::RevokePermissionRequest& v)
146  {
147  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
148  {
149  const std::vector<size_t> fo = rd->fieldOrder();
150 
151  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
152  {
153  switch (*it)
154  {
155  case 0:
156  ::avro::decode(d, v.principal);
157  break;
158 
159  case 1:
160  ::avro::decode(d, v.object);
161  break;
162 
163  case 2:
164  ::avro::decode(d, v.objectType);
165  break;
166 
167  case 3:
168  ::avro::decode(d, v.permission);
169  break;
170 
171  case 4:
172  ::avro::decode(d, v.options);
173  break;
174 
175  default:
176  break;
177  }
178  }
179  }
180  else
181  {
182  ::avro::decode(d, v.principal);
183  ::avro::decode(d, v.object);
184  ::avro::decode(d, v.objectType);
185  ::avro::decode(d, v.permission);
186  ::avro::decode(d, v.options);
187  }
188  }
189  };
190 }
191 
192 namespace gpudb
193 {
194 
202  {
203 
209  principal(std::string()),
210  object(std::string()),
211  objectType(std::string()),
212  permission(std::string()),
213  info(std::map<std::string, std::string>())
214  {
215  }
216 
217  std::string principal;
218  std::string object;
219  std::string objectType;
220  std::string permission;
221  std::map<std::string, std::string> info;
222  };
223 }
224 
225 namespace avro
226 {
227  template<> struct codec_traits<gpudb::RevokePermissionResponse>
228  {
229  static void encode(Encoder& e, const gpudb::RevokePermissionResponse& v)
230  {
231  ::avro::encode(e, v.principal);
232  ::avro::encode(e, v.object);
233  ::avro::encode(e, v.objectType);
234  ::avro::encode(e, v.permission);
235  ::avro::encode(e, v.info);
236  }
237 
238  static void decode(Decoder& d, gpudb::RevokePermissionResponse& v)
239  {
240  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
241  {
242  const std::vector<size_t> fo = rd->fieldOrder();
243 
244  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
245  {
246  switch (*it)
247  {
248  case 0:
249  ::avro::decode(d, v.principal);
250  break;
251 
252  case 1:
253  ::avro::decode(d, v.object);
254  break;
255 
256  case 2:
257  ::avro::decode(d, v.objectType);
258  break;
259 
260  case 3:
261  ::avro::decode(d, v.permission);
262  break;
263 
264  case 4:
265  ::avro::decode(d, v.info);
266  break;
267 
268  default:
269  break;
270  }
271  }
272  }
273  else
274  {
275  ::avro::decode(d, v.principal);
276  ::avro::decode(d, v.object);
277  ::avro::decode(d, v.objectType);
278  ::avro::decode(d, v.permission);
279  ::avro::decode(d, v.info);
280  }
281  }
282  };
283 }
284 
285 #endif
std::map< std::string, std::string > info
RevokePermissionRequest(const std::string &principal_, const std::string &object_, const std::string &objectType_, const std::string &permission_, const std::map< std::string, std::string > &options_)
Constructs a RevokePermissionRequest object with the specified parameters.
RevokePermissionRequest()
Constructs a RevokePermissionRequest object with default parameter values.
A set of output parameters for const.
std::map< std::string, std::string > options
RevokePermissionResponse()
Constructs a RevokePermissionResponse object with default parameter values.
A set of input parameters for const.