GPUdb C++ API  Version 7.1.10.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
collect_statistics.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 __COLLECT_STATISTICS_H__
7 #define __COLLECT_STATISTICS_H__
8 
9 namespace gpudb
10 {
11 
19  {
20 
26  tableName(std::string()),
27  columnNames(std::vector<std::string>()),
28  options(std::map<std::string, std::string>())
29  {
30  }
31 
47  CollectStatisticsRequest(const std::string& tableName_, const std::vector<std::string>& columnNames_, const std::map<std::string, std::string>& options_):
48  tableName( tableName_ ),
49  columnNames( columnNames_ ),
50  options( options_ )
51  {
52  }
53 
54  std::string tableName;
55  std::vector<std::string> columnNames;
56  std::map<std::string, std::string> options;
57  };
58 }
59 
60 namespace avro
61 {
62  template<> struct codec_traits<gpudb::CollectStatisticsRequest>
63  {
64  static void encode(Encoder& e, const gpudb::CollectStatisticsRequest& v)
65  {
66  ::avro::encode(e, v.tableName);
67  ::avro::encode(e, v.columnNames);
68  ::avro::encode(e, v.options);
69  }
70 
71  static void decode(Decoder& d, gpudb::CollectStatisticsRequest& v)
72  {
73  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
74  {
75  const std::vector<size_t> fo = rd->fieldOrder();
76 
77  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
78  {
79  switch (*it)
80  {
81  case 0:
82  ::avro::decode(d, v.tableName);
83  break;
84 
85  case 1:
86  ::avro::decode(d, v.columnNames);
87  break;
88 
89  case 2:
90  ::avro::decode(d, v.options);
91  break;
92 
93  default:
94  break;
95  }
96  }
97  }
98  else
99  {
100  ::avro::decode(d, v.tableName);
101  ::avro::decode(d, v.columnNames);
102  ::avro::decode(d, v.options);
103  }
104  }
105  };
106 }
107 
108 namespace gpudb
109 {
110 
118  {
119 
125  tableName(std::string()),
126  columnNames(std::vector<std::string>()),
127  info(std::map<std::string, std::string>())
128  {
129  }
130 
131  std::string tableName;
132  std::vector<std::string> columnNames;
133  std::map<std::string, std::string> info;
134  };
135 }
136 
137 namespace avro
138 {
139  template<> struct codec_traits<gpudb::CollectStatisticsResponse>
140  {
141  static void encode(Encoder& e, const gpudb::CollectStatisticsResponse& v)
142  {
143  ::avro::encode(e, v.tableName);
144  ::avro::encode(e, v.columnNames);
145  ::avro::encode(e, v.info);
146  }
147 
148  static void decode(Decoder& d, gpudb::CollectStatisticsResponse& v)
149  {
150  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
151  {
152  const std::vector<size_t> fo = rd->fieldOrder();
153 
154  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
155  {
156  switch (*it)
157  {
158  case 0:
159  ::avro::decode(d, v.tableName);
160  break;
161 
162  case 1:
163  ::avro::decode(d, v.columnNames);
164  break;
165 
166  case 2:
167  ::avro::decode(d, v.info);
168  break;
169 
170  default:
171  break;
172  }
173  }
174  }
175  else
176  {
177  ::avro::decode(d, v.tableName);
178  ::avro::decode(d, v.columnNames);
179  ::avro::decode(d, v.info);
180  }
181  }
182  };
183 }
184 
185 #endif
std::map< std::string, std::string > info
A set of output parameters for const.
std::vector< std::string > columnNames
CollectStatisticsRequest(const std::string &tableName_, const std::vector< std::string > &columnNames_, const std::map< std::string, std::string > &options_)
Constructs a CollectStatisticsRequest object with the specified parameters.
A set of input parameters for const.
CollectStatisticsRequest()
Constructs a CollectStatisticsRequest object with default parameter values.
CollectStatisticsResponse()
Constructs a CollectStatisticsResponse object with default parameter values.
std::vector< std::string > columnNames
std::map< std::string, std::string > options