• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /* This file was generated by upbc (the upb compiler) from the input
2  * file:
3  *
4  *     envoy/service/discovery/v3/discovery.proto
5  *
6  * Do not edit -- your changes will be discarded when the file is
7  * regenerated. */
8 
9 #ifndef ENVOY_SERVICE_DISCOVERY_V3_DISCOVERY_PROTO_UPB_H_
10 #define ENVOY_SERVICE_DISCOVERY_V3_DISCOVERY_PROTO_UPB_H_
11 
12 #include "upb/msg.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_service_discovery_v3_DiscoveryRequest;
24 struct envoy_service_discovery_v3_DiscoveryResponse;
25 struct envoy_service_discovery_v3_DeltaDiscoveryRequest;
26 struct envoy_service_discovery_v3_DeltaDiscoveryRequest_InitialResourceVersionsEntry;
27 struct envoy_service_discovery_v3_DeltaDiscoveryResponse;
28 struct envoy_service_discovery_v3_Resource;
29 struct envoy_service_discovery_v3_Resource_CacheControl;
30 typedef struct envoy_service_discovery_v3_DiscoveryRequest envoy_service_discovery_v3_DiscoveryRequest;
31 typedef struct envoy_service_discovery_v3_DiscoveryResponse envoy_service_discovery_v3_DiscoveryResponse;
32 typedef struct envoy_service_discovery_v3_DeltaDiscoveryRequest envoy_service_discovery_v3_DeltaDiscoveryRequest;
33 typedef struct envoy_service_discovery_v3_DeltaDiscoveryRequest_InitialResourceVersionsEntry envoy_service_discovery_v3_DeltaDiscoveryRequest_InitialResourceVersionsEntry;
34 typedef struct envoy_service_discovery_v3_DeltaDiscoveryResponse envoy_service_discovery_v3_DeltaDiscoveryResponse;
35 typedef struct envoy_service_discovery_v3_Resource envoy_service_discovery_v3_Resource;
36 typedef struct envoy_service_discovery_v3_Resource_CacheControl envoy_service_discovery_v3_Resource_CacheControl;
37 extern const upb_msglayout envoy_service_discovery_v3_DiscoveryRequest_msginit;
38 extern const upb_msglayout envoy_service_discovery_v3_DiscoveryResponse_msginit;
39 extern const upb_msglayout envoy_service_discovery_v3_DeltaDiscoveryRequest_msginit;
40 extern const upb_msglayout envoy_service_discovery_v3_DeltaDiscoveryRequest_InitialResourceVersionsEntry_msginit;
41 extern const upb_msglayout envoy_service_discovery_v3_DeltaDiscoveryResponse_msginit;
42 extern const upb_msglayout envoy_service_discovery_v3_Resource_msginit;
43 extern const upb_msglayout envoy_service_discovery_v3_Resource_CacheControl_msginit;
44 struct envoy_config_core_v3_ControlPlane;
45 struct envoy_config_core_v3_Node;
46 struct google_protobuf_Any;
47 struct google_protobuf_Duration;
48 struct google_rpc_Status;
49 extern const upb_msglayout envoy_config_core_v3_ControlPlane_msginit;
50 extern const upb_msglayout envoy_config_core_v3_Node_msginit;
51 extern const upb_msglayout google_protobuf_Any_msginit;
52 extern const upb_msglayout google_protobuf_Duration_msginit;
53 extern const upb_msglayout google_rpc_Status_msginit;
54 
55 
56 /* envoy.service.discovery.v3.DiscoveryRequest */
57 
envoy_service_discovery_v3_DiscoveryRequest_new(upb_arena * arena)58 UPB_INLINE envoy_service_discovery_v3_DiscoveryRequest *envoy_service_discovery_v3_DiscoveryRequest_new(upb_arena *arena) {
59   return (envoy_service_discovery_v3_DiscoveryRequest *)_upb_msg_new(&envoy_service_discovery_v3_DiscoveryRequest_msginit, arena);
60 }
envoy_service_discovery_v3_DiscoveryRequest_parse(const char * buf,size_t size,upb_arena * arena)61 UPB_INLINE envoy_service_discovery_v3_DiscoveryRequest *envoy_service_discovery_v3_DiscoveryRequest_parse(const char *buf, size_t size,
62                         upb_arena *arena) {
63   envoy_service_discovery_v3_DiscoveryRequest *ret = envoy_service_discovery_v3_DiscoveryRequest_new(arena);
64   return (ret && upb_decode(buf, size, ret, &envoy_service_discovery_v3_DiscoveryRequest_msginit, arena)) ? ret : NULL;
65 }
envoy_service_discovery_v3_DiscoveryRequest_parse_ex(const char * buf,size_t size,upb_arena * arena,int options)66 UPB_INLINE envoy_service_discovery_v3_DiscoveryRequest *envoy_service_discovery_v3_DiscoveryRequest_parse_ex(const char *buf, size_t size,
67                            upb_arena *arena, int options) {
68   envoy_service_discovery_v3_DiscoveryRequest *ret = envoy_service_discovery_v3_DiscoveryRequest_new(arena);
69   return (ret && _upb_decode(buf, size, ret, &envoy_service_discovery_v3_DiscoveryRequest_msginit, arena, options))
70       ? ret : NULL;
71 }
envoy_service_discovery_v3_DiscoveryRequest_serialize(const envoy_service_discovery_v3_DiscoveryRequest * msg,upb_arena * arena,size_t * len)72 UPB_INLINE char *envoy_service_discovery_v3_DiscoveryRequest_serialize(const envoy_service_discovery_v3_DiscoveryRequest *msg, upb_arena *arena, size_t *len) {
73   return upb_encode(msg, &envoy_service_discovery_v3_DiscoveryRequest_msginit, arena, len);
74 }
75 
envoy_service_discovery_v3_DiscoveryRequest_version_info(const envoy_service_discovery_v3_DiscoveryRequest * msg)76 UPB_INLINE upb_strview envoy_service_discovery_v3_DiscoveryRequest_version_info(const envoy_service_discovery_v3_DiscoveryRequest *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_strview); }
envoy_service_discovery_v3_DiscoveryRequest_has_node(const envoy_service_discovery_v3_DiscoveryRequest * msg)77 UPB_INLINE bool envoy_service_discovery_v3_DiscoveryRequest_has_node(const envoy_service_discovery_v3_DiscoveryRequest *msg) { return _upb_hasbit(msg, 1); }
envoy_service_discovery_v3_DiscoveryRequest_node(const envoy_service_discovery_v3_DiscoveryRequest * msg)78 UPB_INLINE const struct envoy_config_core_v3_Node* envoy_service_discovery_v3_DiscoveryRequest_node(const envoy_service_discovery_v3_DiscoveryRequest *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(28, 56), const struct envoy_config_core_v3_Node*); }
envoy_service_discovery_v3_DiscoveryRequest_resource_names(const envoy_service_discovery_v3_DiscoveryRequest * msg,size_t * len)79 UPB_INLINE upb_strview const* envoy_service_discovery_v3_DiscoveryRequest_resource_names(const envoy_service_discovery_v3_DiscoveryRequest *msg, size_t *len) { return (upb_strview const*)_upb_array_accessor(msg, UPB_SIZE(36, 72), len); }
envoy_service_discovery_v3_DiscoveryRequest_type_url(const envoy_service_discovery_v3_DiscoveryRequest * msg)80 UPB_INLINE upb_strview envoy_service_discovery_v3_DiscoveryRequest_type_url(const envoy_service_discovery_v3_DiscoveryRequest *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(12, 24), upb_strview); }
envoy_service_discovery_v3_DiscoveryRequest_response_nonce(const envoy_service_discovery_v3_DiscoveryRequest * msg)81 UPB_INLINE upb_strview envoy_service_discovery_v3_DiscoveryRequest_response_nonce(const envoy_service_discovery_v3_DiscoveryRequest *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(20, 40), upb_strview); }
envoy_service_discovery_v3_DiscoveryRequest_has_error_detail(const envoy_service_discovery_v3_DiscoveryRequest * msg)82 UPB_INLINE bool envoy_service_discovery_v3_DiscoveryRequest_has_error_detail(const envoy_service_discovery_v3_DiscoveryRequest *msg) { return _upb_hasbit(msg, 2); }
envoy_service_discovery_v3_DiscoveryRequest_error_detail(const envoy_service_discovery_v3_DiscoveryRequest * msg)83 UPB_INLINE const struct google_rpc_Status* envoy_service_discovery_v3_DiscoveryRequest_error_detail(const envoy_service_discovery_v3_DiscoveryRequest *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(32, 64), const struct google_rpc_Status*); }
84 
envoy_service_discovery_v3_DiscoveryRequest_set_version_info(envoy_service_discovery_v3_DiscoveryRequest * msg,upb_strview value)85 UPB_INLINE void envoy_service_discovery_v3_DiscoveryRequest_set_version_info(envoy_service_discovery_v3_DiscoveryRequest *msg, upb_strview value) {
86   *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_strview) = value;
87 }
envoy_service_discovery_v3_DiscoveryRequest_set_node(envoy_service_discovery_v3_DiscoveryRequest * msg,struct envoy_config_core_v3_Node * value)88 UPB_INLINE void envoy_service_discovery_v3_DiscoveryRequest_set_node(envoy_service_discovery_v3_DiscoveryRequest *msg, struct envoy_config_core_v3_Node* value) {
89   _upb_sethas(msg, 1);
90   *UPB_PTR_AT(msg, UPB_SIZE(28, 56), struct envoy_config_core_v3_Node*) = value;
91 }
envoy_service_discovery_v3_DiscoveryRequest_mutable_node(envoy_service_discovery_v3_DiscoveryRequest * msg,upb_arena * arena)92 UPB_INLINE struct envoy_config_core_v3_Node* envoy_service_discovery_v3_DiscoveryRequest_mutable_node(envoy_service_discovery_v3_DiscoveryRequest *msg, upb_arena *arena) {
93   struct envoy_config_core_v3_Node* sub = (struct envoy_config_core_v3_Node*)envoy_service_discovery_v3_DiscoveryRequest_node(msg);
94   if (sub == NULL) {
95     sub = (struct envoy_config_core_v3_Node*)_upb_msg_new(&envoy_config_core_v3_Node_msginit, arena);
96     if (!sub) return NULL;
97     envoy_service_discovery_v3_DiscoveryRequest_set_node(msg, sub);
98   }
99   return sub;
100 }
envoy_service_discovery_v3_DiscoveryRequest_mutable_resource_names(envoy_service_discovery_v3_DiscoveryRequest * msg,size_t * len)101 UPB_INLINE upb_strview* envoy_service_discovery_v3_DiscoveryRequest_mutable_resource_names(envoy_service_discovery_v3_DiscoveryRequest *msg, size_t *len) {
102   return (upb_strview*)_upb_array_mutable_accessor(msg, UPB_SIZE(36, 72), len);
103 }
envoy_service_discovery_v3_DiscoveryRequest_resize_resource_names(envoy_service_discovery_v3_DiscoveryRequest * msg,size_t len,upb_arena * arena)104 UPB_INLINE upb_strview* envoy_service_discovery_v3_DiscoveryRequest_resize_resource_names(envoy_service_discovery_v3_DiscoveryRequest *msg, size_t len, upb_arena *arena) {
105   return (upb_strview*)_upb_array_resize_accessor2(msg, UPB_SIZE(36, 72), len, UPB_SIZE(3, 4), arena);
106 }
envoy_service_discovery_v3_DiscoveryRequest_add_resource_names(envoy_service_discovery_v3_DiscoveryRequest * msg,upb_strview val,upb_arena * arena)107 UPB_INLINE bool envoy_service_discovery_v3_DiscoveryRequest_add_resource_names(envoy_service_discovery_v3_DiscoveryRequest *msg, upb_strview val, upb_arena *arena) {
108   return _upb_array_append_accessor2(msg, UPB_SIZE(36, 72), UPB_SIZE(3, 4), &val,
109       arena);
110 }
envoy_service_discovery_v3_DiscoveryRequest_set_type_url(envoy_service_discovery_v3_DiscoveryRequest * msg,upb_strview value)111 UPB_INLINE void envoy_service_discovery_v3_DiscoveryRequest_set_type_url(envoy_service_discovery_v3_DiscoveryRequest *msg, upb_strview value) {
112   *UPB_PTR_AT(msg, UPB_SIZE(12, 24), upb_strview) = value;
113 }
envoy_service_discovery_v3_DiscoveryRequest_set_response_nonce(envoy_service_discovery_v3_DiscoveryRequest * msg,upb_strview value)114 UPB_INLINE void envoy_service_discovery_v3_DiscoveryRequest_set_response_nonce(envoy_service_discovery_v3_DiscoveryRequest *msg, upb_strview value) {
115   *UPB_PTR_AT(msg, UPB_SIZE(20, 40), upb_strview) = value;
116 }
envoy_service_discovery_v3_DiscoveryRequest_set_error_detail(envoy_service_discovery_v3_DiscoveryRequest * msg,struct google_rpc_Status * value)117 UPB_INLINE void envoy_service_discovery_v3_DiscoveryRequest_set_error_detail(envoy_service_discovery_v3_DiscoveryRequest *msg, struct google_rpc_Status* value) {
118   _upb_sethas(msg, 2);
119   *UPB_PTR_AT(msg, UPB_SIZE(32, 64), struct google_rpc_Status*) = value;
120 }
envoy_service_discovery_v3_DiscoveryRequest_mutable_error_detail(envoy_service_discovery_v3_DiscoveryRequest * msg,upb_arena * arena)121 UPB_INLINE struct google_rpc_Status* envoy_service_discovery_v3_DiscoveryRequest_mutable_error_detail(envoy_service_discovery_v3_DiscoveryRequest *msg, upb_arena *arena) {
122   struct google_rpc_Status* sub = (struct google_rpc_Status*)envoy_service_discovery_v3_DiscoveryRequest_error_detail(msg);
123   if (sub == NULL) {
124     sub = (struct google_rpc_Status*)_upb_msg_new(&google_rpc_Status_msginit, arena);
125     if (!sub) return NULL;
126     envoy_service_discovery_v3_DiscoveryRequest_set_error_detail(msg, sub);
127   }
128   return sub;
129 }
130 
131 /* envoy.service.discovery.v3.DiscoveryResponse */
132 
envoy_service_discovery_v3_DiscoveryResponse_new(upb_arena * arena)133 UPB_INLINE envoy_service_discovery_v3_DiscoveryResponse *envoy_service_discovery_v3_DiscoveryResponse_new(upb_arena *arena) {
134   return (envoy_service_discovery_v3_DiscoveryResponse *)_upb_msg_new(&envoy_service_discovery_v3_DiscoveryResponse_msginit, arena);
135 }
envoy_service_discovery_v3_DiscoveryResponse_parse(const char * buf,size_t size,upb_arena * arena)136 UPB_INLINE envoy_service_discovery_v3_DiscoveryResponse *envoy_service_discovery_v3_DiscoveryResponse_parse(const char *buf, size_t size,
137                         upb_arena *arena) {
138   envoy_service_discovery_v3_DiscoveryResponse *ret = envoy_service_discovery_v3_DiscoveryResponse_new(arena);
139   return (ret && upb_decode(buf, size, ret, &envoy_service_discovery_v3_DiscoveryResponse_msginit, arena)) ? ret : NULL;
140 }
envoy_service_discovery_v3_DiscoveryResponse_parse_ex(const char * buf,size_t size,upb_arena * arena,int options)141 UPB_INLINE envoy_service_discovery_v3_DiscoveryResponse *envoy_service_discovery_v3_DiscoveryResponse_parse_ex(const char *buf, size_t size,
142                            upb_arena *arena, int options) {
143   envoy_service_discovery_v3_DiscoveryResponse *ret = envoy_service_discovery_v3_DiscoveryResponse_new(arena);
144   return (ret && _upb_decode(buf, size, ret, &envoy_service_discovery_v3_DiscoveryResponse_msginit, arena, options))
145       ? ret : NULL;
146 }
envoy_service_discovery_v3_DiscoveryResponse_serialize(const envoy_service_discovery_v3_DiscoveryResponse * msg,upb_arena * arena,size_t * len)147 UPB_INLINE char *envoy_service_discovery_v3_DiscoveryResponse_serialize(const envoy_service_discovery_v3_DiscoveryResponse *msg, upb_arena *arena, size_t *len) {
148   return upb_encode(msg, &envoy_service_discovery_v3_DiscoveryResponse_msginit, arena, len);
149 }
150 
envoy_service_discovery_v3_DiscoveryResponse_version_info(const envoy_service_discovery_v3_DiscoveryResponse * msg)151 UPB_INLINE upb_strview envoy_service_discovery_v3_DiscoveryResponse_version_info(const envoy_service_discovery_v3_DiscoveryResponse *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_strview); }
envoy_service_discovery_v3_DiscoveryResponse_has_resources(const envoy_service_discovery_v3_DiscoveryResponse * msg)152 UPB_INLINE bool envoy_service_discovery_v3_DiscoveryResponse_has_resources(const envoy_service_discovery_v3_DiscoveryResponse *msg) { return _upb_has_submsg_nohasbit(msg, UPB_SIZE(32, 64)); }
envoy_service_discovery_v3_DiscoveryResponse_resources(const envoy_service_discovery_v3_DiscoveryResponse * msg,size_t * len)153 UPB_INLINE const struct google_protobuf_Any* const* envoy_service_discovery_v3_DiscoveryResponse_resources(const envoy_service_discovery_v3_DiscoveryResponse *msg, size_t *len) { return (const struct google_protobuf_Any* const*)_upb_array_accessor(msg, UPB_SIZE(32, 64), len); }
envoy_service_discovery_v3_DiscoveryResponse_canary(const envoy_service_discovery_v3_DiscoveryResponse * msg)154 UPB_INLINE bool envoy_service_discovery_v3_DiscoveryResponse_canary(const envoy_service_discovery_v3_DiscoveryResponse *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(1, 1), bool); }
envoy_service_discovery_v3_DiscoveryResponse_type_url(const envoy_service_discovery_v3_DiscoveryResponse * msg)155 UPB_INLINE upb_strview envoy_service_discovery_v3_DiscoveryResponse_type_url(const envoy_service_discovery_v3_DiscoveryResponse *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(12, 24), upb_strview); }
envoy_service_discovery_v3_DiscoveryResponse_nonce(const envoy_service_discovery_v3_DiscoveryResponse * msg)156 UPB_INLINE upb_strview envoy_service_discovery_v3_DiscoveryResponse_nonce(const envoy_service_discovery_v3_DiscoveryResponse *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(20, 40), upb_strview); }
envoy_service_discovery_v3_DiscoveryResponse_has_control_plane(const envoy_service_discovery_v3_DiscoveryResponse * msg)157 UPB_INLINE bool envoy_service_discovery_v3_DiscoveryResponse_has_control_plane(const envoy_service_discovery_v3_DiscoveryResponse *msg) { return _upb_hasbit(msg, 1); }
envoy_service_discovery_v3_DiscoveryResponse_control_plane(const envoy_service_discovery_v3_DiscoveryResponse * msg)158 UPB_INLINE const struct envoy_config_core_v3_ControlPlane* envoy_service_discovery_v3_DiscoveryResponse_control_plane(const envoy_service_discovery_v3_DiscoveryResponse *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(28, 56), const struct envoy_config_core_v3_ControlPlane*); }
159 
envoy_service_discovery_v3_DiscoveryResponse_set_version_info(envoy_service_discovery_v3_DiscoveryResponse * msg,upb_strview value)160 UPB_INLINE void envoy_service_discovery_v3_DiscoveryResponse_set_version_info(envoy_service_discovery_v3_DiscoveryResponse *msg, upb_strview value) {
161   *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_strview) = value;
162 }
envoy_service_discovery_v3_DiscoveryResponse_mutable_resources(envoy_service_discovery_v3_DiscoveryResponse * msg,size_t * len)163 UPB_INLINE struct google_protobuf_Any** envoy_service_discovery_v3_DiscoveryResponse_mutable_resources(envoy_service_discovery_v3_DiscoveryResponse *msg, size_t *len) {
164   return (struct google_protobuf_Any**)_upb_array_mutable_accessor(msg, UPB_SIZE(32, 64), len);
165 }
envoy_service_discovery_v3_DiscoveryResponse_resize_resources(envoy_service_discovery_v3_DiscoveryResponse * msg,size_t len,upb_arena * arena)166 UPB_INLINE struct google_protobuf_Any** envoy_service_discovery_v3_DiscoveryResponse_resize_resources(envoy_service_discovery_v3_DiscoveryResponse *msg, size_t len, upb_arena *arena) {
167   return (struct google_protobuf_Any**)_upb_array_resize_accessor2(msg, UPB_SIZE(32, 64), len, UPB_SIZE(2, 3), arena);
168 }
envoy_service_discovery_v3_DiscoveryResponse_add_resources(envoy_service_discovery_v3_DiscoveryResponse * msg,upb_arena * arena)169 UPB_INLINE struct google_protobuf_Any* envoy_service_discovery_v3_DiscoveryResponse_add_resources(envoy_service_discovery_v3_DiscoveryResponse *msg, upb_arena *arena) {
170   struct google_protobuf_Any* sub = (struct google_protobuf_Any*)_upb_msg_new(&google_protobuf_Any_msginit, arena);
171   bool ok = _upb_array_append_accessor2(
172       msg, UPB_SIZE(32, 64), UPB_SIZE(2, 3), &sub, arena);
173   if (!ok) return NULL;
174   return sub;
175 }
envoy_service_discovery_v3_DiscoveryResponse_set_canary(envoy_service_discovery_v3_DiscoveryResponse * msg,bool value)176 UPB_INLINE void envoy_service_discovery_v3_DiscoveryResponse_set_canary(envoy_service_discovery_v3_DiscoveryResponse *msg, bool value) {
177   *UPB_PTR_AT(msg, UPB_SIZE(1, 1), bool) = value;
178 }
envoy_service_discovery_v3_DiscoveryResponse_set_type_url(envoy_service_discovery_v3_DiscoveryResponse * msg,upb_strview value)179 UPB_INLINE void envoy_service_discovery_v3_DiscoveryResponse_set_type_url(envoy_service_discovery_v3_DiscoveryResponse *msg, upb_strview value) {
180   *UPB_PTR_AT(msg, UPB_SIZE(12, 24), upb_strview) = value;
181 }
envoy_service_discovery_v3_DiscoveryResponse_set_nonce(envoy_service_discovery_v3_DiscoveryResponse * msg,upb_strview value)182 UPB_INLINE void envoy_service_discovery_v3_DiscoveryResponse_set_nonce(envoy_service_discovery_v3_DiscoveryResponse *msg, upb_strview value) {
183   *UPB_PTR_AT(msg, UPB_SIZE(20, 40), upb_strview) = value;
184 }
envoy_service_discovery_v3_DiscoveryResponse_set_control_plane(envoy_service_discovery_v3_DiscoveryResponse * msg,struct envoy_config_core_v3_ControlPlane * value)185 UPB_INLINE void envoy_service_discovery_v3_DiscoveryResponse_set_control_plane(envoy_service_discovery_v3_DiscoveryResponse *msg, struct envoy_config_core_v3_ControlPlane* value) {
186   _upb_sethas(msg, 1);
187   *UPB_PTR_AT(msg, UPB_SIZE(28, 56), struct envoy_config_core_v3_ControlPlane*) = value;
188 }
envoy_service_discovery_v3_DiscoveryResponse_mutable_control_plane(envoy_service_discovery_v3_DiscoveryResponse * msg,upb_arena * arena)189 UPB_INLINE struct envoy_config_core_v3_ControlPlane* envoy_service_discovery_v3_DiscoveryResponse_mutable_control_plane(envoy_service_discovery_v3_DiscoveryResponse *msg, upb_arena *arena) {
190   struct envoy_config_core_v3_ControlPlane* sub = (struct envoy_config_core_v3_ControlPlane*)envoy_service_discovery_v3_DiscoveryResponse_control_plane(msg);
191   if (sub == NULL) {
192     sub = (struct envoy_config_core_v3_ControlPlane*)_upb_msg_new(&envoy_config_core_v3_ControlPlane_msginit, arena);
193     if (!sub) return NULL;
194     envoy_service_discovery_v3_DiscoveryResponse_set_control_plane(msg, sub);
195   }
196   return sub;
197 }
198 
199 /* envoy.service.discovery.v3.DeltaDiscoveryRequest */
200 
envoy_service_discovery_v3_DeltaDiscoveryRequest_new(upb_arena * arena)201 UPB_INLINE envoy_service_discovery_v3_DeltaDiscoveryRequest *envoy_service_discovery_v3_DeltaDiscoveryRequest_new(upb_arena *arena) {
202   return (envoy_service_discovery_v3_DeltaDiscoveryRequest *)_upb_msg_new(&envoy_service_discovery_v3_DeltaDiscoveryRequest_msginit, arena);
203 }
envoy_service_discovery_v3_DeltaDiscoveryRequest_parse(const char * buf,size_t size,upb_arena * arena)204 UPB_INLINE envoy_service_discovery_v3_DeltaDiscoveryRequest *envoy_service_discovery_v3_DeltaDiscoveryRequest_parse(const char *buf, size_t size,
205                         upb_arena *arena) {
206   envoy_service_discovery_v3_DeltaDiscoveryRequest *ret = envoy_service_discovery_v3_DeltaDiscoveryRequest_new(arena);
207   return (ret && upb_decode(buf, size, ret, &envoy_service_discovery_v3_DeltaDiscoveryRequest_msginit, arena)) ? ret : NULL;
208 }
envoy_service_discovery_v3_DeltaDiscoveryRequest_parse_ex(const char * buf,size_t size,upb_arena * arena,int options)209 UPB_INLINE envoy_service_discovery_v3_DeltaDiscoveryRequest *envoy_service_discovery_v3_DeltaDiscoveryRequest_parse_ex(const char *buf, size_t size,
210                            upb_arena *arena, int options) {
211   envoy_service_discovery_v3_DeltaDiscoveryRequest *ret = envoy_service_discovery_v3_DeltaDiscoveryRequest_new(arena);
212   return (ret && _upb_decode(buf, size, ret, &envoy_service_discovery_v3_DeltaDiscoveryRequest_msginit, arena, options))
213       ? ret : NULL;
214 }
envoy_service_discovery_v3_DeltaDiscoveryRequest_serialize(const envoy_service_discovery_v3_DeltaDiscoveryRequest * msg,upb_arena * arena,size_t * len)215 UPB_INLINE char *envoy_service_discovery_v3_DeltaDiscoveryRequest_serialize(const envoy_service_discovery_v3_DeltaDiscoveryRequest *msg, upb_arena *arena, size_t *len) {
216   return upb_encode(msg, &envoy_service_discovery_v3_DeltaDiscoveryRequest_msginit, arena, len);
217 }
218 
envoy_service_discovery_v3_DeltaDiscoveryRequest_has_node(const envoy_service_discovery_v3_DeltaDiscoveryRequest * msg)219 UPB_INLINE bool envoy_service_discovery_v3_DeltaDiscoveryRequest_has_node(const envoy_service_discovery_v3_DeltaDiscoveryRequest *msg) { return _upb_hasbit(msg, 1); }
envoy_service_discovery_v3_DeltaDiscoveryRequest_node(const envoy_service_discovery_v3_DeltaDiscoveryRequest * msg)220 UPB_INLINE const struct envoy_config_core_v3_Node* envoy_service_discovery_v3_DeltaDiscoveryRequest_node(const envoy_service_discovery_v3_DeltaDiscoveryRequest *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(20, 40), const struct envoy_config_core_v3_Node*); }
envoy_service_discovery_v3_DeltaDiscoveryRequest_type_url(const envoy_service_discovery_v3_DeltaDiscoveryRequest * msg)221 UPB_INLINE upb_strview envoy_service_discovery_v3_DeltaDiscoveryRequest_type_url(const envoy_service_discovery_v3_DeltaDiscoveryRequest *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_strview); }
envoy_service_discovery_v3_DeltaDiscoveryRequest_resource_names_subscribe(const envoy_service_discovery_v3_DeltaDiscoveryRequest * msg,size_t * len)222 UPB_INLINE upb_strview const* envoy_service_discovery_v3_DeltaDiscoveryRequest_resource_names_subscribe(const envoy_service_discovery_v3_DeltaDiscoveryRequest *msg, size_t *len) { return (upb_strview const*)_upb_array_accessor(msg, UPB_SIZE(28, 56), len); }
envoy_service_discovery_v3_DeltaDiscoveryRequest_resource_names_unsubscribe(const envoy_service_discovery_v3_DeltaDiscoveryRequest * msg,size_t * len)223 UPB_INLINE upb_strview const* envoy_service_discovery_v3_DeltaDiscoveryRequest_resource_names_unsubscribe(const envoy_service_discovery_v3_DeltaDiscoveryRequest *msg, size_t *len) { return (upb_strview const*)_upb_array_accessor(msg, UPB_SIZE(32, 64), len); }
envoy_service_discovery_v3_DeltaDiscoveryRequest_has_initial_resource_versions(const envoy_service_discovery_v3_DeltaDiscoveryRequest * msg)224 UPB_INLINE bool envoy_service_discovery_v3_DeltaDiscoveryRequest_has_initial_resource_versions(const envoy_service_discovery_v3_DeltaDiscoveryRequest *msg) { return _upb_has_submsg_nohasbit(msg, UPB_SIZE(36, 72)); }
envoy_service_discovery_v3_DeltaDiscoveryRequest_initial_resource_versions_size(const envoy_service_discovery_v3_DeltaDiscoveryRequest * msg)225 UPB_INLINE size_t envoy_service_discovery_v3_DeltaDiscoveryRequest_initial_resource_versions_size(const envoy_service_discovery_v3_DeltaDiscoveryRequest *msg) {return _upb_msg_map_size(msg, UPB_SIZE(36, 72)); }
envoy_service_discovery_v3_DeltaDiscoveryRequest_initial_resource_versions_get(const envoy_service_discovery_v3_DeltaDiscoveryRequest * msg,upb_strview key,upb_strview * val)226 UPB_INLINE bool envoy_service_discovery_v3_DeltaDiscoveryRequest_initial_resource_versions_get(const envoy_service_discovery_v3_DeltaDiscoveryRequest *msg, upb_strview key, upb_strview *val) { return _upb_msg_map_get(msg, UPB_SIZE(36, 72), &key, 0, val, 0); }
envoy_service_discovery_v3_DeltaDiscoveryRequest_initial_resource_versions_next(const envoy_service_discovery_v3_DeltaDiscoveryRequest * msg,size_t * iter)227 UPB_INLINE const envoy_service_discovery_v3_DeltaDiscoveryRequest_InitialResourceVersionsEntry* envoy_service_discovery_v3_DeltaDiscoveryRequest_initial_resource_versions_next(const envoy_service_discovery_v3_DeltaDiscoveryRequest *msg, size_t* iter) { return (const envoy_service_discovery_v3_DeltaDiscoveryRequest_InitialResourceVersionsEntry*)_upb_msg_map_next(msg, UPB_SIZE(36, 72), iter); }
envoy_service_discovery_v3_DeltaDiscoveryRequest_response_nonce(const envoy_service_discovery_v3_DeltaDiscoveryRequest * msg)228 UPB_INLINE upb_strview envoy_service_discovery_v3_DeltaDiscoveryRequest_response_nonce(const envoy_service_discovery_v3_DeltaDiscoveryRequest *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(12, 24), upb_strview); }
envoy_service_discovery_v3_DeltaDiscoveryRequest_has_error_detail(const envoy_service_discovery_v3_DeltaDiscoveryRequest * msg)229 UPB_INLINE bool envoy_service_discovery_v3_DeltaDiscoveryRequest_has_error_detail(const envoy_service_discovery_v3_DeltaDiscoveryRequest *msg) { return _upb_hasbit(msg, 2); }
envoy_service_discovery_v3_DeltaDiscoveryRequest_error_detail(const envoy_service_discovery_v3_DeltaDiscoveryRequest * msg)230 UPB_INLINE const struct google_rpc_Status* envoy_service_discovery_v3_DeltaDiscoveryRequest_error_detail(const envoy_service_discovery_v3_DeltaDiscoveryRequest *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(24, 48), const struct google_rpc_Status*); }
231 
envoy_service_discovery_v3_DeltaDiscoveryRequest_set_node(envoy_service_discovery_v3_DeltaDiscoveryRequest * msg,struct envoy_config_core_v3_Node * value)232 UPB_INLINE void envoy_service_discovery_v3_DeltaDiscoveryRequest_set_node(envoy_service_discovery_v3_DeltaDiscoveryRequest *msg, struct envoy_config_core_v3_Node* value) {
233   _upb_sethas(msg, 1);
234   *UPB_PTR_AT(msg, UPB_SIZE(20, 40), struct envoy_config_core_v3_Node*) = value;
235 }
envoy_service_discovery_v3_DeltaDiscoveryRequest_mutable_node(envoy_service_discovery_v3_DeltaDiscoveryRequest * msg,upb_arena * arena)236 UPB_INLINE struct envoy_config_core_v3_Node* envoy_service_discovery_v3_DeltaDiscoveryRequest_mutable_node(envoy_service_discovery_v3_DeltaDiscoveryRequest *msg, upb_arena *arena) {
237   struct envoy_config_core_v3_Node* sub = (struct envoy_config_core_v3_Node*)envoy_service_discovery_v3_DeltaDiscoveryRequest_node(msg);
238   if (sub == NULL) {
239     sub = (struct envoy_config_core_v3_Node*)_upb_msg_new(&envoy_config_core_v3_Node_msginit, arena);
240     if (!sub) return NULL;
241     envoy_service_discovery_v3_DeltaDiscoveryRequest_set_node(msg, sub);
242   }
243   return sub;
244 }
envoy_service_discovery_v3_DeltaDiscoveryRequest_set_type_url(envoy_service_discovery_v3_DeltaDiscoveryRequest * msg,upb_strview value)245 UPB_INLINE void envoy_service_discovery_v3_DeltaDiscoveryRequest_set_type_url(envoy_service_discovery_v3_DeltaDiscoveryRequest *msg, upb_strview value) {
246   *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_strview) = value;
247 }
envoy_service_discovery_v3_DeltaDiscoveryRequest_mutable_resource_names_subscribe(envoy_service_discovery_v3_DeltaDiscoveryRequest * msg,size_t * len)248 UPB_INLINE upb_strview* envoy_service_discovery_v3_DeltaDiscoveryRequest_mutable_resource_names_subscribe(envoy_service_discovery_v3_DeltaDiscoveryRequest *msg, size_t *len) {
249   return (upb_strview*)_upb_array_mutable_accessor(msg, UPB_SIZE(28, 56), len);
250 }
envoy_service_discovery_v3_DeltaDiscoveryRequest_resize_resource_names_subscribe(envoy_service_discovery_v3_DeltaDiscoveryRequest * msg,size_t len,upb_arena * arena)251 UPB_INLINE upb_strview* envoy_service_discovery_v3_DeltaDiscoveryRequest_resize_resource_names_subscribe(envoy_service_discovery_v3_DeltaDiscoveryRequest *msg, size_t len, upb_arena *arena) {
252   return (upb_strview*)_upb_array_resize_accessor2(msg, UPB_SIZE(28, 56), len, UPB_SIZE(3, 4), arena);
253 }
envoy_service_discovery_v3_DeltaDiscoveryRequest_add_resource_names_subscribe(envoy_service_discovery_v3_DeltaDiscoveryRequest * msg,upb_strview val,upb_arena * arena)254 UPB_INLINE bool envoy_service_discovery_v3_DeltaDiscoveryRequest_add_resource_names_subscribe(envoy_service_discovery_v3_DeltaDiscoveryRequest *msg, upb_strview val, upb_arena *arena) {
255   return _upb_array_append_accessor2(msg, UPB_SIZE(28, 56), UPB_SIZE(3, 4), &val,
256       arena);
257 }
envoy_service_discovery_v3_DeltaDiscoveryRequest_mutable_resource_names_unsubscribe(envoy_service_discovery_v3_DeltaDiscoveryRequest * msg,size_t * len)258 UPB_INLINE upb_strview* envoy_service_discovery_v3_DeltaDiscoveryRequest_mutable_resource_names_unsubscribe(envoy_service_discovery_v3_DeltaDiscoveryRequest *msg, size_t *len) {
259   return (upb_strview*)_upb_array_mutable_accessor(msg, UPB_SIZE(32, 64), len);
260 }
envoy_service_discovery_v3_DeltaDiscoveryRequest_resize_resource_names_unsubscribe(envoy_service_discovery_v3_DeltaDiscoveryRequest * msg,size_t len,upb_arena * arena)261 UPB_INLINE upb_strview* envoy_service_discovery_v3_DeltaDiscoveryRequest_resize_resource_names_unsubscribe(envoy_service_discovery_v3_DeltaDiscoveryRequest *msg, size_t len, upb_arena *arena) {
262   return (upb_strview*)_upb_array_resize_accessor2(msg, UPB_SIZE(32, 64), len, UPB_SIZE(3, 4), arena);
263 }
envoy_service_discovery_v3_DeltaDiscoveryRequest_add_resource_names_unsubscribe(envoy_service_discovery_v3_DeltaDiscoveryRequest * msg,upb_strview val,upb_arena * arena)264 UPB_INLINE bool envoy_service_discovery_v3_DeltaDiscoveryRequest_add_resource_names_unsubscribe(envoy_service_discovery_v3_DeltaDiscoveryRequest *msg, upb_strview val, upb_arena *arena) {
265   return _upb_array_append_accessor2(msg, UPB_SIZE(32, 64), UPB_SIZE(3, 4), &val,
266       arena);
267 }
envoy_service_discovery_v3_DeltaDiscoveryRequest_initial_resource_versions_clear(envoy_service_discovery_v3_DeltaDiscoveryRequest * msg)268 UPB_INLINE void envoy_service_discovery_v3_DeltaDiscoveryRequest_initial_resource_versions_clear(envoy_service_discovery_v3_DeltaDiscoveryRequest *msg) { _upb_msg_map_clear(msg, UPB_SIZE(36, 72)); }
envoy_service_discovery_v3_DeltaDiscoveryRequest_initial_resource_versions_set(envoy_service_discovery_v3_DeltaDiscoveryRequest * msg,upb_strview key,upb_strview val,upb_arena * a)269 UPB_INLINE bool envoy_service_discovery_v3_DeltaDiscoveryRequest_initial_resource_versions_set(envoy_service_discovery_v3_DeltaDiscoveryRequest *msg, upb_strview key, upb_strview val, upb_arena *a) { return _upb_msg_map_set(msg, UPB_SIZE(36, 72), &key, 0, &val, 0, a); }
envoy_service_discovery_v3_DeltaDiscoveryRequest_initial_resource_versions_delete(envoy_service_discovery_v3_DeltaDiscoveryRequest * msg,upb_strview key)270 UPB_INLINE bool envoy_service_discovery_v3_DeltaDiscoveryRequest_initial_resource_versions_delete(envoy_service_discovery_v3_DeltaDiscoveryRequest *msg, upb_strview key) { return _upb_msg_map_delete(msg, UPB_SIZE(36, 72), &key, 0); }
envoy_service_discovery_v3_DeltaDiscoveryRequest_initial_resource_versions_nextmutable(envoy_service_discovery_v3_DeltaDiscoveryRequest * msg,size_t * iter)271 UPB_INLINE envoy_service_discovery_v3_DeltaDiscoveryRequest_InitialResourceVersionsEntry* envoy_service_discovery_v3_DeltaDiscoveryRequest_initial_resource_versions_nextmutable(envoy_service_discovery_v3_DeltaDiscoveryRequest *msg, size_t* iter) { return (envoy_service_discovery_v3_DeltaDiscoveryRequest_InitialResourceVersionsEntry*)_upb_msg_map_next(msg, UPB_SIZE(36, 72), iter); }
envoy_service_discovery_v3_DeltaDiscoveryRequest_set_response_nonce(envoy_service_discovery_v3_DeltaDiscoveryRequest * msg,upb_strview value)272 UPB_INLINE void envoy_service_discovery_v3_DeltaDiscoveryRequest_set_response_nonce(envoy_service_discovery_v3_DeltaDiscoveryRequest *msg, upb_strview value) {
273   *UPB_PTR_AT(msg, UPB_SIZE(12, 24), upb_strview) = value;
274 }
envoy_service_discovery_v3_DeltaDiscoveryRequest_set_error_detail(envoy_service_discovery_v3_DeltaDiscoveryRequest * msg,struct google_rpc_Status * value)275 UPB_INLINE void envoy_service_discovery_v3_DeltaDiscoveryRequest_set_error_detail(envoy_service_discovery_v3_DeltaDiscoveryRequest *msg, struct google_rpc_Status* value) {
276   _upb_sethas(msg, 2);
277   *UPB_PTR_AT(msg, UPB_SIZE(24, 48), struct google_rpc_Status*) = value;
278 }
envoy_service_discovery_v3_DeltaDiscoveryRequest_mutable_error_detail(envoy_service_discovery_v3_DeltaDiscoveryRequest * msg,upb_arena * arena)279 UPB_INLINE struct google_rpc_Status* envoy_service_discovery_v3_DeltaDiscoveryRequest_mutable_error_detail(envoy_service_discovery_v3_DeltaDiscoveryRequest *msg, upb_arena *arena) {
280   struct google_rpc_Status* sub = (struct google_rpc_Status*)envoy_service_discovery_v3_DeltaDiscoveryRequest_error_detail(msg);
281   if (sub == NULL) {
282     sub = (struct google_rpc_Status*)_upb_msg_new(&google_rpc_Status_msginit, arena);
283     if (!sub) return NULL;
284     envoy_service_discovery_v3_DeltaDiscoveryRequest_set_error_detail(msg, sub);
285   }
286   return sub;
287 }
288 
289 /* envoy.service.discovery.v3.DeltaDiscoveryRequest.InitialResourceVersionsEntry */
290 
envoy_service_discovery_v3_DeltaDiscoveryRequest_InitialResourceVersionsEntry_key(const envoy_service_discovery_v3_DeltaDiscoveryRequest_InitialResourceVersionsEntry * msg)291 UPB_INLINE upb_strview envoy_service_discovery_v3_DeltaDiscoveryRequest_InitialResourceVersionsEntry_key(const envoy_service_discovery_v3_DeltaDiscoveryRequest_InitialResourceVersionsEntry *msg) {
292   upb_strview ret;
293   _upb_msg_map_key(msg, &ret, 0);
294   return ret;
295 }
envoy_service_discovery_v3_DeltaDiscoveryRequest_InitialResourceVersionsEntry_value(const envoy_service_discovery_v3_DeltaDiscoveryRequest_InitialResourceVersionsEntry * msg)296 UPB_INLINE upb_strview envoy_service_discovery_v3_DeltaDiscoveryRequest_InitialResourceVersionsEntry_value(const envoy_service_discovery_v3_DeltaDiscoveryRequest_InitialResourceVersionsEntry *msg) {
297   upb_strview ret;
298   _upb_msg_map_value(msg, &ret, 0);
299   return ret;
300 }
301 
envoy_service_discovery_v3_DeltaDiscoveryRequest_InitialResourceVersionsEntry_set_value(envoy_service_discovery_v3_DeltaDiscoveryRequest_InitialResourceVersionsEntry * msg,upb_strview value)302 UPB_INLINE void envoy_service_discovery_v3_DeltaDiscoveryRequest_InitialResourceVersionsEntry_set_value(envoy_service_discovery_v3_DeltaDiscoveryRequest_InitialResourceVersionsEntry *msg, upb_strview value) {
303   _upb_msg_map_set_value(msg, &value, 0);
304 }
305 
306 /* envoy.service.discovery.v3.DeltaDiscoveryResponse */
307 
envoy_service_discovery_v3_DeltaDiscoveryResponse_new(upb_arena * arena)308 UPB_INLINE envoy_service_discovery_v3_DeltaDiscoveryResponse *envoy_service_discovery_v3_DeltaDiscoveryResponse_new(upb_arena *arena) {
309   return (envoy_service_discovery_v3_DeltaDiscoveryResponse *)_upb_msg_new(&envoy_service_discovery_v3_DeltaDiscoveryResponse_msginit, arena);
310 }
envoy_service_discovery_v3_DeltaDiscoveryResponse_parse(const char * buf,size_t size,upb_arena * arena)311 UPB_INLINE envoy_service_discovery_v3_DeltaDiscoveryResponse *envoy_service_discovery_v3_DeltaDiscoveryResponse_parse(const char *buf, size_t size,
312                         upb_arena *arena) {
313   envoy_service_discovery_v3_DeltaDiscoveryResponse *ret = envoy_service_discovery_v3_DeltaDiscoveryResponse_new(arena);
314   return (ret && upb_decode(buf, size, ret, &envoy_service_discovery_v3_DeltaDiscoveryResponse_msginit, arena)) ? ret : NULL;
315 }
envoy_service_discovery_v3_DeltaDiscoveryResponse_parse_ex(const char * buf,size_t size,upb_arena * arena,int options)316 UPB_INLINE envoy_service_discovery_v3_DeltaDiscoveryResponse *envoy_service_discovery_v3_DeltaDiscoveryResponse_parse_ex(const char *buf, size_t size,
317                            upb_arena *arena, int options) {
318   envoy_service_discovery_v3_DeltaDiscoveryResponse *ret = envoy_service_discovery_v3_DeltaDiscoveryResponse_new(arena);
319   return (ret && _upb_decode(buf, size, ret, &envoy_service_discovery_v3_DeltaDiscoveryResponse_msginit, arena, options))
320       ? ret : NULL;
321 }
envoy_service_discovery_v3_DeltaDiscoveryResponse_serialize(const envoy_service_discovery_v3_DeltaDiscoveryResponse * msg,upb_arena * arena,size_t * len)322 UPB_INLINE char *envoy_service_discovery_v3_DeltaDiscoveryResponse_serialize(const envoy_service_discovery_v3_DeltaDiscoveryResponse *msg, upb_arena *arena, size_t *len) {
323   return upb_encode(msg, &envoy_service_discovery_v3_DeltaDiscoveryResponse_msginit, arena, len);
324 }
325 
envoy_service_discovery_v3_DeltaDiscoveryResponse_system_version_info(const envoy_service_discovery_v3_DeltaDiscoveryResponse * msg)326 UPB_INLINE upb_strview envoy_service_discovery_v3_DeltaDiscoveryResponse_system_version_info(const envoy_service_discovery_v3_DeltaDiscoveryResponse *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_strview); }
envoy_service_discovery_v3_DeltaDiscoveryResponse_has_resources(const envoy_service_discovery_v3_DeltaDiscoveryResponse * msg)327 UPB_INLINE bool envoy_service_discovery_v3_DeltaDiscoveryResponse_has_resources(const envoy_service_discovery_v3_DeltaDiscoveryResponse *msg) { return _upb_has_submsg_nohasbit(msg, UPB_SIZE(32, 64)); }
envoy_service_discovery_v3_DeltaDiscoveryResponse_resources(const envoy_service_discovery_v3_DeltaDiscoveryResponse * msg,size_t * len)328 UPB_INLINE const envoy_service_discovery_v3_Resource* const* envoy_service_discovery_v3_DeltaDiscoveryResponse_resources(const envoy_service_discovery_v3_DeltaDiscoveryResponse *msg, size_t *len) { return (const envoy_service_discovery_v3_Resource* const*)_upb_array_accessor(msg, UPB_SIZE(32, 64), len); }
envoy_service_discovery_v3_DeltaDiscoveryResponse_type_url(const envoy_service_discovery_v3_DeltaDiscoveryResponse * msg)329 UPB_INLINE upb_strview envoy_service_discovery_v3_DeltaDiscoveryResponse_type_url(const envoy_service_discovery_v3_DeltaDiscoveryResponse *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(12, 24), upb_strview); }
envoy_service_discovery_v3_DeltaDiscoveryResponse_nonce(const envoy_service_discovery_v3_DeltaDiscoveryResponse * msg)330 UPB_INLINE upb_strview envoy_service_discovery_v3_DeltaDiscoveryResponse_nonce(const envoy_service_discovery_v3_DeltaDiscoveryResponse *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(20, 40), upb_strview); }
envoy_service_discovery_v3_DeltaDiscoveryResponse_removed_resources(const envoy_service_discovery_v3_DeltaDiscoveryResponse * msg,size_t * len)331 UPB_INLINE upb_strview const* envoy_service_discovery_v3_DeltaDiscoveryResponse_removed_resources(const envoy_service_discovery_v3_DeltaDiscoveryResponse *msg, size_t *len) { return (upb_strview const*)_upb_array_accessor(msg, UPB_SIZE(36, 72), len); }
envoy_service_discovery_v3_DeltaDiscoveryResponse_has_control_plane(const envoy_service_discovery_v3_DeltaDiscoveryResponse * msg)332 UPB_INLINE bool envoy_service_discovery_v3_DeltaDiscoveryResponse_has_control_plane(const envoy_service_discovery_v3_DeltaDiscoveryResponse *msg) { return _upb_hasbit(msg, 1); }
envoy_service_discovery_v3_DeltaDiscoveryResponse_control_plane(const envoy_service_discovery_v3_DeltaDiscoveryResponse * msg)333 UPB_INLINE const struct envoy_config_core_v3_ControlPlane* envoy_service_discovery_v3_DeltaDiscoveryResponse_control_plane(const envoy_service_discovery_v3_DeltaDiscoveryResponse *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(28, 56), const struct envoy_config_core_v3_ControlPlane*); }
334 
envoy_service_discovery_v3_DeltaDiscoveryResponse_set_system_version_info(envoy_service_discovery_v3_DeltaDiscoveryResponse * msg,upb_strview value)335 UPB_INLINE void envoy_service_discovery_v3_DeltaDiscoveryResponse_set_system_version_info(envoy_service_discovery_v3_DeltaDiscoveryResponse *msg, upb_strview value) {
336   *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_strview) = value;
337 }
envoy_service_discovery_v3_DeltaDiscoveryResponse_mutable_resources(envoy_service_discovery_v3_DeltaDiscoveryResponse * msg,size_t * len)338 UPB_INLINE envoy_service_discovery_v3_Resource** envoy_service_discovery_v3_DeltaDiscoveryResponse_mutable_resources(envoy_service_discovery_v3_DeltaDiscoveryResponse *msg, size_t *len) {
339   return (envoy_service_discovery_v3_Resource**)_upb_array_mutable_accessor(msg, UPB_SIZE(32, 64), len);
340 }
envoy_service_discovery_v3_DeltaDiscoveryResponse_resize_resources(envoy_service_discovery_v3_DeltaDiscoveryResponse * msg,size_t len,upb_arena * arena)341 UPB_INLINE envoy_service_discovery_v3_Resource** envoy_service_discovery_v3_DeltaDiscoveryResponse_resize_resources(envoy_service_discovery_v3_DeltaDiscoveryResponse *msg, size_t len, upb_arena *arena) {
342   return (envoy_service_discovery_v3_Resource**)_upb_array_resize_accessor2(msg, UPB_SIZE(32, 64), len, UPB_SIZE(2, 3), arena);
343 }
envoy_service_discovery_v3_DeltaDiscoveryResponse_add_resources(envoy_service_discovery_v3_DeltaDiscoveryResponse * msg,upb_arena * arena)344 UPB_INLINE struct envoy_service_discovery_v3_Resource* envoy_service_discovery_v3_DeltaDiscoveryResponse_add_resources(envoy_service_discovery_v3_DeltaDiscoveryResponse *msg, upb_arena *arena) {
345   struct envoy_service_discovery_v3_Resource* sub = (struct envoy_service_discovery_v3_Resource*)_upb_msg_new(&envoy_service_discovery_v3_Resource_msginit, arena);
346   bool ok = _upb_array_append_accessor2(
347       msg, UPB_SIZE(32, 64), UPB_SIZE(2, 3), &sub, arena);
348   if (!ok) return NULL;
349   return sub;
350 }
envoy_service_discovery_v3_DeltaDiscoveryResponse_set_type_url(envoy_service_discovery_v3_DeltaDiscoveryResponse * msg,upb_strview value)351 UPB_INLINE void envoy_service_discovery_v3_DeltaDiscoveryResponse_set_type_url(envoy_service_discovery_v3_DeltaDiscoveryResponse *msg, upb_strview value) {
352   *UPB_PTR_AT(msg, UPB_SIZE(12, 24), upb_strview) = value;
353 }
envoy_service_discovery_v3_DeltaDiscoveryResponse_set_nonce(envoy_service_discovery_v3_DeltaDiscoveryResponse * msg,upb_strview value)354 UPB_INLINE void envoy_service_discovery_v3_DeltaDiscoveryResponse_set_nonce(envoy_service_discovery_v3_DeltaDiscoveryResponse *msg, upb_strview value) {
355   *UPB_PTR_AT(msg, UPB_SIZE(20, 40), upb_strview) = value;
356 }
envoy_service_discovery_v3_DeltaDiscoveryResponse_mutable_removed_resources(envoy_service_discovery_v3_DeltaDiscoveryResponse * msg,size_t * len)357 UPB_INLINE upb_strview* envoy_service_discovery_v3_DeltaDiscoveryResponse_mutable_removed_resources(envoy_service_discovery_v3_DeltaDiscoveryResponse *msg, size_t *len) {
358   return (upb_strview*)_upb_array_mutable_accessor(msg, UPB_SIZE(36, 72), len);
359 }
envoy_service_discovery_v3_DeltaDiscoveryResponse_resize_removed_resources(envoy_service_discovery_v3_DeltaDiscoveryResponse * msg,size_t len,upb_arena * arena)360 UPB_INLINE upb_strview* envoy_service_discovery_v3_DeltaDiscoveryResponse_resize_removed_resources(envoy_service_discovery_v3_DeltaDiscoveryResponse *msg, size_t len, upb_arena *arena) {
361   return (upb_strview*)_upb_array_resize_accessor2(msg, UPB_SIZE(36, 72), len, UPB_SIZE(3, 4), arena);
362 }
envoy_service_discovery_v3_DeltaDiscoveryResponse_add_removed_resources(envoy_service_discovery_v3_DeltaDiscoveryResponse * msg,upb_strview val,upb_arena * arena)363 UPB_INLINE bool envoy_service_discovery_v3_DeltaDiscoveryResponse_add_removed_resources(envoy_service_discovery_v3_DeltaDiscoveryResponse *msg, upb_strview val, upb_arena *arena) {
364   return _upb_array_append_accessor2(msg, UPB_SIZE(36, 72), UPB_SIZE(3, 4), &val,
365       arena);
366 }
envoy_service_discovery_v3_DeltaDiscoveryResponse_set_control_plane(envoy_service_discovery_v3_DeltaDiscoveryResponse * msg,struct envoy_config_core_v3_ControlPlane * value)367 UPB_INLINE void envoy_service_discovery_v3_DeltaDiscoveryResponse_set_control_plane(envoy_service_discovery_v3_DeltaDiscoveryResponse *msg, struct envoy_config_core_v3_ControlPlane* value) {
368   _upb_sethas(msg, 1);
369   *UPB_PTR_AT(msg, UPB_SIZE(28, 56), struct envoy_config_core_v3_ControlPlane*) = value;
370 }
envoy_service_discovery_v3_DeltaDiscoveryResponse_mutable_control_plane(envoy_service_discovery_v3_DeltaDiscoveryResponse * msg,upb_arena * arena)371 UPB_INLINE struct envoy_config_core_v3_ControlPlane* envoy_service_discovery_v3_DeltaDiscoveryResponse_mutable_control_plane(envoy_service_discovery_v3_DeltaDiscoveryResponse *msg, upb_arena *arena) {
372   struct envoy_config_core_v3_ControlPlane* sub = (struct envoy_config_core_v3_ControlPlane*)envoy_service_discovery_v3_DeltaDiscoveryResponse_control_plane(msg);
373   if (sub == NULL) {
374     sub = (struct envoy_config_core_v3_ControlPlane*)_upb_msg_new(&envoy_config_core_v3_ControlPlane_msginit, arena);
375     if (!sub) return NULL;
376     envoy_service_discovery_v3_DeltaDiscoveryResponse_set_control_plane(msg, sub);
377   }
378   return sub;
379 }
380 
381 /* envoy.service.discovery.v3.Resource */
382 
envoy_service_discovery_v3_Resource_new(upb_arena * arena)383 UPB_INLINE envoy_service_discovery_v3_Resource *envoy_service_discovery_v3_Resource_new(upb_arena *arena) {
384   return (envoy_service_discovery_v3_Resource *)_upb_msg_new(&envoy_service_discovery_v3_Resource_msginit, arena);
385 }
envoy_service_discovery_v3_Resource_parse(const char * buf,size_t size,upb_arena * arena)386 UPB_INLINE envoy_service_discovery_v3_Resource *envoy_service_discovery_v3_Resource_parse(const char *buf, size_t size,
387                         upb_arena *arena) {
388   envoy_service_discovery_v3_Resource *ret = envoy_service_discovery_v3_Resource_new(arena);
389   return (ret && upb_decode(buf, size, ret, &envoy_service_discovery_v3_Resource_msginit, arena)) ? ret : NULL;
390 }
envoy_service_discovery_v3_Resource_parse_ex(const char * buf,size_t size,upb_arena * arena,int options)391 UPB_INLINE envoy_service_discovery_v3_Resource *envoy_service_discovery_v3_Resource_parse_ex(const char *buf, size_t size,
392                            upb_arena *arena, int options) {
393   envoy_service_discovery_v3_Resource *ret = envoy_service_discovery_v3_Resource_new(arena);
394   return (ret && _upb_decode(buf, size, ret, &envoy_service_discovery_v3_Resource_msginit, arena, options))
395       ? ret : NULL;
396 }
envoy_service_discovery_v3_Resource_serialize(const envoy_service_discovery_v3_Resource * msg,upb_arena * arena,size_t * len)397 UPB_INLINE char *envoy_service_discovery_v3_Resource_serialize(const envoy_service_discovery_v3_Resource *msg, upb_arena *arena, size_t *len) {
398   return upb_encode(msg, &envoy_service_discovery_v3_Resource_msginit, arena, len);
399 }
400 
envoy_service_discovery_v3_Resource_version(const envoy_service_discovery_v3_Resource * msg)401 UPB_INLINE upb_strview envoy_service_discovery_v3_Resource_version(const envoy_service_discovery_v3_Resource *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_strview); }
envoy_service_discovery_v3_Resource_has_resource(const envoy_service_discovery_v3_Resource * msg)402 UPB_INLINE bool envoy_service_discovery_v3_Resource_has_resource(const envoy_service_discovery_v3_Resource *msg) { return _upb_hasbit(msg, 1); }
envoy_service_discovery_v3_Resource_resource(const envoy_service_discovery_v3_Resource * msg)403 UPB_INLINE const struct google_protobuf_Any* envoy_service_discovery_v3_Resource_resource(const envoy_service_discovery_v3_Resource *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(20, 40), const struct google_protobuf_Any*); }
envoy_service_discovery_v3_Resource_name(const envoy_service_discovery_v3_Resource * msg)404 UPB_INLINE upb_strview envoy_service_discovery_v3_Resource_name(const envoy_service_discovery_v3_Resource *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(12, 24), upb_strview); }
envoy_service_discovery_v3_Resource_aliases(const envoy_service_discovery_v3_Resource * msg,size_t * len)405 UPB_INLINE upb_strview const* envoy_service_discovery_v3_Resource_aliases(const envoy_service_discovery_v3_Resource *msg, size_t *len) { return (upb_strview const*)_upb_array_accessor(msg, UPB_SIZE(32, 64), len); }
envoy_service_discovery_v3_Resource_has_ttl(const envoy_service_discovery_v3_Resource * msg)406 UPB_INLINE bool envoy_service_discovery_v3_Resource_has_ttl(const envoy_service_discovery_v3_Resource *msg) { return _upb_hasbit(msg, 2); }
envoy_service_discovery_v3_Resource_ttl(const envoy_service_discovery_v3_Resource * msg)407 UPB_INLINE const struct google_protobuf_Duration* envoy_service_discovery_v3_Resource_ttl(const envoy_service_discovery_v3_Resource *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(24, 48), const struct google_protobuf_Duration*); }
envoy_service_discovery_v3_Resource_has_cache_control(const envoy_service_discovery_v3_Resource * msg)408 UPB_INLINE bool envoy_service_discovery_v3_Resource_has_cache_control(const envoy_service_discovery_v3_Resource *msg) { return _upb_hasbit(msg, 3); }
envoy_service_discovery_v3_Resource_cache_control(const envoy_service_discovery_v3_Resource * msg)409 UPB_INLINE const envoy_service_discovery_v3_Resource_CacheControl* envoy_service_discovery_v3_Resource_cache_control(const envoy_service_discovery_v3_Resource *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(28, 56), const envoy_service_discovery_v3_Resource_CacheControl*); }
410 
envoy_service_discovery_v3_Resource_set_version(envoy_service_discovery_v3_Resource * msg,upb_strview value)411 UPB_INLINE void envoy_service_discovery_v3_Resource_set_version(envoy_service_discovery_v3_Resource *msg, upb_strview value) {
412   *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_strview) = value;
413 }
envoy_service_discovery_v3_Resource_set_resource(envoy_service_discovery_v3_Resource * msg,struct google_protobuf_Any * value)414 UPB_INLINE void envoy_service_discovery_v3_Resource_set_resource(envoy_service_discovery_v3_Resource *msg, struct google_protobuf_Any* value) {
415   _upb_sethas(msg, 1);
416   *UPB_PTR_AT(msg, UPB_SIZE(20, 40), struct google_protobuf_Any*) = value;
417 }
envoy_service_discovery_v3_Resource_mutable_resource(envoy_service_discovery_v3_Resource * msg,upb_arena * arena)418 UPB_INLINE struct google_protobuf_Any* envoy_service_discovery_v3_Resource_mutable_resource(envoy_service_discovery_v3_Resource *msg, upb_arena *arena) {
419   struct google_protobuf_Any* sub = (struct google_protobuf_Any*)envoy_service_discovery_v3_Resource_resource(msg);
420   if (sub == NULL) {
421     sub = (struct google_protobuf_Any*)_upb_msg_new(&google_protobuf_Any_msginit, arena);
422     if (!sub) return NULL;
423     envoy_service_discovery_v3_Resource_set_resource(msg, sub);
424   }
425   return sub;
426 }
envoy_service_discovery_v3_Resource_set_name(envoy_service_discovery_v3_Resource * msg,upb_strview value)427 UPB_INLINE void envoy_service_discovery_v3_Resource_set_name(envoy_service_discovery_v3_Resource *msg, upb_strview value) {
428   *UPB_PTR_AT(msg, UPB_SIZE(12, 24), upb_strview) = value;
429 }
envoy_service_discovery_v3_Resource_mutable_aliases(envoy_service_discovery_v3_Resource * msg,size_t * len)430 UPB_INLINE upb_strview* envoy_service_discovery_v3_Resource_mutable_aliases(envoy_service_discovery_v3_Resource *msg, size_t *len) {
431   return (upb_strview*)_upb_array_mutable_accessor(msg, UPB_SIZE(32, 64), len);
432 }
envoy_service_discovery_v3_Resource_resize_aliases(envoy_service_discovery_v3_Resource * msg,size_t len,upb_arena * arena)433 UPB_INLINE upb_strview* envoy_service_discovery_v3_Resource_resize_aliases(envoy_service_discovery_v3_Resource *msg, size_t len, upb_arena *arena) {
434   return (upb_strview*)_upb_array_resize_accessor2(msg, UPB_SIZE(32, 64), len, UPB_SIZE(3, 4), arena);
435 }
envoy_service_discovery_v3_Resource_add_aliases(envoy_service_discovery_v3_Resource * msg,upb_strview val,upb_arena * arena)436 UPB_INLINE bool envoy_service_discovery_v3_Resource_add_aliases(envoy_service_discovery_v3_Resource *msg, upb_strview val, upb_arena *arena) {
437   return _upb_array_append_accessor2(msg, UPB_SIZE(32, 64), UPB_SIZE(3, 4), &val,
438       arena);
439 }
envoy_service_discovery_v3_Resource_set_ttl(envoy_service_discovery_v3_Resource * msg,struct google_protobuf_Duration * value)440 UPB_INLINE void envoy_service_discovery_v3_Resource_set_ttl(envoy_service_discovery_v3_Resource *msg, struct google_protobuf_Duration* value) {
441   _upb_sethas(msg, 2);
442   *UPB_PTR_AT(msg, UPB_SIZE(24, 48), struct google_protobuf_Duration*) = value;
443 }
envoy_service_discovery_v3_Resource_mutable_ttl(envoy_service_discovery_v3_Resource * msg,upb_arena * arena)444 UPB_INLINE struct google_protobuf_Duration* envoy_service_discovery_v3_Resource_mutable_ttl(envoy_service_discovery_v3_Resource *msg, upb_arena *arena) {
445   struct google_protobuf_Duration* sub = (struct google_protobuf_Duration*)envoy_service_discovery_v3_Resource_ttl(msg);
446   if (sub == NULL) {
447     sub = (struct google_protobuf_Duration*)_upb_msg_new(&google_protobuf_Duration_msginit, arena);
448     if (!sub) return NULL;
449     envoy_service_discovery_v3_Resource_set_ttl(msg, sub);
450   }
451   return sub;
452 }
envoy_service_discovery_v3_Resource_set_cache_control(envoy_service_discovery_v3_Resource * msg,envoy_service_discovery_v3_Resource_CacheControl * value)453 UPB_INLINE void envoy_service_discovery_v3_Resource_set_cache_control(envoy_service_discovery_v3_Resource *msg, envoy_service_discovery_v3_Resource_CacheControl* value) {
454   _upb_sethas(msg, 3);
455   *UPB_PTR_AT(msg, UPB_SIZE(28, 56), envoy_service_discovery_v3_Resource_CacheControl*) = value;
456 }
envoy_service_discovery_v3_Resource_mutable_cache_control(envoy_service_discovery_v3_Resource * msg,upb_arena * arena)457 UPB_INLINE struct envoy_service_discovery_v3_Resource_CacheControl* envoy_service_discovery_v3_Resource_mutable_cache_control(envoy_service_discovery_v3_Resource *msg, upb_arena *arena) {
458   struct envoy_service_discovery_v3_Resource_CacheControl* sub = (struct envoy_service_discovery_v3_Resource_CacheControl*)envoy_service_discovery_v3_Resource_cache_control(msg);
459   if (sub == NULL) {
460     sub = (struct envoy_service_discovery_v3_Resource_CacheControl*)_upb_msg_new(&envoy_service_discovery_v3_Resource_CacheControl_msginit, arena);
461     if (!sub) return NULL;
462     envoy_service_discovery_v3_Resource_set_cache_control(msg, sub);
463   }
464   return sub;
465 }
466 
467 /* envoy.service.discovery.v3.Resource.CacheControl */
468 
envoy_service_discovery_v3_Resource_CacheControl_new(upb_arena * arena)469 UPB_INLINE envoy_service_discovery_v3_Resource_CacheControl *envoy_service_discovery_v3_Resource_CacheControl_new(upb_arena *arena) {
470   return (envoy_service_discovery_v3_Resource_CacheControl *)_upb_msg_new(&envoy_service_discovery_v3_Resource_CacheControl_msginit, arena);
471 }
envoy_service_discovery_v3_Resource_CacheControl_parse(const char * buf,size_t size,upb_arena * arena)472 UPB_INLINE envoy_service_discovery_v3_Resource_CacheControl *envoy_service_discovery_v3_Resource_CacheControl_parse(const char *buf, size_t size,
473                         upb_arena *arena) {
474   envoy_service_discovery_v3_Resource_CacheControl *ret = envoy_service_discovery_v3_Resource_CacheControl_new(arena);
475   return (ret && upb_decode(buf, size, ret, &envoy_service_discovery_v3_Resource_CacheControl_msginit, arena)) ? ret : NULL;
476 }
envoy_service_discovery_v3_Resource_CacheControl_parse_ex(const char * buf,size_t size,upb_arena * arena,int options)477 UPB_INLINE envoy_service_discovery_v3_Resource_CacheControl *envoy_service_discovery_v3_Resource_CacheControl_parse_ex(const char *buf, size_t size,
478                            upb_arena *arena, int options) {
479   envoy_service_discovery_v3_Resource_CacheControl *ret = envoy_service_discovery_v3_Resource_CacheControl_new(arena);
480   return (ret && _upb_decode(buf, size, ret, &envoy_service_discovery_v3_Resource_CacheControl_msginit, arena, options))
481       ? ret : NULL;
482 }
envoy_service_discovery_v3_Resource_CacheControl_serialize(const envoy_service_discovery_v3_Resource_CacheControl * msg,upb_arena * arena,size_t * len)483 UPB_INLINE char *envoy_service_discovery_v3_Resource_CacheControl_serialize(const envoy_service_discovery_v3_Resource_CacheControl *msg, upb_arena *arena, size_t *len) {
484   return upb_encode(msg, &envoy_service_discovery_v3_Resource_CacheControl_msginit, arena, len);
485 }
486 
envoy_service_discovery_v3_Resource_CacheControl_do_not_cache(const envoy_service_discovery_v3_Resource_CacheControl * msg)487 UPB_INLINE bool envoy_service_discovery_v3_Resource_CacheControl_do_not_cache(const envoy_service_discovery_v3_Resource_CacheControl *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(0, 0), bool); }
488 
envoy_service_discovery_v3_Resource_CacheControl_set_do_not_cache(envoy_service_discovery_v3_Resource_CacheControl * msg,bool value)489 UPB_INLINE void envoy_service_discovery_v3_Resource_CacheControl_set_do_not_cache(envoy_service_discovery_v3_Resource_CacheControl *msg, bool value) {
490   *UPB_PTR_AT(msg, UPB_SIZE(0, 0), bool) = value;
491 }
492 
493 #ifdef __cplusplus
494 }  /* extern "C" */
495 #endif
496 
497 #include "upb/port_undef.inc"
498 
499 #endif  /* ENVOY_SERVICE_DISCOVERY_V3_DISCOVERY_PROTO_UPB_H_ */
500