1 /* This file was generated by upbc (the upb compiler) from the input
2 * file:
3 *
4 * validate/validate.proto
5 *
6 * Do not edit -- your changes will be discarded when the file is
7 * regenerated. */
8
9 #ifndef VALIDATE_VALIDATE_PROTO_UPB_H_
10 #define VALIDATE_VALIDATE_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 validate_FieldRules;
24 struct validate_FloatRules;
25 struct validate_DoubleRules;
26 struct validate_Int32Rules;
27 struct validate_Int64Rules;
28 struct validate_UInt32Rules;
29 struct validate_UInt64Rules;
30 struct validate_SInt32Rules;
31 struct validate_SInt64Rules;
32 struct validate_Fixed32Rules;
33 struct validate_Fixed64Rules;
34 struct validate_SFixed32Rules;
35 struct validate_SFixed64Rules;
36 struct validate_BoolRules;
37 struct validate_StringRules;
38 struct validate_BytesRules;
39 struct validate_EnumRules;
40 struct validate_MessageRules;
41 struct validate_RepeatedRules;
42 struct validate_MapRules;
43 struct validate_AnyRules;
44 struct validate_DurationRules;
45 struct validate_TimestampRules;
46 typedef struct validate_FieldRules validate_FieldRules;
47 typedef struct validate_FloatRules validate_FloatRules;
48 typedef struct validate_DoubleRules validate_DoubleRules;
49 typedef struct validate_Int32Rules validate_Int32Rules;
50 typedef struct validate_Int64Rules validate_Int64Rules;
51 typedef struct validate_UInt32Rules validate_UInt32Rules;
52 typedef struct validate_UInt64Rules validate_UInt64Rules;
53 typedef struct validate_SInt32Rules validate_SInt32Rules;
54 typedef struct validate_SInt64Rules validate_SInt64Rules;
55 typedef struct validate_Fixed32Rules validate_Fixed32Rules;
56 typedef struct validate_Fixed64Rules validate_Fixed64Rules;
57 typedef struct validate_SFixed32Rules validate_SFixed32Rules;
58 typedef struct validate_SFixed64Rules validate_SFixed64Rules;
59 typedef struct validate_BoolRules validate_BoolRules;
60 typedef struct validate_StringRules validate_StringRules;
61 typedef struct validate_BytesRules validate_BytesRules;
62 typedef struct validate_EnumRules validate_EnumRules;
63 typedef struct validate_MessageRules validate_MessageRules;
64 typedef struct validate_RepeatedRules validate_RepeatedRules;
65 typedef struct validate_MapRules validate_MapRules;
66 typedef struct validate_AnyRules validate_AnyRules;
67 typedef struct validate_DurationRules validate_DurationRules;
68 typedef struct validate_TimestampRules validate_TimestampRules;
69 extern const upb_msglayout validate_FieldRules_msginit;
70 extern const upb_msglayout validate_FloatRules_msginit;
71 extern const upb_msglayout validate_DoubleRules_msginit;
72 extern const upb_msglayout validate_Int32Rules_msginit;
73 extern const upb_msglayout validate_Int64Rules_msginit;
74 extern const upb_msglayout validate_UInt32Rules_msginit;
75 extern const upb_msglayout validate_UInt64Rules_msginit;
76 extern const upb_msglayout validate_SInt32Rules_msginit;
77 extern const upb_msglayout validate_SInt64Rules_msginit;
78 extern const upb_msglayout validate_Fixed32Rules_msginit;
79 extern const upb_msglayout validate_Fixed64Rules_msginit;
80 extern const upb_msglayout validate_SFixed32Rules_msginit;
81 extern const upb_msglayout validate_SFixed64Rules_msginit;
82 extern const upb_msglayout validate_BoolRules_msginit;
83 extern const upb_msglayout validate_StringRules_msginit;
84 extern const upb_msglayout validate_BytesRules_msginit;
85 extern const upb_msglayout validate_EnumRules_msginit;
86 extern const upb_msglayout validate_MessageRules_msginit;
87 extern const upb_msglayout validate_RepeatedRules_msginit;
88 extern const upb_msglayout validate_MapRules_msginit;
89 extern const upb_msglayout validate_AnyRules_msginit;
90 extern const upb_msglayout validate_DurationRules_msginit;
91 extern const upb_msglayout validate_TimestampRules_msginit;
92 struct google_protobuf_Duration;
93 struct google_protobuf_Timestamp;
94 extern const upb_msglayout google_protobuf_Duration_msginit;
95 extern const upb_msglayout google_protobuf_Timestamp_msginit;
96
97 typedef enum {
98 validate_UNKNOWN = 0,
99 validate_HTTP_HEADER_NAME = 1,
100 validate_HTTP_HEADER_VALUE = 2
101 } validate_KnownRegex;
102
103
104 /* validate.FieldRules */
105
validate_FieldRules_new(upb_arena * arena)106 UPB_INLINE validate_FieldRules *validate_FieldRules_new(upb_arena *arena) {
107 return (validate_FieldRules *)_upb_msg_new(&validate_FieldRules_msginit, arena);
108 }
validate_FieldRules_parse(const char * buf,size_t size,upb_arena * arena)109 UPB_INLINE validate_FieldRules *validate_FieldRules_parse(const char *buf, size_t size,
110 upb_arena *arena) {
111 validate_FieldRules *ret = validate_FieldRules_new(arena);
112 return (ret && upb_decode(buf, size, ret, &validate_FieldRules_msginit, arena)) ? ret : NULL;
113 }
validate_FieldRules_parse_ex(const char * buf,size_t size,upb_arena * arena,int options)114 UPB_INLINE validate_FieldRules *validate_FieldRules_parse_ex(const char *buf, size_t size,
115 upb_arena *arena, int options) {
116 validate_FieldRules *ret = validate_FieldRules_new(arena);
117 return (ret && _upb_decode(buf, size, ret, &validate_FieldRules_msginit, arena, options))
118 ? ret : NULL;
119 }
validate_FieldRules_serialize(const validate_FieldRules * msg,upb_arena * arena,size_t * len)120 UPB_INLINE char *validate_FieldRules_serialize(const validate_FieldRules *msg, upb_arena *arena, size_t *len) {
121 return upb_encode(msg, &validate_FieldRules_msginit, arena, len);
122 }
123
124 typedef enum {
125 validate_FieldRules_type_float = 1,
126 validate_FieldRules_type_double = 2,
127 validate_FieldRules_type_int32 = 3,
128 validate_FieldRules_type_int64 = 4,
129 validate_FieldRules_type_uint32 = 5,
130 validate_FieldRules_type_uint64 = 6,
131 validate_FieldRules_type_sint32 = 7,
132 validate_FieldRules_type_sint64 = 8,
133 validate_FieldRules_type_fixed32 = 9,
134 validate_FieldRules_type_fixed64 = 10,
135 validate_FieldRules_type_sfixed32 = 11,
136 validate_FieldRules_type_sfixed64 = 12,
137 validate_FieldRules_type_bool = 13,
138 validate_FieldRules_type_string = 14,
139 validate_FieldRules_type_bytes = 15,
140 validate_FieldRules_type_enum = 16,
141 validate_FieldRules_type_repeated = 18,
142 validate_FieldRules_type_map = 19,
143 validate_FieldRules_type_any = 20,
144 validate_FieldRules_type_duration = 21,
145 validate_FieldRules_type_timestamp = 22,
146 validate_FieldRules_type_NOT_SET = 0
147 } validate_FieldRules_type_oneofcases;
validate_FieldRules_type_case(const validate_FieldRules * msg)148 UPB_INLINE validate_FieldRules_type_oneofcases validate_FieldRules_type_case(const validate_FieldRules* msg) { return (validate_FieldRules_type_oneofcases)*UPB_PTR_AT(msg, UPB_SIZE(12, 24), int32_t); }
149
validate_FieldRules_has_float(const validate_FieldRules * msg)150 UPB_INLINE bool validate_FieldRules_has_float(const validate_FieldRules *msg) { return _upb_getoneofcase(msg, UPB_SIZE(12, 24)) == 1; }
validate_FieldRules_float(const validate_FieldRules * msg)151 UPB_INLINE const validate_FloatRules* validate_FieldRules_float(const validate_FieldRules *msg) { return UPB_READ_ONEOF(msg, const validate_FloatRules*, UPB_SIZE(8, 16), UPB_SIZE(12, 24), 1, NULL); }
validate_FieldRules_has_double(const validate_FieldRules * msg)152 UPB_INLINE bool validate_FieldRules_has_double(const validate_FieldRules *msg) { return _upb_getoneofcase(msg, UPB_SIZE(12, 24)) == 2; }
validate_FieldRules_double(const validate_FieldRules * msg)153 UPB_INLINE const validate_DoubleRules* validate_FieldRules_double(const validate_FieldRules *msg) { return UPB_READ_ONEOF(msg, const validate_DoubleRules*, UPB_SIZE(8, 16), UPB_SIZE(12, 24), 2, NULL); }
validate_FieldRules_has_int32(const validate_FieldRules * msg)154 UPB_INLINE bool validate_FieldRules_has_int32(const validate_FieldRules *msg) { return _upb_getoneofcase(msg, UPB_SIZE(12, 24)) == 3; }
validate_FieldRules_int32(const validate_FieldRules * msg)155 UPB_INLINE const validate_Int32Rules* validate_FieldRules_int32(const validate_FieldRules *msg) { return UPB_READ_ONEOF(msg, const validate_Int32Rules*, UPB_SIZE(8, 16), UPB_SIZE(12, 24), 3, NULL); }
validate_FieldRules_has_int64(const validate_FieldRules * msg)156 UPB_INLINE bool validate_FieldRules_has_int64(const validate_FieldRules *msg) { return _upb_getoneofcase(msg, UPB_SIZE(12, 24)) == 4; }
validate_FieldRules_int64(const validate_FieldRules * msg)157 UPB_INLINE const validate_Int64Rules* validate_FieldRules_int64(const validate_FieldRules *msg) { return UPB_READ_ONEOF(msg, const validate_Int64Rules*, UPB_SIZE(8, 16), UPB_SIZE(12, 24), 4, NULL); }
validate_FieldRules_has_uint32(const validate_FieldRules * msg)158 UPB_INLINE bool validate_FieldRules_has_uint32(const validate_FieldRules *msg) { return _upb_getoneofcase(msg, UPB_SIZE(12, 24)) == 5; }
validate_FieldRules_uint32(const validate_FieldRules * msg)159 UPB_INLINE const validate_UInt32Rules* validate_FieldRules_uint32(const validate_FieldRules *msg) { return UPB_READ_ONEOF(msg, const validate_UInt32Rules*, UPB_SIZE(8, 16), UPB_SIZE(12, 24), 5, NULL); }
validate_FieldRules_has_uint64(const validate_FieldRules * msg)160 UPB_INLINE bool validate_FieldRules_has_uint64(const validate_FieldRules *msg) { return _upb_getoneofcase(msg, UPB_SIZE(12, 24)) == 6; }
validate_FieldRules_uint64(const validate_FieldRules * msg)161 UPB_INLINE const validate_UInt64Rules* validate_FieldRules_uint64(const validate_FieldRules *msg) { return UPB_READ_ONEOF(msg, const validate_UInt64Rules*, UPB_SIZE(8, 16), UPB_SIZE(12, 24), 6, NULL); }
validate_FieldRules_has_sint32(const validate_FieldRules * msg)162 UPB_INLINE bool validate_FieldRules_has_sint32(const validate_FieldRules *msg) { return _upb_getoneofcase(msg, UPB_SIZE(12, 24)) == 7; }
validate_FieldRules_sint32(const validate_FieldRules * msg)163 UPB_INLINE const validate_SInt32Rules* validate_FieldRules_sint32(const validate_FieldRules *msg) { return UPB_READ_ONEOF(msg, const validate_SInt32Rules*, UPB_SIZE(8, 16), UPB_SIZE(12, 24), 7, NULL); }
validate_FieldRules_has_sint64(const validate_FieldRules * msg)164 UPB_INLINE bool validate_FieldRules_has_sint64(const validate_FieldRules *msg) { return _upb_getoneofcase(msg, UPB_SIZE(12, 24)) == 8; }
validate_FieldRules_sint64(const validate_FieldRules * msg)165 UPB_INLINE const validate_SInt64Rules* validate_FieldRules_sint64(const validate_FieldRules *msg) { return UPB_READ_ONEOF(msg, const validate_SInt64Rules*, UPB_SIZE(8, 16), UPB_SIZE(12, 24), 8, NULL); }
validate_FieldRules_has_fixed32(const validate_FieldRules * msg)166 UPB_INLINE bool validate_FieldRules_has_fixed32(const validate_FieldRules *msg) { return _upb_getoneofcase(msg, UPB_SIZE(12, 24)) == 9; }
validate_FieldRules_fixed32(const validate_FieldRules * msg)167 UPB_INLINE const validate_Fixed32Rules* validate_FieldRules_fixed32(const validate_FieldRules *msg) { return UPB_READ_ONEOF(msg, const validate_Fixed32Rules*, UPB_SIZE(8, 16), UPB_SIZE(12, 24), 9, NULL); }
validate_FieldRules_has_fixed64(const validate_FieldRules * msg)168 UPB_INLINE bool validate_FieldRules_has_fixed64(const validate_FieldRules *msg) { return _upb_getoneofcase(msg, UPB_SIZE(12, 24)) == 10; }
validate_FieldRules_fixed64(const validate_FieldRules * msg)169 UPB_INLINE const validate_Fixed64Rules* validate_FieldRules_fixed64(const validate_FieldRules *msg) { return UPB_READ_ONEOF(msg, const validate_Fixed64Rules*, UPB_SIZE(8, 16), UPB_SIZE(12, 24), 10, NULL); }
validate_FieldRules_has_sfixed32(const validate_FieldRules * msg)170 UPB_INLINE bool validate_FieldRules_has_sfixed32(const validate_FieldRules *msg) { return _upb_getoneofcase(msg, UPB_SIZE(12, 24)) == 11; }
validate_FieldRules_sfixed32(const validate_FieldRules * msg)171 UPB_INLINE const validate_SFixed32Rules* validate_FieldRules_sfixed32(const validate_FieldRules *msg) { return UPB_READ_ONEOF(msg, const validate_SFixed32Rules*, UPB_SIZE(8, 16), UPB_SIZE(12, 24), 11, NULL); }
validate_FieldRules_has_sfixed64(const validate_FieldRules * msg)172 UPB_INLINE bool validate_FieldRules_has_sfixed64(const validate_FieldRules *msg) { return _upb_getoneofcase(msg, UPB_SIZE(12, 24)) == 12; }
validate_FieldRules_sfixed64(const validate_FieldRules * msg)173 UPB_INLINE const validate_SFixed64Rules* validate_FieldRules_sfixed64(const validate_FieldRules *msg) { return UPB_READ_ONEOF(msg, const validate_SFixed64Rules*, UPB_SIZE(8, 16), UPB_SIZE(12, 24), 12, NULL); }
validate_FieldRules_has_bool(const validate_FieldRules * msg)174 UPB_INLINE bool validate_FieldRules_has_bool(const validate_FieldRules *msg) { return _upb_getoneofcase(msg, UPB_SIZE(12, 24)) == 13; }
validate_FieldRules_bool(const validate_FieldRules * msg)175 UPB_INLINE const validate_BoolRules* validate_FieldRules_bool(const validate_FieldRules *msg) { return UPB_READ_ONEOF(msg, const validate_BoolRules*, UPB_SIZE(8, 16), UPB_SIZE(12, 24), 13, NULL); }
validate_FieldRules_has_string(const validate_FieldRules * msg)176 UPB_INLINE bool validate_FieldRules_has_string(const validate_FieldRules *msg) { return _upb_getoneofcase(msg, UPB_SIZE(12, 24)) == 14; }
validate_FieldRules_string(const validate_FieldRules * msg)177 UPB_INLINE const validate_StringRules* validate_FieldRules_string(const validate_FieldRules *msg) { return UPB_READ_ONEOF(msg, const validate_StringRules*, UPB_SIZE(8, 16), UPB_SIZE(12, 24), 14, NULL); }
validate_FieldRules_has_bytes(const validate_FieldRules * msg)178 UPB_INLINE bool validate_FieldRules_has_bytes(const validate_FieldRules *msg) { return _upb_getoneofcase(msg, UPB_SIZE(12, 24)) == 15; }
validate_FieldRules_bytes(const validate_FieldRules * msg)179 UPB_INLINE const validate_BytesRules* validate_FieldRules_bytes(const validate_FieldRules *msg) { return UPB_READ_ONEOF(msg, const validate_BytesRules*, UPB_SIZE(8, 16), UPB_SIZE(12, 24), 15, NULL); }
validate_FieldRules_has_enum(const validate_FieldRules * msg)180 UPB_INLINE bool validate_FieldRules_has_enum(const validate_FieldRules *msg) { return _upb_getoneofcase(msg, UPB_SIZE(12, 24)) == 16; }
validate_FieldRules_enum(const validate_FieldRules * msg)181 UPB_INLINE const validate_EnumRules* validate_FieldRules_enum(const validate_FieldRules *msg) { return UPB_READ_ONEOF(msg, const validate_EnumRules*, UPB_SIZE(8, 16), UPB_SIZE(12, 24), 16, NULL); }
validate_FieldRules_has_message(const validate_FieldRules * msg)182 UPB_INLINE bool validate_FieldRules_has_message(const validate_FieldRules *msg) { return _upb_hasbit(msg, 1); }
validate_FieldRules_message(const validate_FieldRules * msg)183 UPB_INLINE const validate_MessageRules* validate_FieldRules_message(const validate_FieldRules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(4, 8), const validate_MessageRules*); }
validate_FieldRules_has_repeated(const validate_FieldRules * msg)184 UPB_INLINE bool validate_FieldRules_has_repeated(const validate_FieldRules *msg) { return _upb_getoneofcase(msg, UPB_SIZE(12, 24)) == 18; }
validate_FieldRules_repeated(const validate_FieldRules * msg)185 UPB_INLINE const validate_RepeatedRules* validate_FieldRules_repeated(const validate_FieldRules *msg) { return UPB_READ_ONEOF(msg, const validate_RepeatedRules*, UPB_SIZE(8, 16), UPB_SIZE(12, 24), 18, NULL); }
validate_FieldRules_has_map(const validate_FieldRules * msg)186 UPB_INLINE bool validate_FieldRules_has_map(const validate_FieldRules *msg) { return _upb_getoneofcase(msg, UPB_SIZE(12, 24)) == 19; }
validate_FieldRules_map(const validate_FieldRules * msg)187 UPB_INLINE const validate_MapRules* validate_FieldRules_map(const validate_FieldRules *msg) { return UPB_READ_ONEOF(msg, const validate_MapRules*, UPB_SIZE(8, 16), UPB_SIZE(12, 24), 19, NULL); }
validate_FieldRules_has_any(const validate_FieldRules * msg)188 UPB_INLINE bool validate_FieldRules_has_any(const validate_FieldRules *msg) { return _upb_getoneofcase(msg, UPB_SIZE(12, 24)) == 20; }
validate_FieldRules_any(const validate_FieldRules * msg)189 UPB_INLINE const validate_AnyRules* validate_FieldRules_any(const validate_FieldRules *msg) { return UPB_READ_ONEOF(msg, const validate_AnyRules*, UPB_SIZE(8, 16), UPB_SIZE(12, 24), 20, NULL); }
validate_FieldRules_has_duration(const validate_FieldRules * msg)190 UPB_INLINE bool validate_FieldRules_has_duration(const validate_FieldRules *msg) { return _upb_getoneofcase(msg, UPB_SIZE(12, 24)) == 21; }
validate_FieldRules_duration(const validate_FieldRules * msg)191 UPB_INLINE const validate_DurationRules* validate_FieldRules_duration(const validate_FieldRules *msg) { return UPB_READ_ONEOF(msg, const validate_DurationRules*, UPB_SIZE(8, 16), UPB_SIZE(12, 24), 21, NULL); }
validate_FieldRules_has_timestamp(const validate_FieldRules * msg)192 UPB_INLINE bool validate_FieldRules_has_timestamp(const validate_FieldRules *msg) { return _upb_getoneofcase(msg, UPB_SIZE(12, 24)) == 22; }
validate_FieldRules_timestamp(const validate_FieldRules * msg)193 UPB_INLINE const validate_TimestampRules* validate_FieldRules_timestamp(const validate_FieldRules *msg) { return UPB_READ_ONEOF(msg, const validate_TimestampRules*, UPB_SIZE(8, 16), UPB_SIZE(12, 24), 22, NULL); }
194
validate_FieldRules_set_float(validate_FieldRules * msg,validate_FloatRules * value)195 UPB_INLINE void validate_FieldRules_set_float(validate_FieldRules *msg, validate_FloatRules* value) {
196 UPB_WRITE_ONEOF(msg, validate_FloatRules*, UPB_SIZE(8, 16), value, UPB_SIZE(12, 24), 1);
197 }
validate_FieldRules_mutable_float(validate_FieldRules * msg,upb_arena * arena)198 UPB_INLINE struct validate_FloatRules* validate_FieldRules_mutable_float(validate_FieldRules *msg, upb_arena *arena) {
199 struct validate_FloatRules* sub = (struct validate_FloatRules*)validate_FieldRules_float(msg);
200 if (sub == NULL) {
201 sub = (struct validate_FloatRules*)_upb_msg_new(&validate_FloatRules_msginit, arena);
202 if (!sub) return NULL;
203 validate_FieldRules_set_float(msg, sub);
204 }
205 return sub;
206 }
validate_FieldRules_set_double(validate_FieldRules * msg,validate_DoubleRules * value)207 UPB_INLINE void validate_FieldRules_set_double(validate_FieldRules *msg, validate_DoubleRules* value) {
208 UPB_WRITE_ONEOF(msg, validate_DoubleRules*, UPB_SIZE(8, 16), value, UPB_SIZE(12, 24), 2);
209 }
validate_FieldRules_mutable_double(validate_FieldRules * msg,upb_arena * arena)210 UPB_INLINE struct validate_DoubleRules* validate_FieldRules_mutable_double(validate_FieldRules *msg, upb_arena *arena) {
211 struct validate_DoubleRules* sub = (struct validate_DoubleRules*)validate_FieldRules_double(msg);
212 if (sub == NULL) {
213 sub = (struct validate_DoubleRules*)_upb_msg_new(&validate_DoubleRules_msginit, arena);
214 if (!sub) return NULL;
215 validate_FieldRules_set_double(msg, sub);
216 }
217 return sub;
218 }
validate_FieldRules_set_int32(validate_FieldRules * msg,validate_Int32Rules * value)219 UPB_INLINE void validate_FieldRules_set_int32(validate_FieldRules *msg, validate_Int32Rules* value) {
220 UPB_WRITE_ONEOF(msg, validate_Int32Rules*, UPB_SIZE(8, 16), value, UPB_SIZE(12, 24), 3);
221 }
validate_FieldRules_mutable_int32(validate_FieldRules * msg,upb_arena * arena)222 UPB_INLINE struct validate_Int32Rules* validate_FieldRules_mutable_int32(validate_FieldRules *msg, upb_arena *arena) {
223 struct validate_Int32Rules* sub = (struct validate_Int32Rules*)validate_FieldRules_int32(msg);
224 if (sub == NULL) {
225 sub = (struct validate_Int32Rules*)_upb_msg_new(&validate_Int32Rules_msginit, arena);
226 if (!sub) return NULL;
227 validate_FieldRules_set_int32(msg, sub);
228 }
229 return sub;
230 }
validate_FieldRules_set_int64(validate_FieldRules * msg,validate_Int64Rules * value)231 UPB_INLINE void validate_FieldRules_set_int64(validate_FieldRules *msg, validate_Int64Rules* value) {
232 UPB_WRITE_ONEOF(msg, validate_Int64Rules*, UPB_SIZE(8, 16), value, UPB_SIZE(12, 24), 4);
233 }
validate_FieldRules_mutable_int64(validate_FieldRules * msg,upb_arena * arena)234 UPB_INLINE struct validate_Int64Rules* validate_FieldRules_mutable_int64(validate_FieldRules *msg, upb_arena *arena) {
235 struct validate_Int64Rules* sub = (struct validate_Int64Rules*)validate_FieldRules_int64(msg);
236 if (sub == NULL) {
237 sub = (struct validate_Int64Rules*)_upb_msg_new(&validate_Int64Rules_msginit, arena);
238 if (!sub) return NULL;
239 validate_FieldRules_set_int64(msg, sub);
240 }
241 return sub;
242 }
validate_FieldRules_set_uint32(validate_FieldRules * msg,validate_UInt32Rules * value)243 UPB_INLINE void validate_FieldRules_set_uint32(validate_FieldRules *msg, validate_UInt32Rules* value) {
244 UPB_WRITE_ONEOF(msg, validate_UInt32Rules*, UPB_SIZE(8, 16), value, UPB_SIZE(12, 24), 5);
245 }
validate_FieldRules_mutable_uint32(validate_FieldRules * msg,upb_arena * arena)246 UPB_INLINE struct validate_UInt32Rules* validate_FieldRules_mutable_uint32(validate_FieldRules *msg, upb_arena *arena) {
247 struct validate_UInt32Rules* sub = (struct validate_UInt32Rules*)validate_FieldRules_uint32(msg);
248 if (sub == NULL) {
249 sub = (struct validate_UInt32Rules*)_upb_msg_new(&validate_UInt32Rules_msginit, arena);
250 if (!sub) return NULL;
251 validate_FieldRules_set_uint32(msg, sub);
252 }
253 return sub;
254 }
validate_FieldRules_set_uint64(validate_FieldRules * msg,validate_UInt64Rules * value)255 UPB_INLINE void validate_FieldRules_set_uint64(validate_FieldRules *msg, validate_UInt64Rules* value) {
256 UPB_WRITE_ONEOF(msg, validate_UInt64Rules*, UPB_SIZE(8, 16), value, UPB_SIZE(12, 24), 6);
257 }
validate_FieldRules_mutable_uint64(validate_FieldRules * msg,upb_arena * arena)258 UPB_INLINE struct validate_UInt64Rules* validate_FieldRules_mutable_uint64(validate_FieldRules *msg, upb_arena *arena) {
259 struct validate_UInt64Rules* sub = (struct validate_UInt64Rules*)validate_FieldRules_uint64(msg);
260 if (sub == NULL) {
261 sub = (struct validate_UInt64Rules*)_upb_msg_new(&validate_UInt64Rules_msginit, arena);
262 if (!sub) return NULL;
263 validate_FieldRules_set_uint64(msg, sub);
264 }
265 return sub;
266 }
validate_FieldRules_set_sint32(validate_FieldRules * msg,validate_SInt32Rules * value)267 UPB_INLINE void validate_FieldRules_set_sint32(validate_FieldRules *msg, validate_SInt32Rules* value) {
268 UPB_WRITE_ONEOF(msg, validate_SInt32Rules*, UPB_SIZE(8, 16), value, UPB_SIZE(12, 24), 7);
269 }
validate_FieldRules_mutable_sint32(validate_FieldRules * msg,upb_arena * arena)270 UPB_INLINE struct validate_SInt32Rules* validate_FieldRules_mutable_sint32(validate_FieldRules *msg, upb_arena *arena) {
271 struct validate_SInt32Rules* sub = (struct validate_SInt32Rules*)validate_FieldRules_sint32(msg);
272 if (sub == NULL) {
273 sub = (struct validate_SInt32Rules*)_upb_msg_new(&validate_SInt32Rules_msginit, arena);
274 if (!sub) return NULL;
275 validate_FieldRules_set_sint32(msg, sub);
276 }
277 return sub;
278 }
validate_FieldRules_set_sint64(validate_FieldRules * msg,validate_SInt64Rules * value)279 UPB_INLINE void validate_FieldRules_set_sint64(validate_FieldRules *msg, validate_SInt64Rules* value) {
280 UPB_WRITE_ONEOF(msg, validate_SInt64Rules*, UPB_SIZE(8, 16), value, UPB_SIZE(12, 24), 8);
281 }
validate_FieldRules_mutable_sint64(validate_FieldRules * msg,upb_arena * arena)282 UPB_INLINE struct validate_SInt64Rules* validate_FieldRules_mutable_sint64(validate_FieldRules *msg, upb_arena *arena) {
283 struct validate_SInt64Rules* sub = (struct validate_SInt64Rules*)validate_FieldRules_sint64(msg);
284 if (sub == NULL) {
285 sub = (struct validate_SInt64Rules*)_upb_msg_new(&validate_SInt64Rules_msginit, arena);
286 if (!sub) return NULL;
287 validate_FieldRules_set_sint64(msg, sub);
288 }
289 return sub;
290 }
validate_FieldRules_set_fixed32(validate_FieldRules * msg,validate_Fixed32Rules * value)291 UPB_INLINE void validate_FieldRules_set_fixed32(validate_FieldRules *msg, validate_Fixed32Rules* value) {
292 UPB_WRITE_ONEOF(msg, validate_Fixed32Rules*, UPB_SIZE(8, 16), value, UPB_SIZE(12, 24), 9);
293 }
validate_FieldRules_mutable_fixed32(validate_FieldRules * msg,upb_arena * arena)294 UPB_INLINE struct validate_Fixed32Rules* validate_FieldRules_mutable_fixed32(validate_FieldRules *msg, upb_arena *arena) {
295 struct validate_Fixed32Rules* sub = (struct validate_Fixed32Rules*)validate_FieldRules_fixed32(msg);
296 if (sub == NULL) {
297 sub = (struct validate_Fixed32Rules*)_upb_msg_new(&validate_Fixed32Rules_msginit, arena);
298 if (!sub) return NULL;
299 validate_FieldRules_set_fixed32(msg, sub);
300 }
301 return sub;
302 }
validate_FieldRules_set_fixed64(validate_FieldRules * msg,validate_Fixed64Rules * value)303 UPB_INLINE void validate_FieldRules_set_fixed64(validate_FieldRules *msg, validate_Fixed64Rules* value) {
304 UPB_WRITE_ONEOF(msg, validate_Fixed64Rules*, UPB_SIZE(8, 16), value, UPB_SIZE(12, 24), 10);
305 }
validate_FieldRules_mutable_fixed64(validate_FieldRules * msg,upb_arena * arena)306 UPB_INLINE struct validate_Fixed64Rules* validate_FieldRules_mutable_fixed64(validate_FieldRules *msg, upb_arena *arena) {
307 struct validate_Fixed64Rules* sub = (struct validate_Fixed64Rules*)validate_FieldRules_fixed64(msg);
308 if (sub == NULL) {
309 sub = (struct validate_Fixed64Rules*)_upb_msg_new(&validate_Fixed64Rules_msginit, arena);
310 if (!sub) return NULL;
311 validate_FieldRules_set_fixed64(msg, sub);
312 }
313 return sub;
314 }
validate_FieldRules_set_sfixed32(validate_FieldRules * msg,validate_SFixed32Rules * value)315 UPB_INLINE void validate_FieldRules_set_sfixed32(validate_FieldRules *msg, validate_SFixed32Rules* value) {
316 UPB_WRITE_ONEOF(msg, validate_SFixed32Rules*, UPB_SIZE(8, 16), value, UPB_SIZE(12, 24), 11);
317 }
validate_FieldRules_mutable_sfixed32(validate_FieldRules * msg,upb_arena * arena)318 UPB_INLINE struct validate_SFixed32Rules* validate_FieldRules_mutable_sfixed32(validate_FieldRules *msg, upb_arena *arena) {
319 struct validate_SFixed32Rules* sub = (struct validate_SFixed32Rules*)validate_FieldRules_sfixed32(msg);
320 if (sub == NULL) {
321 sub = (struct validate_SFixed32Rules*)_upb_msg_new(&validate_SFixed32Rules_msginit, arena);
322 if (!sub) return NULL;
323 validate_FieldRules_set_sfixed32(msg, sub);
324 }
325 return sub;
326 }
validate_FieldRules_set_sfixed64(validate_FieldRules * msg,validate_SFixed64Rules * value)327 UPB_INLINE void validate_FieldRules_set_sfixed64(validate_FieldRules *msg, validate_SFixed64Rules* value) {
328 UPB_WRITE_ONEOF(msg, validate_SFixed64Rules*, UPB_SIZE(8, 16), value, UPB_SIZE(12, 24), 12);
329 }
validate_FieldRules_mutable_sfixed64(validate_FieldRules * msg,upb_arena * arena)330 UPB_INLINE struct validate_SFixed64Rules* validate_FieldRules_mutable_sfixed64(validate_FieldRules *msg, upb_arena *arena) {
331 struct validate_SFixed64Rules* sub = (struct validate_SFixed64Rules*)validate_FieldRules_sfixed64(msg);
332 if (sub == NULL) {
333 sub = (struct validate_SFixed64Rules*)_upb_msg_new(&validate_SFixed64Rules_msginit, arena);
334 if (!sub) return NULL;
335 validate_FieldRules_set_sfixed64(msg, sub);
336 }
337 return sub;
338 }
validate_FieldRules_set_bool(validate_FieldRules * msg,validate_BoolRules * value)339 UPB_INLINE void validate_FieldRules_set_bool(validate_FieldRules *msg, validate_BoolRules* value) {
340 UPB_WRITE_ONEOF(msg, validate_BoolRules*, UPB_SIZE(8, 16), value, UPB_SIZE(12, 24), 13);
341 }
validate_FieldRules_mutable_bool(validate_FieldRules * msg,upb_arena * arena)342 UPB_INLINE struct validate_BoolRules* validate_FieldRules_mutable_bool(validate_FieldRules *msg, upb_arena *arena) {
343 struct validate_BoolRules* sub = (struct validate_BoolRules*)validate_FieldRules_bool(msg);
344 if (sub == NULL) {
345 sub = (struct validate_BoolRules*)_upb_msg_new(&validate_BoolRules_msginit, arena);
346 if (!sub) return NULL;
347 validate_FieldRules_set_bool(msg, sub);
348 }
349 return sub;
350 }
validate_FieldRules_set_string(validate_FieldRules * msg,validate_StringRules * value)351 UPB_INLINE void validate_FieldRules_set_string(validate_FieldRules *msg, validate_StringRules* value) {
352 UPB_WRITE_ONEOF(msg, validate_StringRules*, UPB_SIZE(8, 16), value, UPB_SIZE(12, 24), 14);
353 }
validate_FieldRules_mutable_string(validate_FieldRules * msg,upb_arena * arena)354 UPB_INLINE struct validate_StringRules* validate_FieldRules_mutable_string(validate_FieldRules *msg, upb_arena *arena) {
355 struct validate_StringRules* sub = (struct validate_StringRules*)validate_FieldRules_string(msg);
356 if (sub == NULL) {
357 sub = (struct validate_StringRules*)_upb_msg_new(&validate_StringRules_msginit, arena);
358 if (!sub) return NULL;
359 validate_FieldRules_set_string(msg, sub);
360 }
361 return sub;
362 }
validate_FieldRules_set_bytes(validate_FieldRules * msg,validate_BytesRules * value)363 UPB_INLINE void validate_FieldRules_set_bytes(validate_FieldRules *msg, validate_BytesRules* value) {
364 UPB_WRITE_ONEOF(msg, validate_BytesRules*, UPB_SIZE(8, 16), value, UPB_SIZE(12, 24), 15);
365 }
validate_FieldRules_mutable_bytes(validate_FieldRules * msg,upb_arena * arena)366 UPB_INLINE struct validate_BytesRules* validate_FieldRules_mutable_bytes(validate_FieldRules *msg, upb_arena *arena) {
367 struct validate_BytesRules* sub = (struct validate_BytesRules*)validate_FieldRules_bytes(msg);
368 if (sub == NULL) {
369 sub = (struct validate_BytesRules*)_upb_msg_new(&validate_BytesRules_msginit, arena);
370 if (!sub) return NULL;
371 validate_FieldRules_set_bytes(msg, sub);
372 }
373 return sub;
374 }
validate_FieldRules_set_enum(validate_FieldRules * msg,validate_EnumRules * value)375 UPB_INLINE void validate_FieldRules_set_enum(validate_FieldRules *msg, validate_EnumRules* value) {
376 UPB_WRITE_ONEOF(msg, validate_EnumRules*, UPB_SIZE(8, 16), value, UPB_SIZE(12, 24), 16);
377 }
validate_FieldRules_mutable_enum(validate_FieldRules * msg,upb_arena * arena)378 UPB_INLINE struct validate_EnumRules* validate_FieldRules_mutable_enum(validate_FieldRules *msg, upb_arena *arena) {
379 struct validate_EnumRules* sub = (struct validate_EnumRules*)validate_FieldRules_enum(msg);
380 if (sub == NULL) {
381 sub = (struct validate_EnumRules*)_upb_msg_new(&validate_EnumRules_msginit, arena);
382 if (!sub) return NULL;
383 validate_FieldRules_set_enum(msg, sub);
384 }
385 return sub;
386 }
validate_FieldRules_set_message(validate_FieldRules * msg,validate_MessageRules * value)387 UPB_INLINE void validate_FieldRules_set_message(validate_FieldRules *msg, validate_MessageRules* value) {
388 _upb_sethas(msg, 1);
389 *UPB_PTR_AT(msg, UPB_SIZE(4, 8), validate_MessageRules*) = value;
390 }
validate_FieldRules_mutable_message(validate_FieldRules * msg,upb_arena * arena)391 UPB_INLINE struct validate_MessageRules* validate_FieldRules_mutable_message(validate_FieldRules *msg, upb_arena *arena) {
392 struct validate_MessageRules* sub = (struct validate_MessageRules*)validate_FieldRules_message(msg);
393 if (sub == NULL) {
394 sub = (struct validate_MessageRules*)_upb_msg_new(&validate_MessageRules_msginit, arena);
395 if (!sub) return NULL;
396 validate_FieldRules_set_message(msg, sub);
397 }
398 return sub;
399 }
validate_FieldRules_set_repeated(validate_FieldRules * msg,validate_RepeatedRules * value)400 UPB_INLINE void validate_FieldRules_set_repeated(validate_FieldRules *msg, validate_RepeatedRules* value) {
401 UPB_WRITE_ONEOF(msg, validate_RepeatedRules*, UPB_SIZE(8, 16), value, UPB_SIZE(12, 24), 18);
402 }
validate_FieldRules_mutable_repeated(validate_FieldRules * msg,upb_arena * arena)403 UPB_INLINE struct validate_RepeatedRules* validate_FieldRules_mutable_repeated(validate_FieldRules *msg, upb_arena *arena) {
404 struct validate_RepeatedRules* sub = (struct validate_RepeatedRules*)validate_FieldRules_repeated(msg);
405 if (sub == NULL) {
406 sub = (struct validate_RepeatedRules*)_upb_msg_new(&validate_RepeatedRules_msginit, arena);
407 if (!sub) return NULL;
408 validate_FieldRules_set_repeated(msg, sub);
409 }
410 return sub;
411 }
validate_FieldRules_set_map(validate_FieldRules * msg,validate_MapRules * value)412 UPB_INLINE void validate_FieldRules_set_map(validate_FieldRules *msg, validate_MapRules* value) {
413 UPB_WRITE_ONEOF(msg, validate_MapRules*, UPB_SIZE(8, 16), value, UPB_SIZE(12, 24), 19);
414 }
validate_FieldRules_mutable_map(validate_FieldRules * msg,upb_arena * arena)415 UPB_INLINE struct validate_MapRules* validate_FieldRules_mutable_map(validate_FieldRules *msg, upb_arena *arena) {
416 struct validate_MapRules* sub = (struct validate_MapRules*)validate_FieldRules_map(msg);
417 if (sub == NULL) {
418 sub = (struct validate_MapRules*)_upb_msg_new(&validate_MapRules_msginit, arena);
419 if (!sub) return NULL;
420 validate_FieldRules_set_map(msg, sub);
421 }
422 return sub;
423 }
validate_FieldRules_set_any(validate_FieldRules * msg,validate_AnyRules * value)424 UPB_INLINE void validate_FieldRules_set_any(validate_FieldRules *msg, validate_AnyRules* value) {
425 UPB_WRITE_ONEOF(msg, validate_AnyRules*, UPB_SIZE(8, 16), value, UPB_SIZE(12, 24), 20);
426 }
validate_FieldRules_mutable_any(validate_FieldRules * msg,upb_arena * arena)427 UPB_INLINE struct validate_AnyRules* validate_FieldRules_mutable_any(validate_FieldRules *msg, upb_arena *arena) {
428 struct validate_AnyRules* sub = (struct validate_AnyRules*)validate_FieldRules_any(msg);
429 if (sub == NULL) {
430 sub = (struct validate_AnyRules*)_upb_msg_new(&validate_AnyRules_msginit, arena);
431 if (!sub) return NULL;
432 validate_FieldRules_set_any(msg, sub);
433 }
434 return sub;
435 }
validate_FieldRules_set_duration(validate_FieldRules * msg,validate_DurationRules * value)436 UPB_INLINE void validate_FieldRules_set_duration(validate_FieldRules *msg, validate_DurationRules* value) {
437 UPB_WRITE_ONEOF(msg, validate_DurationRules*, UPB_SIZE(8, 16), value, UPB_SIZE(12, 24), 21);
438 }
validate_FieldRules_mutable_duration(validate_FieldRules * msg,upb_arena * arena)439 UPB_INLINE struct validate_DurationRules* validate_FieldRules_mutable_duration(validate_FieldRules *msg, upb_arena *arena) {
440 struct validate_DurationRules* sub = (struct validate_DurationRules*)validate_FieldRules_duration(msg);
441 if (sub == NULL) {
442 sub = (struct validate_DurationRules*)_upb_msg_new(&validate_DurationRules_msginit, arena);
443 if (!sub) return NULL;
444 validate_FieldRules_set_duration(msg, sub);
445 }
446 return sub;
447 }
validate_FieldRules_set_timestamp(validate_FieldRules * msg,validate_TimestampRules * value)448 UPB_INLINE void validate_FieldRules_set_timestamp(validate_FieldRules *msg, validate_TimestampRules* value) {
449 UPB_WRITE_ONEOF(msg, validate_TimestampRules*, UPB_SIZE(8, 16), value, UPB_SIZE(12, 24), 22);
450 }
validate_FieldRules_mutable_timestamp(validate_FieldRules * msg,upb_arena * arena)451 UPB_INLINE struct validate_TimestampRules* validate_FieldRules_mutable_timestamp(validate_FieldRules *msg, upb_arena *arena) {
452 struct validate_TimestampRules* sub = (struct validate_TimestampRules*)validate_FieldRules_timestamp(msg);
453 if (sub == NULL) {
454 sub = (struct validate_TimestampRules*)_upb_msg_new(&validate_TimestampRules_msginit, arena);
455 if (!sub) return NULL;
456 validate_FieldRules_set_timestamp(msg, sub);
457 }
458 return sub;
459 }
460
461 /* validate.FloatRules */
462
validate_FloatRules_new(upb_arena * arena)463 UPB_INLINE validate_FloatRules *validate_FloatRules_new(upb_arena *arena) {
464 return (validate_FloatRules *)_upb_msg_new(&validate_FloatRules_msginit, arena);
465 }
validate_FloatRules_parse(const char * buf,size_t size,upb_arena * arena)466 UPB_INLINE validate_FloatRules *validate_FloatRules_parse(const char *buf, size_t size,
467 upb_arena *arena) {
468 validate_FloatRules *ret = validate_FloatRules_new(arena);
469 return (ret && upb_decode(buf, size, ret, &validate_FloatRules_msginit, arena)) ? ret : NULL;
470 }
validate_FloatRules_parse_ex(const char * buf,size_t size,upb_arena * arena,int options)471 UPB_INLINE validate_FloatRules *validate_FloatRules_parse_ex(const char *buf, size_t size,
472 upb_arena *arena, int options) {
473 validate_FloatRules *ret = validate_FloatRules_new(arena);
474 return (ret && _upb_decode(buf, size, ret, &validate_FloatRules_msginit, arena, options))
475 ? ret : NULL;
476 }
validate_FloatRules_serialize(const validate_FloatRules * msg,upb_arena * arena,size_t * len)477 UPB_INLINE char *validate_FloatRules_serialize(const validate_FloatRules *msg, upb_arena *arena, size_t *len) {
478 return upb_encode(msg, &validate_FloatRules_msginit, arena, len);
479 }
480
validate_FloatRules_has_const(const validate_FloatRules * msg)481 UPB_INLINE bool validate_FloatRules_has_const(const validate_FloatRules *msg) { return _upb_hasbit(msg, 1); }
validate_FloatRules_const(const validate_FloatRules * msg)482 UPB_INLINE float validate_FloatRules_const(const validate_FloatRules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(4, 4), float); }
validate_FloatRules_has_lt(const validate_FloatRules * msg)483 UPB_INLINE bool validate_FloatRules_has_lt(const validate_FloatRules *msg) { return _upb_hasbit(msg, 2); }
validate_FloatRules_lt(const validate_FloatRules * msg)484 UPB_INLINE float validate_FloatRules_lt(const validate_FloatRules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(8, 8), float); }
validate_FloatRules_has_lte(const validate_FloatRules * msg)485 UPB_INLINE bool validate_FloatRules_has_lte(const validate_FloatRules *msg) { return _upb_hasbit(msg, 3); }
validate_FloatRules_lte(const validate_FloatRules * msg)486 UPB_INLINE float validate_FloatRules_lte(const validate_FloatRules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(12, 12), float); }
validate_FloatRules_has_gt(const validate_FloatRules * msg)487 UPB_INLINE bool validate_FloatRules_has_gt(const validate_FloatRules *msg) { return _upb_hasbit(msg, 4); }
validate_FloatRules_gt(const validate_FloatRules * msg)488 UPB_INLINE float validate_FloatRules_gt(const validate_FloatRules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(16, 16), float); }
validate_FloatRules_has_gte(const validate_FloatRules * msg)489 UPB_INLINE bool validate_FloatRules_has_gte(const validate_FloatRules *msg) { return _upb_hasbit(msg, 5); }
validate_FloatRules_gte(const validate_FloatRules * msg)490 UPB_INLINE float validate_FloatRules_gte(const validate_FloatRules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(20, 20), float); }
validate_FloatRules_in(const validate_FloatRules * msg,size_t * len)491 UPB_INLINE float const* validate_FloatRules_in(const validate_FloatRules *msg, size_t *len) { return (float const*)_upb_array_accessor(msg, UPB_SIZE(24, 24), len); }
validate_FloatRules_not_in(const validate_FloatRules * msg,size_t * len)492 UPB_INLINE float const* validate_FloatRules_not_in(const validate_FloatRules *msg, size_t *len) { return (float const*)_upb_array_accessor(msg, UPB_SIZE(28, 32), len); }
493
validate_FloatRules_set_const(validate_FloatRules * msg,float value)494 UPB_INLINE void validate_FloatRules_set_const(validate_FloatRules *msg, float value) {
495 _upb_sethas(msg, 1);
496 *UPB_PTR_AT(msg, UPB_SIZE(4, 4), float) = value;
497 }
validate_FloatRules_set_lt(validate_FloatRules * msg,float value)498 UPB_INLINE void validate_FloatRules_set_lt(validate_FloatRules *msg, float value) {
499 _upb_sethas(msg, 2);
500 *UPB_PTR_AT(msg, UPB_SIZE(8, 8), float) = value;
501 }
validate_FloatRules_set_lte(validate_FloatRules * msg,float value)502 UPB_INLINE void validate_FloatRules_set_lte(validate_FloatRules *msg, float value) {
503 _upb_sethas(msg, 3);
504 *UPB_PTR_AT(msg, UPB_SIZE(12, 12), float) = value;
505 }
validate_FloatRules_set_gt(validate_FloatRules * msg,float value)506 UPB_INLINE void validate_FloatRules_set_gt(validate_FloatRules *msg, float value) {
507 _upb_sethas(msg, 4);
508 *UPB_PTR_AT(msg, UPB_SIZE(16, 16), float) = value;
509 }
validate_FloatRules_set_gte(validate_FloatRules * msg,float value)510 UPB_INLINE void validate_FloatRules_set_gte(validate_FloatRules *msg, float value) {
511 _upb_sethas(msg, 5);
512 *UPB_PTR_AT(msg, UPB_SIZE(20, 20), float) = value;
513 }
validate_FloatRules_mutable_in(validate_FloatRules * msg,size_t * len)514 UPB_INLINE float* validate_FloatRules_mutable_in(validate_FloatRules *msg, size_t *len) {
515 return (float*)_upb_array_mutable_accessor(msg, UPB_SIZE(24, 24), len);
516 }
validate_FloatRules_resize_in(validate_FloatRules * msg,size_t len,upb_arena * arena)517 UPB_INLINE float* validate_FloatRules_resize_in(validate_FloatRules *msg, size_t len, upb_arena *arena) {
518 return (float*)_upb_array_resize_accessor2(msg, UPB_SIZE(24, 24), len, 2, arena);
519 }
validate_FloatRules_add_in(validate_FloatRules * msg,float val,upb_arena * arena)520 UPB_INLINE bool validate_FloatRules_add_in(validate_FloatRules *msg, float val, upb_arena *arena) {
521 return _upb_array_append_accessor2(msg, UPB_SIZE(24, 24), 2, &val,
522 arena);
523 }
validate_FloatRules_mutable_not_in(validate_FloatRules * msg,size_t * len)524 UPB_INLINE float* validate_FloatRules_mutable_not_in(validate_FloatRules *msg, size_t *len) {
525 return (float*)_upb_array_mutable_accessor(msg, UPB_SIZE(28, 32), len);
526 }
validate_FloatRules_resize_not_in(validate_FloatRules * msg,size_t len,upb_arena * arena)527 UPB_INLINE float* validate_FloatRules_resize_not_in(validate_FloatRules *msg, size_t len, upb_arena *arena) {
528 return (float*)_upb_array_resize_accessor2(msg, UPB_SIZE(28, 32), len, 2, arena);
529 }
validate_FloatRules_add_not_in(validate_FloatRules * msg,float val,upb_arena * arena)530 UPB_INLINE bool validate_FloatRules_add_not_in(validate_FloatRules *msg, float val, upb_arena *arena) {
531 return _upb_array_append_accessor2(msg, UPB_SIZE(28, 32), 2, &val,
532 arena);
533 }
534
535 /* validate.DoubleRules */
536
validate_DoubleRules_new(upb_arena * arena)537 UPB_INLINE validate_DoubleRules *validate_DoubleRules_new(upb_arena *arena) {
538 return (validate_DoubleRules *)_upb_msg_new(&validate_DoubleRules_msginit, arena);
539 }
validate_DoubleRules_parse(const char * buf,size_t size,upb_arena * arena)540 UPB_INLINE validate_DoubleRules *validate_DoubleRules_parse(const char *buf, size_t size,
541 upb_arena *arena) {
542 validate_DoubleRules *ret = validate_DoubleRules_new(arena);
543 return (ret && upb_decode(buf, size, ret, &validate_DoubleRules_msginit, arena)) ? ret : NULL;
544 }
validate_DoubleRules_parse_ex(const char * buf,size_t size,upb_arena * arena,int options)545 UPB_INLINE validate_DoubleRules *validate_DoubleRules_parse_ex(const char *buf, size_t size,
546 upb_arena *arena, int options) {
547 validate_DoubleRules *ret = validate_DoubleRules_new(arena);
548 return (ret && _upb_decode(buf, size, ret, &validate_DoubleRules_msginit, arena, options))
549 ? ret : NULL;
550 }
validate_DoubleRules_serialize(const validate_DoubleRules * msg,upb_arena * arena,size_t * len)551 UPB_INLINE char *validate_DoubleRules_serialize(const validate_DoubleRules *msg, upb_arena *arena, size_t *len) {
552 return upb_encode(msg, &validate_DoubleRules_msginit, arena, len);
553 }
554
validate_DoubleRules_has_const(const validate_DoubleRules * msg)555 UPB_INLINE bool validate_DoubleRules_has_const(const validate_DoubleRules *msg) { return _upb_hasbit(msg, 1); }
validate_DoubleRules_const(const validate_DoubleRules * msg)556 UPB_INLINE double validate_DoubleRules_const(const validate_DoubleRules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(8, 8), double); }
validate_DoubleRules_has_lt(const validate_DoubleRules * msg)557 UPB_INLINE bool validate_DoubleRules_has_lt(const validate_DoubleRules *msg) { return _upb_hasbit(msg, 2); }
validate_DoubleRules_lt(const validate_DoubleRules * msg)558 UPB_INLINE double validate_DoubleRules_lt(const validate_DoubleRules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(16, 16), double); }
validate_DoubleRules_has_lte(const validate_DoubleRules * msg)559 UPB_INLINE bool validate_DoubleRules_has_lte(const validate_DoubleRules *msg) { return _upb_hasbit(msg, 3); }
validate_DoubleRules_lte(const validate_DoubleRules * msg)560 UPB_INLINE double validate_DoubleRules_lte(const validate_DoubleRules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(24, 24), double); }
validate_DoubleRules_has_gt(const validate_DoubleRules * msg)561 UPB_INLINE bool validate_DoubleRules_has_gt(const validate_DoubleRules *msg) { return _upb_hasbit(msg, 4); }
validate_DoubleRules_gt(const validate_DoubleRules * msg)562 UPB_INLINE double validate_DoubleRules_gt(const validate_DoubleRules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(32, 32), double); }
validate_DoubleRules_has_gte(const validate_DoubleRules * msg)563 UPB_INLINE bool validate_DoubleRules_has_gte(const validate_DoubleRules *msg) { return _upb_hasbit(msg, 5); }
validate_DoubleRules_gte(const validate_DoubleRules * msg)564 UPB_INLINE double validate_DoubleRules_gte(const validate_DoubleRules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(40, 40), double); }
validate_DoubleRules_in(const validate_DoubleRules * msg,size_t * len)565 UPB_INLINE double const* validate_DoubleRules_in(const validate_DoubleRules *msg, size_t *len) { return (double const*)_upb_array_accessor(msg, UPB_SIZE(48, 48), len); }
validate_DoubleRules_not_in(const validate_DoubleRules * msg,size_t * len)566 UPB_INLINE double const* validate_DoubleRules_not_in(const validate_DoubleRules *msg, size_t *len) { return (double const*)_upb_array_accessor(msg, UPB_SIZE(52, 56), len); }
567
validate_DoubleRules_set_const(validate_DoubleRules * msg,double value)568 UPB_INLINE void validate_DoubleRules_set_const(validate_DoubleRules *msg, double value) {
569 _upb_sethas(msg, 1);
570 *UPB_PTR_AT(msg, UPB_SIZE(8, 8), double) = value;
571 }
validate_DoubleRules_set_lt(validate_DoubleRules * msg,double value)572 UPB_INLINE void validate_DoubleRules_set_lt(validate_DoubleRules *msg, double value) {
573 _upb_sethas(msg, 2);
574 *UPB_PTR_AT(msg, UPB_SIZE(16, 16), double) = value;
575 }
validate_DoubleRules_set_lte(validate_DoubleRules * msg,double value)576 UPB_INLINE void validate_DoubleRules_set_lte(validate_DoubleRules *msg, double value) {
577 _upb_sethas(msg, 3);
578 *UPB_PTR_AT(msg, UPB_SIZE(24, 24), double) = value;
579 }
validate_DoubleRules_set_gt(validate_DoubleRules * msg,double value)580 UPB_INLINE void validate_DoubleRules_set_gt(validate_DoubleRules *msg, double value) {
581 _upb_sethas(msg, 4);
582 *UPB_PTR_AT(msg, UPB_SIZE(32, 32), double) = value;
583 }
validate_DoubleRules_set_gte(validate_DoubleRules * msg,double value)584 UPB_INLINE void validate_DoubleRules_set_gte(validate_DoubleRules *msg, double value) {
585 _upb_sethas(msg, 5);
586 *UPB_PTR_AT(msg, UPB_SIZE(40, 40), double) = value;
587 }
validate_DoubleRules_mutable_in(validate_DoubleRules * msg,size_t * len)588 UPB_INLINE double* validate_DoubleRules_mutable_in(validate_DoubleRules *msg, size_t *len) {
589 return (double*)_upb_array_mutable_accessor(msg, UPB_SIZE(48, 48), len);
590 }
validate_DoubleRules_resize_in(validate_DoubleRules * msg,size_t len,upb_arena * arena)591 UPB_INLINE double* validate_DoubleRules_resize_in(validate_DoubleRules *msg, size_t len, upb_arena *arena) {
592 return (double*)_upb_array_resize_accessor2(msg, UPB_SIZE(48, 48), len, 3, arena);
593 }
validate_DoubleRules_add_in(validate_DoubleRules * msg,double val,upb_arena * arena)594 UPB_INLINE bool validate_DoubleRules_add_in(validate_DoubleRules *msg, double val, upb_arena *arena) {
595 return _upb_array_append_accessor2(msg, UPB_SIZE(48, 48), 3, &val,
596 arena);
597 }
validate_DoubleRules_mutable_not_in(validate_DoubleRules * msg,size_t * len)598 UPB_INLINE double* validate_DoubleRules_mutable_not_in(validate_DoubleRules *msg, size_t *len) {
599 return (double*)_upb_array_mutable_accessor(msg, UPB_SIZE(52, 56), len);
600 }
validate_DoubleRules_resize_not_in(validate_DoubleRules * msg,size_t len,upb_arena * arena)601 UPB_INLINE double* validate_DoubleRules_resize_not_in(validate_DoubleRules *msg, size_t len, upb_arena *arena) {
602 return (double*)_upb_array_resize_accessor2(msg, UPB_SIZE(52, 56), len, 3, arena);
603 }
validate_DoubleRules_add_not_in(validate_DoubleRules * msg,double val,upb_arena * arena)604 UPB_INLINE bool validate_DoubleRules_add_not_in(validate_DoubleRules *msg, double val, upb_arena *arena) {
605 return _upb_array_append_accessor2(msg, UPB_SIZE(52, 56), 3, &val,
606 arena);
607 }
608
609 /* validate.Int32Rules */
610
validate_Int32Rules_new(upb_arena * arena)611 UPB_INLINE validate_Int32Rules *validate_Int32Rules_new(upb_arena *arena) {
612 return (validate_Int32Rules *)_upb_msg_new(&validate_Int32Rules_msginit, arena);
613 }
validate_Int32Rules_parse(const char * buf,size_t size,upb_arena * arena)614 UPB_INLINE validate_Int32Rules *validate_Int32Rules_parse(const char *buf, size_t size,
615 upb_arena *arena) {
616 validate_Int32Rules *ret = validate_Int32Rules_new(arena);
617 return (ret && upb_decode(buf, size, ret, &validate_Int32Rules_msginit, arena)) ? ret : NULL;
618 }
validate_Int32Rules_parse_ex(const char * buf,size_t size,upb_arena * arena,int options)619 UPB_INLINE validate_Int32Rules *validate_Int32Rules_parse_ex(const char *buf, size_t size,
620 upb_arena *arena, int options) {
621 validate_Int32Rules *ret = validate_Int32Rules_new(arena);
622 return (ret && _upb_decode(buf, size, ret, &validate_Int32Rules_msginit, arena, options))
623 ? ret : NULL;
624 }
validate_Int32Rules_serialize(const validate_Int32Rules * msg,upb_arena * arena,size_t * len)625 UPB_INLINE char *validate_Int32Rules_serialize(const validate_Int32Rules *msg, upb_arena *arena, size_t *len) {
626 return upb_encode(msg, &validate_Int32Rules_msginit, arena, len);
627 }
628
validate_Int32Rules_has_const(const validate_Int32Rules * msg)629 UPB_INLINE bool validate_Int32Rules_has_const(const validate_Int32Rules *msg) { return _upb_hasbit(msg, 1); }
validate_Int32Rules_const(const validate_Int32Rules * msg)630 UPB_INLINE int32_t validate_Int32Rules_const(const validate_Int32Rules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(4, 4), int32_t); }
validate_Int32Rules_has_lt(const validate_Int32Rules * msg)631 UPB_INLINE bool validate_Int32Rules_has_lt(const validate_Int32Rules *msg) { return _upb_hasbit(msg, 2); }
validate_Int32Rules_lt(const validate_Int32Rules * msg)632 UPB_INLINE int32_t validate_Int32Rules_lt(const validate_Int32Rules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(8, 8), int32_t); }
validate_Int32Rules_has_lte(const validate_Int32Rules * msg)633 UPB_INLINE bool validate_Int32Rules_has_lte(const validate_Int32Rules *msg) { return _upb_hasbit(msg, 3); }
validate_Int32Rules_lte(const validate_Int32Rules * msg)634 UPB_INLINE int32_t validate_Int32Rules_lte(const validate_Int32Rules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(12, 12), int32_t); }
validate_Int32Rules_has_gt(const validate_Int32Rules * msg)635 UPB_INLINE bool validate_Int32Rules_has_gt(const validate_Int32Rules *msg) { return _upb_hasbit(msg, 4); }
validate_Int32Rules_gt(const validate_Int32Rules * msg)636 UPB_INLINE int32_t validate_Int32Rules_gt(const validate_Int32Rules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(16, 16), int32_t); }
validate_Int32Rules_has_gte(const validate_Int32Rules * msg)637 UPB_INLINE bool validate_Int32Rules_has_gte(const validate_Int32Rules *msg) { return _upb_hasbit(msg, 5); }
validate_Int32Rules_gte(const validate_Int32Rules * msg)638 UPB_INLINE int32_t validate_Int32Rules_gte(const validate_Int32Rules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(20, 20), int32_t); }
validate_Int32Rules_in(const validate_Int32Rules * msg,size_t * len)639 UPB_INLINE int32_t const* validate_Int32Rules_in(const validate_Int32Rules *msg, size_t *len) { return (int32_t const*)_upb_array_accessor(msg, UPB_SIZE(24, 24), len); }
validate_Int32Rules_not_in(const validate_Int32Rules * msg,size_t * len)640 UPB_INLINE int32_t const* validate_Int32Rules_not_in(const validate_Int32Rules *msg, size_t *len) { return (int32_t const*)_upb_array_accessor(msg, UPB_SIZE(28, 32), len); }
641
validate_Int32Rules_set_const(validate_Int32Rules * msg,int32_t value)642 UPB_INLINE void validate_Int32Rules_set_const(validate_Int32Rules *msg, int32_t value) {
643 _upb_sethas(msg, 1);
644 *UPB_PTR_AT(msg, UPB_SIZE(4, 4), int32_t) = value;
645 }
validate_Int32Rules_set_lt(validate_Int32Rules * msg,int32_t value)646 UPB_INLINE void validate_Int32Rules_set_lt(validate_Int32Rules *msg, int32_t value) {
647 _upb_sethas(msg, 2);
648 *UPB_PTR_AT(msg, UPB_SIZE(8, 8), int32_t) = value;
649 }
validate_Int32Rules_set_lte(validate_Int32Rules * msg,int32_t value)650 UPB_INLINE void validate_Int32Rules_set_lte(validate_Int32Rules *msg, int32_t value) {
651 _upb_sethas(msg, 3);
652 *UPB_PTR_AT(msg, UPB_SIZE(12, 12), int32_t) = value;
653 }
validate_Int32Rules_set_gt(validate_Int32Rules * msg,int32_t value)654 UPB_INLINE void validate_Int32Rules_set_gt(validate_Int32Rules *msg, int32_t value) {
655 _upb_sethas(msg, 4);
656 *UPB_PTR_AT(msg, UPB_SIZE(16, 16), int32_t) = value;
657 }
validate_Int32Rules_set_gte(validate_Int32Rules * msg,int32_t value)658 UPB_INLINE void validate_Int32Rules_set_gte(validate_Int32Rules *msg, int32_t value) {
659 _upb_sethas(msg, 5);
660 *UPB_PTR_AT(msg, UPB_SIZE(20, 20), int32_t) = value;
661 }
validate_Int32Rules_mutable_in(validate_Int32Rules * msg,size_t * len)662 UPB_INLINE int32_t* validate_Int32Rules_mutable_in(validate_Int32Rules *msg, size_t *len) {
663 return (int32_t*)_upb_array_mutable_accessor(msg, UPB_SIZE(24, 24), len);
664 }
validate_Int32Rules_resize_in(validate_Int32Rules * msg,size_t len,upb_arena * arena)665 UPB_INLINE int32_t* validate_Int32Rules_resize_in(validate_Int32Rules *msg, size_t len, upb_arena *arena) {
666 return (int32_t*)_upb_array_resize_accessor2(msg, UPB_SIZE(24, 24), len, 2, arena);
667 }
validate_Int32Rules_add_in(validate_Int32Rules * msg,int32_t val,upb_arena * arena)668 UPB_INLINE bool validate_Int32Rules_add_in(validate_Int32Rules *msg, int32_t val, upb_arena *arena) {
669 return _upb_array_append_accessor2(msg, UPB_SIZE(24, 24), 2, &val,
670 arena);
671 }
validate_Int32Rules_mutable_not_in(validate_Int32Rules * msg,size_t * len)672 UPB_INLINE int32_t* validate_Int32Rules_mutable_not_in(validate_Int32Rules *msg, size_t *len) {
673 return (int32_t*)_upb_array_mutable_accessor(msg, UPB_SIZE(28, 32), len);
674 }
validate_Int32Rules_resize_not_in(validate_Int32Rules * msg,size_t len,upb_arena * arena)675 UPB_INLINE int32_t* validate_Int32Rules_resize_not_in(validate_Int32Rules *msg, size_t len, upb_arena *arena) {
676 return (int32_t*)_upb_array_resize_accessor2(msg, UPB_SIZE(28, 32), len, 2, arena);
677 }
validate_Int32Rules_add_not_in(validate_Int32Rules * msg,int32_t val,upb_arena * arena)678 UPB_INLINE bool validate_Int32Rules_add_not_in(validate_Int32Rules *msg, int32_t val, upb_arena *arena) {
679 return _upb_array_append_accessor2(msg, UPB_SIZE(28, 32), 2, &val,
680 arena);
681 }
682
683 /* validate.Int64Rules */
684
validate_Int64Rules_new(upb_arena * arena)685 UPB_INLINE validate_Int64Rules *validate_Int64Rules_new(upb_arena *arena) {
686 return (validate_Int64Rules *)_upb_msg_new(&validate_Int64Rules_msginit, arena);
687 }
validate_Int64Rules_parse(const char * buf,size_t size,upb_arena * arena)688 UPB_INLINE validate_Int64Rules *validate_Int64Rules_parse(const char *buf, size_t size,
689 upb_arena *arena) {
690 validate_Int64Rules *ret = validate_Int64Rules_new(arena);
691 return (ret && upb_decode(buf, size, ret, &validate_Int64Rules_msginit, arena)) ? ret : NULL;
692 }
validate_Int64Rules_parse_ex(const char * buf,size_t size,upb_arena * arena,int options)693 UPB_INLINE validate_Int64Rules *validate_Int64Rules_parse_ex(const char *buf, size_t size,
694 upb_arena *arena, int options) {
695 validate_Int64Rules *ret = validate_Int64Rules_new(arena);
696 return (ret && _upb_decode(buf, size, ret, &validate_Int64Rules_msginit, arena, options))
697 ? ret : NULL;
698 }
validate_Int64Rules_serialize(const validate_Int64Rules * msg,upb_arena * arena,size_t * len)699 UPB_INLINE char *validate_Int64Rules_serialize(const validate_Int64Rules *msg, upb_arena *arena, size_t *len) {
700 return upb_encode(msg, &validate_Int64Rules_msginit, arena, len);
701 }
702
validate_Int64Rules_has_const(const validate_Int64Rules * msg)703 UPB_INLINE bool validate_Int64Rules_has_const(const validate_Int64Rules *msg) { return _upb_hasbit(msg, 1); }
validate_Int64Rules_const(const validate_Int64Rules * msg)704 UPB_INLINE int64_t validate_Int64Rules_const(const validate_Int64Rules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(8, 8), int64_t); }
validate_Int64Rules_has_lt(const validate_Int64Rules * msg)705 UPB_INLINE bool validate_Int64Rules_has_lt(const validate_Int64Rules *msg) { return _upb_hasbit(msg, 2); }
validate_Int64Rules_lt(const validate_Int64Rules * msg)706 UPB_INLINE int64_t validate_Int64Rules_lt(const validate_Int64Rules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(16, 16), int64_t); }
validate_Int64Rules_has_lte(const validate_Int64Rules * msg)707 UPB_INLINE bool validate_Int64Rules_has_lte(const validate_Int64Rules *msg) { return _upb_hasbit(msg, 3); }
validate_Int64Rules_lte(const validate_Int64Rules * msg)708 UPB_INLINE int64_t validate_Int64Rules_lte(const validate_Int64Rules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(24, 24), int64_t); }
validate_Int64Rules_has_gt(const validate_Int64Rules * msg)709 UPB_INLINE bool validate_Int64Rules_has_gt(const validate_Int64Rules *msg) { return _upb_hasbit(msg, 4); }
validate_Int64Rules_gt(const validate_Int64Rules * msg)710 UPB_INLINE int64_t validate_Int64Rules_gt(const validate_Int64Rules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(32, 32), int64_t); }
validate_Int64Rules_has_gte(const validate_Int64Rules * msg)711 UPB_INLINE bool validate_Int64Rules_has_gte(const validate_Int64Rules *msg) { return _upb_hasbit(msg, 5); }
validate_Int64Rules_gte(const validate_Int64Rules * msg)712 UPB_INLINE int64_t validate_Int64Rules_gte(const validate_Int64Rules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(40, 40), int64_t); }
validate_Int64Rules_in(const validate_Int64Rules * msg,size_t * len)713 UPB_INLINE int64_t const* validate_Int64Rules_in(const validate_Int64Rules *msg, size_t *len) { return (int64_t const*)_upb_array_accessor(msg, UPB_SIZE(48, 48), len); }
validate_Int64Rules_not_in(const validate_Int64Rules * msg,size_t * len)714 UPB_INLINE int64_t const* validate_Int64Rules_not_in(const validate_Int64Rules *msg, size_t *len) { return (int64_t const*)_upb_array_accessor(msg, UPB_SIZE(52, 56), len); }
715
validate_Int64Rules_set_const(validate_Int64Rules * msg,int64_t value)716 UPB_INLINE void validate_Int64Rules_set_const(validate_Int64Rules *msg, int64_t value) {
717 _upb_sethas(msg, 1);
718 *UPB_PTR_AT(msg, UPB_SIZE(8, 8), int64_t) = value;
719 }
validate_Int64Rules_set_lt(validate_Int64Rules * msg,int64_t value)720 UPB_INLINE void validate_Int64Rules_set_lt(validate_Int64Rules *msg, int64_t value) {
721 _upb_sethas(msg, 2);
722 *UPB_PTR_AT(msg, UPB_SIZE(16, 16), int64_t) = value;
723 }
validate_Int64Rules_set_lte(validate_Int64Rules * msg,int64_t value)724 UPB_INLINE void validate_Int64Rules_set_lte(validate_Int64Rules *msg, int64_t value) {
725 _upb_sethas(msg, 3);
726 *UPB_PTR_AT(msg, UPB_SIZE(24, 24), int64_t) = value;
727 }
validate_Int64Rules_set_gt(validate_Int64Rules * msg,int64_t value)728 UPB_INLINE void validate_Int64Rules_set_gt(validate_Int64Rules *msg, int64_t value) {
729 _upb_sethas(msg, 4);
730 *UPB_PTR_AT(msg, UPB_SIZE(32, 32), int64_t) = value;
731 }
validate_Int64Rules_set_gte(validate_Int64Rules * msg,int64_t value)732 UPB_INLINE void validate_Int64Rules_set_gte(validate_Int64Rules *msg, int64_t value) {
733 _upb_sethas(msg, 5);
734 *UPB_PTR_AT(msg, UPB_SIZE(40, 40), int64_t) = value;
735 }
validate_Int64Rules_mutable_in(validate_Int64Rules * msg,size_t * len)736 UPB_INLINE int64_t* validate_Int64Rules_mutable_in(validate_Int64Rules *msg, size_t *len) {
737 return (int64_t*)_upb_array_mutable_accessor(msg, UPB_SIZE(48, 48), len);
738 }
validate_Int64Rules_resize_in(validate_Int64Rules * msg,size_t len,upb_arena * arena)739 UPB_INLINE int64_t* validate_Int64Rules_resize_in(validate_Int64Rules *msg, size_t len, upb_arena *arena) {
740 return (int64_t*)_upb_array_resize_accessor2(msg, UPB_SIZE(48, 48), len, 3, arena);
741 }
validate_Int64Rules_add_in(validate_Int64Rules * msg,int64_t val,upb_arena * arena)742 UPB_INLINE bool validate_Int64Rules_add_in(validate_Int64Rules *msg, int64_t val, upb_arena *arena) {
743 return _upb_array_append_accessor2(msg, UPB_SIZE(48, 48), 3, &val,
744 arena);
745 }
validate_Int64Rules_mutable_not_in(validate_Int64Rules * msg,size_t * len)746 UPB_INLINE int64_t* validate_Int64Rules_mutable_not_in(validate_Int64Rules *msg, size_t *len) {
747 return (int64_t*)_upb_array_mutable_accessor(msg, UPB_SIZE(52, 56), len);
748 }
validate_Int64Rules_resize_not_in(validate_Int64Rules * msg,size_t len,upb_arena * arena)749 UPB_INLINE int64_t* validate_Int64Rules_resize_not_in(validate_Int64Rules *msg, size_t len, upb_arena *arena) {
750 return (int64_t*)_upb_array_resize_accessor2(msg, UPB_SIZE(52, 56), len, 3, arena);
751 }
validate_Int64Rules_add_not_in(validate_Int64Rules * msg,int64_t val,upb_arena * arena)752 UPB_INLINE bool validate_Int64Rules_add_not_in(validate_Int64Rules *msg, int64_t val, upb_arena *arena) {
753 return _upb_array_append_accessor2(msg, UPB_SIZE(52, 56), 3, &val,
754 arena);
755 }
756
757 /* validate.UInt32Rules */
758
validate_UInt32Rules_new(upb_arena * arena)759 UPB_INLINE validate_UInt32Rules *validate_UInt32Rules_new(upb_arena *arena) {
760 return (validate_UInt32Rules *)_upb_msg_new(&validate_UInt32Rules_msginit, arena);
761 }
validate_UInt32Rules_parse(const char * buf,size_t size,upb_arena * arena)762 UPB_INLINE validate_UInt32Rules *validate_UInt32Rules_parse(const char *buf, size_t size,
763 upb_arena *arena) {
764 validate_UInt32Rules *ret = validate_UInt32Rules_new(arena);
765 return (ret && upb_decode(buf, size, ret, &validate_UInt32Rules_msginit, arena)) ? ret : NULL;
766 }
validate_UInt32Rules_parse_ex(const char * buf,size_t size,upb_arena * arena,int options)767 UPB_INLINE validate_UInt32Rules *validate_UInt32Rules_parse_ex(const char *buf, size_t size,
768 upb_arena *arena, int options) {
769 validate_UInt32Rules *ret = validate_UInt32Rules_new(arena);
770 return (ret && _upb_decode(buf, size, ret, &validate_UInt32Rules_msginit, arena, options))
771 ? ret : NULL;
772 }
validate_UInt32Rules_serialize(const validate_UInt32Rules * msg,upb_arena * arena,size_t * len)773 UPB_INLINE char *validate_UInt32Rules_serialize(const validate_UInt32Rules *msg, upb_arena *arena, size_t *len) {
774 return upb_encode(msg, &validate_UInt32Rules_msginit, arena, len);
775 }
776
validate_UInt32Rules_has_const(const validate_UInt32Rules * msg)777 UPB_INLINE bool validate_UInt32Rules_has_const(const validate_UInt32Rules *msg) { return _upb_hasbit(msg, 1); }
validate_UInt32Rules_const(const validate_UInt32Rules * msg)778 UPB_INLINE uint32_t validate_UInt32Rules_const(const validate_UInt32Rules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(4, 4), uint32_t); }
validate_UInt32Rules_has_lt(const validate_UInt32Rules * msg)779 UPB_INLINE bool validate_UInt32Rules_has_lt(const validate_UInt32Rules *msg) { return _upb_hasbit(msg, 2); }
validate_UInt32Rules_lt(const validate_UInt32Rules * msg)780 UPB_INLINE uint32_t validate_UInt32Rules_lt(const validate_UInt32Rules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(8, 8), uint32_t); }
validate_UInt32Rules_has_lte(const validate_UInt32Rules * msg)781 UPB_INLINE bool validate_UInt32Rules_has_lte(const validate_UInt32Rules *msg) { return _upb_hasbit(msg, 3); }
validate_UInt32Rules_lte(const validate_UInt32Rules * msg)782 UPB_INLINE uint32_t validate_UInt32Rules_lte(const validate_UInt32Rules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(12, 12), uint32_t); }
validate_UInt32Rules_has_gt(const validate_UInt32Rules * msg)783 UPB_INLINE bool validate_UInt32Rules_has_gt(const validate_UInt32Rules *msg) { return _upb_hasbit(msg, 4); }
validate_UInt32Rules_gt(const validate_UInt32Rules * msg)784 UPB_INLINE uint32_t validate_UInt32Rules_gt(const validate_UInt32Rules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(16, 16), uint32_t); }
validate_UInt32Rules_has_gte(const validate_UInt32Rules * msg)785 UPB_INLINE bool validate_UInt32Rules_has_gte(const validate_UInt32Rules *msg) { return _upb_hasbit(msg, 5); }
validate_UInt32Rules_gte(const validate_UInt32Rules * msg)786 UPB_INLINE uint32_t validate_UInt32Rules_gte(const validate_UInt32Rules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(20, 20), uint32_t); }
validate_UInt32Rules_in(const validate_UInt32Rules * msg,size_t * len)787 UPB_INLINE uint32_t const* validate_UInt32Rules_in(const validate_UInt32Rules *msg, size_t *len) { return (uint32_t const*)_upb_array_accessor(msg, UPB_SIZE(24, 24), len); }
validate_UInt32Rules_not_in(const validate_UInt32Rules * msg,size_t * len)788 UPB_INLINE uint32_t const* validate_UInt32Rules_not_in(const validate_UInt32Rules *msg, size_t *len) { return (uint32_t const*)_upb_array_accessor(msg, UPB_SIZE(28, 32), len); }
789
validate_UInt32Rules_set_const(validate_UInt32Rules * msg,uint32_t value)790 UPB_INLINE void validate_UInt32Rules_set_const(validate_UInt32Rules *msg, uint32_t value) {
791 _upb_sethas(msg, 1);
792 *UPB_PTR_AT(msg, UPB_SIZE(4, 4), uint32_t) = value;
793 }
validate_UInt32Rules_set_lt(validate_UInt32Rules * msg,uint32_t value)794 UPB_INLINE void validate_UInt32Rules_set_lt(validate_UInt32Rules *msg, uint32_t value) {
795 _upb_sethas(msg, 2);
796 *UPB_PTR_AT(msg, UPB_SIZE(8, 8), uint32_t) = value;
797 }
validate_UInt32Rules_set_lte(validate_UInt32Rules * msg,uint32_t value)798 UPB_INLINE void validate_UInt32Rules_set_lte(validate_UInt32Rules *msg, uint32_t value) {
799 _upb_sethas(msg, 3);
800 *UPB_PTR_AT(msg, UPB_SIZE(12, 12), uint32_t) = value;
801 }
validate_UInt32Rules_set_gt(validate_UInt32Rules * msg,uint32_t value)802 UPB_INLINE void validate_UInt32Rules_set_gt(validate_UInt32Rules *msg, uint32_t value) {
803 _upb_sethas(msg, 4);
804 *UPB_PTR_AT(msg, UPB_SIZE(16, 16), uint32_t) = value;
805 }
validate_UInt32Rules_set_gte(validate_UInt32Rules * msg,uint32_t value)806 UPB_INLINE void validate_UInt32Rules_set_gte(validate_UInt32Rules *msg, uint32_t value) {
807 _upb_sethas(msg, 5);
808 *UPB_PTR_AT(msg, UPB_SIZE(20, 20), uint32_t) = value;
809 }
validate_UInt32Rules_mutable_in(validate_UInt32Rules * msg,size_t * len)810 UPB_INLINE uint32_t* validate_UInt32Rules_mutable_in(validate_UInt32Rules *msg, size_t *len) {
811 return (uint32_t*)_upb_array_mutable_accessor(msg, UPB_SIZE(24, 24), len);
812 }
validate_UInt32Rules_resize_in(validate_UInt32Rules * msg,size_t len,upb_arena * arena)813 UPB_INLINE uint32_t* validate_UInt32Rules_resize_in(validate_UInt32Rules *msg, size_t len, upb_arena *arena) {
814 return (uint32_t*)_upb_array_resize_accessor2(msg, UPB_SIZE(24, 24), len, 2, arena);
815 }
validate_UInt32Rules_add_in(validate_UInt32Rules * msg,uint32_t val,upb_arena * arena)816 UPB_INLINE bool validate_UInt32Rules_add_in(validate_UInt32Rules *msg, uint32_t val, upb_arena *arena) {
817 return _upb_array_append_accessor2(msg, UPB_SIZE(24, 24), 2, &val,
818 arena);
819 }
validate_UInt32Rules_mutable_not_in(validate_UInt32Rules * msg,size_t * len)820 UPB_INLINE uint32_t* validate_UInt32Rules_mutable_not_in(validate_UInt32Rules *msg, size_t *len) {
821 return (uint32_t*)_upb_array_mutable_accessor(msg, UPB_SIZE(28, 32), len);
822 }
validate_UInt32Rules_resize_not_in(validate_UInt32Rules * msg,size_t len,upb_arena * arena)823 UPB_INLINE uint32_t* validate_UInt32Rules_resize_not_in(validate_UInt32Rules *msg, size_t len, upb_arena *arena) {
824 return (uint32_t*)_upb_array_resize_accessor2(msg, UPB_SIZE(28, 32), len, 2, arena);
825 }
validate_UInt32Rules_add_not_in(validate_UInt32Rules * msg,uint32_t val,upb_arena * arena)826 UPB_INLINE bool validate_UInt32Rules_add_not_in(validate_UInt32Rules *msg, uint32_t val, upb_arena *arena) {
827 return _upb_array_append_accessor2(msg, UPB_SIZE(28, 32), 2, &val,
828 arena);
829 }
830
831 /* validate.UInt64Rules */
832
validate_UInt64Rules_new(upb_arena * arena)833 UPB_INLINE validate_UInt64Rules *validate_UInt64Rules_new(upb_arena *arena) {
834 return (validate_UInt64Rules *)_upb_msg_new(&validate_UInt64Rules_msginit, arena);
835 }
validate_UInt64Rules_parse(const char * buf,size_t size,upb_arena * arena)836 UPB_INLINE validate_UInt64Rules *validate_UInt64Rules_parse(const char *buf, size_t size,
837 upb_arena *arena) {
838 validate_UInt64Rules *ret = validate_UInt64Rules_new(arena);
839 return (ret && upb_decode(buf, size, ret, &validate_UInt64Rules_msginit, arena)) ? ret : NULL;
840 }
validate_UInt64Rules_parse_ex(const char * buf,size_t size,upb_arena * arena,int options)841 UPB_INLINE validate_UInt64Rules *validate_UInt64Rules_parse_ex(const char *buf, size_t size,
842 upb_arena *arena, int options) {
843 validate_UInt64Rules *ret = validate_UInt64Rules_new(arena);
844 return (ret && _upb_decode(buf, size, ret, &validate_UInt64Rules_msginit, arena, options))
845 ? ret : NULL;
846 }
validate_UInt64Rules_serialize(const validate_UInt64Rules * msg,upb_arena * arena,size_t * len)847 UPB_INLINE char *validate_UInt64Rules_serialize(const validate_UInt64Rules *msg, upb_arena *arena, size_t *len) {
848 return upb_encode(msg, &validate_UInt64Rules_msginit, arena, len);
849 }
850
validate_UInt64Rules_has_const(const validate_UInt64Rules * msg)851 UPB_INLINE bool validate_UInt64Rules_has_const(const validate_UInt64Rules *msg) { return _upb_hasbit(msg, 1); }
validate_UInt64Rules_const(const validate_UInt64Rules * msg)852 UPB_INLINE uint64_t validate_UInt64Rules_const(const validate_UInt64Rules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(8, 8), uint64_t); }
validate_UInt64Rules_has_lt(const validate_UInt64Rules * msg)853 UPB_INLINE bool validate_UInt64Rules_has_lt(const validate_UInt64Rules *msg) { return _upb_hasbit(msg, 2); }
validate_UInt64Rules_lt(const validate_UInt64Rules * msg)854 UPB_INLINE uint64_t validate_UInt64Rules_lt(const validate_UInt64Rules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(16, 16), uint64_t); }
validate_UInt64Rules_has_lte(const validate_UInt64Rules * msg)855 UPB_INLINE bool validate_UInt64Rules_has_lte(const validate_UInt64Rules *msg) { return _upb_hasbit(msg, 3); }
validate_UInt64Rules_lte(const validate_UInt64Rules * msg)856 UPB_INLINE uint64_t validate_UInt64Rules_lte(const validate_UInt64Rules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(24, 24), uint64_t); }
validate_UInt64Rules_has_gt(const validate_UInt64Rules * msg)857 UPB_INLINE bool validate_UInt64Rules_has_gt(const validate_UInt64Rules *msg) { return _upb_hasbit(msg, 4); }
validate_UInt64Rules_gt(const validate_UInt64Rules * msg)858 UPB_INLINE uint64_t validate_UInt64Rules_gt(const validate_UInt64Rules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(32, 32), uint64_t); }
validate_UInt64Rules_has_gte(const validate_UInt64Rules * msg)859 UPB_INLINE bool validate_UInt64Rules_has_gte(const validate_UInt64Rules *msg) { return _upb_hasbit(msg, 5); }
validate_UInt64Rules_gte(const validate_UInt64Rules * msg)860 UPB_INLINE uint64_t validate_UInt64Rules_gte(const validate_UInt64Rules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(40, 40), uint64_t); }
validate_UInt64Rules_in(const validate_UInt64Rules * msg,size_t * len)861 UPB_INLINE uint64_t const* validate_UInt64Rules_in(const validate_UInt64Rules *msg, size_t *len) { return (uint64_t const*)_upb_array_accessor(msg, UPB_SIZE(48, 48), len); }
validate_UInt64Rules_not_in(const validate_UInt64Rules * msg,size_t * len)862 UPB_INLINE uint64_t const* validate_UInt64Rules_not_in(const validate_UInt64Rules *msg, size_t *len) { return (uint64_t const*)_upb_array_accessor(msg, UPB_SIZE(52, 56), len); }
863
validate_UInt64Rules_set_const(validate_UInt64Rules * msg,uint64_t value)864 UPB_INLINE void validate_UInt64Rules_set_const(validate_UInt64Rules *msg, uint64_t value) {
865 _upb_sethas(msg, 1);
866 *UPB_PTR_AT(msg, UPB_SIZE(8, 8), uint64_t) = value;
867 }
validate_UInt64Rules_set_lt(validate_UInt64Rules * msg,uint64_t value)868 UPB_INLINE void validate_UInt64Rules_set_lt(validate_UInt64Rules *msg, uint64_t value) {
869 _upb_sethas(msg, 2);
870 *UPB_PTR_AT(msg, UPB_SIZE(16, 16), uint64_t) = value;
871 }
validate_UInt64Rules_set_lte(validate_UInt64Rules * msg,uint64_t value)872 UPB_INLINE void validate_UInt64Rules_set_lte(validate_UInt64Rules *msg, uint64_t value) {
873 _upb_sethas(msg, 3);
874 *UPB_PTR_AT(msg, UPB_SIZE(24, 24), uint64_t) = value;
875 }
validate_UInt64Rules_set_gt(validate_UInt64Rules * msg,uint64_t value)876 UPB_INLINE void validate_UInt64Rules_set_gt(validate_UInt64Rules *msg, uint64_t value) {
877 _upb_sethas(msg, 4);
878 *UPB_PTR_AT(msg, UPB_SIZE(32, 32), uint64_t) = value;
879 }
validate_UInt64Rules_set_gte(validate_UInt64Rules * msg,uint64_t value)880 UPB_INLINE void validate_UInt64Rules_set_gte(validate_UInt64Rules *msg, uint64_t value) {
881 _upb_sethas(msg, 5);
882 *UPB_PTR_AT(msg, UPB_SIZE(40, 40), uint64_t) = value;
883 }
validate_UInt64Rules_mutable_in(validate_UInt64Rules * msg,size_t * len)884 UPB_INLINE uint64_t* validate_UInt64Rules_mutable_in(validate_UInt64Rules *msg, size_t *len) {
885 return (uint64_t*)_upb_array_mutable_accessor(msg, UPB_SIZE(48, 48), len);
886 }
validate_UInt64Rules_resize_in(validate_UInt64Rules * msg,size_t len,upb_arena * arena)887 UPB_INLINE uint64_t* validate_UInt64Rules_resize_in(validate_UInt64Rules *msg, size_t len, upb_arena *arena) {
888 return (uint64_t*)_upb_array_resize_accessor2(msg, UPB_SIZE(48, 48), len, 3, arena);
889 }
validate_UInt64Rules_add_in(validate_UInt64Rules * msg,uint64_t val,upb_arena * arena)890 UPB_INLINE bool validate_UInt64Rules_add_in(validate_UInt64Rules *msg, uint64_t val, upb_arena *arena) {
891 return _upb_array_append_accessor2(msg, UPB_SIZE(48, 48), 3, &val,
892 arena);
893 }
validate_UInt64Rules_mutable_not_in(validate_UInt64Rules * msg,size_t * len)894 UPB_INLINE uint64_t* validate_UInt64Rules_mutable_not_in(validate_UInt64Rules *msg, size_t *len) {
895 return (uint64_t*)_upb_array_mutable_accessor(msg, UPB_SIZE(52, 56), len);
896 }
validate_UInt64Rules_resize_not_in(validate_UInt64Rules * msg,size_t len,upb_arena * arena)897 UPB_INLINE uint64_t* validate_UInt64Rules_resize_not_in(validate_UInt64Rules *msg, size_t len, upb_arena *arena) {
898 return (uint64_t*)_upb_array_resize_accessor2(msg, UPB_SIZE(52, 56), len, 3, arena);
899 }
validate_UInt64Rules_add_not_in(validate_UInt64Rules * msg,uint64_t val,upb_arena * arena)900 UPB_INLINE bool validate_UInt64Rules_add_not_in(validate_UInt64Rules *msg, uint64_t val, upb_arena *arena) {
901 return _upb_array_append_accessor2(msg, UPB_SIZE(52, 56), 3, &val,
902 arena);
903 }
904
905 /* validate.SInt32Rules */
906
validate_SInt32Rules_new(upb_arena * arena)907 UPB_INLINE validate_SInt32Rules *validate_SInt32Rules_new(upb_arena *arena) {
908 return (validate_SInt32Rules *)_upb_msg_new(&validate_SInt32Rules_msginit, arena);
909 }
validate_SInt32Rules_parse(const char * buf,size_t size,upb_arena * arena)910 UPB_INLINE validate_SInt32Rules *validate_SInt32Rules_parse(const char *buf, size_t size,
911 upb_arena *arena) {
912 validate_SInt32Rules *ret = validate_SInt32Rules_new(arena);
913 return (ret && upb_decode(buf, size, ret, &validate_SInt32Rules_msginit, arena)) ? ret : NULL;
914 }
validate_SInt32Rules_parse_ex(const char * buf,size_t size,upb_arena * arena,int options)915 UPB_INLINE validate_SInt32Rules *validate_SInt32Rules_parse_ex(const char *buf, size_t size,
916 upb_arena *arena, int options) {
917 validate_SInt32Rules *ret = validate_SInt32Rules_new(arena);
918 return (ret && _upb_decode(buf, size, ret, &validate_SInt32Rules_msginit, arena, options))
919 ? ret : NULL;
920 }
validate_SInt32Rules_serialize(const validate_SInt32Rules * msg,upb_arena * arena,size_t * len)921 UPB_INLINE char *validate_SInt32Rules_serialize(const validate_SInt32Rules *msg, upb_arena *arena, size_t *len) {
922 return upb_encode(msg, &validate_SInt32Rules_msginit, arena, len);
923 }
924
validate_SInt32Rules_has_const(const validate_SInt32Rules * msg)925 UPB_INLINE bool validate_SInt32Rules_has_const(const validate_SInt32Rules *msg) { return _upb_hasbit(msg, 1); }
validate_SInt32Rules_const(const validate_SInt32Rules * msg)926 UPB_INLINE int32_t validate_SInt32Rules_const(const validate_SInt32Rules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(4, 4), int32_t); }
validate_SInt32Rules_has_lt(const validate_SInt32Rules * msg)927 UPB_INLINE bool validate_SInt32Rules_has_lt(const validate_SInt32Rules *msg) { return _upb_hasbit(msg, 2); }
validate_SInt32Rules_lt(const validate_SInt32Rules * msg)928 UPB_INLINE int32_t validate_SInt32Rules_lt(const validate_SInt32Rules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(8, 8), int32_t); }
validate_SInt32Rules_has_lte(const validate_SInt32Rules * msg)929 UPB_INLINE bool validate_SInt32Rules_has_lte(const validate_SInt32Rules *msg) { return _upb_hasbit(msg, 3); }
validate_SInt32Rules_lte(const validate_SInt32Rules * msg)930 UPB_INLINE int32_t validate_SInt32Rules_lte(const validate_SInt32Rules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(12, 12), int32_t); }
validate_SInt32Rules_has_gt(const validate_SInt32Rules * msg)931 UPB_INLINE bool validate_SInt32Rules_has_gt(const validate_SInt32Rules *msg) { return _upb_hasbit(msg, 4); }
validate_SInt32Rules_gt(const validate_SInt32Rules * msg)932 UPB_INLINE int32_t validate_SInt32Rules_gt(const validate_SInt32Rules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(16, 16), int32_t); }
validate_SInt32Rules_has_gte(const validate_SInt32Rules * msg)933 UPB_INLINE bool validate_SInt32Rules_has_gte(const validate_SInt32Rules *msg) { return _upb_hasbit(msg, 5); }
validate_SInt32Rules_gte(const validate_SInt32Rules * msg)934 UPB_INLINE int32_t validate_SInt32Rules_gte(const validate_SInt32Rules *msg) { return *UPB_PTR_AT(msg, UPB_SIZE(20, 20), int32_t); }
validate_SInt32Rules_in(const validate_SInt32Rules * msg,size_t * len)935 UPB_INLINE int32_t const* validate_SInt32Rules_in(const validate_SInt32Rules *msg, size_t *len) { return (int32_t const*)_upb_array_accessor(msg, UPB_SIZE(24, 24), len); }
validate_SInt32Rules_not_in(const validate_SInt32Rules * msg,size_t * len)936 UPB_INLINE int32_t const* validate_SInt32Rules_not_in(const validate_SInt32Rules *msg, size_t *len) { return (int32_t const*)_upb_array_accessor(msg, UPB_SIZE(28, 32), len); }
937
validate_SInt32Rules_set_const(validate_SInt32Rules * msg,int32_t value)938 UPB_INLINE void validate_SInt32Rules_set_const(validate_SInt32Rules *msg, int32_t value) {
939 _upb_sethas(msg, 1);
940 *UPB_PTR_AT(msg, UPB_SIZE(4, 4), int32_t) = value;
941 }
validate_SInt32Rules_set_lt(validate_SInt32Rules * msg,int32_t value)942 UPB_INLINE void validate_SInt32Rules_set_lt(validate_SInt32Rules *msg, int32_t value) {
943 _upb_sethas(msg, 2);
944 *UPB_PTR_AT(msg, UPB_SIZE(8, 8), int32_t) = value;
945 }
validate_SInt32Rules_set_lte(validate_SInt32Rules * msg,int32_t value)946