6 #ifndef __SHOW_CONTAINER_REGISTRY_H__
7 #define __SHOW_CONTAINER_REGISTRY_H__
18 struct ShowContainerRegistryRequest
26 ShowContainerRegistryRequest() :
27 registryName(std::string()),
28 options(std::map<std::string, std::string>())
41 ShowContainerRegistryRequest(
const std::string& registryName_,
const std::map<std::string, std::string>& options_):
42 registryName( registryName_ ),
47 std::string registryName;
48 std::map<std::string, std::string> options;
58 template<>
struct codec_traits<gpudb::ShowContainerRegistryRequest>
60 static void encode(Encoder& e,
const gpudb::ShowContainerRegistryRequest& v)
62 ::avro::encode(e, v.registryName);
63 ::avro::encode(e, v.options);
66 static void decode(Decoder& d, gpudb::ShowContainerRegistryRequest& v)
68 if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
70 const std::vector<size_t> fo = rd->fieldOrder();
72 for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
77 ::avro::decode(d, v.registryName);
81 ::avro::decode(d, v.options);
91 ::avro::decode(d, v.registryName);
92 ::avro::decode(d, v.options);
107 struct ShowContainerRegistryResponse
115 ShowContainerRegistryResponse() :
116 registryName(std::string()),
117 registryNames(std::vector<std::string>()),
118 entityIds(std::vector<int32_t>()),
119 uriList(std::vector<std::string>()),
120 credentialList(std::vector<std::string>()),
121 info(std::map<std::string, std::string>())
125 std::string registryName;
126 std::vector<std::string> registryNames;
127 std::vector<int32_t> entityIds;
128 std::vector<std::string> uriList;
129 std::vector<std::string> credentialList;
130 std::map<std::string, std::string> info;
140 template<>
struct codec_traits<gpudb::ShowContainerRegistryResponse>
142 static void encode(Encoder& e,
const gpudb::ShowContainerRegistryResponse& v)
144 ::avro::encode(e, v.registryName);
145 ::avro::encode(e, v.registryNames);
146 ::avro::encode(e, v.entityIds);
147 ::avro::encode(e, v.uriList);
148 ::avro::encode(e, v.credentialList);
149 ::avro::encode(e, v.info);
152 static void decode(Decoder& d, gpudb::ShowContainerRegistryResponse& v)
154 if (::avro::ResolvingDecoder *rd = dynamic_cast< ::avro::ResolvingDecoder*>(&d))
156 const std::vector<size_t> fo = rd->fieldOrder();
158 for (std::vector<size_t>::const_iterator it = fo.begin(); it != fo.end(); ++it)
163 ::avro::decode(d, v.registryName);
167 ::avro::decode(d, v.registryNames);
171 ::avro::decode(d, v.entityIds);
175 ::avro::decode(d, v.uriList);
179 ::avro::decode(d, v.credentialList);
183 ::avro::decode(d, v.info);
193 ::avro::decode(d, v.registryName);
194 ::avro::decode(d, v.registryNames);
195 ::avro::decode(d, v.entityIds);
196 ::avro::decode(d, v.uriList);
197 ::avro::decode(d, v.credentialList);
198 ::avro::decode(d, v.info);