GPUdb C++ API  Version 7.0.19.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
create_trigger_by_area.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_TRIGGER_BY_AREA_H__
7 #define __CREATE_TRIGGER_BY_AREA_H__
8 
9 namespace gpudb
10 {
11 
35  {
36 
42  requestId(std::string()),
43  tableNames(std::vector<std::string>()),
44  xColumnName(std::string()),
45  xVector(std::vector<double>()),
46  yColumnName(std::string()),
47  yVector(std::vector<double>()),
48  options(std::map<std::string, std::string>())
49  {
50  }
51 
78  CreateTriggerByAreaRequest(const std::string& requestId_, const std::vector<std::string>& tableNames_, const std::string& xColumnName_, const std::vector<double>& xVector_, const std::string& yColumnName_, const std::vector<double>& yVector_, const std::map<std::string, std::string>& options_):
79  requestId( requestId_ ),
80  tableNames( tableNames_ ),
81  xColumnName( xColumnName_ ),
82  xVector( xVector_ ),
83  yColumnName( yColumnName_ ),
84  yVector( yVector_ ),
85  options( options_ )
86  {
87  }
88 
89  std::string requestId;
90  std::vector<std::string> tableNames;
91  std::string xColumnName;
92  std::vector<double> xVector;
93  std::string yColumnName;
94  std::vector<double> yVector;
95  std::map<std::string, std::string> options;
96  };
97 }
98 
99 namespace avro
100 {
101  template<> struct codec_traits<gpudb::CreateTriggerByAreaRequest>
102  {
103  static void encode(Encoder& e, const gpudb::CreateTriggerByAreaRequest& v)
104  {
105  ::avro::encode(e, v.requestId);
106  ::avro::encode(e, v.tableNames);
107  ::avro::encode(e, v.xColumnName);
108  ::avro::encode(e, v.xVector);
109  ::avro::encode(e, v.yColumnName);
110  ::avro::encode(e, v.yVector);
111  ::avro::encode(e, v.options);
112  }
113 
114  static void decode(Decoder& d, gpudb::CreateTriggerByAreaRequest& v)
115  {
116  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
117  {
118  const std::vector<size_t> fo = rd->fieldOrder();
119 
120  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
121  {
122  switch (*it)
123  {
124  case 0:
125  ::avro::decode(d, v.requestId);
126  break;
127 
128  case 1:
129  ::avro::decode(d, v.tableNames);
130  break;
131 
132  case 2:
133  ::avro::decode(d, v.xColumnName);
134  break;
135 
136  case 3:
137  ::avro::decode(d, v.xVector);
138  break;
139 
140  case 4:
141  ::avro::decode(d, v.yColumnName);
142  break;
143 
144  case 5:
145  ::avro::decode(d, v.yVector);
146  break;
147 
148  case 6:
149  ::avro::decode(d, v.options);
150  break;
151 
152  default:
153  break;
154  }
155  }
156  }
157  else
158  {
159  ::avro::decode(d, v.requestId);
160  ::avro::decode(d, v.tableNames);
161  ::avro::decode(d, v.xColumnName);
162  ::avro::decode(d, v.xVector);
163  ::avro::decode(d, v.yColumnName);
164  ::avro::decode(d, v.yVector);
165  ::avro::decode(d, v.options);
166  }
167  }
168  };
169 }
170 
171 namespace gpudb
172 {
173 
197  {
198 
204  triggerId(std::string()),
205  info(std::map<std::string, std::string>())
206  {
207  }
208 
209  std::string triggerId;
210  std::map<std::string, std::string> info;
211  };
212 }
213 
214 namespace avro
215 {
216  template<> struct codec_traits<gpudb::CreateTriggerByAreaResponse>
217  {
218  static void encode(Encoder& e, const gpudb::CreateTriggerByAreaResponse& v)
219  {
220  ::avro::encode(e, v.triggerId);
221  ::avro::encode(e, v.info);
222  }
223 
224  static void decode(Decoder& d, gpudb::CreateTriggerByAreaResponse& v)
225  {
226  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
227  {
228  const std::vector<size_t> fo = rd->fieldOrder();
229 
230  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
231  {
232  switch (*it)
233  {
234  case 0:
235  ::avro::decode(d, v.triggerId);
236  break;
237 
238  case 1:
239  ::avro::decode(d, v.info);
240  break;
241 
242  default:
243  break;
244  }
245  }
246  }
247  else
248  {
249  ::avro::decode(d, v.triggerId);
250  ::avro::decode(d, v.info);
251  }
252  }
253  };
254 }
255 
256 #endif
CreateTriggerByAreaResponse()
Constructs a CreateTriggerByAreaResponse object with default parameter values.
std::map< std::string, std::string > options
A set of output parameters for const.
CreateTriggerByAreaRequest()
Constructs a CreateTriggerByAreaRequest object with default parameter values.
std::vector< std::string > tableNames
A set of input parameters for const.
CreateTriggerByAreaRequest(const std::string &requestId_, const std::vector< std::string > &tableNames_, const std::string &xColumnName_, const std::vector< double > &xVector_, const std::string &yColumnName_, const std::vector< double > &yVector_, const std::map< std::string, std::string > &options_)
Constructs a CreateTriggerByAreaRequest object with the specified parameters.
std::map< std::string, std::string > info