GRPC Core  18.0.0
wrappers.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  * google/protobuf/wrappers.proto
5  *
6  * Do not edit -- your changes will be discarded when the file is
7  * regenerated. */
8 
9 #ifndef GOOGLE_PROTOBUF_WRAPPERS_PROTO_UPB_H_
10 #define GOOGLE_PROTOBUF_WRAPPERS_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 
41 extern const upb_msglayout google_protobuf_DoubleValue_msginit;
42 extern const upb_msglayout google_protobuf_FloatValue_msginit;
43 extern const upb_msglayout google_protobuf_Int64Value_msginit;
44 extern const upb_msglayout google_protobuf_UInt64Value_msginit;
45 extern const upb_msglayout google_protobuf_Int32Value_msginit;
46 extern const upb_msglayout google_protobuf_UInt32Value_msginit;
47 extern const upb_msglayout google_protobuf_BoolValue_msginit;
48 extern const upb_msglayout google_protobuf_StringValue_msginit;
49 extern const upb_msglayout google_protobuf_BytesValue_msginit;
50 
51 
52 /* google.protobuf.DoubleValue */
53 
56 }
57 UPB_INLINE google_protobuf_DoubleValue *google_protobuf_DoubleValue_parse(const char *buf, size_t size,
58  upb_arena *arena) {
60  return (ret && upb_decode(buf, size, ret, &google_protobuf_DoubleValue_msginit, arena)) ? ret : NULL;
61 }
62 UPB_INLINE google_protobuf_DoubleValue *google_protobuf_DoubleValue_parse_ex(const char *buf, size_t size,
63  upb_arena *arena, int options) {
65  return (ret && _upb_decode(buf, size, ret, &google_protobuf_DoubleValue_msginit, arena, options))
66  ? ret : NULL;
67 }
68 UPB_INLINE char *google_protobuf_DoubleValue_serialize(const google_protobuf_DoubleValue *msg, upb_arena *arena, size_t *len) {
69  return upb_encode(msg, &google_protobuf_DoubleValue_msginit, arena, len);
70 }
71 
72 UPB_INLINE double google_protobuf_DoubleValue_value(const google_protobuf_DoubleValue *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(0, 0), double); }
73 
75  *UPB_PTR_AT(msg, UPB_SIZE(0, 0), double) = value;
76 }
77 
78 /* google.protobuf.FloatValue */
79 
82 }
83 UPB_INLINE google_protobuf_FloatValue *google_protobuf_FloatValue_parse(const char *buf, size_t size,
84  upb_arena *arena) {
86  return (ret && upb_decode(buf, size, ret, &google_protobuf_FloatValue_msginit, arena)) ? ret : NULL;
87 }
88 UPB_INLINE google_protobuf_FloatValue *google_protobuf_FloatValue_parse_ex(const char *buf, size_t size,
89  upb_arena *arena, int options) {
91  return (ret && _upb_decode(buf, size, ret, &google_protobuf_FloatValue_msginit, arena, options))
92  ? ret : NULL;
93 }
94 UPB_INLINE char *google_protobuf_FloatValue_serialize(const google_protobuf_FloatValue *msg, upb_arena *arena, size_t *len) {
95  return upb_encode(msg, &google_protobuf_FloatValue_msginit, arena, len);
96 }
97 
98 UPB_INLINE float google_protobuf_FloatValue_value(const google_protobuf_FloatValue *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(0, 0), float); }
99 
101  *UPB_PTR_AT(msg, UPB_SIZE(0, 0), float) = value;
102 }
103 
104 /* google.protobuf.Int64Value */
105 
108 }
109 UPB_INLINE google_protobuf_Int64Value *google_protobuf_Int64Value_parse(const char *buf, size_t size,
110  upb_arena *arena) {
112  return (ret && upb_decode(buf, size, ret, &google_protobuf_Int64Value_msginit, arena)) ? ret : NULL;
113 }
114 UPB_INLINE google_protobuf_Int64Value *google_protobuf_Int64Value_parse_ex(const char *buf, size_t size,
115  upb_arena *arena, int options) {
117  return (ret && _upb_decode(buf, size, ret, &google_protobuf_Int64Value_msginit, arena, options))
118  ? ret : NULL;
119 }
120 UPB_INLINE char *google_protobuf_Int64Value_serialize(const google_protobuf_Int64Value *msg, upb_arena *arena, size_t *len) {
121  return upb_encode(msg, &google_protobuf_Int64Value_msginit, arena, len);
122 }
123 
124 UPB_INLINE int64_t google_protobuf_Int64Value_value(const google_protobuf_Int64Value *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(0, 0), int64_t); }
125 
127  *UPB_PTR_AT(msg, UPB_SIZE(0, 0), int64_t) = value;
128 }
129 
130 /* google.protobuf.UInt64Value */
131 
134 }
135 UPB_INLINE google_protobuf_UInt64Value *google_protobuf_UInt64Value_parse(const char *buf, size_t size,
136  upb_arena *arena) {
138  return (ret && upb_decode(buf, size, ret, &google_protobuf_UInt64Value_msginit, arena)) ? ret : NULL;
139 }
140 UPB_INLINE google_protobuf_UInt64Value *google_protobuf_UInt64Value_parse_ex(const char *buf, size_t size,
141  upb_arena *arena, int options) {
143  return (ret && _upb_decode(buf, size, ret, &google_protobuf_UInt64Value_msginit, arena, options))
144  ? ret : NULL;
145 }
146 UPB_INLINE char *google_protobuf_UInt64Value_serialize(const google_protobuf_UInt64Value *msg, upb_arena *arena, size_t *len) {
147  return upb_encode(msg, &google_protobuf_UInt64Value_msginit, arena, len);
148 }
149 
150 UPB_INLINE uint64_t google_protobuf_UInt64Value_value(const google_protobuf_UInt64Value *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(0, 0), uint64_t); }
151 
153  *UPB_PTR_AT(msg, UPB_SIZE(0, 0), uint64_t) = value;
154 }
155 
156 /* google.protobuf.Int32Value */
157 
160 }
161 UPB_INLINE google_protobuf_Int32Value *google_protobuf_Int32Value_parse(const char *buf, size_t size,
162  upb_arena *arena) {
164  return (ret && upb_decode(buf, size, ret, &google_protobuf_Int32Value_msginit, arena)) ? ret : NULL;
165 }
166 UPB_INLINE google_protobuf_Int32Value *google_protobuf_Int32Value_parse_ex(const char *buf, size_t size,
167  upb_arena *arena, int options) {
169  return (ret && _upb_decode(buf, size, ret, &google_protobuf_Int32Value_msginit, arena, options))
170  ? ret : NULL;
171 }
172 UPB_INLINE char *google_protobuf_Int32Value_serialize(const google_protobuf_Int32Value *msg, upb_arena *arena, size_t *len) {
173  return upb_encode(msg, &google_protobuf_Int32Value_msginit, arena, len);
174 }
175 
176 UPB_INLINE int32_t google_protobuf_Int32Value_value(const google_protobuf_Int32Value *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(0, 0), int32_t); }
177 
179  *UPB_PTR_AT(msg, UPB_SIZE(0, 0), int32_t) = value;
180 }
181 
182 /* google.protobuf.UInt32Value */
183 
186 }
187 UPB_INLINE google_protobuf_UInt32Value *google_protobuf_UInt32Value_parse(const char *buf, size_t size,
188  upb_arena *arena) {
190  return (ret && upb_decode(buf, size, ret, &google_protobuf_UInt32Value_msginit, arena)) ? ret : NULL;
191 }
192 UPB_INLINE google_protobuf_UInt32Value *google_protobuf_UInt32Value_parse_ex(const char *buf, size_t size,
193  upb_arena *arena, int options) {
195  return (ret && _upb_decode(buf, size, ret, &google_protobuf_UInt32Value_msginit, arena, options))
196  ? ret : NULL;
197 }
198 UPB_INLINE char *google_protobuf_UInt32Value_serialize(const google_protobuf_UInt32Value *msg, upb_arena *arena, size_t *len) {
199  return upb_encode(msg, &google_protobuf_UInt32Value_msginit, arena, len);
200 }
201 
202 UPB_INLINE uint32_t google_protobuf_UInt32Value_value(const google_protobuf_UInt32Value *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(0, 0), uint32_t); }
203 
205  *UPB_PTR_AT(msg, UPB_SIZE(0, 0), uint32_t) = value;
206 }
207 
208 /* google.protobuf.BoolValue */
209 
212 }
213 UPB_INLINE google_protobuf_BoolValue *google_protobuf_BoolValue_parse(const char *buf, size_t size,
214  upb_arena *arena) {
216  return (ret && upb_decode(buf, size, ret, &google_protobuf_BoolValue_msginit, arena)) ? ret : NULL;
217 }
218 UPB_INLINE google_protobuf_BoolValue *google_protobuf_BoolValue_parse_ex(const char *buf, size_t size,
219  upb_arena *arena, int options) {
221  return (ret && _upb_decode(buf, size, ret, &google_protobuf_BoolValue_msginit, arena, options))
222  ? ret : NULL;
223 }
224 UPB_INLINE char *google_protobuf_BoolValue_serialize(const google_protobuf_BoolValue *msg, upb_arena *arena, size_t *len) {
225  return upb_encode(msg, &google_protobuf_BoolValue_msginit, arena, len);
226 }
227 
228 UPB_INLINE bool google_protobuf_BoolValue_value(const google_protobuf_BoolValue *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(0, 0), bool); }
229 
231  *UPB_PTR_AT(msg, UPB_SIZE(0, 0), bool) = value;
232 }
233 
234 /* google.protobuf.StringValue */
235 
238 }
239 UPB_INLINE google_protobuf_StringValue *google_protobuf_StringValue_parse(const char *buf, size_t size,
240  upb_arena *arena) {
242  return (ret && upb_decode(buf, size, ret, &google_protobuf_StringValue_msginit, arena)) ? ret : NULL;
243 }
244 UPB_INLINE google_protobuf_StringValue *google_protobuf_StringValue_parse_ex(const char *buf, size_t size,
245  upb_arena *arena, int options) {
247  return (ret && _upb_decode(buf, size, ret, &google_protobuf_StringValue_msginit, arena, options))
248  ? ret : NULL;
249 }
250 UPB_INLINE char *google_protobuf_StringValue_serialize(const google_protobuf_StringValue *msg, upb_arena *arena, size_t *len) {
251  return upb_encode(msg, &google_protobuf_StringValue_msginit, arena, len);
252 }
253 
254 UPB_INLINE upb_strview google_protobuf_StringValue_value(const google_protobuf_StringValue *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(0, 0), upb_strview); }
255 
256 UPB_INLINE void google_protobuf_StringValue_set_value(google_protobuf_StringValue *msg, upb_strview value) {
257  *UPB_PTR_AT(msg, UPB_SIZE(0, 0), upb_strview) = value;
258 }
259 
260 /* google.protobuf.BytesValue */
261 
264 }
265 UPB_INLINE google_protobuf_BytesValue *google_protobuf_BytesValue_parse(const char *buf, size_t size,
266  upb_arena *arena) {
268  return (ret && upb_decode(buf, size, ret, &google_protobuf_BytesValue_msginit, arena)) ? ret : NULL;
269 }
270 UPB_INLINE google_protobuf_BytesValue *google_protobuf_BytesValue_parse_ex(const char *buf, size_t size,
271  upb_arena *arena, int options) {
273  return (ret && _upb_decode(buf, size, ret, &google_protobuf_BytesValue_msginit, arena, options))
274  ? ret : NULL;
275 }
276 UPB_INLINE char *google_protobuf_BytesValue_serialize(const google_protobuf_BytesValue *msg, upb_arena *arena, size_t *len) {
277  return upb_encode(msg, &google_protobuf_BytesValue_msginit, arena, len);
278 }
279 
280 UPB_INLINE upb_strview google_protobuf_BytesValue_value(const google_protobuf_BytesValue *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(0, 0), upb_strview); }
281 
282 UPB_INLINE void google_protobuf_BytesValue_set_value(google_protobuf_BytesValue *msg, upb_strview value) {
283  *UPB_PTR_AT(msg, UPB_SIZE(0, 0), upb_strview) = value;
284 }
285 
286 #ifdef __cplusplus
287 } /* extern "C" */
288 #endif
289 
290 #include "upb/port_undef.inc"
291 
292 #endif /* GOOGLE_PROTOBUF_WRAPPERS_PROTO_UPB_H_ */
const upb_msglayout google_protobuf_UInt64Value_msginit
Definition: wrappers.upb.c:49
const upb_msglayout google_protobuf_Int64Value_msginit
Definition: wrappers.upb.c:39
UPB_INLINE google_protobuf_Int64Value * google_protobuf_Int64Value_new(upb_arena *arena)
Definition: wrappers.upb.h:106
UPB_INLINE upb_strview google_protobuf_BytesValue_value(const google_protobuf_BytesValue *msg)
Definition: wrappers.upb.h:280
UPB_INLINE uint64_t google_protobuf_UInt64Value_value(const google_protobuf_UInt64Value *msg)
Definition: wrappers.upb.h:150
UPB_INLINE google_protobuf_UInt64Value * google_protobuf_UInt64Value_parse_ex(const char *buf, size_t size, upb_arena *arena, int options)
Definition: wrappers.upb.h:140
UPB_INLINE google_protobuf_Int32Value * google_protobuf_Int32Value_parse(const char *buf, size_t size, upb_arena *arena)
Definition: wrappers.upb.h:161
UPB_INLINE char * google_protobuf_UInt64Value_serialize(const google_protobuf_UInt64Value *msg, upb_arena *arena, size_t *len)
Definition: wrappers.upb.h:146
struct google_protobuf_StringValue google_protobuf_StringValue
Definition: wrappers.upb.h:39
UPB_INLINE google_protobuf_Int64Value * google_protobuf_Int64Value_parse(const char *buf, size_t size, upb_arena *arena)
Definition: wrappers.upb.h:109
const upb_msglayout google_protobuf_BytesValue_msginit
Definition: wrappers.upb.c:99
UPB_INLINE google_protobuf_FloatValue * google_protobuf_FloatValue_new(upb_arena *arena)
Definition: wrappers.upb.h:80
const upb_msglayout google_protobuf_FloatValue_msginit
Definition: wrappers.upb.c:29
struct google_protobuf_UInt64Value google_protobuf_UInt64Value
Definition: wrappers.upb.h:35
struct google_protobuf_Int32Value google_protobuf_Int32Value
Definition: wrappers.upb.h:36
UPB_INLINE google_protobuf_BytesValue * google_protobuf_BytesValue_parse_ex(const char *buf, size_t size, upb_arena *arena, int options)
Definition: wrappers.upb.h:270
UPB_INLINE char * google_protobuf_BoolValue_serialize(const google_protobuf_BoolValue *msg, upb_arena *arena, size_t *len)
Definition: wrappers.upb.h:224
UPB_INLINE google_protobuf_DoubleValue * google_protobuf_DoubleValue_parse_ex(const char *buf, size_t size, upb_arena *arena, int options)
Definition: wrappers.upb.h:62
UPB_INLINE int64_t google_protobuf_Int64Value_value(const google_protobuf_Int64Value *msg)
Definition: wrappers.upb.h:124
UPB_INLINE google_protobuf_UInt32Value * google_protobuf_UInt32Value_new(upb_arena *arena)
Definition: wrappers.upb.h:184
UPB_INLINE void google_protobuf_DoubleValue_set_value(google_protobuf_DoubleValue *msg, double value)
Definition: wrappers.upb.h:74
UPB_INLINE google_protobuf_BoolValue * google_protobuf_BoolValue_new(upb_arena *arena)
Definition: wrappers.upb.h:210
UPB_INLINE google_protobuf_DoubleValue * google_protobuf_DoubleValue_new(upb_arena *arena)
Definition: wrappers.upb.h:54
UPB_INLINE google_protobuf_Int64Value * google_protobuf_Int64Value_parse_ex(const char *buf, size_t size, upb_arena *arena, int options)
Definition: wrappers.upb.h:114
UPB_INLINE uint32_t google_protobuf_UInt32Value_value(const google_protobuf_UInt32Value *msg)
Definition: wrappers.upb.h:202
struct google_protobuf_BoolValue google_protobuf_BoolValue
Definition: wrappers.upb.h:38
UPB_INLINE google_protobuf_StringValue * google_protobuf_StringValue_parse_ex(const char *buf, size_t size, upb_arena *arena, int options)
Definition: wrappers.upb.h:244
const upb_msglayout google_protobuf_UInt32Value_msginit
Definition: wrappers.upb.c:69
UPB_INLINE char * google_protobuf_BytesValue_serialize(const google_protobuf_BytesValue *msg, upb_arena *arena, size_t *len)
Definition: wrappers.upb.h:276
UPB_INLINE bool google_protobuf_BoolValue_value(const google_protobuf_BoolValue *msg)
Definition: wrappers.upb.h:228
UPB_INLINE google_protobuf_UInt32Value * google_protobuf_UInt32Value_parse(const char *buf, size_t size, upb_arena *arena)
Definition: wrappers.upb.h:187
UPB_INLINE google_protobuf_DoubleValue * google_protobuf_DoubleValue_parse(const char *buf, size_t size, upb_arena *arena)
Definition: wrappers.upb.h:57
UPB_INLINE upb_strview google_protobuf_StringValue_value(const google_protobuf_StringValue *msg)
Definition: wrappers.upb.h:254
UPB_INLINE google_protobuf_UInt64Value * google_protobuf_UInt64Value_new(upb_arena *arena)
Definition: wrappers.upb.h:132
UPB_INLINE char * google_protobuf_StringValue_serialize(const google_protobuf_StringValue *msg, upb_arena *arena, size_t *len)
Definition: wrappers.upb.h:250
UPB_INLINE google_protobuf_BoolValue * google_protobuf_BoolValue_parse_ex(const char *buf, size_t size, upb_arena *arena, int options)
Definition: wrappers.upb.h:218
UPB_INLINE google_protobuf_FloatValue * google_protobuf_FloatValue_parse(const char *buf, size_t size, upb_arena *arena)
Definition: wrappers.upb.h:83
UPB_INLINE google_protobuf_UInt32Value * google_protobuf_UInt32Value_parse_ex(const char *buf, size_t size, upb_arena *arena, int options)
Definition: wrappers.upb.h:192
UPB_INLINE google_protobuf_FloatValue * google_protobuf_FloatValue_parse_ex(const char *buf, size_t size, upb_arena *arena, int options)
Definition: wrappers.upb.h:88
UPB_INLINE void google_protobuf_Int64Value_set_value(google_protobuf_Int64Value *msg, int64_t value)
Definition: wrappers.upb.h:126
UPB_INLINE google_protobuf_BytesValue * google_protobuf_BytesValue_parse(const char *buf, size_t size, upb_arena *arena)
Definition: wrappers.upb.h:265
const upb_msglayout google_protobuf_Int32Value_msginit
Definition: wrappers.upb.c:59
const upb_msglayout google_protobuf_DoubleValue_msginit
Definition: wrappers.upb.c:19
UPB_INLINE char * google_protobuf_Int64Value_serialize(const google_protobuf_Int64Value *msg, upb_arena *arena, size_t *len)
Definition: wrappers.upb.h:120
UPB_INLINE double google_protobuf_DoubleValue_value(const google_protobuf_DoubleValue *msg)
Definition: wrappers.upb.h:72
UPB_INLINE google_protobuf_StringValue * google_protobuf_StringValue_new(upb_arena *arena)
Definition: wrappers.upb.h:236
UPB_INLINE google_protobuf_Int32Value * google_protobuf_Int32Value_parse_ex(const char *buf, size_t size, upb_arena *arena, int options)
Definition: wrappers.upb.h:166
struct google_protobuf_BytesValue google_protobuf_BytesValue
Definition: wrappers.upb.h:40
UPB_INLINE char * google_protobuf_DoubleValue_serialize(const google_protobuf_DoubleValue *msg, upb_arena *arena, size_t *len)
Definition: wrappers.upb.h:68
UPB_INLINE void google_protobuf_BoolValue_set_value(google_protobuf_BoolValue *msg, bool value)
Definition: wrappers.upb.h:230
UPB_INLINE char * google_protobuf_UInt32Value_serialize(const google_protobuf_UInt32Value *msg, upb_arena *arena, size_t *len)
Definition: wrappers.upb.h:198
UPB_INLINE google_protobuf_StringValue * google_protobuf_StringValue_parse(const char *buf, size_t size, upb_arena *arena)
Definition: wrappers.upb.h:239
UPB_INLINE google_protobuf_BytesValue * google_protobuf_BytesValue_new(upb_arena *arena)
Definition: wrappers.upb.h:262
const upb_msglayout google_protobuf_StringValue_msginit
Definition: wrappers.upb.c:89
UPB_INLINE int32_t google_protobuf_Int32Value_value(const google_protobuf_Int32Value *msg)
Definition: wrappers.upb.h:176
const upb_msglayout google_protobuf_BoolValue_msginit
Definition: wrappers.upb.c:79
struct google_protobuf_Int64Value google_protobuf_Int64Value
Definition: wrappers.upb.h:34
UPB_INLINE char * google_protobuf_Int32Value_serialize(const google_protobuf_Int32Value *msg, upb_arena *arena, size_t *len)
Definition: wrappers.upb.h:172
UPB_INLINE void google_protobuf_StringValue_set_value(google_protobuf_StringValue *msg, upb_strview value)
Definition: wrappers.upb.h:256
struct google_protobuf_FloatValue google_protobuf_FloatValue
Definition: wrappers.upb.h:33
UPB_INLINE void google_protobuf_UInt32Value_set_value(google_protobuf_UInt32Value *msg, uint32_t value)
Definition: wrappers.upb.h:204
UPB_INLINE void google_protobuf_Int32Value_set_value(google_protobuf_Int32Value *msg, int32_t value)
Definition: wrappers.upb.h:178
struct google_protobuf_UInt32Value google_protobuf_UInt32Value
Definition: wrappers.upb.h:37
UPB_INLINE char * google_protobuf_FloatValue_serialize(const google_protobuf_FloatValue *msg, upb_arena *arena, size_t *len)
Definition: wrappers.upb.h:94
UPB_INLINE float google_protobuf_FloatValue_value(const google_protobuf_FloatValue *msg)
Definition: wrappers.upb.h:98
UPB_INLINE google_protobuf_Int32Value * google_protobuf_Int32Value_new(upb_arena *arena)
Definition: wrappers.upb.h:158
UPB_INLINE google_protobuf_BoolValue * google_protobuf_BoolValue_parse(const char *buf, size_t size, upb_arena *arena)
Definition: wrappers.upb.h:213
UPB_INLINE void google_protobuf_FloatValue_set_value(google_protobuf_FloatValue *msg, float value)
Definition: wrappers.upb.h:100
UPB_INLINE void google_protobuf_UInt64Value_set_value(google_protobuf_UInt64Value *msg, uint64_t value)
Definition: wrappers.upb.h:152
UPB_INLINE google_protobuf_UInt64Value * google_protobuf_UInt64Value_parse(const char *buf, size_t size, upb_arena *arena)
Definition: wrappers.upb.h:135
struct google_protobuf_DoubleValue google_protobuf_DoubleValue
Definition: wrappers.upb.h:32
UPB_INLINE void google_protobuf_BytesValue_set_value(google_protobuf_BytesValue *msg, upb_strview value)
Definition: wrappers.upb.h:282
upb_arena * arena
Definition: xds_api.cc:909