GPUdb C++ API  Version 7.2.3.0
alter_backup.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 __ALTER_BACKUP_H__
7 #define __ALTER_BACKUP_H__
8 
9 namespace gpudb
10 {
23  {
28  backupName(std::string()),
29  action(std::string()),
30  value(std::string()),
31  datasinkName(std::string()),
32  options(std::map<std::string, std::string>())
33  {
34  }
35 
96  AlterBackupRequest(const std::string& backupName_, const std::string& action_, const std::string& value_, const std::string& datasinkName_, const std::map<std::string, std::string>& options_):
97  backupName( backupName_ ),
98  action( action_ ),
99  value( value_ ),
100  datasinkName( datasinkName_ ),
101  options( options_ )
102  {
103  }
104 
108  std::string backupName;
109 
133  std::string action;
134 
138  std::string value;
139 
143  std::string datasinkName;
144 
162  std::map<std::string, std::string> options;
163  };
164 } // end namespace gpudb
165 
166 namespace avro
167 {
168  template<> struct codec_traits<gpudb::AlterBackupRequest>
169  {
170  static void encode(Encoder& e, const gpudb::AlterBackupRequest& v)
171  {
172  ::avro::encode(e, v.backupName);
173  ::avro::encode(e, v.action);
174  ::avro::encode(e, v.value);
175  ::avro::encode(e, v.datasinkName);
176  ::avro::encode(e, v.options);
177  }
178 
179  static void decode(Decoder& d, gpudb::AlterBackupRequest& v)
180  {
181  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
182  {
183  const std::vector<size_t> fo = rd->fieldOrder();
184 
185  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
186  {
187  switch (*it)
188  {
189  case 0:
190  ::avro::decode(d, v.backupName);
191  break;
192 
193  case 1:
194  ::avro::decode(d, v.action);
195  break;
196 
197  case 2:
198  ::avro::decode(d, v.value);
199  break;
200 
201  case 3:
202  ::avro::decode(d, v.datasinkName);
203  break;
204 
205  case 4:
206  ::avro::decode(d, v.options);
207  break;
208 
209  default:
210  break;
211  }
212  }
213  }
214  else
215  {
216  ::avro::decode(d, v.backupName);
217  ::avro::decode(d, v.action);
218  ::avro::decode(d, v.value);
219  ::avro::decode(d, v.datasinkName);
220  ::avro::decode(d, v.options);
221  }
222  }
223  };
224 } // end namespace avro
225 
226 namespace gpudb
227 {
234  {
239  backupName(std::string()),
240  backupId(int64_t()),
241  totalBytes(int64_t()),
242  totalNumberOfRecords(int64_t()),
243  info(std::map<std::string, std::string>())
244  {
245  }
246 
250  std::string backupName;
251 
255  int64_t backupId;
256 
260  int64_t totalBytes;
261 
266 
270  std::map<std::string, std::string> info;
271  };
272 } // end namespace gpudb
273 
274 namespace avro
275 {
276  template<> struct codec_traits<gpudb::AlterBackupResponse>
277  {
278  static void encode(Encoder& e, const gpudb::AlterBackupResponse& v)
279  {
280  ::avro::encode(e, v.backupName);
281  ::avro::encode(e, v.backupId);
282  ::avro::encode(e, v.totalBytes);
283  ::avro::encode(e, v.totalNumberOfRecords);
284  ::avro::encode(e, v.info);
285  }
286 
287  static void decode(Decoder& d, gpudb::AlterBackupResponse& v)
288  {
289  if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
290  {
291  const std::vector<size_t> fo = rd->fieldOrder();
292 
293  for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
294  {
295  switch (*it)
296  {
297  case 0:
298  ::avro::decode(d, v.backupName);
299  break;
300 
301  case 1:
302  ::avro::decode(d, v.backupId);
303  break;
304 
305  case 2:
306  ::avro::decode(d, v.totalBytes);
307  break;
308 
309  case 3:
310  ::avro::decode(d, v.totalNumberOfRecords);
311  break;
312 
313  case 4:
314  ::avro::decode(d, v.info);
315  break;
316 
317  default:
318  break;
319  }
320  }
321  }
322  else
323  {
324  ::avro::decode(d, v.backupName);
325  ::avro::decode(d, v.backupId);
326  ::avro::decode(d, v.totalBytes);
327  ::avro::decode(d, v.totalNumberOfRecords);
328  ::avro::decode(d, v.info);
329  }
330  }
331  };
332 } // end namespace avro
333 
334 #endif // __ALTER_BACKUP_H__
std::string value
Value of the modification, depending on action.
Definition: alter_backup.h:138
int64_t backupId
ID of the snapshot affected by the alter operation, if any.
Definition: alter_backup.h:255
std::string datasinkName
Data sink through which the backup is accessible.
Definition: alter_backup.h:143
std::string action
Operation to be applied.
Definition: alter_backup.h:133
int64_t totalNumberOfRecords
Total number of records affected by the alter operation.
Definition: alter_backup.h:265
AlterBackupRequest(const std::string &backupName_, const std::string &action_, const std::string &value_, const std::string &datasinkName_, const std::map< std::string, std::string > &options_)
Constructs an AlterBackupRequest object with the specified parameters.
Definition: alter_backup.h:96
A set of results returned by GPUdb::alterBackup.
Definition: alter_backup.h:233
AlterBackupResponse()
Constructs an AlterBackupResponse object with default parameters.
Definition: alter_backup.h:238
A set of parameters for GPUdb::alterBackup.
Definition: alter_backup.h:22
std::string backupName
Name of the backup to be altered.
Definition: alter_backup.h:108
std::map< std::string, std::string > options
Optional parameters.
Definition: alter_backup.h:162
std::string backupName
Value of backupName.
Definition: alter_backup.h:250
AlterBackupRequest()
Constructs an AlterBackupRequest object with default parameters.
Definition: alter_backup.h:27
int64_t totalBytes
Total size of files affected by the alter operation.
Definition: alter_backup.h:260
std::map< std::string, std::string > info
Additional information.
Definition: alter_backup.h:270