Debian Codegraph @

src/core/ext/upb-generated/envoy/config/route/v3/route.upb.h

raw
1 /* This file was generated by upbc (the upb compiler) from the input
2 * file:
3 *
4 * envoy/config/route/v3/route.proto
5 *
6 * Do not edit -- your changes will be discarded when the file is
7 * regenerated. */
8
9 #ifndef ENVOY_CONFIG_ROUTE_V3_ROUTE_PROTO_UPB_H_
10 #define ENVOY_CONFIG_ROUTE_V3_ROUTE_PROTO_UPB_H_
11
12 #include "upb/msg_internal.h"
13 #include "upb/decode.h"
14 #include "upb/decode_fast.h"
15 #include "upb/encode.h"
16
17 #include "upb/port_def.inc"
18
19 #ifdef __cplusplus
20 extern "C" {
21 #endif
22
23 struct envoy_config_route_v3_RouteConfiguration;
24 struct envoy_config_route_v3_Vhds;
25 typedef struct envoy_config_route_v3_RouteConfiguration envoy_config_route_v3_RouteConfiguration;
26 typedef struct envoy_config_route_v3_Vhds envoy_config_route_v3_Vhds;
27 extern const upb_MiniTable envoy_config_route_v3_RouteConfiguration_msginit;
28 extern const upb_MiniTable envoy_config_route_v3_Vhds_msginit;
29 struct envoy_config_core_v3_ConfigSource;
30 struct envoy_config_core_v3_HeaderValueOption;
31 struct envoy_config_route_v3_ClusterSpecifierPlugin;
32 struct envoy_config_route_v3_RouteAction_RequestMirrorPolicy;
33 struct envoy_config_route_v3_VirtualHost;
34 struct google_protobuf_BoolValue;
35 struct google_protobuf_UInt32Value;
36 extern const upb_MiniTable envoy_config_core_v3_ConfigSource_msginit;
37 extern const upb_MiniTable envoy_config_core_v3_HeaderValueOption_msginit;
38 extern const upb_MiniTable envoy_config_route_v3_ClusterSpecifierPlugin_msginit;
39 extern const upb_MiniTable envoy_config_route_v3_RouteAction_RequestMirrorPolicy_msginit;
40 extern const upb_MiniTable envoy_config_route_v3_VirtualHost_msginit;
41 extern const upb_MiniTable google_protobuf_BoolValue_msginit;
42 extern const upb_MiniTable google_protobuf_UInt32Value_msginit;
43
44
45
46 /* envoy.config.route.v3.RouteConfiguration */
47
48 UPB_INLINE envoy_config_route_v3_RouteConfiguration* envoy_config_route_v3_RouteConfiguration_new(upb_Arena* arena) {
49 return (envoy_config_route_v3_RouteConfiguration*)_upb_Message_New(&envoy_config_route_v3_RouteConfiguration_msginit, arena);
50 }
51 UPB_INLINE envoy_config_route_v3_RouteConfiguration* envoy_config_route_v3_RouteConfiguration_parse(const char* buf, size_t size, upb_Arena* arena) {
52 envoy_config_route_v3_RouteConfiguration* ret = envoy_config_route_v3_RouteConfiguration_new(arena);
53 if (!ret) return NULL;
54 if (upb_Decode(buf, size, ret, &envoy_config_route_v3_RouteConfiguration_msginit, NULL, 0, arena) != kUpb_DecodeStatus_Ok) {
55 return NULL;
56 }
57 return ret;
58 }
59 UPB_INLINE envoy_config_route_v3_RouteConfiguration* envoy_config_route_v3_RouteConfiguration_parse_ex(const char* buf, size_t size,
60 const upb_ExtensionRegistry* extreg,
61 int options, upb_Arena* arena) {
62 envoy_config_route_v3_RouteConfiguration* ret = envoy_config_route_v3_RouteConfiguration_new(arena);
63 if (!ret) return NULL;
64 if (upb_Decode(buf, size, ret, &envoy_config_route_v3_RouteConfiguration_msginit, extreg, options, arena) !=
65 kUpb_DecodeStatus_Ok) {
66 return NULL;
67 }
68 return ret;
69 }
70 UPB_INLINE char* envoy_config_route_v3_RouteConfiguration_serialize(const envoy_config_route_v3_RouteConfiguration* msg, upb_Arena* arena, size_t* len) {
71 char* ptr;
72 (void)upb_Encode(msg, &envoy_config_route_v3_RouteConfiguration_msginit, 0, arena, &ptr, len);
73 return ptr;
74 }
75 UPB_INLINE char* envoy_config_route_v3_RouteConfiguration_serialize_ex(const envoy_config_route_v3_RouteConfiguration* msg, int options,
76 upb_Arena* arena, size_t* len) {
77 char* ptr;
78 (void)upb_Encode(msg, &envoy_config_route_v3_RouteConfiguration_msginit, options, arena, &ptr, len);
79 return ptr;
80 }
81 UPB_INLINE void envoy_config_route_v3_RouteConfiguration_clear_name(const envoy_config_route_v3_RouteConfiguration* msg) {
82 *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
83 }
84 UPB_INLINE upb_StringView envoy_config_route_v3_RouteConfiguration_name(const envoy_config_route_v3_RouteConfiguration* msg) {
85 return *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_StringView);
86 }
87 UPB_INLINE bool envoy_config_route_v3_RouteConfiguration_has_virtual_hosts(const envoy_config_route_v3_RouteConfiguration* msg) {
88 return _upb_has_submsg_nohasbit(msg, UPB_SIZE(12, 24));
89 }
90 UPB_INLINE void envoy_config_route_v3_RouteConfiguration_clear_virtual_hosts(const envoy_config_route_v3_RouteConfiguration* msg) {
91 _upb_array_detach(msg, UPB_SIZE(12, 24));
92 }
93 UPB_INLINE const struct envoy_config_route_v3_VirtualHost* const* envoy_config_route_v3_RouteConfiguration_virtual_hosts(const envoy_config_route_v3_RouteConfiguration* msg, size_t* len) {
94 return (const struct envoy_config_route_v3_VirtualHost* const*)_upb_array_accessor(msg, UPB_SIZE(12, 24), len);
95 }
96 UPB_INLINE void envoy_config_route_v3_RouteConfiguration_clear_internal_only_headers(const envoy_config_route_v3_RouteConfiguration* msg) {
97 _upb_array_detach(msg, UPB_SIZE(16, 32));
98 }
99 UPB_INLINE upb_StringView const* envoy_config_route_v3_RouteConfiguration_internal_only_headers(const envoy_config_route_v3_RouteConfiguration* msg, size_t* len) {
100 return (upb_StringView const*)_upb_array_accessor(msg, UPB_SIZE(16, 32), len);
101 }
102 UPB_INLINE bool envoy_config_route_v3_RouteConfiguration_has_response_headers_to_add(const envoy_config_route_v3_RouteConfiguration* msg) {
103 return _upb_has_submsg_nohasbit(msg, UPB_SIZE(20, 40));
104 }
105 UPB_INLINE void envoy_config_route_v3_RouteConfiguration_clear_response_headers_to_add(const envoy_config_route_v3_RouteConfiguration* msg) {
106 _upb_array_detach(msg, UPB_SIZE(20, 40));
107 }
108 UPB_INLINE const struct envoy_config_core_v3_HeaderValueOption* const* envoy_config_route_v3_RouteConfiguration_response_headers_to_add(const envoy_config_route_v3_RouteConfiguration* msg, size_t* len) {
109 return (const struct envoy_config_core_v3_HeaderValueOption* const*)_upb_array_accessor(msg, UPB_SIZE(20, 40), len);
110 }
111 UPB_INLINE void envoy_config_route_v3_RouteConfiguration_clear_response_headers_to_remove(const envoy_config_route_v3_RouteConfiguration* msg) {
112 _upb_array_detach(msg, UPB_SIZE(24, 48));
113 }
114 UPB_INLINE upb_StringView const* envoy_config_route_v3_RouteConfiguration_response_headers_to_remove(const envoy_config_route_v3_RouteConfiguration* msg, size_t* len) {
115 return (upb_StringView const*)_upb_array_accessor(msg, UPB_SIZE(24, 48), len);
116 }
117 UPB_INLINE bool envoy_config_route_v3_RouteConfiguration_has_request_headers_to_add(const envoy_config_route_v3_RouteConfiguration* msg) {
118 return _upb_has_submsg_nohasbit(msg, UPB_SIZE(28, 56));
119 }
120 UPB_INLINE void envoy_config_route_v3_RouteConfiguration_clear_request_headers_to_add(const envoy_config_route_v3_RouteConfiguration* msg) {
121 _upb_array_detach(msg, UPB_SIZE(28, 56));
122 }
123 UPB_INLINE const struct envoy_config_core_v3_HeaderValueOption* const* envoy_config_route_v3_RouteConfiguration_request_headers_to_add(const envoy_config_route_v3_RouteConfiguration* msg, size_t* len) {
124 return (const struct envoy_config_core_v3_HeaderValueOption* const*)_upb_array_accessor(msg, UPB_SIZE(28, 56), len);
125 }
126 UPB_INLINE bool envoy_config_route_v3_RouteConfiguration_has_validate_clusters(const envoy_config_route_v3_RouteConfiguration* msg) {
127 return _upb_hasbit(msg, 1);
128 }
129 UPB_INLINE void envoy_config_route_v3_RouteConfiguration_clear_validate_clusters(const envoy_config_route_v3_RouteConfiguration* msg) {
130 *UPB_PTR_AT(msg, UPB_SIZE(32, 64), const upb_Message*) = NULL;
131 }
132 UPB_INLINE const struct google_protobuf_BoolValue* envoy_config_route_v3_RouteConfiguration_validate_clusters(const envoy_config_route_v3_RouteConfiguration* msg) {
133 return *UPB_PTR_AT(msg, UPB_SIZE(32, 64), const struct google_protobuf_BoolValue*);
134 }
135 UPB_INLINE void envoy_config_route_v3_RouteConfiguration_clear_request_headers_to_remove(const envoy_config_route_v3_RouteConfiguration* msg) {
136 _upb_array_detach(msg, UPB_SIZE(36, 72));
137 }
138 UPB_INLINE upb_StringView const* envoy_config_route_v3_RouteConfiguration_request_headers_to_remove(const envoy_config_route_v3_RouteConfiguration* msg, size_t* len) {
139 return (upb_StringView const*)_upb_array_accessor(msg, UPB_SIZE(36, 72), len);
140 }
141 UPB_INLINE bool envoy_config_route_v3_RouteConfiguration_has_vhds(const envoy_config_route_v3_RouteConfiguration* msg) {
142 return _upb_hasbit(msg, 2);
143 }
144 UPB_INLINE void envoy_config_route_v3_RouteConfiguration_clear_vhds(const envoy_config_route_v3_RouteConfiguration* msg) {
145 *UPB_PTR_AT(msg, UPB_SIZE(40, 80), const upb_Message*) = NULL;
146 }
147 UPB_INLINE const envoy_config_route_v3_Vhds* envoy_config_route_v3_RouteConfiguration_vhds(const envoy_config_route_v3_RouteConfiguration* msg) {
148 return *UPB_PTR_AT(msg, UPB_SIZE(40, 80), const envoy_config_route_v3_Vhds*);
149 }
150 UPB_INLINE void envoy_config_route_v3_RouteConfiguration_clear_most_specific_header_mutations_wins(const envoy_config_route_v3_RouteConfiguration* msg) {
151 *UPB_PTR_AT(msg, UPB_SIZE(1, 1), bool) = 0;
152 }
153 UPB_INLINE bool envoy_config_route_v3_RouteConfiguration_most_specific_header_mutations_wins(const envoy_config_route_v3_RouteConfiguration* msg) {
154 return *UPB_PTR_AT(msg, UPB_SIZE(1, 1), bool);
155 }
156 UPB_INLINE bool envoy_config_route_v3_RouteConfiguration_has_max_direct_response_body_size_bytes(const envoy_config_route_v3_RouteConfiguration* msg) {
157 return _upb_hasbit(msg, 3);
158 }
159 UPB_INLINE void envoy_config_route_v3_RouteConfiguration_clear_max_direct_response_body_size_bytes(const envoy_config_route_v3_RouteConfiguration* msg) {
160 *UPB_PTR_AT(msg, UPB_SIZE(44, 88), const upb_Message*) = NULL;
161 }
162 UPB_INLINE const struct google_protobuf_UInt32Value* envoy_config_route_v3_RouteConfiguration_max_direct_response_body_size_bytes(const envoy_config_route_v3_RouteConfiguration* msg) {
163 return *UPB_PTR_AT(msg, UPB_SIZE(44, 88), const struct google_protobuf_UInt32Value*);
164 }
165 UPB_INLINE bool envoy_config_route_v3_RouteConfiguration_has_cluster_specifier_plugins(const envoy_config_route_v3_RouteConfiguration* msg) {
166 return _upb_has_submsg_nohasbit(msg, UPB_SIZE(48, 96));
167 }
168 UPB_INLINE void envoy_config_route_v3_RouteConfiguration_clear_cluster_specifier_plugins(const envoy_config_route_v3_RouteConfiguration* msg) {
169 _upb_array_detach(msg, UPB_SIZE(48, 96));
170 }
171 UPB_INLINE const struct envoy_config_route_v3_ClusterSpecifierPlugin* const* envoy_config_route_v3_RouteConfiguration_cluster_specifier_plugins(const envoy_config_route_v3_RouteConfiguration* msg, size_t* len) {
172 return (const struct envoy_config_route_v3_ClusterSpecifierPlugin* const*)_upb_array_accessor(msg, UPB_SIZE(48, 96), len);
173 }
174 UPB_INLINE bool envoy_config_route_v3_RouteConfiguration_has_request_mirror_policies(const envoy_config_route_v3_RouteConfiguration* msg) {
175 return _upb_has_submsg_nohasbit(msg, UPB_SIZE(52, 104));
176 }
177 UPB_INLINE void envoy_config_route_v3_RouteConfiguration_clear_request_mirror_policies(const envoy_config_route_v3_RouteConfiguration* msg) {
178 _upb_array_detach(msg, UPB_SIZE(52, 104));
179 }
180 UPB_INLINE const struct envoy_config_route_v3_RouteAction_RequestMirrorPolicy* const* envoy_config_route_v3_RouteConfiguration_request_mirror_policies(const envoy_config_route_v3_RouteConfiguration* msg, size_t* len) {
181 return (const struct envoy_config_route_v3_RouteAction_RequestMirrorPolicy* const*)_upb_array_accessor(msg, UPB_SIZE(52, 104), len);
182 }
183 UPB_INLINE void envoy_config_route_v3_RouteConfiguration_clear_ignore_port_in_host_matching(const envoy_config_route_v3_RouteConfiguration* msg) {
184 *UPB_PTR_AT(msg, UPB_SIZE(2, 2), bool) = 0;
185 }
186 UPB_INLINE bool envoy_config_route_v3_RouteConfiguration_ignore_port_in_host_matching(const envoy_config_route_v3_RouteConfiguration* msg) {
187 return *UPB_PTR_AT(msg, UPB_SIZE(2, 2), bool);
188 }
189 UPB_INLINE void envoy_config_route_v3_RouteConfiguration_clear_ignore_path_parameters_in_path_matching(const envoy_config_route_v3_RouteConfiguration* msg) {
190 *UPB_PTR_AT(msg, UPB_SIZE(3, 3), bool) = 0;
191 }
192 UPB_INLINE bool envoy_config_route_v3_RouteConfiguration_ignore_path_parameters_in_path_matching(const envoy_config_route_v3_RouteConfiguration* msg) {
193 return *UPB_PTR_AT(msg, UPB_SIZE(3, 3), bool);
194 }
195
196 UPB_INLINE void envoy_config_route_v3_RouteConfiguration_set_name(envoy_config_route_v3_RouteConfiguration *msg, upb_StringView value) {
197 *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_StringView) = value;
198 }
199 UPB_INLINE struct envoy_config_route_v3_VirtualHost** envoy_config_route_v3_RouteConfiguration_mutable_virtual_hosts(envoy_config_route_v3_RouteConfiguration* msg, size_t* len) {
200 return (struct envoy_config_route_v3_VirtualHost**)_upb_array_mutable_accessor(msg, UPB_SIZE(12, 24), len);
201 }
202 UPB_INLINE struct envoy_config_route_v3_VirtualHost** envoy_config_route_v3_RouteConfiguration_resize_virtual_hosts(envoy_config_route_v3_RouteConfiguration* msg, size_t len, upb_Arena* arena) {
203 return (struct envoy_config_route_v3_VirtualHost**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(12, 24), len, UPB_SIZE(2, 3), arena);
204 }
205 UPB_INLINE struct envoy_config_route_v3_VirtualHost* envoy_config_route_v3_RouteConfiguration_add_virtual_hosts(envoy_config_route_v3_RouteConfiguration* msg, upb_Arena* arena) {
206 struct envoy_config_route_v3_VirtualHost* sub = (struct envoy_config_route_v3_VirtualHost*)_upb_Message_New(&envoy_config_route_v3_VirtualHost_msginit, arena);
207 bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(12, 24), UPB_SIZE(2, 3), &sub, arena);
208 if (!ok) return NULL;
209 return sub;
210 }
211 UPB_INLINE upb_StringView* envoy_config_route_v3_RouteConfiguration_mutable_internal_only_headers(envoy_config_route_v3_RouteConfiguration* msg, size_t* len) {
212 return (upb_StringView*)_upb_array_mutable_accessor(msg, UPB_SIZE(16, 32), len);
213 }
214 UPB_INLINE upb_StringView* envoy_config_route_v3_RouteConfiguration_resize_internal_only_headers(envoy_config_route_v3_RouteConfiguration* msg, size_t len, upb_Arena* arena) {
215 return (upb_StringView*)_upb_Array_Resize_accessor2(msg, UPB_SIZE(16, 32), len, UPB_SIZE(3, 4), arena);
216 }
217 UPB_INLINE bool envoy_config_route_v3_RouteConfiguration_add_internal_only_headers(envoy_config_route_v3_RouteConfiguration* msg, upb_StringView val, upb_Arena* arena) {
218 return _upb_Array_Append_accessor2(msg, UPB_SIZE(16, 32), UPB_SIZE(3, 4), &val, arena);
219 }
220 UPB_INLINE struct envoy_config_core_v3_HeaderValueOption** envoy_config_route_v3_RouteConfiguration_mutable_response_headers_to_add(envoy_config_route_v3_RouteConfiguration* msg, size_t* len) {
221 return (struct envoy_config_core_v3_HeaderValueOption**)_upb_array_mutable_accessor(msg, UPB_SIZE(20, 40), len);
222 }
223 UPB_INLINE struct envoy_config_core_v3_HeaderValueOption** envoy_config_route_v3_RouteConfiguration_resize_response_headers_to_add(envoy_config_route_v3_RouteConfiguration* msg, size_t len, upb_Arena* arena) {
224 return (struct envoy_config_core_v3_HeaderValueOption**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(20, 40), len, UPB_SIZE(2, 3), arena);
225 }
226 UPB_INLINE struct envoy_config_core_v3_HeaderValueOption* envoy_config_route_v3_RouteConfiguration_add_response_headers_to_add(envoy_config_route_v3_RouteConfiguration* msg, upb_Arena* arena) {
227 struct envoy_config_core_v3_HeaderValueOption* sub = (struct envoy_config_core_v3_HeaderValueOption*)_upb_Message_New(&envoy_config_core_v3_HeaderValueOption_msginit, arena);
228 bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(20, 40), UPB_SIZE(2, 3), &sub, arena);
229 if (!ok) return NULL;
230 return sub;
231 }
232 UPB_INLINE upb_StringView* envoy_config_route_v3_RouteConfiguration_mutable_response_headers_to_remove(envoy_config_route_v3_RouteConfiguration* msg, size_t* len) {
233 return (upb_StringView*)_upb_array_mutable_accessor(msg, UPB_SIZE(24, 48), len);
234 }
235 UPB_INLINE upb_StringView* envoy_config_route_v3_RouteConfiguration_resize_response_headers_to_remove(envoy_config_route_v3_RouteConfiguration* msg, size_t len, upb_Arena* arena) {
236 return (upb_StringView*)_upb_Array_Resize_accessor2(msg, UPB_SIZE(24, 48), len, UPB_SIZE(3, 4), arena);
237 }
238 UPB_INLINE bool envoy_config_route_v3_RouteConfiguration_add_response_headers_to_remove(envoy_config_route_v3_RouteConfiguration* msg, upb_StringView val, upb_Arena* arena) {
239 return _upb_Array_Append_accessor2(msg, UPB_SIZE(24, 48), UPB_SIZE(3, 4), &val, arena);
240 }
241 UPB_INLINE struct envoy_config_core_v3_HeaderValueOption** envoy_config_route_v3_RouteConfiguration_mutable_request_headers_to_add(envoy_config_route_v3_RouteConfiguration* msg, size_t* len) {
242 return (struct envoy_config_core_v3_HeaderValueOption**)_upb_array_mutable_accessor(msg, UPB_SIZE(28, 56), len);
243 }
244 UPB_INLINE struct envoy_config_core_v3_HeaderValueOption** envoy_config_route_v3_RouteConfiguration_resize_request_headers_to_add(envoy_config_route_v3_RouteConfiguration* msg, size_t len, upb_Arena* arena) {
245 return (struct envoy_config_core_v3_HeaderValueOption**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(28, 56), len, UPB_SIZE(2, 3), arena);
246 }
247 UPB_INLINE struct envoy_config_core_v3_HeaderValueOption* envoy_config_route_v3_RouteConfiguration_add_request_headers_to_add(envoy_config_route_v3_RouteConfiguration* msg, upb_Arena* arena) {
248 struct envoy_config_core_v3_HeaderValueOption* sub = (struct envoy_config_core_v3_HeaderValueOption*)_upb_Message_New(&envoy_config_core_v3_HeaderValueOption_msginit, arena);
249 bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(28, 56), UPB_SIZE(2, 3), &sub, arena);
250 if (!ok) return NULL;
251 return sub;
252 }
253 UPB_INLINE void envoy_config_route_v3_RouteConfiguration_set_validate_clusters(envoy_config_route_v3_RouteConfiguration *msg, struct google_protobuf_BoolValue* value) {
254 _upb_sethas(msg, 1);
255 *UPB_PTR_AT(msg, UPB_SIZE(32, 64), struct google_protobuf_BoolValue*) = value;
256 }
257 UPB_INLINE struct google_protobuf_BoolValue* envoy_config_route_v3_RouteConfiguration_mutable_validate_clusters(envoy_config_route_v3_RouteConfiguration* msg, upb_Arena* arena) {
258 struct google_protobuf_BoolValue* sub = (struct google_protobuf_BoolValue*)envoy_config_route_v3_RouteConfiguration_validate_clusters(msg);
259 if (sub == NULL) {
260 sub = (struct google_protobuf_BoolValue*)_upb_Message_New(&google_protobuf_BoolValue_msginit, arena);
261 if (!sub) return NULL;
262 envoy_config_route_v3_RouteConfiguration_set_validate_clusters(msg, sub);
263 }
264 return sub;
265 }
266 UPB_INLINE upb_StringView* envoy_config_route_v3_RouteConfiguration_mutable_request_headers_to_remove(envoy_config_route_v3_RouteConfiguration* msg, size_t* len) {
267 return (upb_StringView*)_upb_array_mutable_accessor(msg, UPB_SIZE(36, 72), len);
268 }
269 UPB_INLINE upb_StringView* envoy_config_route_v3_RouteConfiguration_resize_request_headers_to_remove(envoy_config_route_v3_RouteConfiguration* msg, size_t len, upb_Arena* arena) {
270 return (upb_StringView*)_upb_Array_Resize_accessor2(msg, UPB_SIZE(36, 72), len, UPB_SIZE(3, 4), arena);
271 }
272 UPB_INLINE bool envoy_config_route_v3_RouteConfiguration_add_request_headers_to_remove(envoy_config_route_v3_RouteConfiguration* msg, upb_StringView val, upb_Arena* arena) {
273 return _upb_Array_Append_accessor2(msg, UPB_SIZE(36, 72), UPB_SIZE(3, 4), &val, arena);
274 }
275 UPB_INLINE void envoy_config_route_v3_RouteConfiguration_set_vhds(envoy_config_route_v3_RouteConfiguration *msg, envoy_config_route_v3_Vhds* value) {
276 _upb_sethas(msg, 2);
277 *UPB_PTR_AT(msg, UPB_SIZE(40, 80), envoy_config_route_v3_Vhds*) = value;
278 }
279 UPB_INLINE struct envoy_config_route_v3_Vhds* envoy_config_route_v3_RouteConfiguration_mutable_vhds(envoy_config_route_v3_RouteConfiguration* msg, upb_Arena* arena) {
280 struct envoy_config_route_v3_Vhds* sub = (struct envoy_config_route_v3_Vhds*)envoy_config_route_v3_RouteConfiguration_vhds(msg);
281 if (sub == NULL) {
282 sub = (struct envoy_config_route_v3_Vhds*)_upb_Message_New(&envoy_config_route_v3_Vhds_msginit, arena);
283 if (!sub) return NULL;
284 envoy_config_route_v3_RouteConfiguration_set_vhds(msg, sub);
285 }
286 return sub;
287 }
288 UPB_INLINE void envoy_config_route_v3_RouteConfiguration_set_most_specific_header_mutations_wins(envoy_config_route_v3_RouteConfiguration *msg, bool value) {
289 *UPB_PTR_AT(msg, UPB_SIZE(1, 1), bool) = value;
290 }
291 UPB_INLINE void envoy_config_route_v3_RouteConfiguration_set_max_direct_response_body_size_bytes(envoy_config_route_v3_RouteConfiguration *msg, struct google_protobuf_UInt32Value* value) {
292 _upb_sethas(msg, 3);
293 *UPB_PTR_AT(msg, UPB_SIZE(44, 88), struct google_protobuf_UInt32Value*) = value;
294 }
295 UPB_INLINE struct google_protobuf_UInt32Value* envoy_config_route_v3_RouteConfiguration_mutable_max_direct_response_body_size_bytes(envoy_config_route_v3_RouteConfiguration* msg, upb_Arena* arena) {
296 struct google_protobuf_UInt32Value* sub = (struct google_protobuf_UInt32Value*)envoy_config_route_v3_RouteConfiguration_max_direct_response_body_size_bytes(msg);
297 if (sub == NULL) {
298 sub = (struct google_protobuf_UInt32Value*)_upb_Message_New(&google_protobuf_UInt32Value_msginit, arena);
299 if (!sub) return NULL;
300 envoy_config_route_v3_RouteConfiguration_set_max_direct_response_body_size_bytes(msg, sub);
301 }
302 return sub;
303 }
304 UPB_INLINE struct envoy_config_route_v3_ClusterSpecifierPlugin** envoy_config_route_v3_RouteConfiguration_mutable_cluster_specifier_plugins(envoy_config_route_v3_RouteConfiguration* msg, size_t* len) {
305 return (struct envoy_config_route_v3_ClusterSpecifierPlugin**)_upb_array_mutable_accessor(msg, UPB_SIZE(48, 96), len);
306 }
307 UPB_INLINE struct envoy_config_route_v3_ClusterSpecifierPlugin** envoy_config_route_v3_RouteConfiguration_resize_cluster_specifier_plugins(envoy_config_route_v3_RouteConfiguration* msg, size_t len, upb_Arena* arena) {
308 return (struct envoy_config_route_v3_ClusterSpecifierPlugin**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(48, 96), len, UPB_SIZE(2, 3), arena);
309 }
310 UPB_INLINE struct envoy_config_route_v3_ClusterSpecifierPlugin* envoy_config_route_v3_RouteConfiguration_add_cluster_specifier_plugins(envoy_config_route_v3_RouteConfiguration* msg, upb_Arena* arena) {
311 struct envoy_config_route_v3_ClusterSpecifierPlugin* sub = (struct envoy_config_route_v3_ClusterSpecifierPlugin*)_upb_Message_New(&envoy_config_route_v3_ClusterSpecifierPlugin_msginit, arena);
312 bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(48, 96), UPB_SIZE(2, 3), &sub, arena);
313 if (!ok) return NULL;
314 return sub;
315 }
316 UPB_INLINE struct envoy_config_route_v3_RouteAction_RequestMirrorPolicy** envoy_config_route_v3_RouteConfiguration_mutable_request_mirror_policies(envoy_config_route_v3_RouteConfiguration* msg, size_t* len) {
317 return (struct envoy_config_route_v3_RouteAction_RequestMirrorPolicy**)_upb_array_mutable_accessor(msg, UPB_SIZE(52, 104), len);
318 }
319 UPB_INLINE struct envoy_config_route_v3_RouteAction_RequestMirrorPolicy** envoy_config_route_v3_RouteConfiguration_resize_request_mirror_policies(envoy_config_route_v3_RouteConfiguration* msg, size_t len, upb_Arena* arena) {
320 return (struct envoy_config_route_v3_RouteAction_RequestMirrorPolicy**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(52, 104), len, UPB_SIZE(2, 3), arena);
321 }
322 UPB_INLINE struct envoy_config_route_v3_RouteAction_RequestMirrorPolicy* envoy_config_route_v3_RouteConfiguration_add_request_mirror_policies(envoy_config_route_v3_RouteConfiguration* msg, upb_Arena* arena) {
323 struct envoy_config_route_v3_RouteAction_RequestMirrorPolicy* sub = (struct envoy_config_route_v3_RouteAction_RequestMirrorPolicy*)_upb_Message_New(&envoy_config_route_v3_RouteAction_RequestMirrorPolicy_msginit, arena);
324 bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(52, 104), UPB_SIZE(2, 3), &sub, arena);
325 if (!ok) return NULL;
326 return sub;
327 }
328 UPB_INLINE void envoy_config_route_v3_RouteConfiguration_set_ignore_port_in_host_matching(envoy_config_route_v3_RouteConfiguration *msg, bool value) {
329 *UPB_PTR_AT(msg, UPB_SIZE(2, 2), bool) = value;
330 }
331 UPB_INLINE void envoy_config_route_v3_RouteConfiguration_set_ignore_path_parameters_in_path_matching(envoy_config_route_v3_RouteConfiguration *msg, bool value) {
332 *UPB_PTR_AT(msg, UPB_SIZE(3, 3), bool) = value;
333 }
334
335 /* envoy.config.route.v3.Vhds */
336
337 UPB_INLINE envoy_config_route_v3_Vhds* envoy_config_route_v3_Vhds_new(upb_Arena* arena) {
338 return (envoy_config_route_v3_Vhds*)_upb_Message_New(&envoy_config_route_v3_Vhds_msginit, arena);
339 }
340 UPB_INLINE envoy_config_route_v3_Vhds* envoy_config_route_v3_Vhds_parse(const char* buf, size_t size, upb_Arena* arena) {
341 envoy_config_route_v3_Vhds* ret = envoy_config_route_v3_Vhds_new(arena);
342 if (!ret) return NULL;
343 if (upb_Decode(buf, size, ret, &envoy_config_route_v3_Vhds_msginit, NULL, 0, arena) != kUpb_DecodeStatus_Ok) {
344 return NULL;
345 }
346 return ret;
347 }
348 UPB_INLINE envoy_config_route_v3_Vhds* envoy_config_route_v3_Vhds_parse_ex(const char* buf, size_t size,
349 const upb_ExtensionRegistry* extreg,
350 int options, upb_Arena* arena) {
351 envoy_config_route_v3_Vhds* ret = envoy_config_route_v3_Vhds_new(arena);
352 if (!ret) return NULL;
353 if (upb_Decode(buf, size, ret, &envoy_config_route_v3_Vhds_msginit, extreg, options, arena) !=
354 kUpb_DecodeStatus_Ok) {
355 return NULL;
356 }
357 return ret;
358 }
359 UPB_INLINE char* envoy_config_route_v3_Vhds_serialize(const envoy_config_route_v3_Vhds* msg, upb_Arena* arena, size_t* len) {
360 char* ptr;
361 (void)upb_Encode(msg, &envoy_config_route_v3_Vhds_msginit, 0, arena, &ptr, len);
362 return ptr;
363 }
364 UPB_INLINE char* envoy_config_route_v3_Vhds_serialize_ex(const envoy_config_route_v3_Vhds* msg, int options,
365 upb_Arena* arena, size_t* len) {
366 char* ptr;
367 (void)upb_Encode(msg, &envoy_config_route_v3_Vhds_msginit, options, arena, &ptr, len);
368 return ptr;
369 }
370 UPB_INLINE bool envoy_config_route_v3_Vhds_has_config_source(const envoy_config_route_v3_Vhds* msg) {
371 return _upb_hasbit(msg, 1);
372 }
373 UPB_INLINE void envoy_config_route_v3_Vhds_clear_config_source(const envoy_config_route_v3_Vhds* msg) {
374 *UPB_PTR_AT(msg, UPB_SIZE(4, 8), const upb_Message*) = NULL;
375 }
376 UPB_INLINE const struct envoy_config_core_v3_ConfigSource* envoy_config_route_v3_Vhds_config_source(const envoy_config_route_v3_Vhds* msg) {
377 return *UPB_PTR_AT(msg, UPB_SIZE(4, 8), const struct envoy_config_core_v3_ConfigSource*);
378 }
379
380 UPB_INLINE void envoy_config_route_v3_Vhds_set_config_source(envoy_config_route_v3_Vhds *msg, struct envoy_config_core_v3_ConfigSource* value) {
381 _upb_sethas(msg, 1);
382 *UPB_PTR_AT(msg, UPB_SIZE(4, 8), struct envoy_config_core_v3_ConfigSource*) = value;
383 }
384 UPB_INLINE struct envoy_config_core_v3_ConfigSource* envoy_config_route_v3_Vhds_mutable_config_source(envoy_config_route_v3_Vhds* msg, upb_Arena* arena) {
385 struct envoy_config_core_v3_ConfigSource* sub = (struct envoy_config_core_v3_ConfigSource*)envoy_config_route_v3_Vhds_config_source(msg);
386 if (sub == NULL) {
387 sub = (struct envoy_config_core_v3_ConfigSource*)_upb_Message_New(&envoy_config_core_v3_ConfigSource_msginit, arena);
388 if (!sub) return NULL;
389 envoy_config_route_v3_Vhds_set_config_source(msg, sub);
390 }
391 return sub;
392 }
393
394 extern const upb_MiniTable_File envoy_config_route_v3_route_proto_upb_file_layout;
395
396 #ifdef __cplusplus
397 } /* extern "C" */
398 #endif
399
400 #include "upb/port_undef.inc"
401
402 #endif /* ENVOY_CONFIG_ROUTE_V3_ROUTE_PROTO_UPB_H_ */