GPUdb C++ API  Version 6.2.0.3
admin_shutdown.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 __ADMIN_SHUTDOWN_H__
7 #define __ADMIN_SHUTDOWN_H__
8 
9 namespace gpudb
10 {
11 
19  {
20 
26  exitType(std::string()),
27  authorization(std::string()),
28  options(std::map<std::string, std::string>())
29  {
30  }
31 
43  AdminShutdownRequest(const std::string& exitType_, const std::string& authorization_, const std::map<std::string, std::string>& options_):
44  exitType( exitType_ ),
45  authorization( authorization_ ),
46  options( options_ )
47  {
48  }
49 
50  std::string exitType;
51  std::string authorization;
52  std::map<std::string, std::string> options;
53  };
54 }
55 
56 namespace avro
57 {
58  template<> struct codec_traits<gpudb::AdminShutdownRequest>
59  {
60  static void encode(Encoder& e, const gpudb::AdminShutdownRequest& v)
61  {
62  ::avro::encode(e, v.exitType);
63  ::avro::encode(e, v.authorization);
64  ::avro::encode(e, v.options);
65  }
66 
67  static void decode(Decoder& d, gpudb::AdminShutdownRequest& v)
68  {
69  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
70  {
71  const std::vector<size_t> fo = rd->fieldOrder();
72 
73  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
74  {
75  switch (*it)
76  {
77  case 0:
78  ::avro::decode(d, v.exitType);
79  break;
80 
81  case 1:
82  ::avro::decode(d, v.authorization);
83  break;
84 
85  case 2:
86  ::avro::decode(d, v.options);
87  break;
88 
89  default:
90  break;
91  }
92  }
93  }
94  else
95  {
96  ::avro::decode(d, v.exitType);
97  ::avro::decode(d, v.authorization);
98  ::avro::decode(d, v.options);
99  }
100  }
101  };
102 }
103 
104 namespace gpudb
105 {
106 
114  {
115 
121  exitStatus(std::string())
122  {
123  }
124 
125  std::string exitStatus;
126  };
127 }
128 
129 namespace avro
130 {
131  template<> struct codec_traits<gpudb::AdminShutdownResponse>
132  {
133  static void encode(Encoder& e, const gpudb::AdminShutdownResponse& v)
134  {
135  ::avro::encode(e, v.exitStatus);
136  }
137 
138  static void decode(Decoder& d, gpudb::AdminShutdownResponse& v)
139  {
140  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
141  {
142  const std::vector<size_t> fo = rd->fieldOrder();
143 
144  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
145  {
146  switch (*it)
147  {
148  case 0:
149  ::avro::decode(d, v.exitStatus);
150  break;
151 
152  default:
153  break;
154  }
155  }
156  }
157  else
158  {
159  ::avro::decode(d, v.exitStatus);
160  }
161  }
162  };
163 }
164 
165 #endif
std::map< std::string, std::string > options
AdminShutdownRequest()
Constructs an AdminShutdownRequest object with default parameter values.
AdminShutdownResponse()
Constructs an AdminShutdownResponse object with default parameter values.
A set of output parameters for adminShutdown(const AdminShutdownRequest&) const.
A set of input parameters for adminShutdown(const AdminShutdownRequest&) const.
AdminShutdownRequest(const std::string &exitType_, const std::string &authorization_, const std::map< std::string, std::string > &options_)
Constructs an AdminShutdownRequest object with the specified parameters.