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