GPUdb C++ API  Version 6.2.0.3
delete_role.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 __DELETE_ROLE_H__
7 #define __DELETE_ROLE_H__
8 
9 namespace gpudb
10 {
11 
19  {
20 
25  name(std::string()),
26  options(std::map<std::string, std::string>())
27  {
28  }
29 
38  DeleteRoleRequest(const std::string& name_, const std::map<std::string, std::string>& options_):
39  name( name_ ),
40  options( options_ )
41  {
42  }
43 
44  std::string name;
45  std::map<std::string, std::string> options;
46  };
47 }
48 
49 namespace avro
50 {
51  template<> struct codec_traits<gpudb::DeleteRoleRequest>
52  {
53  static void encode(Encoder& e, const gpudb::DeleteRoleRequest& v)
54  {
55  ::avro::encode(e, v.name);
56  ::avro::encode(e, v.options);
57  }
58 
59  static void decode(Decoder& d, gpudb::DeleteRoleRequest& v)
60  {
61  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
62  {
63  const std::vector<size_t> fo = rd->fieldOrder();
64 
65  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
66  {
67  switch (*it)
68  {
69  case 0:
70  ::avro::decode(d, v.name);
71  break;
72 
73  case 1:
74  ::avro::decode(d, v.options);
75  break;
76 
77  default:
78  break;
79  }
80  }
81  }
82  else
83  {
84  ::avro::decode(d, v.name);
85  ::avro::decode(d, v.options);
86  }
87  }
88  };
89 }
90 
91 namespace gpudb
92 {
93 
101  {
102 
108  name(std::string())
109  {
110  }
111 
112  std::string name;
113  };
114 }
115 
116 namespace avro
117 {
118  template<> struct codec_traits<gpudb::DeleteRoleResponse>
119  {
120  static void encode(Encoder& e, const gpudb::DeleteRoleResponse& v)
121  {
122  ::avro::encode(e, v.name);
123  }
124 
125  static void decode(Decoder& d, gpudb::DeleteRoleResponse& v)
126  {
127  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
128  {
129  const std::vector<size_t> fo = rd->fieldOrder();
130 
131  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
132  {
133  switch (*it)
134  {
135  case 0:
136  ::avro::decode(d, v.name);
137  break;
138 
139  default:
140  break;
141  }
142  }
143  }
144  else
145  {
146  ::avro::decode(d, v.name);
147  }
148  }
149  };
150 }
151 
152 #endif
std::map< std::string, std::string > options
Definition: delete_role.h:45
A set of output parameters for deleteRole(const DeleteRoleRequest&) const.
Definition: delete_role.h:100
A set of input parameters for deleteRole(const DeleteRoleRequest&) const.
Definition: delete_role.h:18
DeleteRoleResponse()
Constructs a DeleteRoleResponse object with default parameter values.
Definition: delete_role.h:107
DeleteRoleRequest()
Constructs a DeleteRoleRequest object with default parameter values.
Definition: delete_role.h:24
DeleteRoleRequest(const std::string &name_, const std::map< std::string, std::string > &options_)
Constructs a DeleteRoleRequest object with the specified parameters.
Definition: delete_role.h:38