GPUdb C++ API  Version 7.2.2.4
admin_ha_offline.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 __ADMIN_HA_OFFLINE_H__
7 #define __ADMIN_HA_OFFLINE_H__
8 
9 namespace gpudb
10 {
21  {
26  offline(bool()),
27  options(std::map<std::string, std::string>())
28  {
29  }
30 
44  AdminHaOfflineRequest(const bool offline_, const std::map<std::string, std::string>& options_):
45  offline( offline_ ),
46  options( options_ )
47  {
48  }
49 
58  bool offline;
59 
63  std::map<std::string, std::string> options;
64  };
65 } // end namespace gpudb
66 
67 namespace avro
68 {
69  template<> struct codec_traits<gpudb::AdminHaOfflineRequest>
70  {
71  static void encode(Encoder& e, const gpudb::AdminHaOfflineRequest& v)
72  {
73  ::avro::encode(e, v.offline);
74  ::avro::encode(e, v.options);
75  }
76 
77  static void decode(Decoder& d, gpudb::AdminHaOfflineRequest& v)
78  {
79  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
80  {
81  const std::vector<size_t> fo = rd->fieldOrder();
82 
83  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
84  {
85  switch (*it)
86  {
87  case 0:
88  ::avro::decode(d, v.offline);
89  break;
90 
91  case 1:
92  ::avro::decode(d, v.options);
93  break;
94 
95  default:
96  break;
97  }
98  }
99  }
100  else
101  {
102  ::avro::decode(d, v.offline);
103  ::avro::decode(d, v.options);
104  }
105  }
106  };
107 } // end namespace avro
108 
109 namespace gpudb
110 {
117  {
122  info(std::map<std::string, std::string>())
123  {
124  }
125 
129  std::map<std::string, std::string> info;
130  };
131 } // end namespace gpudb
132 
133 namespace avro
134 {
135  template<> struct codec_traits<gpudb::AdminHaOfflineResponse>
136  {
137  static void encode(Encoder& e, const gpudb::AdminHaOfflineResponse& v)
138  {
139  ::avro::encode(e, v.info);
140  }
141 
142  static void decode(Decoder& d, gpudb::AdminHaOfflineResponse& v)
143  {
144  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
145  {
146  const std::vector<size_t> fo = rd->fieldOrder();
147 
148  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
149  {
150  switch (*it)
151  {
152  case 0:
153  ::avro::decode(d, v.info);
154  break;
155 
156  default:
157  break;
158  }
159  }
160  }
161  else
162  {
163  ::avro::decode(d, v.info);
164  }
165  }
166  };
167 } // end namespace avro
168 
169 #endif // __ADMIN_HA_OFFLINE_H__
std::map< std::string, std::string > options
Optional parameters.
std::map< std::string, std::string > info
Additional information.
bool offline
Set to true if desired state is offline.
AdminHaOfflineRequest(const bool offline_, const std::map< std::string, std::string > &options_)
Constructs an AdminHaOfflineRequest object with the specified parameters.
A set of parameters for GPUdb::adminHaOffline.
A set of results returned by GPUdb::adminHaOffline.
AdminHaOfflineResponse()
Constructs an AdminHaOfflineResponse object with default parameters.
AdminHaOfflineRequest()
Constructs an AdminHaOfflineRequest object with default parameters.