GRPC Core  18.0.0
extension.upb.h
Go to the documentation of this file.
1 /* This file was generated by upbc (the upb compiler) from the input
2  * file:
3  *
4  * envoy/config/core/v3/extension.proto
5  *
6  * Do not edit -- your changes will be discarded when the file is
7  * regenerated. */
8 
9 #ifndef ENVOY_CONFIG_CORE_V3_EXTENSION_PROTO_UPB_H_
10 #define ENVOY_CONFIG_CORE_V3_EXTENSION_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 
27 extern const upb_msglayout envoy_config_core_v3_TypedExtensionConfig_msginit;
30 struct google_protobuf_Any;
31 extern const upb_msglayout envoy_config_core_v3_ConfigSource_msginit;
32 extern const upb_msglayout google_protobuf_Any_msginit;
33 
34 
35 /* envoy.config.core.v3.TypedExtensionConfig */
36 
39 }
41  upb_arena *arena) {
43  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_TypedExtensionConfig_msginit, arena)) ? ret : NULL;
44 }
46  upb_arena *arena, int options) {
48  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_TypedExtensionConfig_msginit, arena, options))
49  ? ret : NULL;
50 }
52  return upb_encode(msg, &envoy_config_core_v3_TypedExtensionConfig_msginit, arena, len);
53 }
54 
55 UPB_INLINE upb_strview envoy_config_core_v3_TypedExtensionConfig_name(const envoy_config_core_v3_TypedExtensionConfig *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_strview); }
57 UPB_INLINE const struct google_protobuf_Any* envoy_config_core_v3_TypedExtensionConfig_typed_config(const envoy_config_core_v3_TypedExtensionConfig *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(12, 24), const struct google_protobuf_Any*); }
58 
60  *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_strview) = value;
61 }
63  _upb_sethas(msg, 1);
64  *UPB_PTR_AT(msg, UPB_SIZE(12, 24), struct google_protobuf_Any*) = value;
65 }
68  if (sub == NULL) {
69  sub = (struct google_protobuf_Any*)_upb_msg_new(&google_protobuf_Any_msginit, arena);
70  if (!sub) return NULL;
72  }
73  return sub;
74 }
75 
76 /* envoy.config.core.v3.ExtensionConfigSource */
77 
80 }
82  upb_arena *arena) {
84  return (ret && upb_decode(buf, size, ret, &envoy_config_core_v3_ExtensionConfigSource_msginit, arena)) ? ret : NULL;
85 }
87  upb_arena *arena, int options) {
89  return (ret && _upb_decode(buf, size, ret, &envoy_config_core_v3_ExtensionConfigSource_msginit, arena, options))
90  ? ret : NULL;
91 }
93  return upb_encode(msg, &envoy_config_core_v3_ExtensionConfigSource_msginit, arena, len);
94 }
95 
99 UPB_INLINE const struct google_protobuf_Any* envoy_config_core_v3_ExtensionConfigSource_default_config(const envoy_config_core_v3_ExtensionConfigSource *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(8, 16), const struct google_protobuf_Any*); }
101 UPB_INLINE upb_strview const* envoy_config_core_v3_ExtensionConfigSource_type_urls(const envoy_config_core_v3_ExtensionConfigSource *msg, size_t *len) { return (upb_strview const*)_upb_array_accessor(msg, UPB_SIZE(12, 24), len); }
102 
104  _upb_sethas(msg, 1);
105  *UPB_PTR_AT(msg, UPB_SIZE(4, 8), struct envoy_config_core_v3_ConfigSource*) = value;
106 }
109  if (sub == NULL) {
111  if (!sub) return NULL;
113  }
114  return sub;
115 }
117  _upb_sethas(msg, 2);
118  *UPB_PTR_AT(msg, UPB_SIZE(8, 16), struct google_protobuf_Any*) = value;
119 }
122  if (sub == NULL) {
123  sub = (struct google_protobuf_Any*)_upb_msg_new(&google_protobuf_Any_msginit, arena);
124  if (!sub) return NULL;
126  }
127  return sub;
128 }
130  *UPB_PTR_AT(msg, UPB_SIZE(1, 1), bool) = value;
131 }
133  return (upb_strview*)_upb_array_mutable_accessor(msg, UPB_SIZE(12, 24), len);
134 }
136  return (upb_strview*)_upb_array_resize_accessor2(msg, UPB_SIZE(12, 24), len, UPB_SIZE(3, 4), arena);
137 }
139  return _upb_array_append_accessor2(msg, UPB_SIZE(12, 24), UPB_SIZE(3, 4), &val,
140  arena);
141 }
142 
143 #ifdef __cplusplus
144 } /* extern "C" */
145 #endif
146 
147 #include "upb/port_undef.inc"
148 
149 #endif /* ENVOY_CONFIG_CORE_V3_EXTENSION_PROTO_UPB_H_ */
struct google_protobuf_Any google_protobuf_Any
Definition: any.upb.h:24
struct envoy_config_core_v3_ConfigSource envoy_config_core_v3_ConfigSource
Definition: config_source.upb.h:32
struct envoy_config_core_v3_ExtensionConfigSource envoy_config_core_v3_ExtensionConfigSource
Definition: extension.upb.h:26
struct envoy_config_core_v3_TypedExtensionConfig envoy_config_core_v3_TypedExtensionConfig
Definition: extension.upb.h:25
UPB_INLINE upb_strview envoy_config_core_v3_TypedExtensionConfig_name(const envoy_config_core_v3_TypedExtensionConfig *msg)
Definition: extension.upb.h:55
UPB_INLINE struct google_protobuf_Any * envoy_config_core_v3_TypedExtensionConfig_mutable_typed_config(envoy_config_core_v3_TypedExtensionConfig *msg, upb_arena *arena)
Definition: extension.upb.h:66
UPB_INLINE bool envoy_config_core_v3_TypedExtensionConfig_has_typed_config(const envoy_config_core_v3_TypedExtensionConfig *msg)
Definition: extension.upb.h:56
UPB_INLINE bool envoy_config_core_v3_ExtensionConfigSource_has_default_config(const envoy_config_core_v3_ExtensionConfigSource *msg)
Definition: extension.upb.h:98
UPB_INLINE upb_strview * envoy_config_core_v3_ExtensionConfigSource_resize_type_urls(envoy_config_core_v3_ExtensionConfigSource *msg, size_t len, upb_arena *arena)
Definition: extension.upb.h:135
const upb_msglayout envoy_config_core_v3_ConfigSource_msginit
Definition: config_source.upb.c:96
UPB_INLINE char * envoy_config_core_v3_TypedExtensionConfig_serialize(const envoy_config_core_v3_TypedExtensionConfig *msg, upb_arena *arena, size_t *len)
Definition: extension.upb.h:51
UPB_INLINE const struct envoy_config_core_v3_ConfigSource * envoy_config_core_v3_ExtensionConfigSource_config_source(const envoy_config_core_v3_ExtensionConfigSource *msg)
Definition: extension.upb.h:97
UPB_INLINE upb_strview const * envoy_config_core_v3_ExtensionConfigSource_type_urls(const envoy_config_core_v3_ExtensionConfigSource *msg, size_t *len)
Definition: extension.upb.h:101
UPB_INLINE envoy_config_core_v3_ExtensionConfigSource * envoy_config_core_v3_ExtensionConfigSource_parse_ex(const char *buf, size_t size, upb_arena *arena, int options)
Definition: extension.upb.h:86
UPB_INLINE envoy_config_core_v3_ExtensionConfigSource * envoy_config_core_v3_ExtensionConfigSource_new(upb_arena *arena)
Definition: extension.upb.h:78
const upb_msglayout envoy_config_core_v3_ExtensionConfigSource_msginit
Definition: extension.upb.c:46
UPB_INLINE void envoy_config_core_v3_ExtensionConfigSource_set_apply_default_config_without_warming(envoy_config_core_v3_ExtensionConfigSource *msg, bool value)
Definition: extension.upb.h:129
UPB_INLINE void envoy_config_core_v3_ExtensionConfigSource_set_config_source(envoy_config_core_v3_ExtensionConfigSource *msg, struct envoy_config_core_v3_ConfigSource *value)
Definition: extension.upb.h:103
UPB_INLINE void envoy_config_core_v3_TypedExtensionConfig_set_name(envoy_config_core_v3_TypedExtensionConfig *msg, upb_strview value)
Definition: extension.upb.h:59
UPB_INLINE bool envoy_config_core_v3_ExtensionConfigSource_apply_default_config_without_warming(const envoy_config_core_v3_ExtensionConfigSource *msg)
Definition: extension.upb.h:100
UPB_INLINE const struct google_protobuf_Any * envoy_config_core_v3_ExtensionConfigSource_default_config(const envoy_config_core_v3_ExtensionConfigSource *msg)
Definition: extension.upb.h:99
UPB_INLINE const struct google_protobuf_Any * envoy_config_core_v3_TypedExtensionConfig_typed_config(const envoy_config_core_v3_TypedExtensionConfig *msg)
Definition: extension.upb.h:57
UPB_INLINE upb_strview * envoy_config_core_v3_ExtensionConfigSource_mutable_type_urls(envoy_config_core_v3_ExtensionConfigSource *msg, size_t *len)
Definition: extension.upb.h:132
UPB_INLINE char * envoy_config_core_v3_ExtensionConfigSource_serialize(const envoy_config_core_v3_ExtensionConfigSource *msg, upb_arena *arena, size_t *len)
Definition: extension.upb.h:92
UPB_INLINE void envoy_config_core_v3_ExtensionConfigSource_set_default_config(envoy_config_core_v3_ExtensionConfigSource *msg, struct google_protobuf_Any *value)
Definition: extension.upb.h:116
const upb_msglayout envoy_config_core_v3_TypedExtensionConfig_msginit
Definition: extension.upb.c:28
UPB_INLINE bool envoy_config_core_v3_ExtensionConfigSource_add_type_urls(envoy_config_core_v3_ExtensionConfigSource *msg, upb_strview val, upb_arena *arena)
Definition: extension.upb.h:138
UPB_INLINE struct envoy_config_core_v3_ConfigSource * envoy_config_core_v3_ExtensionConfigSource_mutable_config_source(envoy_config_core_v3_ExtensionConfigSource *msg, upb_arena *arena)
Definition: extension.upb.h:107
UPB_INLINE void envoy_config_core_v3_TypedExtensionConfig_set_typed_config(envoy_config_core_v3_TypedExtensionConfig *msg, struct google_protobuf_Any *value)
Definition: extension.upb.h:62
UPB_INLINE struct google_protobuf_Any * envoy_config_core_v3_ExtensionConfigSource_mutable_default_config(envoy_config_core_v3_ExtensionConfigSource *msg, upb_arena *arena)
Definition: extension.upb.h:120
UPB_INLINE envoy_config_core_v3_TypedExtensionConfig * envoy_config_core_v3_TypedExtensionConfig_parse(const char *buf, size_t size, upb_arena *arena)
Definition: extension.upb.h:40
const upb_msglayout google_protobuf_Any_msginit
Definition: any.upb.c:20
UPB_INLINE envoy_config_core_v3_ExtensionConfigSource * envoy_config_core_v3_ExtensionConfigSource_parse(const char *buf, size_t size, upb_arena *arena)
Definition: extension.upb.h:81
UPB_INLINE envoy_config_core_v3_TypedExtensionConfig * envoy_config_core_v3_TypedExtensionConfig_parse_ex(const char *buf, size_t size, upb_arena *arena, int options)
Definition: extension.upb.h:45
UPB_INLINE envoy_config_core_v3_TypedExtensionConfig * envoy_config_core_v3_TypedExtensionConfig_new(upb_arena *arena)
Definition: extension.upb.h:37
UPB_INLINE bool envoy_config_core_v3_ExtensionConfigSource_has_config_source(const envoy_config_core_v3_ExtensionConfigSource *msg)
Definition: extension.upb.h:96
upb_arena * arena
Definition: xds_api.cc:909