1 // automatically generated by the FlatBuffers compiler, do not modify
2
3
4 #ifndef FLATBUFFERS_GENERATED_INTENTCONFIG_LIBTEXTCLASSIFIER3_H_
5 #define FLATBUFFERS_GENERATED_INTENTCONFIG_LIBTEXTCLASSIFIER3_H_
6
7 #include "flatbuffers/flatbuffers.h"
8
9 // Ensure the included flatbuffers.h is the same version as when this file was
10 // generated, otherwise it may not be compatible.
11 static_assert(FLATBUFFERS_VERSION_MAJOR == 2 &&
12 FLATBUFFERS_VERSION_MINOR == 0 &&
13 FLATBUFFERS_VERSION_REVISION == 7,
14 "Non-compatible flatbuffers version included");
15
16 #include "utils/zlib/buffer_generated.h"
17
18 namespace libtextclassifier3 {
19
20 struct AndroidIntentFactoryOptions;
21 struct AndroidIntentFactoryOptionsBuilder;
22 struct AndroidIntentFactoryOptionsT;
23
24 struct AndroidIntentFactoryEntityOptions;
25 struct AndroidIntentFactoryEntityOptionsBuilder;
26 struct AndroidIntentFactoryEntityOptionsT;
27
28 struct AndroidIntentGeneratorOptions;
29 struct AndroidIntentGeneratorOptionsBuilder;
30 struct AndroidIntentGeneratorOptionsT;
31
32 struct AndroidIntentGeneratorStrings;
33 struct AndroidIntentGeneratorStringsBuilder;
34 struct AndroidIntentGeneratorStringsT;
35
36 struct AndroidSimpleIntentGeneratorExtra;
37 struct AndroidSimpleIntentGeneratorExtraBuilder;
38 struct AndroidSimpleIntentGeneratorExtraT;
39
40 struct AndroidSimpleIntentGeneratorCondition;
41 struct AndroidSimpleIntentGeneratorConditionBuilder;
42 struct AndroidSimpleIntentGeneratorConditionT;
43
44 struct AndroidSimpleIntentGeneratorOptions;
45 struct AndroidSimpleIntentGeneratorOptionsBuilder;
46 struct AndroidSimpleIntentGeneratorOptionsT;
47
48 namespace IntentFactoryModel_ {
49
50 struct IntentGenerator;
51 struct IntentGeneratorBuilder;
52 struct IntentGeneratorT;
53
54 } // namespace IntentFactoryModel_
55
56 struct IntentFactoryModel;
57 struct IntentFactoryModelBuilder;
58 struct IntentFactoryModelT;
59
60 enum AndroidSimpleIntentGeneratorVariableType : int32_t {
61 AndroidSimpleIntentGeneratorVariableType_INVALID_VARIABLE = 0,
62 AndroidSimpleIntentGeneratorVariableType_RAW_TEXT = 1,
63 AndroidSimpleIntentGeneratorVariableType_URL_TEXT = 2,
64 AndroidSimpleIntentGeneratorVariableType_URL_ENCODED_TEXT = 3,
65 AndroidSimpleIntentGeneratorVariableType_EVENT_TIME_MS_UTC = 4,
66 AndroidSimpleIntentGeneratorVariableType_EVENT_START_MS_UTC = 5,
67 AndroidSimpleIntentGeneratorVariableType_EVENT_END_MS_UTC = 6,
68 AndroidSimpleIntentGeneratorVariableType_PACKAGE_NAME = 7,
69 AndroidSimpleIntentGeneratorVariableType_MIN = AndroidSimpleIntentGeneratorVariableType_INVALID_VARIABLE,
70 AndroidSimpleIntentGeneratorVariableType_MAX = AndroidSimpleIntentGeneratorVariableType_PACKAGE_NAME
71 };
72
EnumValuesAndroidSimpleIntentGeneratorVariableType()73 inline const AndroidSimpleIntentGeneratorVariableType (&EnumValuesAndroidSimpleIntentGeneratorVariableType())[8] {
74 static const AndroidSimpleIntentGeneratorVariableType values[] = {
75 AndroidSimpleIntentGeneratorVariableType_INVALID_VARIABLE,
76 AndroidSimpleIntentGeneratorVariableType_RAW_TEXT,
77 AndroidSimpleIntentGeneratorVariableType_URL_TEXT,
78 AndroidSimpleIntentGeneratorVariableType_URL_ENCODED_TEXT,
79 AndroidSimpleIntentGeneratorVariableType_EVENT_TIME_MS_UTC,
80 AndroidSimpleIntentGeneratorVariableType_EVENT_START_MS_UTC,
81 AndroidSimpleIntentGeneratorVariableType_EVENT_END_MS_UTC,
82 AndroidSimpleIntentGeneratorVariableType_PACKAGE_NAME
83 };
84 return values;
85 }
86
EnumNamesAndroidSimpleIntentGeneratorVariableType()87 inline const char * const *EnumNamesAndroidSimpleIntentGeneratorVariableType() {
88 static const char * const names[9] = {
89 "INVALID_VARIABLE",
90 "RAW_TEXT",
91 "URL_TEXT",
92 "URL_ENCODED_TEXT",
93 "EVENT_TIME_MS_UTC",
94 "EVENT_START_MS_UTC",
95 "EVENT_END_MS_UTC",
96 "PACKAGE_NAME",
97 nullptr
98 };
99 return names;
100 }
101
EnumNameAndroidSimpleIntentGeneratorVariableType(AndroidSimpleIntentGeneratorVariableType e)102 inline const char *EnumNameAndroidSimpleIntentGeneratorVariableType(AndroidSimpleIntentGeneratorVariableType e) {
103 if (flatbuffers::IsOutRange(e, AndroidSimpleIntentGeneratorVariableType_INVALID_VARIABLE, AndroidSimpleIntentGeneratorVariableType_PACKAGE_NAME)) return "";
104 const size_t index = static_cast<size_t>(e);
105 return EnumNamesAndroidSimpleIntentGeneratorVariableType()[index];
106 }
107
108 enum AndroidSimpleIntentGeneratorExtraType : int32_t {
109 AndroidSimpleIntentGeneratorExtraType_INVALID_EXTRA_TYPE = 0,
110 AndroidSimpleIntentGeneratorExtraType_STRING = 1,
111 AndroidSimpleIntentGeneratorExtraType_BOOL = 2,
112 AndroidSimpleIntentGeneratorExtraType_VARIABLE_AS_LONG = 3,
113 AndroidSimpleIntentGeneratorExtraType_MIN = AndroidSimpleIntentGeneratorExtraType_INVALID_EXTRA_TYPE,
114 AndroidSimpleIntentGeneratorExtraType_MAX = AndroidSimpleIntentGeneratorExtraType_VARIABLE_AS_LONG
115 };
116
EnumValuesAndroidSimpleIntentGeneratorExtraType()117 inline const AndroidSimpleIntentGeneratorExtraType (&EnumValuesAndroidSimpleIntentGeneratorExtraType())[4] {
118 static const AndroidSimpleIntentGeneratorExtraType values[] = {
119 AndroidSimpleIntentGeneratorExtraType_INVALID_EXTRA_TYPE,
120 AndroidSimpleIntentGeneratorExtraType_STRING,
121 AndroidSimpleIntentGeneratorExtraType_BOOL,
122 AndroidSimpleIntentGeneratorExtraType_VARIABLE_AS_LONG
123 };
124 return values;
125 }
126
EnumNamesAndroidSimpleIntentGeneratorExtraType()127 inline const char * const *EnumNamesAndroidSimpleIntentGeneratorExtraType() {
128 static const char * const names[5] = {
129 "INVALID_EXTRA_TYPE",
130 "STRING",
131 "BOOL",
132 "VARIABLE_AS_LONG",
133 nullptr
134 };
135 return names;
136 }
137
EnumNameAndroidSimpleIntentGeneratorExtraType(AndroidSimpleIntentGeneratorExtraType e)138 inline const char *EnumNameAndroidSimpleIntentGeneratorExtraType(AndroidSimpleIntentGeneratorExtraType e) {
139 if (flatbuffers::IsOutRange(e, AndroidSimpleIntentGeneratorExtraType_INVALID_EXTRA_TYPE, AndroidSimpleIntentGeneratorExtraType_VARIABLE_AS_LONG)) return "";
140 const size_t index = static_cast<size_t>(e);
141 return EnumNamesAndroidSimpleIntentGeneratorExtraType()[index];
142 }
143
144 enum AndroidSimpleIntentGeneratorConditionType : int32_t {
145 AndroidSimpleIntentGeneratorConditionType_INVALID_CONDITION_TYPE = 0,
146 AndroidSimpleIntentGeneratorConditionType_USER_RESTRICTION_NOT_SET = 1,
147 AndroidSimpleIntentGeneratorConditionType_EVENT_START_IN_FUTURE_MS = 2,
148 AndroidSimpleIntentGeneratorConditionType_MIN = AndroidSimpleIntentGeneratorConditionType_INVALID_CONDITION_TYPE,
149 AndroidSimpleIntentGeneratorConditionType_MAX = AndroidSimpleIntentGeneratorConditionType_EVENT_START_IN_FUTURE_MS
150 };
151
EnumValuesAndroidSimpleIntentGeneratorConditionType()152 inline const AndroidSimpleIntentGeneratorConditionType (&EnumValuesAndroidSimpleIntentGeneratorConditionType())[3] {
153 static const AndroidSimpleIntentGeneratorConditionType values[] = {
154 AndroidSimpleIntentGeneratorConditionType_INVALID_CONDITION_TYPE,
155 AndroidSimpleIntentGeneratorConditionType_USER_RESTRICTION_NOT_SET,
156 AndroidSimpleIntentGeneratorConditionType_EVENT_START_IN_FUTURE_MS
157 };
158 return values;
159 }
160
EnumNamesAndroidSimpleIntentGeneratorConditionType()161 inline const char * const *EnumNamesAndroidSimpleIntentGeneratorConditionType() {
162 static const char * const names[4] = {
163 "INVALID_CONDITION_TYPE",
164 "USER_RESTRICTION_NOT_SET",
165 "EVENT_START_IN_FUTURE_MS",
166 nullptr
167 };
168 return names;
169 }
170
EnumNameAndroidSimpleIntentGeneratorConditionType(AndroidSimpleIntentGeneratorConditionType e)171 inline const char *EnumNameAndroidSimpleIntentGeneratorConditionType(AndroidSimpleIntentGeneratorConditionType e) {
172 if (flatbuffers::IsOutRange(e, AndroidSimpleIntentGeneratorConditionType_INVALID_CONDITION_TYPE, AndroidSimpleIntentGeneratorConditionType_EVENT_START_IN_FUTURE_MS)) return "";
173 const size_t index = static_cast<size_t>(e);
174 return EnumNamesAndroidSimpleIntentGeneratorConditionType()[index];
175 }
176
177 struct AndroidIntentFactoryOptionsT : public flatbuffers::NativeTable {
178 typedef AndroidIntentFactoryOptions TableType;
179 std::vector<std::unique_ptr<libtextclassifier3::AndroidIntentFactoryEntityOptionsT>> entity{};
180 AndroidIntentFactoryOptionsT() = default;
181 AndroidIntentFactoryOptionsT(const AndroidIntentFactoryOptionsT &o);
182 AndroidIntentFactoryOptionsT(AndroidIntentFactoryOptionsT&&) FLATBUFFERS_NOEXCEPT = default;
183 AndroidIntentFactoryOptionsT &operator=(AndroidIntentFactoryOptionsT o) FLATBUFFERS_NOEXCEPT;
184 };
185
186 struct AndroidIntentFactoryOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table {
187 typedef AndroidIntentFactoryOptionsT NativeTableType;
188 typedef AndroidIntentFactoryOptionsBuilder Builder;
189 enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE {
190 VT_ENTITY = 4
191 };
entityFLATBUFFERS_FINAL_CLASS192 const flatbuffers::Vector<flatbuffers::Offset<libtextclassifier3::AndroidIntentFactoryEntityOptions>> *entity() const {
193 return GetPointer<const flatbuffers::Vector<flatbuffers::Offset<libtextclassifier3::AndroidIntentFactoryEntityOptions>> *>(VT_ENTITY);
194 }
VerifyFLATBUFFERS_FINAL_CLASS195 bool Verify(flatbuffers::Verifier &verifier) const {
196 return VerifyTableStart(verifier) &&
197 VerifyOffset(verifier, VT_ENTITY) &&
198 verifier.VerifyVector(entity()) &&
199 verifier.VerifyVectorOfTables(entity()) &&
200 verifier.EndTable();
201 }
202 AndroidIntentFactoryOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const;
203 void UnPackTo(AndroidIntentFactoryOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const;
204 static flatbuffers::Offset<AndroidIntentFactoryOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const AndroidIntentFactoryOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr);
205 };
206
207 struct AndroidIntentFactoryOptionsBuilder {
208 typedef AndroidIntentFactoryOptions Table;
209 flatbuffers::FlatBufferBuilder &fbb_;
210 flatbuffers::uoffset_t start_;
add_entityAndroidIntentFactoryOptionsBuilder211 void add_entity(flatbuffers::Offset<flatbuffers::Vector<flatbuffers::Offset<libtextclassifier3::AndroidIntentFactoryEntityOptions>>> entity) {
212 fbb_.AddOffset(AndroidIntentFactoryOptions::VT_ENTITY, entity);
213 }
AndroidIntentFactoryOptionsBuilderAndroidIntentFactoryOptionsBuilder214 explicit AndroidIntentFactoryOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb)
215 : fbb_(_fbb) {
216 start_ = fbb_.StartTable();
217 }
FinishAndroidIntentFactoryOptionsBuilder218 flatbuffers::Offset<AndroidIntentFactoryOptions> Finish() {
219 const auto end = fbb_.EndTable(start_);
220 auto o = flatbuffers::Offset<AndroidIntentFactoryOptions>(end);
221 return o;
222 }
223 };
224
225 inline flatbuffers::Offset<AndroidIntentFactoryOptions> CreateAndroidIntentFactoryOptions(
226 flatbuffers::FlatBufferBuilder &_fbb,
227 flatbuffers::Offset<flatbuffers::Vector<flatbuffers::Offset<libtextclassifier3::AndroidIntentFactoryEntityOptions>>> entity = 0) {
228 AndroidIntentFactoryOptionsBuilder builder_(_fbb);
229 builder_.add_entity(entity);
230 return builder_.Finish();
231 }
232
233 inline flatbuffers::Offset<AndroidIntentFactoryOptions> CreateAndroidIntentFactoryOptionsDirect(
234 flatbuffers::FlatBufferBuilder &_fbb,
235 const std::vector<flatbuffers::Offset<libtextclassifier3::AndroidIntentFactoryEntityOptions>> *entity = nullptr) {
236 auto entity__ = entity ? _fbb.CreateVector<flatbuffers::Offset<libtextclassifier3::AndroidIntentFactoryEntityOptions>>(*entity) : 0;
237 return libtextclassifier3::CreateAndroidIntentFactoryOptions(
238 _fbb,
239 entity__);
240 }
241
242 flatbuffers::Offset<AndroidIntentFactoryOptions> CreateAndroidIntentFactoryOptions(flatbuffers::FlatBufferBuilder &_fbb, const AndroidIntentFactoryOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr);
243
244 struct AndroidIntentFactoryEntityOptionsT : public flatbuffers::NativeTable {
245 typedef AndroidIntentFactoryEntityOptions TableType;
246 std::string entity_type{};
247 std::vector<std::unique_ptr<libtextclassifier3::AndroidIntentGeneratorOptionsT>> generator{};
248 AndroidIntentFactoryEntityOptionsT() = default;
249 AndroidIntentFactoryEntityOptionsT(const AndroidIntentFactoryEntityOptionsT &o);
250 AndroidIntentFactoryEntityOptionsT(AndroidIntentFactoryEntityOptionsT&&) FLATBUFFERS_NOEXCEPT = default;
251 AndroidIntentFactoryEntityOptionsT &operator=(AndroidIntentFactoryEntityOptionsT o) FLATBUFFERS_NOEXCEPT;
252 };
253
254 struct AndroidIntentFactoryEntityOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table {
255 typedef AndroidIntentFactoryEntityOptionsT NativeTableType;
256 typedef AndroidIntentFactoryEntityOptionsBuilder Builder;
257 enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE {
258 VT_ENTITY_TYPE = 4,
259 VT_GENERATOR = 6
260 };
entity_typeFLATBUFFERS_FINAL_CLASS261 const flatbuffers::String *entity_type() const {
262 return GetPointer<const flatbuffers::String *>(VT_ENTITY_TYPE);
263 }
generatorFLATBUFFERS_FINAL_CLASS264 const flatbuffers::Vector<flatbuffers::Offset<libtextclassifier3::AndroidIntentGeneratorOptions>> *generator() const {
265 return GetPointer<const flatbuffers::Vector<flatbuffers::Offset<libtextclassifier3::AndroidIntentGeneratorOptions>> *>(VT_GENERATOR);
266 }
VerifyFLATBUFFERS_FINAL_CLASS267 bool Verify(flatbuffers::Verifier &verifier) const {
268 return VerifyTableStart(verifier) &&
269 VerifyOffset(verifier, VT_ENTITY_TYPE) &&
270 verifier.VerifyString(entity_type()) &&
271 VerifyOffset(verifier, VT_GENERATOR) &&
272 verifier.VerifyVector(generator()) &&
273 verifier.VerifyVectorOfTables(generator()) &&
274 verifier.EndTable();
275 }
276 AndroidIntentFactoryEntityOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const;
277 void UnPackTo(AndroidIntentFactoryEntityOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const;
278 static flatbuffers::Offset<AndroidIntentFactoryEntityOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const AndroidIntentFactoryEntityOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr);
279 };
280
281 struct AndroidIntentFactoryEntityOptionsBuilder {
282 typedef AndroidIntentFactoryEntityOptions Table;
283 flatbuffers::FlatBufferBuilder &fbb_;
284 flatbuffers::uoffset_t start_;
add_entity_typeAndroidIntentFactoryEntityOptionsBuilder285 void add_entity_type(flatbuffers::Offset<flatbuffers::String> entity_type) {
286 fbb_.AddOffset(AndroidIntentFactoryEntityOptions::VT_ENTITY_TYPE, entity_type);
287 }
add_generatorAndroidIntentFactoryEntityOptionsBuilder288 void add_generator(flatbuffers::Offset<flatbuffers::Vector<flatbuffers::Offset<libtextclassifier3::AndroidIntentGeneratorOptions>>> generator) {
289 fbb_.AddOffset(AndroidIntentFactoryEntityOptions::VT_GENERATOR, generator);
290 }
AndroidIntentFactoryEntityOptionsBuilderAndroidIntentFactoryEntityOptionsBuilder291 explicit AndroidIntentFactoryEntityOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb)
292 : fbb_(_fbb) {
293 start_ = fbb_.StartTable();
294 }
FinishAndroidIntentFactoryEntityOptionsBuilder295 flatbuffers::Offset<AndroidIntentFactoryEntityOptions> Finish() {
296 const auto end = fbb_.EndTable(start_);
297 auto o = flatbuffers::Offset<AndroidIntentFactoryEntityOptions>(end);
298 return o;
299 }
300 };
301
302 inline flatbuffers::Offset<AndroidIntentFactoryEntityOptions> CreateAndroidIntentFactoryEntityOptions(
303 flatbuffers::FlatBufferBuilder &_fbb,
304 flatbuffers::Offset<flatbuffers::String> entity_type = 0,
305 flatbuffers::Offset<flatbuffers::Vector<flatbuffers::Offset<libtextclassifier3::AndroidIntentGeneratorOptions>>> generator = 0) {
306 AndroidIntentFactoryEntityOptionsBuilder builder_(_fbb);
307 builder_.add_generator(generator);
308 builder_.add_entity_type(entity_type);
309 return builder_.Finish();
310 }
311
312 inline flatbuffers::Offset<AndroidIntentFactoryEntityOptions> CreateAndroidIntentFactoryEntityOptionsDirect(
313 flatbuffers::FlatBufferBuilder &_fbb,
314 const char *entity_type = nullptr,
315 const std::vector<flatbuffers::Offset<libtextclassifier3::AndroidIntentGeneratorOptions>> *generator = nullptr) {
316 auto entity_type__ = entity_type ? _fbb.CreateSharedString(entity_type) : 0;
317 auto generator__ = generator ? _fbb.CreateVector<flatbuffers::Offset<libtextclassifier3::AndroidIntentGeneratorOptions>>(*generator) : 0;
318 return libtextclassifier3::CreateAndroidIntentFactoryEntityOptions(
319 _fbb,
320 entity_type__,
321 generator__);
322 }
323
324 flatbuffers::Offset<AndroidIntentFactoryEntityOptions> CreateAndroidIntentFactoryEntityOptions(flatbuffers::FlatBufferBuilder &_fbb, const AndroidIntentFactoryEntityOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr);
325
326 struct AndroidIntentGeneratorOptionsT : public flatbuffers::NativeTable {
327 typedef AndroidIntentGeneratorOptions TableType;
328 std::vector<std::unique_ptr<libtextclassifier3::AndroidIntentGeneratorStringsT>> strings{};
329 std::unique_ptr<libtextclassifier3::AndroidSimpleIntentGeneratorOptionsT> simple{};
330 AndroidIntentGeneratorOptionsT() = default;
331 AndroidIntentGeneratorOptionsT(const AndroidIntentGeneratorOptionsT &o);
332 AndroidIntentGeneratorOptionsT(AndroidIntentGeneratorOptionsT&&) FLATBUFFERS_NOEXCEPT = default;
333 AndroidIntentGeneratorOptionsT &operator=(AndroidIntentGeneratorOptionsT o) FLATBUFFERS_NOEXCEPT;
334 };
335
336 struct AndroidIntentGeneratorOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table {
337 typedef AndroidIntentGeneratorOptionsT NativeTableType;
338 typedef AndroidIntentGeneratorOptionsBuilder Builder;
339 enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE {
340 VT_STRINGS = 4,
341 VT_SIMPLE = 6
342 };
stringsFLATBUFFERS_FINAL_CLASS343 const flatbuffers::Vector<flatbuffers::Offset<libtextclassifier3::AndroidIntentGeneratorStrings>> *strings() const {
344 return GetPointer<const flatbuffers::Vector<flatbuffers::Offset<libtextclassifier3::AndroidIntentGeneratorStrings>> *>(VT_STRINGS);
345 }
simpleFLATBUFFERS_FINAL_CLASS346 const libtextclassifier3::AndroidSimpleIntentGeneratorOptions *simple() const {
347 return GetPointer<const libtextclassifier3::AndroidSimpleIntentGeneratorOptions *>(VT_SIMPLE);
348 }
VerifyFLATBUFFERS_FINAL_CLASS349 bool Verify(flatbuffers::Verifier &verifier) const {
350 return VerifyTableStart(verifier) &&
351 VerifyOffset(verifier, VT_STRINGS) &&
352 verifier.VerifyVector(strings()) &&
353 verifier.VerifyVectorOfTables(strings()) &&
354 VerifyOffset(verifier, VT_SIMPLE) &&
355 verifier.VerifyTable(simple()) &&
356 verifier.EndTable();
357 }
358 AndroidIntentGeneratorOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const;
359 void UnPackTo(AndroidIntentGeneratorOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const;
360 static flatbuffers::Offset<AndroidIntentGeneratorOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const AndroidIntentGeneratorOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr);
361 };
362
363 struct AndroidIntentGeneratorOptionsBuilder {
364 typedef AndroidIntentGeneratorOptions Table;
365 flatbuffers::FlatBufferBuilder &fbb_;
366 flatbuffers::uoffset_t start_;
add_stringsAndroidIntentGeneratorOptionsBuilder367 void add_strings(flatbuffers::Offset<flatbuffers::Vector<flatbuffers::Offset<libtextclassifier3::AndroidIntentGeneratorStrings>>> strings) {
368 fbb_.AddOffset(AndroidIntentGeneratorOptions::VT_STRINGS, strings);
369 }
add_simpleAndroidIntentGeneratorOptionsBuilder370 void add_simple(flatbuffers::Offset<libtextclassifier3::AndroidSimpleIntentGeneratorOptions> simple) {
371 fbb_.AddOffset(AndroidIntentGeneratorOptions::VT_SIMPLE, simple);
372 }
AndroidIntentGeneratorOptionsBuilderAndroidIntentGeneratorOptionsBuilder373 explicit AndroidIntentGeneratorOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb)
374 : fbb_(_fbb) {
375 start_ = fbb_.StartTable();
376 }
FinishAndroidIntentGeneratorOptionsBuilder377 flatbuffers::Offset<AndroidIntentGeneratorOptions> Finish() {
378 const auto end = fbb_.EndTable(start_);
379 auto o = flatbuffers::Offset<AndroidIntentGeneratorOptions>(end);
380 return o;
381 }
382 };
383
384 inline flatbuffers::Offset<AndroidIntentGeneratorOptions> CreateAndroidIntentGeneratorOptions(
385 flatbuffers::FlatBufferBuilder &_fbb,
386 flatbuffers::Offset<flatbuffers::Vector<flatbuffers::Offset<libtextclassifier3::AndroidIntentGeneratorStrings>>> strings = 0,
387 flatbuffers::Offset<libtextclassifier3::AndroidSimpleIntentGeneratorOptions> simple = 0) {
388 AndroidIntentGeneratorOptionsBuilder builder_(_fbb);
389 builder_.add_simple(simple);
390 builder_.add_strings(strings);
391 return builder_.Finish();
392 }
393
394 inline flatbuffers::Offset<AndroidIntentGeneratorOptions> CreateAndroidIntentGeneratorOptionsDirect(
395 flatbuffers::FlatBufferBuilder &_fbb,
396 const std::vector<flatbuffers::Offset<libtextclassifier3::AndroidIntentGeneratorStrings>> *strings = nullptr,
397 flatbuffers::Offset<libtextclassifier3::AndroidSimpleIntentGeneratorOptions> simple = 0) {
398 auto strings__ = strings ? _fbb.CreateVector<flatbuffers::Offset<libtextclassifier3::AndroidIntentGeneratorStrings>>(*strings) : 0;
399 return libtextclassifier3::CreateAndroidIntentGeneratorOptions(
400 _fbb,
401 strings__,
402 simple);
403 }
404
405 flatbuffers::Offset<AndroidIntentGeneratorOptions> CreateAndroidIntentGeneratorOptions(flatbuffers::FlatBufferBuilder &_fbb, const AndroidIntentGeneratorOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr);
406
407 struct AndroidIntentGeneratorStringsT : public flatbuffers::NativeTable {
408 typedef AndroidIntentGeneratorStrings TableType;
409 std::string language_tag{};
410 std::string title{};
411 std::string description{};
412 };
413
414 struct AndroidIntentGeneratorStrings FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table {
415 typedef AndroidIntentGeneratorStringsT NativeTableType;
416 typedef AndroidIntentGeneratorStringsBuilder Builder;
417 enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE {
418 VT_LANGUAGE_TAG = 4,
419 VT_TITLE = 6,
420 VT_DESCRIPTION = 8
421 };
language_tagFLATBUFFERS_FINAL_CLASS422 const flatbuffers::String *language_tag() const {
423 return GetPointer<const flatbuffers::String *>(VT_LANGUAGE_TAG);
424 }
titleFLATBUFFERS_FINAL_CLASS425 const flatbuffers::String *title() const {
426 return GetPointer<const flatbuffers::String *>(VT_TITLE);
427 }
descriptionFLATBUFFERS_FINAL_CLASS428 const flatbuffers::String *description() const {
429 return GetPointer<const flatbuffers::String *>(VT_DESCRIPTION);
430 }
VerifyFLATBUFFERS_FINAL_CLASS431 bool Verify(flatbuffers::Verifier &verifier) const {
432 return VerifyTableStart(verifier) &&
433 VerifyOffset(verifier, VT_LANGUAGE_TAG) &&
434 verifier.VerifyString(language_tag()) &&
435 VerifyOffset(verifier, VT_TITLE) &&
436 verifier.VerifyString(title()) &&
437 VerifyOffset(verifier, VT_DESCRIPTION) &&
438 verifier.VerifyString(description()) &&
439 verifier.EndTable();
440 }
441 AndroidIntentGeneratorStringsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const;
442 void UnPackTo(AndroidIntentGeneratorStringsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const;
443 static flatbuffers::Offset<AndroidIntentGeneratorStrings> Pack(flatbuffers::FlatBufferBuilder &_fbb, const AndroidIntentGeneratorStringsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr);
444 };
445
446 struct AndroidIntentGeneratorStringsBuilder {
447 typedef AndroidIntentGeneratorStrings Table;
448 flatbuffers::FlatBufferBuilder &fbb_;
449 flatbuffers::uoffset_t start_;
add_language_tagAndroidIntentGeneratorStringsBuilder450 void add_language_tag(flatbuffers::Offset<flatbuffers::String> language_tag) {
451 fbb_.AddOffset(AndroidIntentGeneratorStrings::VT_LANGUAGE_TAG, language_tag);
452 }
add_titleAndroidIntentGeneratorStringsBuilder453 void add_title(flatbuffers::Offset<flatbuffers::String> title) {
454 fbb_.AddOffset(AndroidIntentGeneratorStrings::VT_TITLE, title);
455 }
add_descriptionAndroidIntentGeneratorStringsBuilder456 void add_description(flatbuffers::Offset<flatbuffers::String> description) {
457 fbb_.AddOffset(AndroidIntentGeneratorStrings::VT_DESCRIPTION, description);
458 }
AndroidIntentGeneratorStringsBuilderAndroidIntentGeneratorStringsBuilder459 explicit AndroidIntentGeneratorStringsBuilder(flatbuffers::FlatBufferBuilder &_fbb)
460 : fbb_(_fbb) {
461 start_ = fbb_.StartTable();
462 }
FinishAndroidIntentGeneratorStringsBuilder463 flatbuffers::Offset<AndroidIntentGeneratorStrings> Finish() {
464 const auto end = fbb_.EndTable(start_);
465 auto o = flatbuffers::Offset<AndroidIntentGeneratorStrings>(end);
466 return o;
467 }
468 };
469
470 inline flatbuffers::Offset<AndroidIntentGeneratorStrings> CreateAndroidIntentGeneratorStrings(
471 flatbuffers::FlatBufferBuilder &_fbb,
472 flatbuffers::Offset<flatbuffers::String> language_tag = 0,
473 flatbuffers::Offset<flatbuffers::String> title = 0,
474 flatbuffers::Offset<flatbuffers::String> description = 0) {
475 AndroidIntentGeneratorStringsBuilder builder_(_fbb);
476 builder_.add_description(description);
477 builder_.add_title(title);
478 builder_.add_language_tag(language_tag);
479 return builder_.Finish();
480 }
481
482 inline flatbuffers::Offset<AndroidIntentGeneratorStrings> CreateAndroidIntentGeneratorStringsDirect(
483 flatbuffers::FlatBufferBuilder &_fbb,
484 const char *language_tag = nullptr,
485 const char *title = nullptr,
486 const char *description = nullptr) {
487 auto language_tag__ = language_tag ? _fbb.CreateSharedString(language_tag) : 0;
488 auto title__ = title ? _fbb.CreateSharedString(title) : 0;
489 auto description__ = description ? _fbb.CreateSharedString(description) : 0;
490 return libtextclassifier3::CreateAndroidIntentGeneratorStrings(
491 _fbb,
492 language_tag__,
493 title__,
494 description__);
495 }
496
497 flatbuffers::Offset<AndroidIntentGeneratorStrings> CreateAndroidIntentGeneratorStrings(flatbuffers::FlatBufferBuilder &_fbb, const AndroidIntentGeneratorStringsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr);
498
499 struct AndroidSimpleIntentGeneratorExtraT : public flatbuffers::NativeTable {
500 typedef AndroidSimpleIntentGeneratorExtra TableType;
501 std::string name{};
502 libtextclassifier3::AndroidSimpleIntentGeneratorExtraType type = libtextclassifier3::AndroidSimpleIntentGeneratorExtraType_INVALID_EXTRA_TYPE;
503 std::string string_{};
504 bool bool_ = false;
505 int32_t int32_ = 0;
506 };
507
508 struct AndroidSimpleIntentGeneratorExtra FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table {
509 typedef AndroidSimpleIntentGeneratorExtraT NativeTableType;
510 typedef AndroidSimpleIntentGeneratorExtraBuilder Builder;
511 enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE {
512 VT_NAME = 4,
513 VT_TYPE = 6,
514 VT_STRING_ = 8,
515 VT_BOOL_ = 10,
516 VT_INT32_ = 12
517 };
nameFLATBUFFERS_FINAL_CLASS518 const flatbuffers::String *name() const {
519 return GetPointer<const flatbuffers::String *>(VT_NAME);
520 }
typeFLATBUFFERS_FINAL_CLASS521 libtextclassifier3::AndroidSimpleIntentGeneratorExtraType type() const {
522 return static_cast<libtextclassifier3::AndroidSimpleIntentGeneratorExtraType>(GetField<int32_t>(VT_TYPE, 0));
523 }
string_FLATBUFFERS_FINAL_CLASS524 const flatbuffers::String *string_() const {
525 return GetPointer<const flatbuffers::String *>(VT_STRING_);
526 }
bool_FLATBUFFERS_FINAL_CLASS527 bool bool_() const {
528 return GetField<uint8_t>(VT_BOOL_, 0) != 0;
529 }
int32_FLATBUFFERS_FINAL_CLASS530 int32_t int32_() const {
531 return GetField<int32_t>(VT_INT32_, 0);
532 }
VerifyFLATBUFFERS_FINAL_CLASS533 bool Verify(flatbuffers::Verifier &verifier) const {
534 return VerifyTableStart(verifier) &&
535 VerifyOffset(verifier, VT_NAME) &&
536 verifier.VerifyString(name()) &&
537 VerifyField<int32_t>(verifier, VT_TYPE, 4) &&
538 VerifyOffset(verifier, VT_STRING_) &&
539 verifier.VerifyString(string_()) &&
540 VerifyField<uint8_t>(verifier, VT_BOOL_, 1) &&
541 VerifyField<int32_t>(verifier, VT_INT32_, 4) &&
542 verifier.EndTable();
543 }
544 AndroidSimpleIntentGeneratorExtraT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const;
545 void UnPackTo(AndroidSimpleIntentGeneratorExtraT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const;
546 static flatbuffers::Offset<AndroidSimpleIntentGeneratorExtra> Pack(flatbuffers::FlatBufferBuilder &_fbb, const AndroidSimpleIntentGeneratorExtraT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr);
547 };
548
549 struct AndroidSimpleIntentGeneratorExtraBuilder {
550 typedef AndroidSimpleIntentGeneratorExtra Table;
551 flatbuffers::FlatBufferBuilder &fbb_;
552 flatbuffers::uoffset_t start_;
add_nameAndroidSimpleIntentGeneratorExtraBuilder553 void add_name(flatbuffers::Offset<flatbuffers::String> name) {
554 fbb_.AddOffset(AndroidSimpleIntentGeneratorExtra::VT_NAME, name);
555 }
add_typeAndroidSimpleIntentGeneratorExtraBuilder556 void add_type(libtextclassifier3::AndroidSimpleIntentGeneratorExtraType type) {
557 fbb_.AddElement<int32_t>(AndroidSimpleIntentGeneratorExtra::VT_TYPE, static_cast<int32_t>(type), 0);
558 }
add_string_AndroidSimpleIntentGeneratorExtraBuilder559 void add_string_(flatbuffers::Offset<flatbuffers::String> string_) {
560 fbb_.AddOffset(AndroidSimpleIntentGeneratorExtra::VT_STRING_, string_);
561 }
add_bool_AndroidSimpleIntentGeneratorExtraBuilder562 void add_bool_(bool bool_) {
563 fbb_.AddElement<uint8_t>(AndroidSimpleIntentGeneratorExtra::VT_BOOL_, static_cast<uint8_t>(bool_), 0);
564 }
add_int32_AndroidSimpleIntentGeneratorExtraBuilder565 void add_int32_(int32_t int32_) {
566 fbb_.AddElement<int32_t>(AndroidSimpleIntentGeneratorExtra::VT_INT32_, int32_, 0);
567 }
AndroidSimpleIntentGeneratorExtraBuilderAndroidSimpleIntentGeneratorExtraBuilder568 explicit AndroidSimpleIntentGeneratorExtraBuilder(flatbuffers::FlatBufferBuilder &_fbb)
569 : fbb_(_fbb) {
570 start_ = fbb_.StartTable();
571 }
FinishAndroidSimpleIntentGeneratorExtraBuilder572 flatbuffers::Offset<AndroidSimpleIntentGeneratorExtra> Finish() {
573 const auto end = fbb_.EndTable(start_);
574 auto o = flatbuffers::Offset<AndroidSimpleIntentGeneratorExtra>(end);
575 return o;
576 }
577 };
578
579 inline flatbuffers::Offset<AndroidSimpleIntentGeneratorExtra> CreateAndroidSimpleIntentGeneratorExtra(
580 flatbuffers::FlatBufferBuilder &_fbb,
581 flatbuffers::Offset<flatbuffers::String> name = 0,
582 libtextclassifier3::AndroidSimpleIntentGeneratorExtraType type = libtextclassifier3::AndroidSimpleIntentGeneratorExtraType_INVALID_EXTRA_TYPE,
583 flatbuffers::Offset<flatbuffers::String> string_ = 0,
584 bool bool_ = false,
585 int32_t int32_ = 0) {
586 AndroidSimpleIntentGeneratorExtraBuilder builder_(_fbb);
587 builder_.add_int32_(int32_);
588 builder_.add_string_(string_);
589 builder_.add_type(type);
590 builder_.add_name(name);
591 builder_.add_bool_(bool_);
592 return builder_.Finish();
593 }
594
595 inline flatbuffers::Offset<AndroidSimpleIntentGeneratorExtra> CreateAndroidSimpleIntentGeneratorExtraDirect(
596 flatbuffers::FlatBufferBuilder &_fbb,
597 const char *name = nullptr,
598 libtextclassifier3::AndroidSimpleIntentGeneratorExtraType type = libtextclassifier3::AndroidSimpleIntentGeneratorExtraType_INVALID_EXTRA_TYPE,
599 const char *string_ = nullptr,
600 bool bool_ = false,
601 int32_t int32_ = 0) {
602 auto name__ = name ? _fbb.CreateSharedString(name) : 0;
603 auto string___ = string_ ? _fbb.CreateSharedString(string_) : 0;
604 return libtextclassifier3::CreateAndroidSimpleIntentGeneratorExtra(
605 _fbb,
606 name__,
607 type,
608 string___,
609 bool_,
610 int32_);
611 }
612
613 flatbuffers::Offset<AndroidSimpleIntentGeneratorExtra> CreateAndroidSimpleIntentGeneratorExtra(flatbuffers::FlatBufferBuilder &_fbb, const AndroidSimpleIntentGeneratorExtraT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr);
614
615 struct AndroidSimpleIntentGeneratorConditionT : public flatbuffers::NativeTable {
616 typedef AndroidSimpleIntentGeneratorCondition TableType;
617 libtextclassifier3::AndroidSimpleIntentGeneratorConditionType type = libtextclassifier3::AndroidSimpleIntentGeneratorConditionType_INVALID_CONDITION_TYPE;
618 std::string string_{};
619 int32_t int32_ = 0;
620 int64_t int64_ = 0;
621 };
622
623 struct AndroidSimpleIntentGeneratorCondition FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table {
624 typedef AndroidSimpleIntentGeneratorConditionT NativeTableType;
625 typedef AndroidSimpleIntentGeneratorConditionBuilder Builder;
626 enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE {
627 VT_TYPE = 4,
628 VT_STRING_ = 6,
629 VT_INT32_ = 8,
630 VT_INT64_ = 10
631 };
typeFLATBUFFERS_FINAL_CLASS632 libtextclassifier3::AndroidSimpleIntentGeneratorConditionType type() const {
633 return static_cast<libtextclassifier3::AndroidSimpleIntentGeneratorConditionType>(GetField<int32_t>(VT_TYPE, 0));
634 }
string_FLATBUFFERS_FINAL_CLASS635 const flatbuffers::String *string_() const {
636 return GetPointer<const flatbuffers::String *>(VT_STRING_);
637 }
int32_FLATBUFFERS_FINAL_CLASS638 int32_t int32_() const {
639 return GetField<int32_t>(VT_INT32_, 0);
640 }
int64_FLATBUFFERS_FINAL_CLASS641 int64_t int64_() const {
642 return GetField<int64_t>(VT_INT64_, 0);
643 }
VerifyFLATBUFFERS_FINAL_CLASS644 bool Verify(flatbuffers::Verifier &verifier) const {
645 return VerifyTableStart(verifier) &&
646 VerifyField<int32_t>(verifier, VT_TYPE, 4) &&
647 VerifyOffset(verifier, VT_STRING_) &&
648 verifier.VerifyString(string_()) &&
649 VerifyField<int32_t>(verifier, VT_INT32_, 4) &&
650 VerifyField<int64_t>(verifier, VT_INT64_, 8) &&
651 verifier.EndTable();
652 }
653 AndroidSimpleIntentGeneratorConditionT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const;
654 void UnPackTo(AndroidSimpleIntentGeneratorConditionT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const;
655 static flatbuffers::Offset<AndroidSimpleIntentGeneratorCondition> Pack(flatbuffers::FlatBufferBuilder &_fbb, const AndroidSimpleIntentGeneratorConditionT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr);
656 };
657
658 struct AndroidSimpleIntentGeneratorConditionBuilder {
659 typedef AndroidSimpleIntentGeneratorCondition Table;
660 flatbuffers::FlatBufferBuilder &fbb_;
661 flatbuffers::uoffset_t start_;
add_typeAndroidSimpleIntentGeneratorConditionBuilder662 void add_type(libtextclassifier3::AndroidSimpleIntentGeneratorConditionType type) {
663 fbb_.AddElement<int32_t>(AndroidSimpleIntentGeneratorCondition::VT_TYPE, static_cast<int32_t>(type), 0);
664 }
add_string_AndroidSimpleIntentGeneratorConditionBuilder665 void add_string_(flatbuffers::Offset<flatbuffers::String> string_) {
666 fbb_.AddOffset(AndroidSimpleIntentGeneratorCondition::VT_STRING_, string_);
667 }
add_int32_AndroidSimpleIntentGeneratorConditionBuilder668 void add_int32_(int32_t int32_) {
669 fbb_.AddElement<int32_t>(AndroidSimpleIntentGeneratorCondition::VT_INT32_, int32_, 0);
670 }
add_int64_AndroidSimpleIntentGeneratorConditionBuilder671 void add_int64_(int64_t int64_) {
672 fbb_.AddElement<int64_t>(AndroidSimpleIntentGeneratorCondition::VT_INT64_, int64_, 0);
673 }
AndroidSimpleIntentGeneratorConditionBuilderAndroidSimpleIntentGeneratorConditionBuilder674 explicit AndroidSimpleIntentGeneratorConditionBuilder(flatbuffers::FlatBufferBuilder &_fbb)
675 : fbb_(_fbb) {
676 start_ = fbb_.StartTable();
677 }
FinishAndroidSimpleIntentGeneratorConditionBuilder678 flatbuffers::Offset<AndroidSimpleIntentGeneratorCondition> Finish() {
679 const auto end = fbb_.EndTable(start_);
680 auto o = flatbuffers::Offset<AndroidSimpleIntentGeneratorCondition>(end);
681 return o;
682 }
683 };
684
685 inline flatbuffers::Offset<AndroidSimpleIntentGeneratorCondition> CreateAndroidSimpleIntentGeneratorCondition(
686 flatbuffers::FlatBufferBuilder &_fbb,
687 libtextclassifier3::AndroidSimpleIntentGeneratorConditionType type = libtextclassifier3::AndroidSimpleIntentGeneratorConditionType_INVALID_CONDITION_TYPE,
688 flatbuffers::Offset<flatbuffers::String> string_ = 0,
689 int32_t int32_ = 0,
690 int64_t int64_ = 0) {
691 AndroidSimpleIntentGeneratorConditionBuilder builder_(_fbb);
692 builder_.add_int64_(int64_);
693 builder_.add_int32_(int32_);
694 builder_.add_string_(string_);
695 builder_.add_type(type);
696 return builder_.Finish();
697 }
698
699 inline flatbuffers::Offset<AndroidSimpleIntentGeneratorCondition> CreateAndroidSimpleIntentGeneratorConditionDirect(
700 flatbuffers::FlatBufferBuilder &_fbb,
701 libtextclassifier3::AndroidSimpleIntentGeneratorConditionType type = libtextclassifier3::AndroidSimpleIntentGeneratorConditionType_INVALID_CONDITION_TYPE,
702 const char *string_ = nullptr,
703 int32_t int32_ = 0,
704 int64_t int64_ = 0) {
705 auto string___ = string_ ? _fbb.CreateSharedString(string_) : 0;
706 return libtextclassifier3::CreateAndroidSimpleIntentGeneratorCondition(
707 _fbb,
708 type,
709 string___,
710 int32_,
711 int64_);
712 }
713
714 flatbuffers::Offset<AndroidSimpleIntentGeneratorCondition> CreateAndroidSimpleIntentGeneratorCondition(flatbuffers::FlatBufferBuilder &_fbb, const AndroidSimpleIntentGeneratorConditionT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr);
715
716 struct AndroidSimpleIntentGeneratorOptionsT : public flatbuffers::NativeTable {
717 typedef AndroidSimpleIntentGeneratorOptions TableType;
718 std::string action{};
719 std::string data{};
720 std::string type{};
721 std::vector<std::unique_ptr<libtextclassifier3::AndroidSimpleIntentGeneratorExtraT>> extra{};
722 std::vector<libtextclassifier3::AndroidSimpleIntentGeneratorVariableType> variable{};
723 std::vector<std::unique_ptr<libtextclassifier3::AndroidSimpleIntentGeneratorConditionT>> condition{};
724 AndroidSimpleIntentGeneratorOptionsT() = default;
725 AndroidSimpleIntentGeneratorOptionsT(const AndroidSimpleIntentGeneratorOptionsT &o);
726 AndroidSimpleIntentGeneratorOptionsT(AndroidSimpleIntentGeneratorOptionsT&&) FLATBUFFERS_NOEXCEPT = default;
727 AndroidSimpleIntentGeneratorOptionsT &operator=(AndroidSimpleIntentGeneratorOptionsT o) FLATBUFFERS_NOEXCEPT;
728 };
729
730 struct AndroidSimpleIntentGeneratorOptions FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table {
731 typedef AndroidSimpleIntentGeneratorOptionsT NativeTableType;
732 typedef AndroidSimpleIntentGeneratorOptionsBuilder Builder;
733 enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE {
734 VT_ACTION = 4,
735 VT_DATA = 6,
736 VT_TYPE = 8,
737 VT_EXTRA = 10,
738 VT_VARIABLE = 12,
739 VT_CONDITION = 14
740 };
actionFLATBUFFERS_FINAL_CLASS741 const flatbuffers::String *action() const {
742 return GetPointer<const flatbuffers::String *>(VT_ACTION);
743 }
dataFLATBUFFERS_FINAL_CLASS744 const flatbuffers::String *data() const {
745 return GetPointer<const flatbuffers::String *>(VT_DATA);
746 }
typeFLATBUFFERS_FINAL_CLASS747 const flatbuffers::String *type() const {
748 return GetPointer<const flatbuffers::String *>(VT_TYPE);
749 }
extraFLATBUFFERS_FINAL_CLASS750 const flatbuffers::Vector<flatbuffers::Offset<libtextclassifier3::AndroidSimpleIntentGeneratorExtra>> *extra() const {
751 return GetPointer<const flatbuffers::Vector<flatbuffers::Offset<libtextclassifier3::AndroidSimpleIntentGeneratorExtra>> *>(VT_EXTRA);
752 }
variableFLATBUFFERS_FINAL_CLASS753 const flatbuffers::Vector<int32_t> *variable() const {
754 return GetPointer<const flatbuffers::Vector<int32_t> *>(VT_VARIABLE);
755 }
conditionFLATBUFFERS_FINAL_CLASS756 const flatbuffers::Vector<flatbuffers::Offset<libtextclassifier3::AndroidSimpleIntentGeneratorCondition>> *condition() const {
757 return GetPointer<const flatbuffers::Vector<flatbuffers::Offset<libtextclassifier3::AndroidSimpleIntentGeneratorCondition>> *>(VT_CONDITION);
758 }
VerifyFLATBUFFERS_FINAL_CLASS759 bool Verify(flatbuffers::Verifier &verifier) const {
760 return VerifyTableStart(verifier) &&
761 VerifyOffset(verifier, VT_ACTION) &&
762 verifier.VerifyString(action()) &&
763 VerifyOffset(verifier, VT_DATA) &&
764 verifier.VerifyString(data()) &&
765 VerifyOffset(verifier, VT_TYPE) &&
766 verifier.VerifyString(type()) &&
767 VerifyOffset(verifier, VT_EXTRA) &&
768 verifier.VerifyVector(extra()) &&
769 verifier.VerifyVectorOfTables(extra()) &&
770 VerifyOffset(verifier, VT_VARIABLE) &&
771 verifier.VerifyVector(variable()) &&
772 VerifyOffset(verifier, VT_CONDITION) &&
773 verifier.VerifyVector(condition()) &&
774 verifier.VerifyVectorOfTables(condition()) &&
775 verifier.EndTable();
776 }
777 AndroidSimpleIntentGeneratorOptionsT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const;
778 void UnPackTo(AndroidSimpleIntentGeneratorOptionsT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const;
779 static flatbuffers::Offset<AndroidSimpleIntentGeneratorOptions> Pack(flatbuffers::FlatBufferBuilder &_fbb, const AndroidSimpleIntentGeneratorOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr);
780 };
781
782 struct AndroidSimpleIntentGeneratorOptionsBuilder {
783 typedef AndroidSimpleIntentGeneratorOptions Table;
784 flatbuffers::FlatBufferBuilder &fbb_;
785 flatbuffers::uoffset_t start_;
add_actionAndroidSimpleIntentGeneratorOptionsBuilder786 void add_action(flatbuffers::Offset<flatbuffers::String> action) {
787 fbb_.AddOffset(AndroidSimpleIntentGeneratorOptions::VT_ACTION, action);
788 }
add_dataAndroidSimpleIntentGeneratorOptionsBuilder789 void add_data(flatbuffers::Offset<flatbuffers::String> data) {
790 fbb_.AddOffset(AndroidSimpleIntentGeneratorOptions::VT_DATA, data);
791 }
add_typeAndroidSimpleIntentGeneratorOptionsBuilder792 void add_type(flatbuffers::Offset<flatbuffers::String> type) {
793 fbb_.AddOffset(AndroidSimpleIntentGeneratorOptions::VT_TYPE, type);
794 }
add_extraAndroidSimpleIntentGeneratorOptionsBuilder795 void add_extra(flatbuffers::Offset<flatbuffers::Vector<flatbuffers::Offset<libtextclassifier3::AndroidSimpleIntentGeneratorExtra>>> extra) {
796 fbb_.AddOffset(AndroidSimpleIntentGeneratorOptions::VT_EXTRA, extra);
797 }
add_variableAndroidSimpleIntentGeneratorOptionsBuilder798 void add_variable(flatbuffers::Offset<flatbuffers::Vector<int32_t>> variable) {
799 fbb_.AddOffset(AndroidSimpleIntentGeneratorOptions::VT_VARIABLE, variable);
800 }
add_conditionAndroidSimpleIntentGeneratorOptionsBuilder801 void add_condition(flatbuffers::Offset<flatbuffers::Vector<flatbuffers::Offset<libtextclassifier3::AndroidSimpleIntentGeneratorCondition>>> condition) {
802 fbb_.AddOffset(AndroidSimpleIntentGeneratorOptions::VT_CONDITION, condition);
803 }
AndroidSimpleIntentGeneratorOptionsBuilderAndroidSimpleIntentGeneratorOptionsBuilder804 explicit AndroidSimpleIntentGeneratorOptionsBuilder(flatbuffers::FlatBufferBuilder &_fbb)
805 : fbb_(_fbb) {
806 start_ = fbb_.StartTable();
807 }
FinishAndroidSimpleIntentGeneratorOptionsBuilder808 flatbuffers::Offset<AndroidSimpleIntentGeneratorOptions> Finish() {
809 const auto end = fbb_.EndTable(start_);
810 auto o = flatbuffers::Offset<AndroidSimpleIntentGeneratorOptions>(end);
811 return o;
812 }
813 };
814
815 inline flatbuffers::Offset<AndroidSimpleIntentGeneratorOptions> CreateAndroidSimpleIntentGeneratorOptions(
816 flatbuffers::FlatBufferBuilder &_fbb,
817 flatbuffers::Offset<flatbuffers::String> action = 0,
818 flatbuffers::Offset<flatbuffers::String> data = 0,
819 flatbuffers::Offset<flatbuffers::String> type = 0,
820 flatbuffers::Offset<flatbuffers::Vector<flatbuffers::Offset<libtextclassifier3::AndroidSimpleIntentGeneratorExtra>>> extra = 0,
821 flatbuffers::Offset<flatbuffers::Vector<int32_t>> variable = 0,
822 flatbuffers::Offset<flatbuffers::Vector<flatbuffers::Offset<libtextclassifier3::AndroidSimpleIntentGeneratorCondition>>> condition = 0) {
823 AndroidSimpleIntentGeneratorOptionsBuilder builder_(_fbb);
824 builder_.add_condition(condition);
825 builder_.add_variable(variable);
826 builder_.add_extra(extra);
827 builder_.add_type(type);
828 builder_.add_data(data);
829 builder_.add_action(action);
830 return builder_.Finish();
831 }
832
833 inline flatbuffers::Offset<AndroidSimpleIntentGeneratorOptions> CreateAndroidSimpleIntentGeneratorOptionsDirect(
834 flatbuffers::FlatBufferBuilder &_fbb,
835 const char *action = nullptr,
836 const char *data = nullptr,
837 const char *type = nullptr,
838 const std::vector<flatbuffers::Offset<libtextclassifier3::AndroidSimpleIntentGeneratorExtra>> *extra = nullptr,
839 const std::vector<int32_t> *variable = nullptr,
840 const std::vector<flatbuffers::Offset<libtextclassifier3::AndroidSimpleIntentGeneratorCondition>> *condition = nullptr) {
841 auto action__ = action ? _fbb.CreateSharedString(action) : 0;
842 auto data__ = data ? _fbb.CreateSharedString(data) : 0;
843 auto type__ = type ? _fbb.CreateSharedString(type) : 0;
844 auto extra__ = extra ? _fbb.CreateVector<flatbuffers::Offset<libtextclassifier3::AndroidSimpleIntentGeneratorExtra>>(*extra) : 0;
845 auto variable__ = variable ? _fbb.CreateVector<int32_t>(*variable) : 0;
846 auto condition__ = condition ? _fbb.CreateVector<flatbuffers::Offset<libtextclassifier3::AndroidSimpleIntentGeneratorCondition>>(*condition) : 0;
847 return libtextclassifier3::CreateAndroidSimpleIntentGeneratorOptions(
848 _fbb,
849 action__,
850 data__,
851 type__,
852 extra__,
853 variable__,
854 condition__);
855 }
856
857 flatbuffers::Offset<AndroidSimpleIntentGeneratorOptions> CreateAndroidSimpleIntentGeneratorOptions(flatbuffers::FlatBufferBuilder &_fbb, const AndroidSimpleIntentGeneratorOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr);
858
859 namespace IntentFactoryModel_ {
860
861 struct IntentGeneratorT : public flatbuffers::NativeTable {
862 typedef IntentGenerator TableType;
863 std::string type{};
864 std::vector<uint8_t> lua_template_generator{};
865 std::unique_ptr<libtextclassifier3::CompressedBufferT> compressed_lua_template_generator{};
866 IntentGeneratorT() = default;
867 IntentGeneratorT(const IntentGeneratorT &o);
868 IntentGeneratorT(IntentGeneratorT&&) FLATBUFFERS_NOEXCEPT = default;
869 IntentGeneratorT &operator=(IntentGeneratorT o) FLATBUFFERS_NOEXCEPT;
870 };
871
872 struct IntentGenerator FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table {
873 typedef IntentGeneratorT NativeTableType;
874 typedef IntentGeneratorBuilder Builder;
875 enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE {
876 VT_TYPE = 4,
877 VT_LUA_TEMPLATE_GENERATOR = 6,
878 VT_COMPRESSED_LUA_TEMPLATE_GENERATOR = 8
879 };
typeFLATBUFFERS_FINAL_CLASS880 const flatbuffers::String *type() const {
881 return GetPointer<const flatbuffers::String *>(VT_TYPE);
882 }
lua_template_generatorFLATBUFFERS_FINAL_CLASS883 const flatbuffers::Vector<uint8_t> *lua_template_generator() const {
884 return GetPointer<const flatbuffers::Vector<uint8_t> *>(VT_LUA_TEMPLATE_GENERATOR);
885 }
compressed_lua_template_generatorFLATBUFFERS_FINAL_CLASS886 const libtextclassifier3::CompressedBuffer *compressed_lua_template_generator() const {
887 return GetPointer<const libtextclassifier3::CompressedBuffer *>(VT_COMPRESSED_LUA_TEMPLATE_GENERATOR);
888 }
VerifyFLATBUFFERS_FINAL_CLASS889 bool Verify(flatbuffers::Verifier &verifier) const {
890 return VerifyTableStart(verifier) &&
891 VerifyOffset(verifier, VT_TYPE) &&
892 verifier.VerifyString(type()) &&
893 VerifyOffset(verifier, VT_LUA_TEMPLATE_GENERATOR) &&
894 verifier.VerifyVector(lua_template_generator()) &&
895 VerifyOffset(verifier, VT_COMPRESSED_LUA_TEMPLATE_GENERATOR) &&
896 verifier.VerifyTable(compressed_lua_template_generator()) &&
897 verifier.EndTable();
898 }
899 IntentGeneratorT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const;
900 void UnPackTo(IntentGeneratorT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const;
901 static flatbuffers::Offset<IntentGenerator> Pack(flatbuffers::FlatBufferBuilder &_fbb, const IntentGeneratorT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr);
902 };
903
904 struct IntentGeneratorBuilder {
905 typedef IntentGenerator Table;
906 flatbuffers::FlatBufferBuilder &fbb_;
907 flatbuffers::uoffset_t start_;
add_typeIntentGeneratorBuilder908 void add_type(flatbuffers::Offset<flatbuffers::String> type) {
909 fbb_.AddOffset(IntentGenerator::VT_TYPE, type);
910 }
add_lua_template_generatorIntentGeneratorBuilder911 void add_lua_template_generator(flatbuffers::Offset<flatbuffers::Vector<uint8_t>> lua_template_generator) {
912 fbb_.AddOffset(IntentGenerator::VT_LUA_TEMPLATE_GENERATOR, lua_template_generator);
913 }
add_compressed_lua_template_generatorIntentGeneratorBuilder914 void add_compressed_lua_template_generator(flatbuffers::Offset<libtextclassifier3::CompressedBuffer> compressed_lua_template_generator) {
915 fbb_.AddOffset(IntentGenerator::VT_COMPRESSED_LUA_TEMPLATE_GENERATOR, compressed_lua_template_generator);
916 }
IntentGeneratorBuilderIntentGeneratorBuilder917 explicit IntentGeneratorBuilder(flatbuffers::FlatBufferBuilder &_fbb)
918 : fbb_(_fbb) {
919 start_ = fbb_.StartTable();
920 }
FinishIntentGeneratorBuilder921 flatbuffers::Offset<IntentGenerator> Finish() {
922 const auto end = fbb_.EndTable(start_);
923 auto o = flatbuffers::Offset<IntentGenerator>(end);
924 return o;
925 }
926 };
927
928 inline flatbuffers::Offset<IntentGenerator> CreateIntentGenerator(
929 flatbuffers::FlatBufferBuilder &_fbb,
930 flatbuffers::Offset<flatbuffers::String> type = 0,
931 flatbuffers::Offset<flatbuffers::Vector<uint8_t>> lua_template_generator = 0,
932 flatbuffers::Offset<libtextclassifier3::CompressedBuffer> compressed_lua_template_generator = 0) {
933 IntentGeneratorBuilder builder_(_fbb);
934 builder_.add_compressed_lua_template_generator(compressed_lua_template_generator);
935 builder_.add_lua_template_generator(lua_template_generator);
936 builder_.add_type(type);
937 return builder_.Finish();
938 }
939
940 inline flatbuffers::Offset<IntentGenerator> CreateIntentGeneratorDirect(
941 flatbuffers::FlatBufferBuilder &_fbb,
942 const char *type = nullptr,
943 const std::vector<uint8_t> *lua_template_generator = nullptr,
944 flatbuffers::Offset<libtextclassifier3::CompressedBuffer> compressed_lua_template_generator = 0) {
945 auto type__ = type ? _fbb.CreateSharedString(type) : 0;
946 auto lua_template_generator__ = lua_template_generator ? _fbb.CreateVector<uint8_t>(*lua_template_generator) : 0;
947 return libtextclassifier3::IntentFactoryModel_::CreateIntentGenerator(
948 _fbb,
949 type__,
950 lua_template_generator__,
951 compressed_lua_template_generator);
952 }
953
954 flatbuffers::Offset<IntentGenerator> CreateIntentGenerator(flatbuffers::FlatBufferBuilder &_fbb, const IntentGeneratorT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr);
955
956 } // namespace IntentFactoryModel_
957
958 struct IntentFactoryModelT : public flatbuffers::NativeTable {
959 typedef IntentFactoryModel TableType;
960 std::vector<std::unique_ptr<libtextclassifier3::IntentFactoryModel_::IntentGeneratorT>> generator{};
961 bool precompile_generators = false;
962 IntentFactoryModelT() = default;
963 IntentFactoryModelT(const IntentFactoryModelT &o);
964 IntentFactoryModelT(IntentFactoryModelT&&) FLATBUFFERS_NOEXCEPT = default;
965 IntentFactoryModelT &operator=(IntentFactoryModelT o) FLATBUFFERS_NOEXCEPT;
966 };
967
968 struct IntentFactoryModel FLATBUFFERS_FINAL_CLASS : private flatbuffers::Table {
969 typedef IntentFactoryModelT NativeTableType;
970 typedef IntentFactoryModelBuilder Builder;
971 enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE {
972 VT_GENERATOR = 4,
973 VT_PRECOMPILE_GENERATORS = 6
974 };
generatorFLATBUFFERS_FINAL_CLASS975 const flatbuffers::Vector<flatbuffers::Offset<libtextclassifier3::IntentFactoryModel_::IntentGenerator>> *generator() const {
976 return GetPointer<const flatbuffers::Vector<flatbuffers::Offset<libtextclassifier3::IntentFactoryModel_::IntentGenerator>> *>(VT_GENERATOR);
977 }
precompile_generatorsFLATBUFFERS_FINAL_CLASS978 bool precompile_generators() const {
979 return GetField<uint8_t>(VT_PRECOMPILE_GENERATORS, 0) != 0;
980 }
VerifyFLATBUFFERS_FINAL_CLASS981 bool Verify(flatbuffers::Verifier &verifier) const {
982 return VerifyTableStart(verifier) &&
983 VerifyOffset(verifier, VT_GENERATOR) &&
984 verifier.VerifyVector(generator()) &&
985 verifier.VerifyVectorOfTables(generator()) &&
986 VerifyField<uint8_t>(verifier, VT_PRECOMPILE_GENERATORS, 1) &&
987 verifier.EndTable();
988 }
989 IntentFactoryModelT *UnPack(const flatbuffers::resolver_function_t *_resolver = nullptr) const;
990 void UnPackTo(IntentFactoryModelT *_o, const flatbuffers::resolver_function_t *_resolver = nullptr) const;
991 static flatbuffers::Offset<IntentFactoryModel> Pack(flatbuffers::FlatBufferBuilder &_fbb, const IntentFactoryModelT* _o, const flatbuffers::rehasher_function_t *_rehasher = nullptr);
992 };
993
994 struct IntentFactoryModelBuilder {
995 typedef IntentFactoryModel Table;
996 flatbuffers::FlatBufferBuilder &fbb_;
997 flatbuffers::uoffset_t start_;
add_generatorIntentFactoryModelBuilder998 void add_generator(flatbuffers::Offset<flatbuffers::Vector<flatbuffers::Offset<libtextclassifier3::IntentFactoryModel_::IntentGenerator>>> generator) {
999 fbb_.AddOffset(IntentFactoryModel::VT_GENERATOR, generator);
1000 }
add_precompile_generatorsIntentFactoryModelBuilder1001 void add_precompile_generators(bool precompile_generators) {
1002 fbb_.AddElement<uint8_t>(IntentFactoryModel::VT_PRECOMPILE_GENERATORS, static_cast<uint8_t>(precompile_generators), 0);
1003 }
IntentFactoryModelBuilderIntentFactoryModelBuilder1004 explicit IntentFactoryModelBuilder(flatbuffers::FlatBufferBuilder &_fbb)
1005 : fbb_(_fbb) {
1006 start_ = fbb_.StartTable();
1007 }
FinishIntentFactoryModelBuilder1008 flatbuffers::Offset<IntentFactoryModel> Finish() {
1009 const auto end = fbb_.EndTable(start_);
1010 auto o = flatbuffers::Offset<IntentFactoryModel>(end);
1011 return o;
1012 }
1013 };
1014
1015 inline flatbuffers::Offset<IntentFactoryModel> CreateIntentFactoryModel(
1016 flatbuffers::FlatBufferBuilder &_fbb,
1017 flatbuffers::Offset<flatbuffers::Vector<flatbuffers::Offset<libtextclassifier3::IntentFactoryModel_::IntentGenerator>>> generator = 0,
1018 bool precompile_generators = false) {
1019 IntentFactoryModelBuilder builder_(_fbb);
1020 builder_.add_generator(generator);
1021 builder_.add_precompile_generators(precompile_generators);
1022 return builder_.Finish();
1023 }
1024
1025 inline flatbuffers::Offset<IntentFactoryModel> CreateIntentFactoryModelDirect(
1026 flatbuffers::FlatBufferBuilder &_fbb,
1027 const std::vector<flatbuffers::Offset<libtextclassifier3::IntentFactoryModel_::IntentGenerator>> *generator = nullptr,
1028 bool precompile_generators = false) {
1029 auto generator__ = generator ? _fbb.CreateVector<flatbuffers::Offset<libtextclassifier3::IntentFactoryModel_::IntentGenerator>>(*generator) : 0;
1030 return libtextclassifier3::CreateIntentFactoryModel(
1031 _fbb,
1032 generator__,
1033 precompile_generators);
1034 }
1035
1036 flatbuffers::Offset<IntentFactoryModel> CreateIntentFactoryModel(flatbuffers::FlatBufferBuilder &_fbb, const IntentFactoryModelT *_o, const flatbuffers::rehasher_function_t *_rehasher = nullptr);
1037
AndroidIntentFactoryOptionsT(const AndroidIntentFactoryOptionsT & o)1038 inline AndroidIntentFactoryOptionsT::AndroidIntentFactoryOptionsT(const AndroidIntentFactoryOptionsT &o) {
1039 entity.reserve(o.entity.size());
1040 for (const auto &entity_ : o.entity) { entity.emplace_back((entity_) ? new libtextclassifier3::AndroidIntentFactoryEntityOptionsT(*entity_) : nullptr); }
1041 }
1042
1043 inline AndroidIntentFactoryOptionsT &AndroidIntentFactoryOptionsT::operator=(AndroidIntentFactoryOptionsT o) FLATBUFFERS_NOEXCEPT {
1044 std::swap(entity, o.entity);
1045 return *this;
1046 }
1047
UnPack(const flatbuffers::resolver_function_t * _resolver)1048 inline AndroidIntentFactoryOptionsT *AndroidIntentFactoryOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const {
1049 auto _o = std::unique_ptr<AndroidIntentFactoryOptionsT>(new AndroidIntentFactoryOptionsT());
1050 UnPackTo(_o.get(), _resolver);
1051 return _o.release();
1052 }
1053
UnPackTo(AndroidIntentFactoryOptionsT * _o,const flatbuffers::resolver_function_t * _resolver)1054 inline void AndroidIntentFactoryOptions::UnPackTo(AndroidIntentFactoryOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const {
1055 (void)_o;
1056 (void)_resolver;
1057 { auto _e = entity(); if (_e) { _o->entity.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->entity[_i] = std::unique_ptr<libtextclassifier3::AndroidIntentFactoryEntityOptionsT>(_e->Get(_i)->UnPack(_resolver)); } } }
1058 }
1059
Pack(flatbuffers::FlatBufferBuilder & _fbb,const AndroidIntentFactoryOptionsT * _o,const flatbuffers::rehasher_function_t * _rehasher)1060 inline flatbuffers::Offset<AndroidIntentFactoryOptions> AndroidIntentFactoryOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const AndroidIntentFactoryOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) {
1061 return CreateAndroidIntentFactoryOptions(_fbb, _o, _rehasher);
1062 }
1063
CreateAndroidIntentFactoryOptions(flatbuffers::FlatBufferBuilder & _fbb,const AndroidIntentFactoryOptionsT * _o,const flatbuffers::rehasher_function_t * _rehasher)1064 inline flatbuffers::Offset<AndroidIntentFactoryOptions> CreateAndroidIntentFactoryOptions(flatbuffers::FlatBufferBuilder &_fbb, const AndroidIntentFactoryOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) {
1065 (void)_rehasher;
1066 (void)_o;
1067 struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const AndroidIntentFactoryOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va;
1068 auto _entity = _o->entity.size() ? _fbb.CreateVector<flatbuffers::Offset<libtextclassifier3::AndroidIntentFactoryEntityOptions>> (_o->entity.size(), [](size_t i, _VectorArgs *__va) { return CreateAndroidIntentFactoryEntityOptions(*__va->__fbb, __va->__o->entity[i].get(), __va->__rehasher); }, &_va ) : 0;
1069 return libtextclassifier3::CreateAndroidIntentFactoryOptions(
1070 _fbb,
1071 _entity);
1072 }
1073
AndroidIntentFactoryEntityOptionsT(const AndroidIntentFactoryEntityOptionsT & o)1074 inline AndroidIntentFactoryEntityOptionsT::AndroidIntentFactoryEntityOptionsT(const AndroidIntentFactoryEntityOptionsT &o)
1075 : entity_type(o.entity_type) {
1076 generator.reserve(o.generator.size());
1077 for (const auto &generator_ : o.generator) { generator.emplace_back((generator_) ? new libtextclassifier3::AndroidIntentGeneratorOptionsT(*generator_) : nullptr); }
1078 }
1079
1080 inline AndroidIntentFactoryEntityOptionsT &AndroidIntentFactoryEntityOptionsT::operator=(AndroidIntentFactoryEntityOptionsT o) FLATBUFFERS_NOEXCEPT {
1081 std::swap(entity_type, o.entity_type);
1082 std::swap(generator, o.generator);
1083 return *this;
1084 }
1085
UnPack(const flatbuffers::resolver_function_t * _resolver)1086 inline AndroidIntentFactoryEntityOptionsT *AndroidIntentFactoryEntityOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const {
1087 auto _o = std::unique_ptr<AndroidIntentFactoryEntityOptionsT>(new AndroidIntentFactoryEntityOptionsT());
1088 UnPackTo(_o.get(), _resolver);
1089 return _o.release();
1090 }
1091
UnPackTo(AndroidIntentFactoryEntityOptionsT * _o,const flatbuffers::resolver_function_t * _resolver)1092 inline void AndroidIntentFactoryEntityOptions::UnPackTo(AndroidIntentFactoryEntityOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const {
1093 (void)_o;
1094 (void)_resolver;
1095 { auto _e = entity_type(); if (_e) _o->entity_type = _e->str(); }
1096 { auto _e = generator(); if (_e) { _o->generator.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->generator[_i] = std::unique_ptr<libtextclassifier3::AndroidIntentGeneratorOptionsT>(_e->Get(_i)->UnPack(_resolver)); } } }
1097 }
1098
Pack(flatbuffers::FlatBufferBuilder & _fbb,const AndroidIntentFactoryEntityOptionsT * _o,const flatbuffers::rehasher_function_t * _rehasher)1099 inline flatbuffers::Offset<AndroidIntentFactoryEntityOptions> AndroidIntentFactoryEntityOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const AndroidIntentFactoryEntityOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) {
1100 return CreateAndroidIntentFactoryEntityOptions(_fbb, _o, _rehasher);
1101 }
1102
CreateAndroidIntentFactoryEntityOptions(flatbuffers::FlatBufferBuilder & _fbb,const AndroidIntentFactoryEntityOptionsT * _o,const flatbuffers::rehasher_function_t * _rehasher)1103 inline flatbuffers::Offset<AndroidIntentFactoryEntityOptions> CreateAndroidIntentFactoryEntityOptions(flatbuffers::FlatBufferBuilder &_fbb, const AndroidIntentFactoryEntityOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) {
1104 (void)_rehasher;
1105 (void)_o;
1106 struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const AndroidIntentFactoryEntityOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va;
1107 auto _entity_type = _o->entity_type.empty() ? 0 : _fbb.CreateSharedString(_o->entity_type);
1108 auto _generator = _o->generator.size() ? _fbb.CreateVector<flatbuffers::Offset<libtextclassifier3::AndroidIntentGeneratorOptions>> (_o->generator.size(), [](size_t i, _VectorArgs *__va) { return CreateAndroidIntentGeneratorOptions(*__va->__fbb, __va->__o->generator[i].get(), __va->__rehasher); }, &_va ) : 0;
1109 return libtextclassifier3::CreateAndroidIntentFactoryEntityOptions(
1110 _fbb,
1111 _entity_type,
1112 _generator);
1113 }
1114
AndroidIntentGeneratorOptionsT(const AndroidIntentGeneratorOptionsT & o)1115 inline AndroidIntentGeneratorOptionsT::AndroidIntentGeneratorOptionsT(const AndroidIntentGeneratorOptionsT &o)
1116 : simple((o.simple) ? new libtextclassifier3::AndroidSimpleIntentGeneratorOptionsT(*o.simple) : nullptr) {
1117 strings.reserve(o.strings.size());
1118 for (const auto &strings_ : o.strings) { strings.emplace_back((strings_) ? new libtextclassifier3::AndroidIntentGeneratorStringsT(*strings_) : nullptr); }
1119 }
1120
1121 inline AndroidIntentGeneratorOptionsT &AndroidIntentGeneratorOptionsT::operator=(AndroidIntentGeneratorOptionsT o) FLATBUFFERS_NOEXCEPT {
1122 std::swap(strings, o.strings);
1123 std::swap(simple, o.simple);
1124 return *this;
1125 }
1126
UnPack(const flatbuffers::resolver_function_t * _resolver)1127 inline AndroidIntentGeneratorOptionsT *AndroidIntentGeneratorOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const {
1128 auto _o = std::unique_ptr<AndroidIntentGeneratorOptionsT>(new AndroidIntentGeneratorOptionsT());
1129 UnPackTo(_o.get(), _resolver);
1130 return _o.release();
1131 }
1132
UnPackTo(AndroidIntentGeneratorOptionsT * _o,const flatbuffers::resolver_function_t * _resolver)1133 inline void AndroidIntentGeneratorOptions::UnPackTo(AndroidIntentGeneratorOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const {
1134 (void)_o;
1135 (void)_resolver;
1136 { auto _e = strings(); if (_e) { _o->strings.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->strings[_i] = std::unique_ptr<libtextclassifier3::AndroidIntentGeneratorStringsT>(_e->Get(_i)->UnPack(_resolver)); } } }
1137 { auto _e = simple(); if (_e) _o->simple = std::unique_ptr<libtextclassifier3::AndroidSimpleIntentGeneratorOptionsT>(_e->UnPack(_resolver)); }
1138 }
1139
Pack(flatbuffers::FlatBufferBuilder & _fbb,const AndroidIntentGeneratorOptionsT * _o,const flatbuffers::rehasher_function_t * _rehasher)1140 inline flatbuffers::Offset<AndroidIntentGeneratorOptions> AndroidIntentGeneratorOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const AndroidIntentGeneratorOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) {
1141 return CreateAndroidIntentGeneratorOptions(_fbb, _o, _rehasher);
1142 }
1143
CreateAndroidIntentGeneratorOptions(flatbuffers::FlatBufferBuilder & _fbb,const AndroidIntentGeneratorOptionsT * _o,const flatbuffers::rehasher_function_t * _rehasher)1144 inline flatbuffers::Offset<AndroidIntentGeneratorOptions> CreateAndroidIntentGeneratorOptions(flatbuffers::FlatBufferBuilder &_fbb, const AndroidIntentGeneratorOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) {
1145 (void)_rehasher;
1146 (void)_o;
1147 struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const AndroidIntentGeneratorOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va;
1148 auto _strings = _o->strings.size() ? _fbb.CreateVector<flatbuffers::Offset<libtextclassifier3::AndroidIntentGeneratorStrings>> (_o->strings.size(), [](size_t i, _VectorArgs *__va) { return CreateAndroidIntentGeneratorStrings(*__va->__fbb, __va->__o->strings[i].get(), __va->__rehasher); }, &_va ) : 0;
1149 auto _simple = _o->simple ? CreateAndroidSimpleIntentGeneratorOptions(_fbb, _o->simple.get(), _rehasher) : 0;
1150 return libtextclassifier3::CreateAndroidIntentGeneratorOptions(
1151 _fbb,
1152 _strings,
1153 _simple);
1154 }
1155
UnPack(const flatbuffers::resolver_function_t * _resolver)1156 inline AndroidIntentGeneratorStringsT *AndroidIntentGeneratorStrings::UnPack(const flatbuffers::resolver_function_t *_resolver) const {
1157 auto _o = std::unique_ptr<AndroidIntentGeneratorStringsT>(new AndroidIntentGeneratorStringsT());
1158 UnPackTo(_o.get(), _resolver);
1159 return _o.release();
1160 }
1161
UnPackTo(AndroidIntentGeneratorStringsT * _o,const flatbuffers::resolver_function_t * _resolver)1162 inline void AndroidIntentGeneratorStrings::UnPackTo(AndroidIntentGeneratorStringsT *_o, const flatbuffers::resolver_function_t *_resolver) const {
1163 (void)_o;
1164 (void)_resolver;
1165 { auto _e = language_tag(); if (_e) _o->language_tag = _e->str(); }
1166 { auto _e = title(); if (_e) _o->title = _e->str(); }
1167 { auto _e = description(); if (_e) _o->description = _e->str(); }
1168 }
1169
Pack(flatbuffers::FlatBufferBuilder & _fbb,const AndroidIntentGeneratorStringsT * _o,const flatbuffers::rehasher_function_t * _rehasher)1170 inline flatbuffers::Offset<AndroidIntentGeneratorStrings> AndroidIntentGeneratorStrings::Pack(flatbuffers::FlatBufferBuilder &_fbb, const AndroidIntentGeneratorStringsT* _o, const flatbuffers::rehasher_function_t *_rehasher) {
1171 return CreateAndroidIntentGeneratorStrings(_fbb, _o, _rehasher);
1172 }
1173
CreateAndroidIntentGeneratorStrings(flatbuffers::FlatBufferBuilder & _fbb,const AndroidIntentGeneratorStringsT * _o,const flatbuffers::rehasher_function_t * _rehasher)1174 inline flatbuffers::Offset<AndroidIntentGeneratorStrings> CreateAndroidIntentGeneratorStrings(flatbuffers::FlatBufferBuilder &_fbb, const AndroidIntentGeneratorStringsT *_o, const flatbuffers::rehasher_function_t *_rehasher) {
1175 (void)_rehasher;
1176 (void)_o;
1177 struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const AndroidIntentGeneratorStringsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va;
1178 auto _language_tag = _o->language_tag.empty() ? 0 : _fbb.CreateSharedString(_o->language_tag);
1179 auto _title = _o->title.empty() ? 0 : _fbb.CreateSharedString(_o->title);
1180 auto _description = _o->description.empty() ? 0 : _fbb.CreateSharedString(_o->description);
1181 return libtextclassifier3::CreateAndroidIntentGeneratorStrings(
1182 _fbb,
1183 _language_tag,
1184 _title,
1185 _description);
1186 }
1187
UnPack(const flatbuffers::resolver_function_t * _resolver)1188 inline AndroidSimpleIntentGeneratorExtraT *AndroidSimpleIntentGeneratorExtra::UnPack(const flatbuffers::resolver_function_t *_resolver) const {
1189 auto _o = std::unique_ptr<AndroidSimpleIntentGeneratorExtraT>(new AndroidSimpleIntentGeneratorExtraT());
1190 UnPackTo(_o.get(), _resolver);
1191 return _o.release();
1192 }
1193
UnPackTo(AndroidSimpleIntentGeneratorExtraT * _o,const flatbuffers::resolver_function_t * _resolver)1194 inline void AndroidSimpleIntentGeneratorExtra::UnPackTo(AndroidSimpleIntentGeneratorExtraT *_o, const flatbuffers::resolver_function_t *_resolver) const {
1195 (void)_o;
1196 (void)_resolver;
1197 { auto _e = name(); if (_e) _o->name = _e->str(); }
1198 { auto _e = type(); _o->type = _e; }
1199 { auto _e = string_(); if (_e) _o->string_ = _e->str(); }
1200 { auto _e = bool_(); _o->bool_ = _e; }
1201 { auto _e = int32_(); _o->int32_ = _e; }
1202 }
1203
Pack(flatbuffers::FlatBufferBuilder & _fbb,const AndroidSimpleIntentGeneratorExtraT * _o,const flatbuffers::rehasher_function_t * _rehasher)1204 inline flatbuffers::Offset<AndroidSimpleIntentGeneratorExtra> AndroidSimpleIntentGeneratorExtra::Pack(flatbuffers::FlatBufferBuilder &_fbb, const AndroidSimpleIntentGeneratorExtraT* _o, const flatbuffers::rehasher_function_t *_rehasher) {
1205 return CreateAndroidSimpleIntentGeneratorExtra(_fbb, _o, _rehasher);
1206 }
1207
CreateAndroidSimpleIntentGeneratorExtra(flatbuffers::FlatBufferBuilder & _fbb,const AndroidSimpleIntentGeneratorExtraT * _o,const flatbuffers::rehasher_function_t * _rehasher)1208 inline flatbuffers::Offset<AndroidSimpleIntentGeneratorExtra> CreateAndroidSimpleIntentGeneratorExtra(flatbuffers::FlatBufferBuilder &_fbb, const AndroidSimpleIntentGeneratorExtraT *_o, const flatbuffers::rehasher_function_t *_rehasher) {
1209 (void)_rehasher;
1210 (void)_o;
1211 struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const AndroidSimpleIntentGeneratorExtraT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va;
1212 auto _name = _o->name.empty() ? 0 : _fbb.CreateSharedString(_o->name);
1213 auto _type = _o->type;
1214 auto _string_ = _o->string_.empty() ? 0 : _fbb.CreateSharedString(_o->string_);
1215 auto _bool_ = _o->bool_;
1216 auto _int32_ = _o->int32_;
1217 return libtextclassifier3::CreateAndroidSimpleIntentGeneratorExtra(
1218 _fbb,
1219 _name,
1220 _type,
1221 _string_,
1222 _bool_,
1223 _int32_);
1224 }
1225
UnPack(const flatbuffers::resolver_function_t * _resolver)1226 inline AndroidSimpleIntentGeneratorConditionT *AndroidSimpleIntentGeneratorCondition::UnPack(const flatbuffers::resolver_function_t *_resolver) const {
1227 auto _o = std::unique_ptr<AndroidSimpleIntentGeneratorConditionT>(new AndroidSimpleIntentGeneratorConditionT());
1228 UnPackTo(_o.get(), _resolver);
1229 return _o.release();
1230 }
1231
UnPackTo(AndroidSimpleIntentGeneratorConditionT * _o,const flatbuffers::resolver_function_t * _resolver)1232 inline void AndroidSimpleIntentGeneratorCondition::UnPackTo(AndroidSimpleIntentGeneratorConditionT *_o, const flatbuffers::resolver_function_t *_resolver) const {
1233 (void)_o;
1234 (void)_resolver;
1235 { auto _e = type(); _o->type = _e; }
1236 { auto _e = string_(); if (_e) _o->string_ = _e->str(); }
1237 { auto _e = int32_(); _o->int32_ = _e; }
1238 { auto _e = int64_(); _o->int64_ = _e; }
1239 }
1240
Pack(flatbuffers::FlatBufferBuilder & _fbb,const AndroidSimpleIntentGeneratorConditionT * _o,const flatbuffers::rehasher_function_t * _rehasher)1241 inline flatbuffers::Offset<AndroidSimpleIntentGeneratorCondition> AndroidSimpleIntentGeneratorCondition::Pack(flatbuffers::FlatBufferBuilder &_fbb, const AndroidSimpleIntentGeneratorConditionT* _o, const flatbuffers::rehasher_function_t *_rehasher) {
1242 return CreateAndroidSimpleIntentGeneratorCondition(_fbb, _o, _rehasher);
1243 }
1244
CreateAndroidSimpleIntentGeneratorCondition(flatbuffers::FlatBufferBuilder & _fbb,const AndroidSimpleIntentGeneratorConditionT * _o,const flatbuffers::rehasher_function_t * _rehasher)1245 inline flatbuffers::Offset<AndroidSimpleIntentGeneratorCondition> CreateAndroidSimpleIntentGeneratorCondition(flatbuffers::FlatBufferBuilder &_fbb, const AndroidSimpleIntentGeneratorConditionT *_o, const flatbuffers::rehasher_function_t *_rehasher) {
1246 (void)_rehasher;
1247 (void)_o;
1248 struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const AndroidSimpleIntentGeneratorConditionT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va;
1249 auto _type = _o->type;
1250 auto _string_ = _o->string_.empty() ? 0 : _fbb.CreateSharedString(_o->string_);
1251 auto _int32_ = _o->int32_;
1252 auto _int64_ = _o->int64_;
1253 return libtextclassifier3::CreateAndroidSimpleIntentGeneratorCondition(
1254 _fbb,
1255 _type,
1256 _string_,
1257 _int32_,
1258 _int64_);
1259 }
1260
AndroidSimpleIntentGeneratorOptionsT(const AndroidSimpleIntentGeneratorOptionsT & o)1261 inline AndroidSimpleIntentGeneratorOptionsT::AndroidSimpleIntentGeneratorOptionsT(const AndroidSimpleIntentGeneratorOptionsT &o)
1262 : action(o.action),
1263 data(o.data),
1264 type(o.type),
1265 variable(o.variable) {
1266 extra.reserve(o.extra.size());
1267 for (const auto &extra_ : o.extra) { extra.emplace_back((extra_) ? new libtextclassifier3::AndroidSimpleIntentGeneratorExtraT(*extra_) : nullptr); }
1268 condition.reserve(o.condition.size());
1269 for (const auto &condition_ : o.condition) { condition.emplace_back((condition_) ? new libtextclassifier3::AndroidSimpleIntentGeneratorConditionT(*condition_) : nullptr); }
1270 }
1271
1272 inline AndroidSimpleIntentGeneratorOptionsT &AndroidSimpleIntentGeneratorOptionsT::operator=(AndroidSimpleIntentGeneratorOptionsT o) FLATBUFFERS_NOEXCEPT {
1273 std::swap(action, o.action);
1274 std::swap(data, o.data);
1275 std::swap(type, o.type);
1276 std::swap(extra, o.extra);
1277 std::swap(variable, o.variable);
1278 std::swap(condition, o.condition);
1279 return *this;
1280 }
1281
UnPack(const flatbuffers::resolver_function_t * _resolver)1282 inline AndroidSimpleIntentGeneratorOptionsT *AndroidSimpleIntentGeneratorOptions::UnPack(const flatbuffers::resolver_function_t *_resolver) const {
1283 auto _o = std::unique_ptr<AndroidSimpleIntentGeneratorOptionsT>(new AndroidSimpleIntentGeneratorOptionsT());
1284 UnPackTo(_o.get(), _resolver);
1285 return _o.release();
1286 }
1287
UnPackTo(AndroidSimpleIntentGeneratorOptionsT * _o,const flatbuffers::resolver_function_t * _resolver)1288 inline void AndroidSimpleIntentGeneratorOptions::UnPackTo(AndroidSimpleIntentGeneratorOptionsT *_o, const flatbuffers::resolver_function_t *_resolver) const {
1289 (void)_o;
1290 (void)_resolver;
1291 { auto _e = action(); if (_e) _o->action = _e->str(); }
1292 { auto _e = data(); if (_e) _o->data = _e->str(); }
1293 { auto _e = type(); if (_e) _o->type = _e->str(); }
1294 { auto _e = extra(); if (_e) { _o->extra.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->extra[_i] = std::unique_ptr<libtextclassifier3::AndroidSimpleIntentGeneratorExtraT>(_e->Get(_i)->UnPack(_resolver)); } } }
1295 { auto _e = variable(); if (_e) { _o->variable.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->variable[_i] = static_cast<libtextclassifier3::AndroidSimpleIntentGeneratorVariableType>(_e->Get(_i)); } } }
1296 { auto _e = condition(); if (_e) { _o->condition.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->condition[_i] = std::unique_ptr<libtextclassifier3::AndroidSimpleIntentGeneratorConditionT>(_e->Get(_i)->UnPack(_resolver)); } } }
1297 }
1298
Pack(flatbuffers::FlatBufferBuilder & _fbb,const AndroidSimpleIntentGeneratorOptionsT * _o,const flatbuffers::rehasher_function_t * _rehasher)1299 inline flatbuffers::Offset<AndroidSimpleIntentGeneratorOptions> AndroidSimpleIntentGeneratorOptions::Pack(flatbuffers::FlatBufferBuilder &_fbb, const AndroidSimpleIntentGeneratorOptionsT* _o, const flatbuffers::rehasher_function_t *_rehasher) {
1300 return CreateAndroidSimpleIntentGeneratorOptions(_fbb, _o, _rehasher);
1301 }
1302
CreateAndroidSimpleIntentGeneratorOptions(flatbuffers::FlatBufferBuilder & _fbb,const AndroidSimpleIntentGeneratorOptionsT * _o,const flatbuffers::rehasher_function_t * _rehasher)1303 inline flatbuffers::Offset<AndroidSimpleIntentGeneratorOptions> CreateAndroidSimpleIntentGeneratorOptions(flatbuffers::FlatBufferBuilder &_fbb, const AndroidSimpleIntentGeneratorOptionsT *_o, const flatbuffers::rehasher_function_t *_rehasher) {
1304 (void)_rehasher;
1305 (void)_o;
1306 struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const AndroidSimpleIntentGeneratorOptionsT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va;
1307 auto _action = _o->action.empty() ? 0 : _fbb.CreateSharedString(_o->action);
1308 auto _data = _o->data.empty() ? 0 : _fbb.CreateSharedString(_o->data);
1309 auto _type = _o->type.empty() ? 0 : _fbb.CreateSharedString(_o->type);
1310 auto _extra = _o->extra.size() ? _fbb.CreateVector<flatbuffers::Offset<libtextclassifier3::AndroidSimpleIntentGeneratorExtra>> (_o->extra.size(), [](size_t i, _VectorArgs *__va) { return CreateAndroidSimpleIntentGeneratorExtra(*__va->__fbb, __va->__o->extra[i].get(), __va->__rehasher); }, &_va ) : 0;
1311 auto _variable = _o->variable.size() ? _fbb.CreateVectorScalarCast<int32_t>(flatbuffers::data(_o->variable), _o->variable.size()) : 0;
1312 auto _condition = _o->condition.size() ? _fbb.CreateVector<flatbuffers::Offset<libtextclassifier3::AndroidSimpleIntentGeneratorCondition>> (_o->condition.size(), [](size_t i, _VectorArgs *__va) { return CreateAndroidSimpleIntentGeneratorCondition(*__va->__fbb, __va->__o->condition[i].get(), __va->__rehasher); }, &_va ) : 0;
1313 return libtextclassifier3::CreateAndroidSimpleIntentGeneratorOptions(
1314 _fbb,
1315 _action,
1316 _data,
1317 _type,
1318 _extra,
1319 _variable,
1320 _condition);
1321 }
1322
1323 namespace IntentFactoryModel_ {
1324
IntentGeneratorT(const IntentGeneratorT & o)1325 inline IntentGeneratorT::IntentGeneratorT(const IntentGeneratorT &o)
1326 : type(o.type),
1327 lua_template_generator(o.lua_template_generator),
1328 compressed_lua_template_generator((o.compressed_lua_template_generator) ? new libtextclassifier3::CompressedBufferT(*o.compressed_lua_template_generator) : nullptr) {
1329 }
1330
1331 inline IntentGeneratorT &IntentGeneratorT::operator=(IntentGeneratorT o) FLATBUFFERS_NOEXCEPT {
1332 std::swap(type, o.type);
1333 std::swap(lua_template_generator, o.lua_template_generator);
1334 std::swap(compressed_lua_template_generator, o.compressed_lua_template_generator);
1335 return *this;
1336 }
1337
UnPack(const flatbuffers::resolver_function_t * _resolver)1338 inline IntentGeneratorT *IntentGenerator::UnPack(const flatbuffers::resolver_function_t *_resolver) const {
1339 auto _o = std::unique_ptr<IntentGeneratorT>(new IntentGeneratorT());
1340 UnPackTo(_o.get(), _resolver);
1341 return _o.release();
1342 }
1343
UnPackTo(IntentGeneratorT * _o,const flatbuffers::resolver_function_t * _resolver)1344 inline void IntentGenerator::UnPackTo(IntentGeneratorT *_o, const flatbuffers::resolver_function_t *_resolver) const {
1345 (void)_o;
1346 (void)_resolver;
1347 { auto _e = type(); if (_e) _o->type = _e->str(); }
1348 { auto _e = lua_template_generator(); if (_e) { _o->lua_template_generator.resize(_e->size()); std::copy(_e->begin(), _e->end(), _o->lua_template_generator.begin()); } }
1349 { auto _e = compressed_lua_template_generator(); if (_e) _o->compressed_lua_template_generator = std::unique_ptr<libtextclassifier3::CompressedBufferT>(_e->UnPack(_resolver)); }
1350 }
1351
Pack(flatbuffers::FlatBufferBuilder & _fbb,const IntentGeneratorT * _o,const flatbuffers::rehasher_function_t * _rehasher)1352 inline flatbuffers::Offset<IntentGenerator> IntentGenerator::Pack(flatbuffers::FlatBufferBuilder &_fbb, const IntentGeneratorT* _o, const flatbuffers::rehasher_function_t *_rehasher) {
1353 return CreateIntentGenerator(_fbb, _o, _rehasher);
1354 }
1355
CreateIntentGenerator(flatbuffers::FlatBufferBuilder & _fbb,const IntentGeneratorT * _o,const flatbuffers::rehasher_function_t * _rehasher)1356 inline flatbuffers::Offset<IntentGenerator> CreateIntentGenerator(flatbuffers::FlatBufferBuilder &_fbb, const IntentGeneratorT *_o, const flatbuffers::rehasher_function_t *_rehasher) {
1357 (void)_rehasher;
1358 (void)_o;
1359 struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const IntentGeneratorT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va;
1360 auto _type = _o->type.empty() ? 0 : _fbb.CreateSharedString(_o->type);
1361 auto _lua_template_generator = _o->lua_template_generator.size() ? _fbb.CreateVector(_o->lua_template_generator) : 0;
1362 auto _compressed_lua_template_generator = _o->compressed_lua_template_generator ? CreateCompressedBuffer(_fbb, _o->compressed_lua_template_generator.get(), _rehasher) : 0;
1363 return libtextclassifier3::IntentFactoryModel_::CreateIntentGenerator(
1364 _fbb,
1365 _type,
1366 _lua_template_generator,
1367 _compressed_lua_template_generator);
1368 }
1369
1370 } // namespace IntentFactoryModel_
1371
IntentFactoryModelT(const IntentFactoryModelT & o)1372 inline IntentFactoryModelT::IntentFactoryModelT(const IntentFactoryModelT &o)
1373 : precompile_generators(o.precompile_generators) {
1374 generator.reserve(o.generator.size());
1375 for (const auto &generator_ : o.generator) { generator.emplace_back((generator_) ? new libtextclassifier3::IntentFactoryModel_::IntentGeneratorT(*generator_) : nullptr); }
1376 }
1377
1378 inline IntentFactoryModelT &IntentFactoryModelT::operator=(IntentFactoryModelT o) FLATBUFFERS_NOEXCEPT {
1379 std::swap(generator, o.generator);
1380 std::swap(precompile_generators, o.precompile_generators);
1381 return *this;
1382 }
1383
UnPack(const flatbuffers::resolver_function_t * _resolver)1384 inline IntentFactoryModelT *IntentFactoryModel::UnPack(const flatbuffers::resolver_function_t *_resolver) const {
1385 auto _o = std::unique_ptr<IntentFactoryModelT>(new IntentFactoryModelT());
1386 UnPackTo(_o.get(), _resolver);
1387 return _o.release();
1388 }
1389
UnPackTo(IntentFactoryModelT * _o,const flatbuffers::resolver_function_t * _resolver)1390 inline void IntentFactoryModel::UnPackTo(IntentFactoryModelT *_o, const flatbuffers::resolver_function_t *_resolver) const {
1391 (void)_o;
1392 (void)_resolver;
1393 { auto _e = generator(); if (_e) { _o->generator.resize(_e->size()); for (flatbuffers::uoffset_t _i = 0; _i < _e->size(); _i++) { _o->generator[_i] = std::unique_ptr<libtextclassifier3::IntentFactoryModel_::IntentGeneratorT>(_e->Get(_i)->UnPack(_resolver)); } } }
1394 { auto _e = precompile_generators(); _o->precompile_generators = _e; }
1395 }
1396
Pack(flatbuffers::FlatBufferBuilder & _fbb,const IntentFactoryModelT * _o,const flatbuffers::rehasher_function_t * _rehasher)1397 inline flatbuffers::Offset<IntentFactoryModel> IntentFactoryModel::Pack(flatbuffers::FlatBufferBuilder &_fbb, const IntentFactoryModelT* _o, const flatbuffers::rehasher_function_t *_rehasher) {
1398 return CreateIntentFactoryModel(_fbb, _o, _rehasher);
1399 }
1400
CreateIntentFactoryModel(flatbuffers::FlatBufferBuilder & _fbb,const IntentFactoryModelT * _o,const flatbuffers::rehasher_function_t * _rehasher)1401 inline flatbuffers::Offset<IntentFactoryModel> CreateIntentFactoryModel(flatbuffers::FlatBufferBuilder &_fbb, const IntentFactoryModelT *_o, const flatbuffers::rehasher_function_t *_rehasher) {
1402 (void)_rehasher;
1403 (void)_o;
1404 struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const IntentFactoryModelT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va;
1405 auto _generator = _o->generator.size() ? _fbb.CreateVector<flatbuffers::Offset<libtextclassifier3::IntentFactoryModel_::IntentGenerator>> (_o->generator.size(), [](size_t i, _VectorArgs *__va) { return CreateIntentGenerator(*__va->__fbb, __va->__o->generator[i].get(), __va->__rehasher); }, &_va ) : 0;
1406 auto _precompile_generators = _o->precompile_generators;
1407 return libtextclassifier3::CreateIntentFactoryModel(
1408 _fbb,
1409 _generator,
1410 _precompile_generators);
1411 }
1412
1413 } // namespace libtextclassifier3
1414
1415 #endif // FLATBUFFERS_GENERATED_INTENTCONFIG_LIBTEXTCLASSIFIER3_H_
1416