@aldiokta/protocgen 1.0.18 → 1.0.19

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (70) hide show
  1. package/package.json +1 -1
  2. package/prisca/v1/core/auth/auth.proto +100 -0
  3. package/prisca/v1/core/company/company.proto +86 -0
  4. package/prisca/v1/core/department_material/department_material.proto +69 -0
  5. package/prisca/v1/core/job_grade/job_grade.proto +79 -0
  6. package/prisca/v1/core/job_position/job_position.proto +107 -0
  7. package/prisca/v1/core/job_title/job_title.proto +88 -0
  8. package/prisca/v1/core/location/location.proto +124 -0
  9. package/prisca/v1/core/material/material.proto +127 -0
  10. package/prisca/v1/core/material_group/material_group.proto +79 -0
  11. package/prisca/v1/core/material_type/material_type.proto +77 -0
  12. package/prisca/v1/core/number_range/number_range.proto +81 -0
  13. package/prisca/v1/core/organization/organization.proto +93 -0
  14. package/prisca/v1/core/organization_level/organization_level.proto +73 -0
  15. package/prisca/v1/core/procurement/procurement.proto +54 -0
  16. package/prisca/v1/core/purchase_requisition_trx/purchase_requisition_trx.proto +131 -0
  17. package/prisca/v1/core/recipient_roles/recipient_roles.proto +10 -0
  18. package/prisca/v1/core/transaction_builder/transaction_builder.proto +278 -0
  19. package/prisca/v1/core/unit_of_measurement/unit_of_measurement.proto +88 -0
  20. package/prisca/v1/core/users/users.proto +22 -0
  21. package/prisca/v1/core/users_role/users_role.proto +72 -0
  22. package/prisca/v1/core/work_location/work_location.proto +88 -0
  23. package/prisca/v1/core/workflow/workflow.proto +191 -0
  24. package/prisca/v1/global/meta/meta.proto +57 -0
  25. package/prisca/v1/core/auth/auth_grpc_pb.js +0 -256
  26. package/prisca/v1/core/auth/auth_pb.js +0 -2801
  27. package/prisca/v1/core/company/company_grpc_pb.js +0 -177
  28. package/prisca/v1/core/company/company_pb.js +0 -2845
  29. package/prisca/v1/core/department_material/department_material_grpc_pb.js +0 -144
  30. package/prisca/v1/core/department_material/department_material_pb.js +0 -2167
  31. package/prisca/v1/core/job_grade/job_grade_grpc_pb.js +0 -178
  32. package/prisca/v1/core/job_grade/job_grade_pb.js +0 -2605
  33. package/prisca/v1/core/job_position/job_position_grpc_pb.js +0 -181
  34. package/prisca/v1/core/job_position/job_position_pb.js +0 -3582
  35. package/prisca/v1/core/job_title/job_title_grpc_pb.js +0 -178
  36. package/prisca/v1/core/job_title/job_title_pb.js +0 -2928
  37. package/prisca/v1/core/location/location_grpc_pb.js +0 -276
  38. package/prisca/v1/core/location/location_pb.js +0 -4334
  39. package/prisca/v1/core/material/material_grpc_pb.js +0 -181
  40. package/prisca/v1/core/material/material_pb.js +0 -4046
  41. package/prisca/v1/core/material_group/material_group_grpc_pb.js +0 -177
  42. package/prisca/v1/core/material_group/material_group_pb.js +0 -2582
  43. package/prisca/v1/core/material_type/material_type_grpc_pb.js +0 -147
  44. package/prisca/v1/core/material_type/material_type_pb.js +0 -2399
  45. package/prisca/v1/core/number_range/number_range_grpc_pb.js +0 -177
  46. package/prisca/v1/core/number_range/number_range_pb.js +0 -2672
  47. package/prisca/v1/core/organization/organization_grpc_pb.js +0 -180
  48. package/prisca/v1/core/organization/organization_pb.js +0 -3002
  49. package/prisca/v1/core/organization_level/organization_level_grpc_pb.js +0 -177
  50. package/prisca/v1/core/organization_level/organization_level_pb.js +0 -2432
  51. package/prisca/v1/core/procurement/procurement_grpc_pb.js +0 -146
  52. package/prisca/v1/core/procurement/procurement_pb.js +0 -1681
  53. package/prisca/v1/core/purchase_requisition_trx/purchase_requisition_trx_grpc_pb.js +0 -266
  54. package/prisca/v1/core/purchase_requisition_trx/purchase_requisition_trx_pb.js +0 -4429
  55. package/prisca/v1/core/recipient_roles/recipient_roles_grpc_pb.js +0 -1
  56. package/prisca/v1/core/recipient_roles/recipient_roles_pb.js +0 -206
  57. package/prisca/v1/core/transaction_builder/transaction_builder_grpc_pb.js +0 -421
  58. package/prisca/v1/core/transaction_builder/transaction_builder_pb.js +0 -9597
  59. package/prisca/v1/core/unit_of_measurement/unit_of_measurement_grpc_pb.js +0 -180
  60. package/prisca/v1/core/unit_of_measurement/unit_of_measurement_pb.js +0 -2798
  61. package/prisca/v1/core/users/users_grpc_pb.js +0 -1
  62. package/prisca/v1/core/users/users_pb.js +0 -626
  63. package/prisca/v1/core/users_role/users_role_grpc_pb.js +0 -177
  64. package/prisca/v1/core/users_role/users_role_pb.js +0 -2372
  65. package/prisca/v1/core/work_location/work_location_grpc_pb.js +0 -177
  66. package/prisca/v1/core/work_location/work_location_pb.js +0 -2850
  67. package/prisca/v1/core/workflow/workflow_grpc_pb.js +0 -179
  68. package/prisca/v1/core/workflow/workflow_pb.js +0 -6318
  69. package/prisca/v1/global/meta/meta_grpc_pb.js +0 -1
  70. package/prisca/v1/global/meta/meta_pb.js +0 -1179
@@ -1,2845 +0,0 @@
1
- // source: prisca/v1/core/company/company.proto
2
- /**
3
- * @fileoverview
4
- * @enhanceable
5
- * @suppress {missingRequire} reports error on implicit type usages.
6
- * @suppress {messageConventions} JS Compiler reports an error if a variable or
7
- * field starts with 'MSG_' and isn't a translatable message.
8
- * @public
9
- */
10
- // GENERATED CODE -- DO NOT EDIT!
11
- /* eslint-disable */
12
- // @ts-nocheck
13
-
14
- var jspb = require('google-protobuf');
15
- var goog = jspb;
16
- var global =
17
- (typeof globalThis !== 'undefined' && globalThis) ||
18
- (typeof window !== 'undefined' && window) ||
19
- (typeof global !== 'undefined' && global) ||
20
- (typeof self !== 'undefined' && self) ||
21
- (function () { return this; }).call(null) ||
22
- Function('return this')();
23
-
24
- var prisca_v1_global_meta_meta_pb = require('../../../../prisca/v1/global/meta/meta_pb.js');
25
- goog.object.extend(proto, prisca_v1_global_meta_meta_pb);
26
- goog.exportSymbol('proto.BaseCompany', null, global);
27
- goog.exportSymbol('proto.BaseCompanyParent', null, global);
28
- goog.exportSymbol('proto.Company', null, global);
29
- goog.exportSymbol('proto.CompanyGetByIdRequest', null, global);
30
- goog.exportSymbol('proto.CompanyGetByIdResponse', null, global);
31
- goog.exportSymbol('proto.CreateCompanyRequest', null, global);
32
- goog.exportSymbol('proto.CreateCompanyResponse', null, global);
33
- goog.exportSymbol('proto.DeleteCompanyRequest', null, global);
34
- goog.exportSymbol('proto.DeleteCompanyResponse', null, global);
35
- goog.exportSymbol('proto.GetListCompanyRequest', null, global);
36
- goog.exportSymbol('proto.GetListCompanyResponse', null, global);
37
- goog.exportSymbol('proto.UpdateCompanyRequest', null, global);
38
- goog.exportSymbol('proto.UpdateCompanyResponse', null, global);
39
- /**
40
- * Generated by JsPbCodeGenerator.
41
- * @param {Array=} opt_data Optional initial data array, typically from a
42
- * server response, or constructed directly in Javascript. The array is used
43
- * in place and becomes part of the constructed object. It is not cloned.
44
- * If no data is provided, the constructed object will be empty, but still
45
- * valid.
46
- * @extends {jspb.Message}
47
- * @constructor
48
- */
49
- proto.Company = function(opt_data) {
50
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
51
- };
52
- goog.inherits(proto.Company, jspb.Message);
53
- if (goog.DEBUG && !COMPILED) {
54
- /**
55
- * @public
56
- * @override
57
- */
58
- proto.Company.displayName = 'proto.Company';
59
- }
60
- /**
61
- * Generated by JsPbCodeGenerator.
62
- * @param {Array=} opt_data Optional initial data array, typically from a
63
- * server response, or constructed directly in Javascript. The array is used
64
- * in place and becomes part of the constructed object. It is not cloned.
65
- * If no data is provided, the constructed object will be empty, but still
66
- * valid.
67
- * @extends {jspb.Message}
68
- * @constructor
69
- */
70
- proto.BaseCompanyParent = function(opt_data) {
71
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
72
- };
73
- goog.inherits(proto.BaseCompanyParent, jspb.Message);
74
- if (goog.DEBUG && !COMPILED) {
75
- /**
76
- * @public
77
- * @override
78
- */
79
- proto.BaseCompanyParent.displayName = 'proto.BaseCompanyParent';
80
- }
81
- /**
82
- * Generated by JsPbCodeGenerator.
83
- * @param {Array=} opt_data Optional initial data array, typically from a
84
- * server response, or constructed directly in Javascript. The array is used
85
- * in place and becomes part of the constructed object. It is not cloned.
86
- * If no data is provided, the constructed object will be empty, but still
87
- * valid.
88
- * @extends {jspb.Message}
89
- * @constructor
90
- */
91
- proto.BaseCompany = function(opt_data) {
92
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
93
- };
94
- goog.inherits(proto.BaseCompany, jspb.Message);
95
- if (goog.DEBUG && !COMPILED) {
96
- /**
97
- * @public
98
- * @override
99
- */
100
- proto.BaseCompany.displayName = 'proto.BaseCompany';
101
- }
102
- /**
103
- * Generated by JsPbCodeGenerator.
104
- * @param {Array=} opt_data Optional initial data array, typically from a
105
- * server response, or constructed directly in Javascript. The array is used
106
- * in place and becomes part of the constructed object. It is not cloned.
107
- * If no data is provided, the constructed object will be empty, but still
108
- * valid.
109
- * @extends {jspb.Message}
110
- * @constructor
111
- */
112
- proto.CompanyGetByIdRequest = function(opt_data) {
113
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
114
- };
115
- goog.inherits(proto.CompanyGetByIdRequest, jspb.Message);
116
- if (goog.DEBUG && !COMPILED) {
117
- /**
118
- * @public
119
- * @override
120
- */
121
- proto.CompanyGetByIdRequest.displayName = 'proto.CompanyGetByIdRequest';
122
- }
123
- /**
124
- * Generated by JsPbCodeGenerator.
125
- * @param {Array=} opt_data Optional initial data array, typically from a
126
- * server response, or constructed directly in Javascript. The array is used
127
- * in place and becomes part of the constructed object. It is not cloned.
128
- * If no data is provided, the constructed object will be empty, but still
129
- * valid.
130
- * @extends {jspb.Message}
131
- * @constructor
132
- */
133
- proto.CompanyGetByIdResponse = function(opt_data) {
134
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
135
- };
136
- goog.inherits(proto.CompanyGetByIdResponse, jspb.Message);
137
- if (goog.DEBUG && !COMPILED) {
138
- /**
139
- * @public
140
- * @override
141
- */
142
- proto.CompanyGetByIdResponse.displayName = 'proto.CompanyGetByIdResponse';
143
- }
144
- /**
145
- * Generated by JsPbCodeGenerator.
146
- * @param {Array=} opt_data Optional initial data array, typically from a
147
- * server response, or constructed directly in Javascript. The array is used
148
- * in place and becomes part of the constructed object. It is not cloned.
149
- * If no data is provided, the constructed object will be empty, but still
150
- * valid.
151
- * @extends {jspb.Message}
152
- * @constructor
153
- */
154
- proto.UpdateCompanyRequest = function(opt_data) {
155
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
156
- };
157
- goog.inherits(proto.UpdateCompanyRequest, jspb.Message);
158
- if (goog.DEBUG && !COMPILED) {
159
- /**
160
- * @public
161
- * @override
162
- */
163
- proto.UpdateCompanyRequest.displayName = 'proto.UpdateCompanyRequest';
164
- }
165
- /**
166
- * Generated by JsPbCodeGenerator.
167
- * @param {Array=} opt_data Optional initial data array, typically from a
168
- * server response, or constructed directly in Javascript. The array is used
169
- * in place and becomes part of the constructed object. It is not cloned.
170
- * If no data is provided, the constructed object will be empty, but still
171
- * valid.
172
- * @extends {jspb.Message}
173
- * @constructor
174
- */
175
- proto.UpdateCompanyResponse = function(opt_data) {
176
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
177
- };
178
- goog.inherits(proto.UpdateCompanyResponse, jspb.Message);
179
- if (goog.DEBUG && !COMPILED) {
180
- /**
181
- * @public
182
- * @override
183
- */
184
- proto.UpdateCompanyResponse.displayName = 'proto.UpdateCompanyResponse';
185
- }
186
- /**
187
- * Generated by JsPbCodeGenerator.
188
- * @param {Array=} opt_data Optional initial data array, typically from a
189
- * server response, or constructed directly in Javascript. The array is used
190
- * in place and becomes part of the constructed object. It is not cloned.
191
- * If no data is provided, the constructed object will be empty, but still
192
- * valid.
193
- * @extends {jspb.Message}
194
- * @constructor
195
- */
196
- proto.CreateCompanyRequest = function(opt_data) {
197
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
198
- };
199
- goog.inherits(proto.CreateCompanyRequest, jspb.Message);
200
- if (goog.DEBUG && !COMPILED) {
201
- /**
202
- * @public
203
- * @override
204
- */
205
- proto.CreateCompanyRequest.displayName = 'proto.CreateCompanyRequest';
206
- }
207
- /**
208
- * Generated by JsPbCodeGenerator.
209
- * @param {Array=} opt_data Optional initial data array, typically from a
210
- * server response, or constructed directly in Javascript. The array is used
211
- * in place and becomes part of the constructed object. It is not cloned.
212
- * If no data is provided, the constructed object will be empty, but still
213
- * valid.
214
- * @extends {jspb.Message}
215
- * @constructor
216
- */
217
- proto.CreateCompanyResponse = function(opt_data) {
218
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
219
- };
220
- goog.inherits(proto.CreateCompanyResponse, jspb.Message);
221
- if (goog.DEBUG && !COMPILED) {
222
- /**
223
- * @public
224
- * @override
225
- */
226
- proto.CreateCompanyResponse.displayName = 'proto.CreateCompanyResponse';
227
- }
228
- /**
229
- * Generated by JsPbCodeGenerator.
230
- * @param {Array=} opt_data Optional initial data array, typically from a
231
- * server response, or constructed directly in Javascript. The array is used
232
- * in place and becomes part of the constructed object. It is not cloned.
233
- * If no data is provided, the constructed object will be empty, but still
234
- * valid.
235
- * @extends {jspb.Message}
236
- * @constructor
237
- */
238
- proto.DeleteCompanyRequest = function(opt_data) {
239
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
240
- };
241
- goog.inherits(proto.DeleteCompanyRequest, jspb.Message);
242
- if (goog.DEBUG && !COMPILED) {
243
- /**
244
- * @public
245
- * @override
246
- */
247
- proto.DeleteCompanyRequest.displayName = 'proto.DeleteCompanyRequest';
248
- }
249
- /**
250
- * Generated by JsPbCodeGenerator.
251
- * @param {Array=} opt_data Optional initial data array, typically from a
252
- * server response, or constructed directly in Javascript. The array is used
253
- * in place and becomes part of the constructed object. It is not cloned.
254
- * If no data is provided, the constructed object will be empty, but still
255
- * valid.
256
- * @extends {jspb.Message}
257
- * @constructor
258
- */
259
- proto.DeleteCompanyResponse = function(opt_data) {
260
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
261
- };
262
- goog.inherits(proto.DeleteCompanyResponse, jspb.Message);
263
- if (goog.DEBUG && !COMPILED) {
264
- /**
265
- * @public
266
- * @override
267
- */
268
- proto.DeleteCompanyResponse.displayName = 'proto.DeleteCompanyResponse';
269
- }
270
- /**
271
- * Generated by JsPbCodeGenerator.
272
- * @param {Array=} opt_data Optional initial data array, typically from a
273
- * server response, or constructed directly in Javascript. The array is used
274
- * in place and becomes part of the constructed object. It is not cloned.
275
- * If no data is provided, the constructed object will be empty, but still
276
- * valid.
277
- * @extends {jspb.Message}
278
- * @constructor
279
- */
280
- proto.GetListCompanyRequest = function(opt_data) {
281
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
282
- };
283
- goog.inherits(proto.GetListCompanyRequest, jspb.Message);
284
- if (goog.DEBUG && !COMPILED) {
285
- /**
286
- * @public
287
- * @override
288
- */
289
- proto.GetListCompanyRequest.displayName = 'proto.GetListCompanyRequest';
290
- }
291
- /**
292
- * Generated by JsPbCodeGenerator.
293
- * @param {Array=} opt_data Optional initial data array, typically from a
294
- * server response, or constructed directly in Javascript. The array is used
295
- * in place and becomes part of the constructed object. It is not cloned.
296
- * If no data is provided, the constructed object will be empty, but still
297
- * valid.
298
- * @extends {jspb.Message}
299
- * @constructor
300
- */
301
- proto.GetListCompanyResponse = function(opt_data) {
302
- jspb.Message.initialize(this, opt_data, 0, -1, proto.GetListCompanyResponse.repeatedFields_, null);
303
- };
304
- goog.inherits(proto.GetListCompanyResponse, jspb.Message);
305
- if (goog.DEBUG && !COMPILED) {
306
- /**
307
- * @public
308
- * @override
309
- */
310
- proto.GetListCompanyResponse.displayName = 'proto.GetListCompanyResponse';
311
- }
312
-
313
-
314
-
315
- if (jspb.Message.GENERATE_TO_OBJECT) {
316
- /**
317
- * Creates an object representation of this proto.
318
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
319
- * Optional fields that are not set will be set to undefined.
320
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
321
- * For the list of reserved names please see:
322
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
323
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
324
- * JSPB instance for transitional soy proto support:
325
- * http://goto/soy-param-migration
326
- * @return {!Object}
327
- */
328
- proto.Company.prototype.toObject = function(opt_includeInstance) {
329
- return proto.Company.toObject(opt_includeInstance, this);
330
- };
331
-
332
-
333
- /**
334
- * Static version of the {@see toObject} method.
335
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
336
- * the JSPB instance for transitional soy proto support:
337
- * http://goto/soy-param-migration
338
- * @param {!proto.Company} msg The msg instance to transform.
339
- * @return {!Object}
340
- * @suppress {unusedLocalVariables} f is only used for nested messages
341
- */
342
- proto.Company.toObject = function(includeInstance, msg) {
343
- var f, obj = {
344
- code: jspb.Message.getFieldWithDefault(msg, 1, ""),
345
- name: jspb.Message.getFieldWithDefault(msg, 2, ""),
346
- currencyCode: jspb.Message.getFieldWithDefault(msg, 3, ""),
347
- description: jspb.Message.getFieldWithDefault(msg, 4, ""),
348
- parentReferencesId: jspb.Message.getFieldWithDefault(msg, 5, "")
349
- };
350
-
351
- if (includeInstance) {
352
- obj.$jspbMessageInstance = msg;
353
- }
354
- return obj;
355
- };
356
- }
357
-
358
-
359
- /**
360
- * Deserializes binary data (in protobuf wire format).
361
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
362
- * @return {!proto.Company}
363
- */
364
- proto.Company.deserializeBinary = function(bytes) {
365
- var reader = new jspb.BinaryReader(bytes);
366
- var msg = new proto.Company;
367
- return proto.Company.deserializeBinaryFromReader(msg, reader);
368
- };
369
-
370
-
371
- /**
372
- * Deserializes binary data (in protobuf wire format) from the
373
- * given reader into the given message object.
374
- * @param {!proto.Company} msg The message object to deserialize into.
375
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
376
- * @return {!proto.Company}
377
- */
378
- proto.Company.deserializeBinaryFromReader = function(msg, reader) {
379
- while (reader.nextField()) {
380
- if (reader.isEndGroup()) {
381
- break;
382
- }
383
- var field = reader.getFieldNumber();
384
- switch (field) {
385
- case 1:
386
- var value = /** @type {string} */ (reader.readString());
387
- msg.setCode(value);
388
- break;
389
- case 2:
390
- var value = /** @type {string} */ (reader.readString());
391
- msg.setName(value);
392
- break;
393
- case 3:
394
- var value = /** @type {string} */ (reader.readString());
395
- msg.setCurrencyCode(value);
396
- break;
397
- case 4:
398
- var value = /** @type {string} */ (reader.readString());
399
- msg.setDescription(value);
400
- break;
401
- case 5:
402
- var value = /** @type {string} */ (reader.readString());
403
- msg.setParentReferencesId(value);
404
- break;
405
- default:
406
- reader.skipField();
407
- break;
408
- }
409
- }
410
- return msg;
411
- };
412
-
413
-
414
- /**
415
- * Serializes the message to binary data (in protobuf wire format).
416
- * @return {!Uint8Array}
417
- */
418
- proto.Company.prototype.serializeBinary = function() {
419
- var writer = new jspb.BinaryWriter();
420
- proto.Company.serializeBinaryToWriter(this, writer);
421
- return writer.getResultBuffer();
422
- };
423
-
424
-
425
- /**
426
- * Serializes the given message to binary data (in protobuf wire
427
- * format), writing to the given BinaryWriter.
428
- * @param {!proto.Company} message
429
- * @param {!jspb.BinaryWriter} writer
430
- * @suppress {unusedLocalVariables} f is only used for nested messages
431
- */
432
- proto.Company.serializeBinaryToWriter = function(message, writer) {
433
- var f = undefined;
434
- f = message.getCode();
435
- if (f.length > 0) {
436
- writer.writeString(
437
- 1,
438
- f
439
- );
440
- }
441
- f = message.getName();
442
- if (f.length > 0) {
443
- writer.writeString(
444
- 2,
445
- f
446
- );
447
- }
448
- f = message.getCurrencyCode();
449
- if (f.length > 0) {
450
- writer.writeString(
451
- 3,
452
- f
453
- );
454
- }
455
- f = message.getDescription();
456
- if (f.length > 0) {
457
- writer.writeString(
458
- 4,
459
- f
460
- );
461
- }
462
- f = message.getParentReferencesId();
463
- if (f.length > 0) {
464
- writer.writeString(
465
- 5,
466
- f
467
- );
468
- }
469
- };
470
-
471
-
472
- /**
473
- * optional string code = 1;
474
- * @return {string}
475
- */
476
- proto.Company.prototype.getCode = function() {
477
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
478
- };
479
-
480
-
481
- /**
482
- * @param {string} value
483
- * @return {!proto.Company} returns this
484
- */
485
- proto.Company.prototype.setCode = function(value) {
486
- return jspb.Message.setProto3StringField(this, 1, value);
487
- };
488
-
489
-
490
- /**
491
- * optional string name = 2;
492
- * @return {string}
493
- */
494
- proto.Company.prototype.getName = function() {
495
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
496
- };
497
-
498
-
499
- /**
500
- * @param {string} value
501
- * @return {!proto.Company} returns this
502
- */
503
- proto.Company.prototype.setName = function(value) {
504
- return jspb.Message.setProto3StringField(this, 2, value);
505
- };
506
-
507
-
508
- /**
509
- * optional string currency_code = 3;
510
- * @return {string}
511
- */
512
- proto.Company.prototype.getCurrencyCode = function() {
513
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
514
- };
515
-
516
-
517
- /**
518
- * @param {string} value
519
- * @return {!proto.Company} returns this
520
- */
521
- proto.Company.prototype.setCurrencyCode = function(value) {
522
- return jspb.Message.setProto3StringField(this, 3, value);
523
- };
524
-
525
-
526
- /**
527
- * optional string description = 4;
528
- * @return {string}
529
- */
530
- proto.Company.prototype.getDescription = function() {
531
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
532
- };
533
-
534
-
535
- /**
536
- * @param {string} value
537
- * @return {!proto.Company} returns this
538
- */
539
- proto.Company.prototype.setDescription = function(value) {
540
- return jspb.Message.setProto3StringField(this, 4, value);
541
- };
542
-
543
-
544
- /**
545
- * optional string parent_references_id = 5;
546
- * @return {string}
547
- */
548
- proto.Company.prototype.getParentReferencesId = function() {
549
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 5, ""));
550
- };
551
-
552
-
553
- /**
554
- * @param {string} value
555
- * @return {!proto.Company} returns this
556
- */
557
- proto.Company.prototype.setParentReferencesId = function(value) {
558
- return jspb.Message.setProto3StringField(this, 5, value);
559
- };
560
-
561
-
562
-
563
-
564
-
565
- if (jspb.Message.GENERATE_TO_OBJECT) {
566
- /**
567
- * Creates an object representation of this proto.
568
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
569
- * Optional fields that are not set will be set to undefined.
570
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
571
- * For the list of reserved names please see:
572
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
573
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
574
- * JSPB instance for transitional soy proto support:
575
- * http://goto/soy-param-migration
576
- * @return {!Object}
577
- */
578
- proto.BaseCompanyParent.prototype.toObject = function(opt_includeInstance) {
579
- return proto.BaseCompanyParent.toObject(opt_includeInstance, this);
580
- };
581
-
582
-
583
- /**
584
- * Static version of the {@see toObject} method.
585
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
586
- * the JSPB instance for transitional soy proto support:
587
- * http://goto/soy-param-migration
588
- * @param {!proto.BaseCompanyParent} msg The msg instance to transform.
589
- * @return {!Object}
590
- * @suppress {unusedLocalVariables} f is only used for nested messages
591
- */
592
- proto.BaseCompanyParent.toObject = function(includeInstance, msg) {
593
- var f, obj = {
594
- code: jspb.Message.getFieldWithDefault(msg, 2, ""),
595
- name: jspb.Message.getFieldWithDefault(msg, 3, ""),
596
- referencesId: jspb.Message.getFieldWithDefault(msg, 4, "")
597
- };
598
-
599
- if (includeInstance) {
600
- obj.$jspbMessageInstance = msg;
601
- }
602
- return obj;
603
- };
604
- }
605
-
606
-
607
- /**
608
- * Deserializes binary data (in protobuf wire format).
609
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
610
- * @return {!proto.BaseCompanyParent}
611
- */
612
- proto.BaseCompanyParent.deserializeBinary = function(bytes) {
613
- var reader = new jspb.BinaryReader(bytes);
614
- var msg = new proto.BaseCompanyParent;
615
- return proto.BaseCompanyParent.deserializeBinaryFromReader(msg, reader);
616
- };
617
-
618
-
619
- /**
620
- * Deserializes binary data (in protobuf wire format) from the
621
- * given reader into the given message object.
622
- * @param {!proto.BaseCompanyParent} msg The message object to deserialize into.
623
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
624
- * @return {!proto.BaseCompanyParent}
625
- */
626
- proto.BaseCompanyParent.deserializeBinaryFromReader = function(msg, reader) {
627
- while (reader.nextField()) {
628
- if (reader.isEndGroup()) {
629
- break;
630
- }
631
- var field = reader.getFieldNumber();
632
- switch (field) {
633
- case 2:
634
- var value = /** @type {string} */ (reader.readString());
635
- msg.setCode(value);
636
- break;
637
- case 3:
638
- var value = /** @type {string} */ (reader.readString());
639
- msg.setName(value);
640
- break;
641
- case 4:
642
- var value = /** @type {string} */ (reader.readString());
643
- msg.setReferencesId(value);
644
- break;
645
- default:
646
- reader.skipField();
647
- break;
648
- }
649
- }
650
- return msg;
651
- };
652
-
653
-
654
- /**
655
- * Serializes the message to binary data (in protobuf wire format).
656
- * @return {!Uint8Array}
657
- */
658
- proto.BaseCompanyParent.prototype.serializeBinary = function() {
659
- var writer = new jspb.BinaryWriter();
660
- proto.BaseCompanyParent.serializeBinaryToWriter(this, writer);
661
- return writer.getResultBuffer();
662
- };
663
-
664
-
665
- /**
666
- * Serializes the given message to binary data (in protobuf wire
667
- * format), writing to the given BinaryWriter.
668
- * @param {!proto.BaseCompanyParent} message
669
- * @param {!jspb.BinaryWriter} writer
670
- * @suppress {unusedLocalVariables} f is only used for nested messages
671
- */
672
- proto.BaseCompanyParent.serializeBinaryToWriter = function(message, writer) {
673
- var f = undefined;
674
- f = message.getCode();
675
- if (f.length > 0) {
676
- writer.writeString(
677
- 2,
678
- f
679
- );
680
- }
681
- f = message.getName();
682
- if (f.length > 0) {
683
- writer.writeString(
684
- 3,
685
- f
686
- );
687
- }
688
- f = message.getReferencesId();
689
- if (f.length > 0) {
690
- writer.writeString(
691
- 4,
692
- f
693
- );
694
- }
695
- };
696
-
697
-
698
- /**
699
- * optional string code = 2;
700
- * @return {string}
701
- */
702
- proto.BaseCompanyParent.prototype.getCode = function() {
703
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
704
- };
705
-
706
-
707
- /**
708
- * @param {string} value
709
- * @return {!proto.BaseCompanyParent} returns this
710
- */
711
- proto.BaseCompanyParent.prototype.setCode = function(value) {
712
- return jspb.Message.setProto3StringField(this, 2, value);
713
- };
714
-
715
-
716
- /**
717
- * optional string name = 3;
718
- * @return {string}
719
- */
720
- proto.BaseCompanyParent.prototype.getName = function() {
721
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
722
- };
723
-
724
-
725
- /**
726
- * @param {string} value
727
- * @return {!proto.BaseCompanyParent} returns this
728
- */
729
- proto.BaseCompanyParent.prototype.setName = function(value) {
730
- return jspb.Message.setProto3StringField(this, 3, value);
731
- };
732
-
733
-
734
- /**
735
- * optional string references_id = 4;
736
- * @return {string}
737
- */
738
- proto.BaseCompanyParent.prototype.getReferencesId = function() {
739
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
740
- };
741
-
742
-
743
- /**
744
- * @param {string} value
745
- * @return {!proto.BaseCompanyParent} returns this
746
- */
747
- proto.BaseCompanyParent.prototype.setReferencesId = function(value) {
748
- return jspb.Message.setProto3StringField(this, 4, value);
749
- };
750
-
751
-
752
-
753
-
754
-
755
- if (jspb.Message.GENERATE_TO_OBJECT) {
756
- /**
757
- * Creates an object representation of this proto.
758
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
759
- * Optional fields that are not set will be set to undefined.
760
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
761
- * For the list of reserved names please see:
762
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
763
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
764
- * JSPB instance for transitional soy proto support:
765
- * http://goto/soy-param-migration
766
- * @return {!Object}
767
- */
768
- proto.BaseCompany.prototype.toObject = function(opt_includeInstance) {
769
- return proto.BaseCompany.toObject(opt_includeInstance, this);
770
- };
771
-
772
-
773
- /**
774
- * Static version of the {@see toObject} method.
775
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
776
- * the JSPB instance for transitional soy proto support:
777
- * http://goto/soy-param-migration
778
- * @param {!proto.BaseCompany} msg The msg instance to transform.
779
- * @return {!Object}
780
- * @suppress {unusedLocalVariables} f is only used for nested messages
781
- */
782
- proto.BaseCompany.toObject = function(includeInstance, msg) {
783
- var f, obj = {
784
- code: jspb.Message.getFieldWithDefault(msg, 1, ""),
785
- name: jspb.Message.getFieldWithDefault(msg, 2, ""),
786
- currencyCode: jspb.Message.getFieldWithDefault(msg, 3, ""),
787
- description: jspb.Message.getFieldWithDefault(msg, 4, ""),
788
- referencesId: jspb.Message.getFieldWithDefault(msg, 5, ""),
789
- parent: (f = msg.getParent()) && proto.BaseCompanyParent.toObject(includeInstance, f)
790
- };
791
-
792
- if (includeInstance) {
793
- obj.$jspbMessageInstance = msg;
794
- }
795
- return obj;
796
- };
797
- }
798
-
799
-
800
- /**
801
- * Deserializes binary data (in protobuf wire format).
802
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
803
- * @return {!proto.BaseCompany}
804
- */
805
- proto.BaseCompany.deserializeBinary = function(bytes) {
806
- var reader = new jspb.BinaryReader(bytes);
807
- var msg = new proto.BaseCompany;
808
- return proto.BaseCompany.deserializeBinaryFromReader(msg, reader);
809
- };
810
-
811
-
812
- /**
813
- * Deserializes binary data (in protobuf wire format) from the
814
- * given reader into the given message object.
815
- * @param {!proto.BaseCompany} msg The message object to deserialize into.
816
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
817
- * @return {!proto.BaseCompany}
818
- */
819
- proto.BaseCompany.deserializeBinaryFromReader = function(msg, reader) {
820
- while (reader.nextField()) {
821
- if (reader.isEndGroup()) {
822
- break;
823
- }
824
- var field = reader.getFieldNumber();
825
- switch (field) {
826
- case 1:
827
- var value = /** @type {string} */ (reader.readString());
828
- msg.setCode(value);
829
- break;
830
- case 2:
831
- var value = /** @type {string} */ (reader.readString());
832
- msg.setName(value);
833
- break;
834
- case 3:
835
- var value = /** @type {string} */ (reader.readString());
836
- msg.setCurrencyCode(value);
837
- break;
838
- case 4:
839
- var value = /** @type {string} */ (reader.readString());
840
- msg.setDescription(value);
841
- break;
842
- case 5:
843
- var value = /** @type {string} */ (reader.readString());
844
- msg.setReferencesId(value);
845
- break;
846
- case 6:
847
- var value = new proto.BaseCompanyParent;
848
- reader.readMessage(value,proto.BaseCompanyParent.deserializeBinaryFromReader);
849
- msg.setParent(value);
850
- break;
851
- default:
852
- reader.skipField();
853
- break;
854
- }
855
- }
856
- return msg;
857
- };
858
-
859
-
860
- /**
861
- * Serializes the message to binary data (in protobuf wire format).
862
- * @return {!Uint8Array}
863
- */
864
- proto.BaseCompany.prototype.serializeBinary = function() {
865
- var writer = new jspb.BinaryWriter();
866
- proto.BaseCompany.serializeBinaryToWriter(this, writer);
867
- return writer.getResultBuffer();
868
- };
869
-
870
-
871
- /**
872
- * Serializes the given message to binary data (in protobuf wire
873
- * format), writing to the given BinaryWriter.
874
- * @param {!proto.BaseCompany} message
875
- * @param {!jspb.BinaryWriter} writer
876
- * @suppress {unusedLocalVariables} f is only used for nested messages
877
- */
878
- proto.BaseCompany.serializeBinaryToWriter = function(message, writer) {
879
- var f = undefined;
880
- f = message.getCode();
881
- if (f.length > 0) {
882
- writer.writeString(
883
- 1,
884
- f
885
- );
886
- }
887
- f = message.getName();
888
- if (f.length > 0) {
889
- writer.writeString(
890
- 2,
891
- f
892
- );
893
- }
894
- f = message.getCurrencyCode();
895
- if (f.length > 0) {
896
- writer.writeString(
897
- 3,
898
- f
899
- );
900
- }
901
- f = message.getDescription();
902
- if (f.length > 0) {
903
- writer.writeString(
904
- 4,
905
- f
906
- );
907
- }
908
- f = message.getReferencesId();
909
- if (f.length > 0) {
910
- writer.writeString(
911
- 5,
912
- f
913
- );
914
- }
915
- f = message.getParent();
916
- if (f != null) {
917
- writer.writeMessage(
918
- 6,
919
- f,
920
- proto.BaseCompanyParent.serializeBinaryToWriter
921
- );
922
- }
923
- };
924
-
925
-
926
- /**
927
- * optional string code = 1;
928
- * @return {string}
929
- */
930
- proto.BaseCompany.prototype.getCode = function() {
931
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
932
- };
933
-
934
-
935
- /**
936
- * @param {string} value
937
- * @return {!proto.BaseCompany} returns this
938
- */
939
- proto.BaseCompany.prototype.setCode = function(value) {
940
- return jspb.Message.setProto3StringField(this, 1, value);
941
- };
942
-
943
-
944
- /**
945
- * optional string name = 2;
946
- * @return {string}
947
- */
948
- proto.BaseCompany.prototype.getName = function() {
949
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
950
- };
951
-
952
-
953
- /**
954
- * @param {string} value
955
- * @return {!proto.BaseCompany} returns this
956
- */
957
- proto.BaseCompany.prototype.setName = function(value) {
958
- return jspb.Message.setProto3StringField(this, 2, value);
959
- };
960
-
961
-
962
- /**
963
- * optional string currency_code = 3;
964
- * @return {string}
965
- */
966
- proto.BaseCompany.prototype.getCurrencyCode = function() {
967
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
968
- };
969
-
970
-
971
- /**
972
- * @param {string} value
973
- * @return {!proto.BaseCompany} returns this
974
- */
975
- proto.BaseCompany.prototype.setCurrencyCode = function(value) {
976
- return jspb.Message.setProto3StringField(this, 3, value);
977
- };
978
-
979
-
980
- /**
981
- * optional string description = 4;
982
- * @return {string}
983
- */
984
- proto.BaseCompany.prototype.getDescription = function() {
985
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
986
- };
987
-
988
-
989
- /**
990
- * @param {string} value
991
- * @return {!proto.BaseCompany} returns this
992
- */
993
- proto.BaseCompany.prototype.setDescription = function(value) {
994
- return jspb.Message.setProto3StringField(this, 4, value);
995
- };
996
-
997
-
998
- /**
999
- * optional string references_id = 5;
1000
- * @return {string}
1001
- */
1002
- proto.BaseCompany.prototype.getReferencesId = function() {
1003
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 5, ""));
1004
- };
1005
-
1006
-
1007
- /**
1008
- * @param {string} value
1009
- * @return {!proto.BaseCompany} returns this
1010
- */
1011
- proto.BaseCompany.prototype.setReferencesId = function(value) {
1012
- return jspb.Message.setProto3StringField(this, 5, value);
1013
- };
1014
-
1015
-
1016
- /**
1017
- * optional BaseCompanyParent parent = 6;
1018
- * @return {?proto.BaseCompanyParent}
1019
- */
1020
- proto.BaseCompany.prototype.getParent = function() {
1021
- return /** @type{?proto.BaseCompanyParent} */ (
1022
- jspb.Message.getWrapperField(this, proto.BaseCompanyParent, 6));
1023
- };
1024
-
1025
-
1026
- /**
1027
- * @param {?proto.BaseCompanyParent|undefined} value
1028
- * @return {!proto.BaseCompany} returns this
1029
- */
1030
- proto.BaseCompany.prototype.setParent = function(value) {
1031
- return jspb.Message.setWrapperField(this, 6, value);
1032
- };
1033
-
1034
-
1035
- /**
1036
- * Clears the message field making it undefined.
1037
- * @return {!proto.BaseCompany} returns this
1038
- */
1039
- proto.BaseCompany.prototype.clearParent = function() {
1040
- return this.setParent(undefined);
1041
- };
1042
-
1043
-
1044
- /**
1045
- * Returns whether this field is set.
1046
- * @return {boolean}
1047
- */
1048
- proto.BaseCompany.prototype.hasParent = function() {
1049
- return jspb.Message.getField(this, 6) != null;
1050
- };
1051
-
1052
-
1053
-
1054
-
1055
-
1056
- if (jspb.Message.GENERATE_TO_OBJECT) {
1057
- /**
1058
- * Creates an object representation of this proto.
1059
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
1060
- * Optional fields that are not set will be set to undefined.
1061
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
1062
- * For the list of reserved names please see:
1063
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
1064
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
1065
- * JSPB instance for transitional soy proto support:
1066
- * http://goto/soy-param-migration
1067
- * @return {!Object}
1068
- */
1069
- proto.CompanyGetByIdRequest.prototype.toObject = function(opt_includeInstance) {
1070
- return proto.CompanyGetByIdRequest.toObject(opt_includeInstance, this);
1071
- };
1072
-
1073
-
1074
- /**
1075
- * Static version of the {@see toObject} method.
1076
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
1077
- * the JSPB instance for transitional soy proto support:
1078
- * http://goto/soy-param-migration
1079
- * @param {!proto.CompanyGetByIdRequest} msg The msg instance to transform.
1080
- * @return {!Object}
1081
- * @suppress {unusedLocalVariables} f is only used for nested messages
1082
- */
1083
- proto.CompanyGetByIdRequest.toObject = function(includeInstance, msg) {
1084
- var f, obj = {
1085
- referencesId: jspb.Message.getFieldWithDefault(msg, 1, "")
1086
- };
1087
-
1088
- if (includeInstance) {
1089
- obj.$jspbMessageInstance = msg;
1090
- }
1091
- return obj;
1092
- };
1093
- }
1094
-
1095
-
1096
- /**
1097
- * Deserializes binary data (in protobuf wire format).
1098
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
1099
- * @return {!proto.CompanyGetByIdRequest}
1100
- */
1101
- proto.CompanyGetByIdRequest.deserializeBinary = function(bytes) {
1102
- var reader = new jspb.BinaryReader(bytes);
1103
- var msg = new proto.CompanyGetByIdRequest;
1104
- return proto.CompanyGetByIdRequest.deserializeBinaryFromReader(msg, reader);
1105
- };
1106
-
1107
-
1108
- /**
1109
- * Deserializes binary data (in protobuf wire format) from the
1110
- * given reader into the given message object.
1111
- * @param {!proto.CompanyGetByIdRequest} msg The message object to deserialize into.
1112
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
1113
- * @return {!proto.CompanyGetByIdRequest}
1114
- */
1115
- proto.CompanyGetByIdRequest.deserializeBinaryFromReader = function(msg, reader) {
1116
- while (reader.nextField()) {
1117
- if (reader.isEndGroup()) {
1118
- break;
1119
- }
1120
- var field = reader.getFieldNumber();
1121
- switch (field) {
1122
- case 1:
1123
- var value = /** @type {string} */ (reader.readString());
1124
- msg.setReferencesId(value);
1125
- break;
1126
- default:
1127
- reader.skipField();
1128
- break;
1129
- }
1130
- }
1131
- return msg;
1132
- };
1133
-
1134
-
1135
- /**
1136
- * Serializes the message to binary data (in protobuf wire format).
1137
- * @return {!Uint8Array}
1138
- */
1139
- proto.CompanyGetByIdRequest.prototype.serializeBinary = function() {
1140
- var writer = new jspb.BinaryWriter();
1141
- proto.CompanyGetByIdRequest.serializeBinaryToWriter(this, writer);
1142
- return writer.getResultBuffer();
1143
- };
1144
-
1145
-
1146
- /**
1147
- * Serializes the given message to binary data (in protobuf wire
1148
- * format), writing to the given BinaryWriter.
1149
- * @param {!proto.CompanyGetByIdRequest} message
1150
- * @param {!jspb.BinaryWriter} writer
1151
- * @suppress {unusedLocalVariables} f is only used for nested messages
1152
- */
1153
- proto.CompanyGetByIdRequest.serializeBinaryToWriter = function(message, writer) {
1154
- var f = undefined;
1155
- f = message.getReferencesId();
1156
- if (f.length > 0) {
1157
- writer.writeString(
1158
- 1,
1159
- f
1160
- );
1161
- }
1162
- };
1163
-
1164
-
1165
- /**
1166
- * optional string references_id = 1;
1167
- * @return {string}
1168
- */
1169
- proto.CompanyGetByIdRequest.prototype.getReferencesId = function() {
1170
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
1171
- };
1172
-
1173
-
1174
- /**
1175
- * @param {string} value
1176
- * @return {!proto.CompanyGetByIdRequest} returns this
1177
- */
1178
- proto.CompanyGetByIdRequest.prototype.setReferencesId = function(value) {
1179
- return jspb.Message.setProto3StringField(this, 1, value);
1180
- };
1181
-
1182
-
1183
-
1184
-
1185
-
1186
- if (jspb.Message.GENERATE_TO_OBJECT) {
1187
- /**
1188
- * Creates an object representation of this proto.
1189
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
1190
- * Optional fields that are not set will be set to undefined.
1191
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
1192
- * For the list of reserved names please see:
1193
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
1194
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
1195
- * JSPB instance for transitional soy proto support:
1196
- * http://goto/soy-param-migration
1197
- * @return {!Object}
1198
- */
1199
- proto.CompanyGetByIdResponse.prototype.toObject = function(opt_includeInstance) {
1200
- return proto.CompanyGetByIdResponse.toObject(opt_includeInstance, this);
1201
- };
1202
-
1203
-
1204
- /**
1205
- * Static version of the {@see toObject} method.
1206
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
1207
- * the JSPB instance for transitional soy proto support:
1208
- * http://goto/soy-param-migration
1209
- * @param {!proto.CompanyGetByIdResponse} msg The msg instance to transform.
1210
- * @return {!Object}
1211
- * @suppress {unusedLocalVariables} f is only used for nested messages
1212
- */
1213
- proto.CompanyGetByIdResponse.toObject = function(includeInstance, msg) {
1214
- var f, obj = {
1215
- company: (f = msg.getCompany()) && proto.BaseCompany.toObject(includeInstance, f),
1216
- meta: (f = msg.getMeta()) && prisca_v1_global_meta_meta_pb.Meta.toObject(includeInstance, f)
1217
- };
1218
-
1219
- if (includeInstance) {
1220
- obj.$jspbMessageInstance = msg;
1221
- }
1222
- return obj;
1223
- };
1224
- }
1225
-
1226
-
1227
- /**
1228
- * Deserializes binary data (in protobuf wire format).
1229
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
1230
- * @return {!proto.CompanyGetByIdResponse}
1231
- */
1232
- proto.CompanyGetByIdResponse.deserializeBinary = function(bytes) {
1233
- var reader = new jspb.BinaryReader(bytes);
1234
- var msg = new proto.CompanyGetByIdResponse;
1235
- return proto.CompanyGetByIdResponse.deserializeBinaryFromReader(msg, reader);
1236
- };
1237
-
1238
-
1239
- /**
1240
- * Deserializes binary data (in protobuf wire format) from the
1241
- * given reader into the given message object.
1242
- * @param {!proto.CompanyGetByIdResponse} msg The message object to deserialize into.
1243
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
1244
- * @return {!proto.CompanyGetByIdResponse}
1245
- */
1246
- proto.CompanyGetByIdResponse.deserializeBinaryFromReader = function(msg, reader) {
1247
- while (reader.nextField()) {
1248
- if (reader.isEndGroup()) {
1249
- break;
1250
- }
1251
- var field = reader.getFieldNumber();
1252
- switch (field) {
1253
- case 1:
1254
- var value = new proto.BaseCompany;
1255
- reader.readMessage(value,proto.BaseCompany.deserializeBinaryFromReader);
1256
- msg.setCompany(value);
1257
- break;
1258
- case 2:
1259
- var value = new prisca_v1_global_meta_meta_pb.Meta;
1260
- reader.readMessage(value,prisca_v1_global_meta_meta_pb.Meta.deserializeBinaryFromReader);
1261
- msg.setMeta(value);
1262
- break;
1263
- default:
1264
- reader.skipField();
1265
- break;
1266
- }
1267
- }
1268
- return msg;
1269
- };
1270
-
1271
-
1272
- /**
1273
- * Serializes the message to binary data (in protobuf wire format).
1274
- * @return {!Uint8Array}
1275
- */
1276
- proto.CompanyGetByIdResponse.prototype.serializeBinary = function() {
1277
- var writer = new jspb.BinaryWriter();
1278
- proto.CompanyGetByIdResponse.serializeBinaryToWriter(this, writer);
1279
- return writer.getResultBuffer();
1280
- };
1281
-
1282
-
1283
- /**
1284
- * Serializes the given message to binary data (in protobuf wire
1285
- * format), writing to the given BinaryWriter.
1286
- * @param {!proto.CompanyGetByIdResponse} message
1287
- * @param {!jspb.BinaryWriter} writer
1288
- * @suppress {unusedLocalVariables} f is only used for nested messages
1289
- */
1290
- proto.CompanyGetByIdResponse.serializeBinaryToWriter = function(message, writer) {
1291
- var f = undefined;
1292
- f = message.getCompany();
1293
- if (f != null) {
1294
- writer.writeMessage(
1295
- 1,
1296
- f,
1297
- proto.BaseCompany.serializeBinaryToWriter
1298
- );
1299
- }
1300
- f = message.getMeta();
1301
- if (f != null) {
1302
- writer.writeMessage(
1303
- 2,
1304
- f,
1305
- prisca_v1_global_meta_meta_pb.Meta.serializeBinaryToWriter
1306
- );
1307
- }
1308
- };
1309
-
1310
-
1311
- /**
1312
- * optional BaseCompany company = 1;
1313
- * @return {?proto.BaseCompany}
1314
- */
1315
- proto.CompanyGetByIdResponse.prototype.getCompany = function() {
1316
- return /** @type{?proto.BaseCompany} */ (
1317
- jspb.Message.getWrapperField(this, proto.BaseCompany, 1));
1318
- };
1319
-
1320
-
1321
- /**
1322
- * @param {?proto.BaseCompany|undefined} value
1323
- * @return {!proto.CompanyGetByIdResponse} returns this
1324
- */
1325
- proto.CompanyGetByIdResponse.prototype.setCompany = function(value) {
1326
- return jspb.Message.setWrapperField(this, 1, value);
1327
- };
1328
-
1329
-
1330
- /**
1331
- * Clears the message field making it undefined.
1332
- * @return {!proto.CompanyGetByIdResponse} returns this
1333
- */
1334
- proto.CompanyGetByIdResponse.prototype.clearCompany = function() {
1335
- return this.setCompany(undefined);
1336
- };
1337
-
1338
-
1339
- /**
1340
- * Returns whether this field is set.
1341
- * @return {boolean}
1342
- */
1343
- proto.CompanyGetByIdResponse.prototype.hasCompany = function() {
1344
- return jspb.Message.getField(this, 1) != null;
1345
- };
1346
-
1347
-
1348
- /**
1349
- * optional prisca.v1.global.meta.Meta meta = 2;
1350
- * @return {?proto.prisca.v1.global.meta.Meta}
1351
- */
1352
- proto.CompanyGetByIdResponse.prototype.getMeta = function() {
1353
- return /** @type{?proto.prisca.v1.global.meta.Meta} */ (
1354
- jspb.Message.getWrapperField(this, prisca_v1_global_meta_meta_pb.Meta, 2));
1355
- };
1356
-
1357
-
1358
- /**
1359
- * @param {?proto.prisca.v1.global.meta.Meta|undefined} value
1360
- * @return {!proto.CompanyGetByIdResponse} returns this
1361
- */
1362
- proto.CompanyGetByIdResponse.prototype.setMeta = function(value) {
1363
- return jspb.Message.setWrapperField(this, 2, value);
1364
- };
1365
-
1366
-
1367
- /**
1368
- * Clears the message field making it undefined.
1369
- * @return {!proto.CompanyGetByIdResponse} returns this
1370
- */
1371
- proto.CompanyGetByIdResponse.prototype.clearMeta = function() {
1372
- return this.setMeta(undefined);
1373
- };
1374
-
1375
-
1376
- /**
1377
- * Returns whether this field is set.
1378
- * @return {boolean}
1379
- */
1380
- proto.CompanyGetByIdResponse.prototype.hasMeta = function() {
1381
- return jspb.Message.getField(this, 2) != null;
1382
- };
1383
-
1384
-
1385
-
1386
-
1387
-
1388
- if (jspb.Message.GENERATE_TO_OBJECT) {
1389
- /**
1390
- * Creates an object representation of this proto.
1391
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
1392
- * Optional fields that are not set will be set to undefined.
1393
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
1394
- * For the list of reserved names please see:
1395
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
1396
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
1397
- * JSPB instance for transitional soy proto support:
1398
- * http://goto/soy-param-migration
1399
- * @return {!Object}
1400
- */
1401
- proto.UpdateCompanyRequest.prototype.toObject = function(opt_includeInstance) {
1402
- return proto.UpdateCompanyRequest.toObject(opt_includeInstance, this);
1403
- };
1404
-
1405
-
1406
- /**
1407
- * Static version of the {@see toObject} method.
1408
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
1409
- * the JSPB instance for transitional soy proto support:
1410
- * http://goto/soy-param-migration
1411
- * @param {!proto.UpdateCompanyRequest} msg The msg instance to transform.
1412
- * @return {!Object}
1413
- * @suppress {unusedLocalVariables} f is only used for nested messages
1414
- */
1415
- proto.UpdateCompanyRequest.toObject = function(includeInstance, msg) {
1416
- var f, obj = {
1417
- referencesId: jspb.Message.getFieldWithDefault(msg, 1, ""),
1418
- company: (f = msg.getCompany()) && proto.Company.toObject(includeInstance, f)
1419
- };
1420
-
1421
- if (includeInstance) {
1422
- obj.$jspbMessageInstance = msg;
1423
- }
1424
- return obj;
1425
- };
1426
- }
1427
-
1428
-
1429
- /**
1430
- * Deserializes binary data (in protobuf wire format).
1431
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
1432
- * @return {!proto.UpdateCompanyRequest}
1433
- */
1434
- proto.UpdateCompanyRequest.deserializeBinary = function(bytes) {
1435
- var reader = new jspb.BinaryReader(bytes);
1436
- var msg = new proto.UpdateCompanyRequest;
1437
- return proto.UpdateCompanyRequest.deserializeBinaryFromReader(msg, reader);
1438
- };
1439
-
1440
-
1441
- /**
1442
- * Deserializes binary data (in protobuf wire format) from the
1443
- * given reader into the given message object.
1444
- * @param {!proto.UpdateCompanyRequest} msg The message object to deserialize into.
1445
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
1446
- * @return {!proto.UpdateCompanyRequest}
1447
- */
1448
- proto.UpdateCompanyRequest.deserializeBinaryFromReader = function(msg, reader) {
1449
- while (reader.nextField()) {
1450
- if (reader.isEndGroup()) {
1451
- break;
1452
- }
1453
- var field = reader.getFieldNumber();
1454
- switch (field) {
1455
- case 1:
1456
- var value = /** @type {string} */ (reader.readString());
1457
- msg.setReferencesId(value);
1458
- break;
1459
- case 2:
1460
- var value = new proto.Company;
1461
- reader.readMessage(value,proto.Company.deserializeBinaryFromReader);
1462
- msg.setCompany(value);
1463
- break;
1464
- default:
1465
- reader.skipField();
1466
- break;
1467
- }
1468
- }
1469
- return msg;
1470
- };
1471
-
1472
-
1473
- /**
1474
- * Serializes the message to binary data (in protobuf wire format).
1475
- * @return {!Uint8Array}
1476
- */
1477
- proto.UpdateCompanyRequest.prototype.serializeBinary = function() {
1478
- var writer = new jspb.BinaryWriter();
1479
- proto.UpdateCompanyRequest.serializeBinaryToWriter(this, writer);
1480
- return writer.getResultBuffer();
1481
- };
1482
-
1483
-
1484
- /**
1485
- * Serializes the given message to binary data (in protobuf wire
1486
- * format), writing to the given BinaryWriter.
1487
- * @param {!proto.UpdateCompanyRequest} message
1488
- * @param {!jspb.BinaryWriter} writer
1489
- * @suppress {unusedLocalVariables} f is only used for nested messages
1490
- */
1491
- proto.UpdateCompanyRequest.serializeBinaryToWriter = function(message, writer) {
1492
- var f = undefined;
1493
- f = message.getReferencesId();
1494
- if (f.length > 0) {
1495
- writer.writeString(
1496
- 1,
1497
- f
1498
- );
1499
- }
1500
- f = message.getCompany();
1501
- if (f != null) {
1502
- writer.writeMessage(
1503
- 2,
1504
- f,
1505
- proto.Company.serializeBinaryToWriter
1506
- );
1507
- }
1508
- };
1509
-
1510
-
1511
- /**
1512
- * optional string references_id = 1;
1513
- * @return {string}
1514
- */
1515
- proto.UpdateCompanyRequest.prototype.getReferencesId = function() {
1516
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
1517
- };
1518
-
1519
-
1520
- /**
1521
- * @param {string} value
1522
- * @return {!proto.UpdateCompanyRequest} returns this
1523
- */
1524
- proto.UpdateCompanyRequest.prototype.setReferencesId = function(value) {
1525
- return jspb.Message.setProto3StringField(this, 1, value);
1526
- };
1527
-
1528
-
1529
- /**
1530
- * optional Company company = 2;
1531
- * @return {?proto.Company}
1532
- */
1533
- proto.UpdateCompanyRequest.prototype.getCompany = function() {
1534
- return /** @type{?proto.Company} */ (
1535
- jspb.Message.getWrapperField(this, proto.Company, 2));
1536
- };
1537
-
1538
-
1539
- /**
1540
- * @param {?proto.Company|undefined} value
1541
- * @return {!proto.UpdateCompanyRequest} returns this
1542
- */
1543
- proto.UpdateCompanyRequest.prototype.setCompany = function(value) {
1544
- return jspb.Message.setWrapperField(this, 2, value);
1545
- };
1546
-
1547
-
1548
- /**
1549
- * Clears the message field making it undefined.
1550
- * @return {!proto.UpdateCompanyRequest} returns this
1551
- */
1552
- proto.UpdateCompanyRequest.prototype.clearCompany = function() {
1553
- return this.setCompany(undefined);
1554
- };
1555
-
1556
-
1557
- /**
1558
- * Returns whether this field is set.
1559
- * @return {boolean}
1560
- */
1561
- proto.UpdateCompanyRequest.prototype.hasCompany = function() {
1562
- return jspb.Message.getField(this, 2) != null;
1563
- };
1564
-
1565
-
1566
-
1567
-
1568
-
1569
- if (jspb.Message.GENERATE_TO_OBJECT) {
1570
- /**
1571
- * Creates an object representation of this proto.
1572
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
1573
- * Optional fields that are not set will be set to undefined.
1574
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
1575
- * For the list of reserved names please see:
1576
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
1577
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
1578
- * JSPB instance for transitional soy proto support:
1579
- * http://goto/soy-param-migration
1580
- * @return {!Object}
1581
- */
1582
- proto.UpdateCompanyResponse.prototype.toObject = function(opt_includeInstance) {
1583
- return proto.UpdateCompanyResponse.toObject(opt_includeInstance, this);
1584
- };
1585
-
1586
-
1587
- /**
1588
- * Static version of the {@see toObject} method.
1589
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
1590
- * the JSPB instance for transitional soy proto support:
1591
- * http://goto/soy-param-migration
1592
- * @param {!proto.UpdateCompanyResponse} msg The msg instance to transform.
1593
- * @return {!Object}
1594
- * @suppress {unusedLocalVariables} f is only used for nested messages
1595
- */
1596
- proto.UpdateCompanyResponse.toObject = function(includeInstance, msg) {
1597
- var f, obj = {
1598
- company: (f = msg.getCompany()) && proto.Company.toObject(includeInstance, f),
1599
- meta: (f = msg.getMeta()) && prisca_v1_global_meta_meta_pb.Meta.toObject(includeInstance, f)
1600
- };
1601
-
1602
- if (includeInstance) {
1603
- obj.$jspbMessageInstance = msg;
1604
- }
1605
- return obj;
1606
- };
1607
- }
1608
-
1609
-
1610
- /**
1611
- * Deserializes binary data (in protobuf wire format).
1612
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
1613
- * @return {!proto.UpdateCompanyResponse}
1614
- */
1615
- proto.UpdateCompanyResponse.deserializeBinary = function(bytes) {
1616
- var reader = new jspb.BinaryReader(bytes);
1617
- var msg = new proto.UpdateCompanyResponse;
1618
- return proto.UpdateCompanyResponse.deserializeBinaryFromReader(msg, reader);
1619
- };
1620
-
1621
-
1622
- /**
1623
- * Deserializes binary data (in protobuf wire format) from the
1624
- * given reader into the given message object.
1625
- * @param {!proto.UpdateCompanyResponse} msg The message object to deserialize into.
1626
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
1627
- * @return {!proto.UpdateCompanyResponse}
1628
- */
1629
- proto.UpdateCompanyResponse.deserializeBinaryFromReader = function(msg, reader) {
1630
- while (reader.nextField()) {
1631
- if (reader.isEndGroup()) {
1632
- break;
1633
- }
1634
- var field = reader.getFieldNumber();
1635
- switch (field) {
1636
- case 1:
1637
- var value = new proto.Company;
1638
- reader.readMessage(value,proto.Company.deserializeBinaryFromReader);
1639
- msg.setCompany(value);
1640
- break;
1641
- case 2:
1642
- var value = new prisca_v1_global_meta_meta_pb.Meta;
1643
- reader.readMessage(value,prisca_v1_global_meta_meta_pb.Meta.deserializeBinaryFromReader);
1644
- msg.setMeta(value);
1645
- break;
1646
- default:
1647
- reader.skipField();
1648
- break;
1649
- }
1650
- }
1651
- return msg;
1652
- };
1653
-
1654
-
1655
- /**
1656
- * Serializes the message to binary data (in protobuf wire format).
1657
- * @return {!Uint8Array}
1658
- */
1659
- proto.UpdateCompanyResponse.prototype.serializeBinary = function() {
1660
- var writer = new jspb.BinaryWriter();
1661
- proto.UpdateCompanyResponse.serializeBinaryToWriter(this, writer);
1662
- return writer.getResultBuffer();
1663
- };
1664
-
1665
-
1666
- /**
1667
- * Serializes the given message to binary data (in protobuf wire
1668
- * format), writing to the given BinaryWriter.
1669
- * @param {!proto.UpdateCompanyResponse} message
1670
- * @param {!jspb.BinaryWriter} writer
1671
- * @suppress {unusedLocalVariables} f is only used for nested messages
1672
- */
1673
- proto.UpdateCompanyResponse.serializeBinaryToWriter = function(message, writer) {
1674
- var f = undefined;
1675
- f = message.getCompany();
1676
- if (f != null) {
1677
- writer.writeMessage(
1678
- 1,
1679
- f,
1680
- proto.Company.serializeBinaryToWriter
1681
- );
1682
- }
1683
- f = message.getMeta();
1684
- if (f != null) {
1685
- writer.writeMessage(
1686
- 2,
1687
- f,
1688
- prisca_v1_global_meta_meta_pb.Meta.serializeBinaryToWriter
1689
- );
1690
- }
1691
- };
1692
-
1693
-
1694
- /**
1695
- * optional Company company = 1;
1696
- * @return {?proto.Company}
1697
- */
1698
- proto.UpdateCompanyResponse.prototype.getCompany = function() {
1699
- return /** @type{?proto.Company} */ (
1700
- jspb.Message.getWrapperField(this, proto.Company, 1));
1701
- };
1702
-
1703
-
1704
- /**
1705
- * @param {?proto.Company|undefined} value
1706
- * @return {!proto.UpdateCompanyResponse} returns this
1707
- */
1708
- proto.UpdateCompanyResponse.prototype.setCompany = function(value) {
1709
- return jspb.Message.setWrapperField(this, 1, value);
1710
- };
1711
-
1712
-
1713
- /**
1714
- * Clears the message field making it undefined.
1715
- * @return {!proto.UpdateCompanyResponse} returns this
1716
- */
1717
- proto.UpdateCompanyResponse.prototype.clearCompany = function() {
1718
- return this.setCompany(undefined);
1719
- };
1720
-
1721
-
1722
- /**
1723
- * Returns whether this field is set.
1724
- * @return {boolean}
1725
- */
1726
- proto.UpdateCompanyResponse.prototype.hasCompany = function() {
1727
- return jspb.Message.getField(this, 1) != null;
1728
- };
1729
-
1730
-
1731
- /**
1732
- * optional prisca.v1.global.meta.Meta meta = 2;
1733
- * @return {?proto.prisca.v1.global.meta.Meta}
1734
- */
1735
- proto.UpdateCompanyResponse.prototype.getMeta = function() {
1736
- return /** @type{?proto.prisca.v1.global.meta.Meta} */ (
1737
- jspb.Message.getWrapperField(this, prisca_v1_global_meta_meta_pb.Meta, 2));
1738
- };
1739
-
1740
-
1741
- /**
1742
- * @param {?proto.prisca.v1.global.meta.Meta|undefined} value
1743
- * @return {!proto.UpdateCompanyResponse} returns this
1744
- */
1745
- proto.UpdateCompanyResponse.prototype.setMeta = function(value) {
1746
- return jspb.Message.setWrapperField(this, 2, value);
1747
- };
1748
-
1749
-
1750
- /**
1751
- * Clears the message field making it undefined.
1752
- * @return {!proto.UpdateCompanyResponse} returns this
1753
- */
1754
- proto.UpdateCompanyResponse.prototype.clearMeta = function() {
1755
- return this.setMeta(undefined);
1756
- };
1757
-
1758
-
1759
- /**
1760
- * Returns whether this field is set.
1761
- * @return {boolean}
1762
- */
1763
- proto.UpdateCompanyResponse.prototype.hasMeta = function() {
1764
- return jspb.Message.getField(this, 2) != null;
1765
- };
1766
-
1767
-
1768
-
1769
-
1770
-
1771
- if (jspb.Message.GENERATE_TO_OBJECT) {
1772
- /**
1773
- * Creates an object representation of this proto.
1774
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
1775
- * Optional fields that are not set will be set to undefined.
1776
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
1777
- * For the list of reserved names please see:
1778
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
1779
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
1780
- * JSPB instance for transitional soy proto support:
1781
- * http://goto/soy-param-migration
1782
- * @return {!Object}
1783
- */
1784
- proto.CreateCompanyRequest.prototype.toObject = function(opt_includeInstance) {
1785
- return proto.CreateCompanyRequest.toObject(opt_includeInstance, this);
1786
- };
1787
-
1788
-
1789
- /**
1790
- * Static version of the {@see toObject} method.
1791
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
1792
- * the JSPB instance for transitional soy proto support:
1793
- * http://goto/soy-param-migration
1794
- * @param {!proto.CreateCompanyRequest} msg The msg instance to transform.
1795
- * @return {!Object}
1796
- * @suppress {unusedLocalVariables} f is only used for nested messages
1797
- */
1798
- proto.CreateCompanyRequest.toObject = function(includeInstance, msg) {
1799
- var f, obj = {
1800
- company: (f = msg.getCompany()) && proto.Company.toObject(includeInstance, f)
1801
- };
1802
-
1803
- if (includeInstance) {
1804
- obj.$jspbMessageInstance = msg;
1805
- }
1806
- return obj;
1807
- };
1808
- }
1809
-
1810
-
1811
- /**
1812
- * Deserializes binary data (in protobuf wire format).
1813
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
1814
- * @return {!proto.CreateCompanyRequest}
1815
- */
1816
- proto.CreateCompanyRequest.deserializeBinary = function(bytes) {
1817
- var reader = new jspb.BinaryReader(bytes);
1818
- var msg = new proto.CreateCompanyRequest;
1819
- return proto.CreateCompanyRequest.deserializeBinaryFromReader(msg, reader);
1820
- };
1821
-
1822
-
1823
- /**
1824
- * Deserializes binary data (in protobuf wire format) from the
1825
- * given reader into the given message object.
1826
- * @param {!proto.CreateCompanyRequest} msg The message object to deserialize into.
1827
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
1828
- * @return {!proto.CreateCompanyRequest}
1829
- */
1830
- proto.CreateCompanyRequest.deserializeBinaryFromReader = function(msg, reader) {
1831
- while (reader.nextField()) {
1832
- if (reader.isEndGroup()) {
1833
- break;
1834
- }
1835
- var field = reader.getFieldNumber();
1836
- switch (field) {
1837
- case 1:
1838
- var value = new proto.Company;
1839
- reader.readMessage(value,proto.Company.deserializeBinaryFromReader);
1840
- msg.setCompany(value);
1841
- break;
1842
- default:
1843
- reader.skipField();
1844
- break;
1845
- }
1846
- }
1847
- return msg;
1848
- };
1849
-
1850
-
1851
- /**
1852
- * Serializes the message to binary data (in protobuf wire format).
1853
- * @return {!Uint8Array}
1854
- */
1855
- proto.CreateCompanyRequest.prototype.serializeBinary = function() {
1856
- var writer = new jspb.BinaryWriter();
1857
- proto.CreateCompanyRequest.serializeBinaryToWriter(this, writer);
1858
- return writer.getResultBuffer();
1859
- };
1860
-
1861
-
1862
- /**
1863
- * Serializes the given message to binary data (in protobuf wire
1864
- * format), writing to the given BinaryWriter.
1865
- * @param {!proto.CreateCompanyRequest} message
1866
- * @param {!jspb.BinaryWriter} writer
1867
- * @suppress {unusedLocalVariables} f is only used for nested messages
1868
- */
1869
- proto.CreateCompanyRequest.serializeBinaryToWriter = function(message, writer) {
1870
- var f = undefined;
1871
- f = message.getCompany();
1872
- if (f != null) {
1873
- writer.writeMessage(
1874
- 1,
1875
- f,
1876
- proto.Company.serializeBinaryToWriter
1877
- );
1878
- }
1879
- };
1880
-
1881
-
1882
- /**
1883
- * optional Company company = 1;
1884
- * @return {?proto.Company}
1885
- */
1886
- proto.CreateCompanyRequest.prototype.getCompany = function() {
1887
- return /** @type{?proto.Company} */ (
1888
- jspb.Message.getWrapperField(this, proto.Company, 1));
1889
- };
1890
-
1891
-
1892
- /**
1893
- * @param {?proto.Company|undefined} value
1894
- * @return {!proto.CreateCompanyRequest} returns this
1895
- */
1896
- proto.CreateCompanyRequest.prototype.setCompany = function(value) {
1897
- return jspb.Message.setWrapperField(this, 1, value);
1898
- };
1899
-
1900
-
1901
- /**
1902
- * Clears the message field making it undefined.
1903
- * @return {!proto.CreateCompanyRequest} returns this
1904
- */
1905
- proto.CreateCompanyRequest.prototype.clearCompany = function() {
1906
- return this.setCompany(undefined);
1907
- };
1908
-
1909
-
1910
- /**
1911
- * Returns whether this field is set.
1912
- * @return {boolean}
1913
- */
1914
- proto.CreateCompanyRequest.prototype.hasCompany = function() {
1915
- return jspb.Message.getField(this, 1) != null;
1916
- };
1917
-
1918
-
1919
-
1920
-
1921
-
1922
- if (jspb.Message.GENERATE_TO_OBJECT) {
1923
- /**
1924
- * Creates an object representation of this proto.
1925
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
1926
- * Optional fields that are not set will be set to undefined.
1927
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
1928
- * For the list of reserved names please see:
1929
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
1930
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
1931
- * JSPB instance for transitional soy proto support:
1932
- * http://goto/soy-param-migration
1933
- * @return {!Object}
1934
- */
1935
- proto.CreateCompanyResponse.prototype.toObject = function(opt_includeInstance) {
1936
- return proto.CreateCompanyResponse.toObject(opt_includeInstance, this);
1937
- };
1938
-
1939
-
1940
- /**
1941
- * Static version of the {@see toObject} method.
1942
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
1943
- * the JSPB instance for transitional soy proto support:
1944
- * http://goto/soy-param-migration
1945
- * @param {!proto.CreateCompanyResponse} msg The msg instance to transform.
1946
- * @return {!Object}
1947
- * @suppress {unusedLocalVariables} f is only used for nested messages
1948
- */
1949
- proto.CreateCompanyResponse.toObject = function(includeInstance, msg) {
1950
- var f, obj = {
1951
- company: (f = msg.getCompany()) && proto.Company.toObject(includeInstance, f),
1952
- meta: (f = msg.getMeta()) && prisca_v1_global_meta_meta_pb.Meta.toObject(includeInstance, f)
1953
- };
1954
-
1955
- if (includeInstance) {
1956
- obj.$jspbMessageInstance = msg;
1957
- }
1958
- return obj;
1959
- };
1960
- }
1961
-
1962
-
1963
- /**
1964
- * Deserializes binary data (in protobuf wire format).
1965
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
1966
- * @return {!proto.CreateCompanyResponse}
1967
- */
1968
- proto.CreateCompanyResponse.deserializeBinary = function(bytes) {
1969
- var reader = new jspb.BinaryReader(bytes);
1970
- var msg = new proto.CreateCompanyResponse;
1971
- return proto.CreateCompanyResponse.deserializeBinaryFromReader(msg, reader);
1972
- };
1973
-
1974
-
1975
- /**
1976
- * Deserializes binary data (in protobuf wire format) from the
1977
- * given reader into the given message object.
1978
- * @param {!proto.CreateCompanyResponse} msg The message object to deserialize into.
1979
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
1980
- * @return {!proto.CreateCompanyResponse}
1981
- */
1982
- proto.CreateCompanyResponse.deserializeBinaryFromReader = function(msg, reader) {
1983
- while (reader.nextField()) {
1984
- if (reader.isEndGroup()) {
1985
- break;
1986
- }
1987
- var field = reader.getFieldNumber();
1988
- switch (field) {
1989
- case 1:
1990
- var value = new proto.Company;
1991
- reader.readMessage(value,proto.Company.deserializeBinaryFromReader);
1992
- msg.setCompany(value);
1993
- break;
1994
- case 2:
1995
- var value = new prisca_v1_global_meta_meta_pb.Meta;
1996
- reader.readMessage(value,prisca_v1_global_meta_meta_pb.Meta.deserializeBinaryFromReader);
1997
- msg.setMeta(value);
1998
- break;
1999
- default:
2000
- reader.skipField();
2001
- break;
2002
- }
2003
- }
2004
- return msg;
2005
- };
2006
-
2007
-
2008
- /**
2009
- * Serializes the message to binary data (in protobuf wire format).
2010
- * @return {!Uint8Array}
2011
- */
2012
- proto.CreateCompanyResponse.prototype.serializeBinary = function() {
2013
- var writer = new jspb.BinaryWriter();
2014
- proto.CreateCompanyResponse.serializeBinaryToWriter(this, writer);
2015
- return writer.getResultBuffer();
2016
- };
2017
-
2018
-
2019
- /**
2020
- * Serializes the given message to binary data (in protobuf wire
2021
- * format), writing to the given BinaryWriter.
2022
- * @param {!proto.CreateCompanyResponse} message
2023
- * @param {!jspb.BinaryWriter} writer
2024
- * @suppress {unusedLocalVariables} f is only used for nested messages
2025
- */
2026
- proto.CreateCompanyResponse.serializeBinaryToWriter = function(message, writer) {
2027
- var f = undefined;
2028
- f = message.getCompany();
2029
- if (f != null) {
2030
- writer.writeMessage(
2031
- 1,
2032
- f,
2033
- proto.Company.serializeBinaryToWriter
2034
- );
2035
- }
2036
- f = message.getMeta();
2037
- if (f != null) {
2038
- writer.writeMessage(
2039
- 2,
2040
- f,
2041
- prisca_v1_global_meta_meta_pb.Meta.serializeBinaryToWriter
2042
- );
2043
- }
2044
- };
2045
-
2046
-
2047
- /**
2048
- * optional Company company = 1;
2049
- * @return {?proto.Company}
2050
- */
2051
- proto.CreateCompanyResponse.prototype.getCompany = function() {
2052
- return /** @type{?proto.Company} */ (
2053
- jspb.Message.getWrapperField(this, proto.Company, 1));
2054
- };
2055
-
2056
-
2057
- /**
2058
- * @param {?proto.Company|undefined} value
2059
- * @return {!proto.CreateCompanyResponse} returns this
2060
- */
2061
- proto.CreateCompanyResponse.prototype.setCompany = function(value) {
2062
- return jspb.Message.setWrapperField(this, 1, value);
2063
- };
2064
-
2065
-
2066
- /**
2067
- * Clears the message field making it undefined.
2068
- * @return {!proto.CreateCompanyResponse} returns this
2069
- */
2070
- proto.CreateCompanyResponse.prototype.clearCompany = function() {
2071
- return this.setCompany(undefined);
2072
- };
2073
-
2074
-
2075
- /**
2076
- * Returns whether this field is set.
2077
- * @return {boolean}
2078
- */
2079
- proto.CreateCompanyResponse.prototype.hasCompany = function() {
2080
- return jspb.Message.getField(this, 1) != null;
2081
- };
2082
-
2083
-
2084
- /**
2085
- * optional prisca.v1.global.meta.Meta meta = 2;
2086
- * @return {?proto.prisca.v1.global.meta.Meta}
2087
- */
2088
- proto.CreateCompanyResponse.prototype.getMeta = function() {
2089
- return /** @type{?proto.prisca.v1.global.meta.Meta} */ (
2090
- jspb.Message.getWrapperField(this, prisca_v1_global_meta_meta_pb.Meta, 2));
2091
- };
2092
-
2093
-
2094
- /**
2095
- * @param {?proto.prisca.v1.global.meta.Meta|undefined} value
2096
- * @return {!proto.CreateCompanyResponse} returns this
2097
- */
2098
- proto.CreateCompanyResponse.prototype.setMeta = function(value) {
2099
- return jspb.Message.setWrapperField(this, 2, value);
2100
- };
2101
-
2102
-
2103
- /**
2104
- * Clears the message field making it undefined.
2105
- * @return {!proto.CreateCompanyResponse} returns this
2106
- */
2107
- proto.CreateCompanyResponse.prototype.clearMeta = function() {
2108
- return this.setMeta(undefined);
2109
- };
2110
-
2111
-
2112
- /**
2113
- * Returns whether this field is set.
2114
- * @return {boolean}
2115
- */
2116
- proto.CreateCompanyResponse.prototype.hasMeta = function() {
2117
- return jspb.Message.getField(this, 2) != null;
2118
- };
2119
-
2120
-
2121
-
2122
-
2123
-
2124
- if (jspb.Message.GENERATE_TO_OBJECT) {
2125
- /**
2126
- * Creates an object representation of this proto.
2127
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
2128
- * Optional fields that are not set will be set to undefined.
2129
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
2130
- * For the list of reserved names please see:
2131
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
2132
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
2133
- * JSPB instance for transitional soy proto support:
2134
- * http://goto/soy-param-migration
2135
- * @return {!Object}
2136
- */
2137
- proto.DeleteCompanyRequest.prototype.toObject = function(opt_includeInstance) {
2138
- return proto.DeleteCompanyRequest.toObject(opt_includeInstance, this);
2139
- };
2140
-
2141
-
2142
- /**
2143
- * Static version of the {@see toObject} method.
2144
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
2145
- * the JSPB instance for transitional soy proto support:
2146
- * http://goto/soy-param-migration
2147
- * @param {!proto.DeleteCompanyRequest} msg The msg instance to transform.
2148
- * @return {!Object}
2149
- * @suppress {unusedLocalVariables} f is only used for nested messages
2150
- */
2151
- proto.DeleteCompanyRequest.toObject = function(includeInstance, msg) {
2152
- var f, obj = {
2153
- referencesId: jspb.Message.getFieldWithDefault(msg, 1, "")
2154
- };
2155
-
2156
- if (includeInstance) {
2157
- obj.$jspbMessageInstance = msg;
2158
- }
2159
- return obj;
2160
- };
2161
- }
2162
-
2163
-
2164
- /**
2165
- * Deserializes binary data (in protobuf wire format).
2166
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
2167
- * @return {!proto.DeleteCompanyRequest}
2168
- */
2169
- proto.DeleteCompanyRequest.deserializeBinary = function(bytes) {
2170
- var reader = new jspb.BinaryReader(bytes);
2171
- var msg = new proto.DeleteCompanyRequest;
2172
- return proto.DeleteCompanyRequest.deserializeBinaryFromReader(msg, reader);
2173
- };
2174
-
2175
-
2176
- /**
2177
- * Deserializes binary data (in protobuf wire format) from the
2178
- * given reader into the given message object.
2179
- * @param {!proto.DeleteCompanyRequest} msg The message object to deserialize into.
2180
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
2181
- * @return {!proto.DeleteCompanyRequest}
2182
- */
2183
- proto.DeleteCompanyRequest.deserializeBinaryFromReader = function(msg, reader) {
2184
- while (reader.nextField()) {
2185
- if (reader.isEndGroup()) {
2186
- break;
2187
- }
2188
- var field = reader.getFieldNumber();
2189
- switch (field) {
2190
- case 1:
2191
- var value = /** @type {string} */ (reader.readString());
2192
- msg.setReferencesId(value);
2193
- break;
2194
- default:
2195
- reader.skipField();
2196
- break;
2197
- }
2198
- }
2199
- return msg;
2200
- };
2201
-
2202
-
2203
- /**
2204
- * Serializes the message to binary data (in protobuf wire format).
2205
- * @return {!Uint8Array}
2206
- */
2207
- proto.DeleteCompanyRequest.prototype.serializeBinary = function() {
2208
- var writer = new jspb.BinaryWriter();
2209
- proto.DeleteCompanyRequest.serializeBinaryToWriter(this, writer);
2210
- return writer.getResultBuffer();
2211
- };
2212
-
2213
-
2214
- /**
2215
- * Serializes the given message to binary data (in protobuf wire
2216
- * format), writing to the given BinaryWriter.
2217
- * @param {!proto.DeleteCompanyRequest} message
2218
- * @param {!jspb.BinaryWriter} writer
2219
- * @suppress {unusedLocalVariables} f is only used for nested messages
2220
- */
2221
- proto.DeleteCompanyRequest.serializeBinaryToWriter = function(message, writer) {
2222
- var f = undefined;
2223
- f = message.getReferencesId();
2224
- if (f.length > 0) {
2225
- writer.writeString(
2226
- 1,
2227
- f
2228
- );
2229
- }
2230
- };
2231
-
2232
-
2233
- /**
2234
- * optional string references_id = 1;
2235
- * @return {string}
2236
- */
2237
- proto.DeleteCompanyRequest.prototype.getReferencesId = function() {
2238
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
2239
- };
2240
-
2241
-
2242
- /**
2243
- * @param {string} value
2244
- * @return {!proto.DeleteCompanyRequest} returns this
2245
- */
2246
- proto.DeleteCompanyRequest.prototype.setReferencesId = function(value) {
2247
- return jspb.Message.setProto3StringField(this, 1, value);
2248
- };
2249
-
2250
-
2251
-
2252
-
2253
-
2254
- if (jspb.Message.GENERATE_TO_OBJECT) {
2255
- /**
2256
- * Creates an object representation of this proto.
2257
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
2258
- * Optional fields that are not set will be set to undefined.
2259
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
2260
- * For the list of reserved names please see:
2261
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
2262
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
2263
- * JSPB instance for transitional soy proto support:
2264
- * http://goto/soy-param-migration
2265
- * @return {!Object}
2266
- */
2267
- proto.DeleteCompanyResponse.prototype.toObject = function(opt_includeInstance) {
2268
- return proto.DeleteCompanyResponse.toObject(opt_includeInstance, this);
2269
- };
2270
-
2271
-
2272
- /**
2273
- * Static version of the {@see toObject} method.
2274
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
2275
- * the JSPB instance for transitional soy proto support:
2276
- * http://goto/soy-param-migration
2277
- * @param {!proto.DeleteCompanyResponse} msg The msg instance to transform.
2278
- * @return {!Object}
2279
- * @suppress {unusedLocalVariables} f is only used for nested messages
2280
- */
2281
- proto.DeleteCompanyResponse.toObject = function(includeInstance, msg) {
2282
- var f, obj = {
2283
- id: jspb.Message.getFieldWithDefault(msg, 1, 0),
2284
- meta: (f = msg.getMeta()) && prisca_v1_global_meta_meta_pb.Meta.toObject(includeInstance, f)
2285
- };
2286
-
2287
- if (includeInstance) {
2288
- obj.$jspbMessageInstance = msg;
2289
- }
2290
- return obj;
2291
- };
2292
- }
2293
-
2294
-
2295
- /**
2296
- * Deserializes binary data (in protobuf wire format).
2297
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
2298
- * @return {!proto.DeleteCompanyResponse}
2299
- */
2300
- proto.DeleteCompanyResponse.deserializeBinary = function(bytes) {
2301
- var reader = new jspb.BinaryReader(bytes);
2302
- var msg = new proto.DeleteCompanyResponse;
2303
- return proto.DeleteCompanyResponse.deserializeBinaryFromReader(msg, reader);
2304
- };
2305
-
2306
-
2307
- /**
2308
- * Deserializes binary data (in protobuf wire format) from the
2309
- * given reader into the given message object.
2310
- * @param {!proto.DeleteCompanyResponse} msg The message object to deserialize into.
2311
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
2312
- * @return {!proto.DeleteCompanyResponse}
2313
- */
2314
- proto.DeleteCompanyResponse.deserializeBinaryFromReader = function(msg, reader) {
2315
- while (reader.nextField()) {
2316
- if (reader.isEndGroup()) {
2317
- break;
2318
- }
2319
- var field = reader.getFieldNumber();
2320
- switch (field) {
2321
- case 1:
2322
- var value = /** @type {number} */ (reader.readInt64());
2323
- msg.setId(value);
2324
- break;
2325
- case 2:
2326
- var value = new prisca_v1_global_meta_meta_pb.Meta;
2327
- reader.readMessage(value,prisca_v1_global_meta_meta_pb.Meta.deserializeBinaryFromReader);
2328
- msg.setMeta(value);
2329
- break;
2330
- default:
2331
- reader.skipField();
2332
- break;
2333
- }
2334
- }
2335
- return msg;
2336
- };
2337
-
2338
-
2339
- /**
2340
- * Serializes the message to binary data (in protobuf wire format).
2341
- * @return {!Uint8Array}
2342
- */
2343
- proto.DeleteCompanyResponse.prototype.serializeBinary = function() {
2344
- var writer = new jspb.BinaryWriter();
2345
- proto.DeleteCompanyResponse.serializeBinaryToWriter(this, writer);
2346
- return writer.getResultBuffer();
2347
- };
2348
-
2349
-
2350
- /**
2351
- * Serializes the given message to binary data (in protobuf wire
2352
- * format), writing to the given BinaryWriter.
2353
- * @param {!proto.DeleteCompanyResponse} message
2354
- * @param {!jspb.BinaryWriter} writer
2355
- * @suppress {unusedLocalVariables} f is only used for nested messages
2356
- */
2357
- proto.DeleteCompanyResponse.serializeBinaryToWriter = function(message, writer) {
2358
- var f = undefined;
2359
- f = message.getId();
2360
- if (f !== 0) {
2361
- writer.writeInt64(
2362
- 1,
2363
- f
2364
- );
2365
- }
2366
- f = message.getMeta();
2367
- if (f != null) {
2368
- writer.writeMessage(
2369
- 2,
2370
- f,
2371
- prisca_v1_global_meta_meta_pb.Meta.serializeBinaryToWriter
2372
- );
2373
- }
2374
- };
2375
-
2376
-
2377
- /**
2378
- * optional int64 id = 1;
2379
- * @return {number}
2380
- */
2381
- proto.DeleteCompanyResponse.prototype.getId = function() {
2382
- return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0));
2383
- };
2384
-
2385
-
2386
- /**
2387
- * @param {number} value
2388
- * @return {!proto.DeleteCompanyResponse} returns this
2389
- */
2390
- proto.DeleteCompanyResponse.prototype.setId = function(value) {
2391
- return jspb.Message.setProto3IntField(this, 1, value);
2392
- };
2393
-
2394
-
2395
- /**
2396
- * optional prisca.v1.global.meta.Meta meta = 2;
2397
- * @return {?proto.prisca.v1.global.meta.Meta}
2398
- */
2399
- proto.DeleteCompanyResponse.prototype.getMeta = function() {
2400
- return /** @type{?proto.prisca.v1.global.meta.Meta} */ (
2401
- jspb.Message.getWrapperField(this, prisca_v1_global_meta_meta_pb.Meta, 2));
2402
- };
2403
-
2404
-
2405
- /**
2406
- * @param {?proto.prisca.v1.global.meta.Meta|undefined} value
2407
- * @return {!proto.DeleteCompanyResponse} returns this
2408
- */
2409
- proto.DeleteCompanyResponse.prototype.setMeta = function(value) {
2410
- return jspb.Message.setWrapperField(this, 2, value);
2411
- };
2412
-
2413
-
2414
- /**
2415
- * Clears the message field making it undefined.
2416
- * @return {!proto.DeleteCompanyResponse} returns this
2417
- */
2418
- proto.DeleteCompanyResponse.prototype.clearMeta = function() {
2419
- return this.setMeta(undefined);
2420
- };
2421
-
2422
-
2423
- /**
2424
- * Returns whether this field is set.
2425
- * @return {boolean}
2426
- */
2427
- proto.DeleteCompanyResponse.prototype.hasMeta = function() {
2428
- return jspb.Message.getField(this, 2) != null;
2429
- };
2430
-
2431
-
2432
-
2433
-
2434
-
2435
- if (jspb.Message.GENERATE_TO_OBJECT) {
2436
- /**
2437
- * Creates an object representation of this proto.
2438
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
2439
- * Optional fields that are not set will be set to undefined.
2440
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
2441
- * For the list of reserved names please see:
2442
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
2443
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
2444
- * JSPB instance for transitional soy proto support:
2445
- * http://goto/soy-param-migration
2446
- * @return {!Object}
2447
- */
2448
- proto.GetListCompanyRequest.prototype.toObject = function(opt_includeInstance) {
2449
- return proto.GetListCompanyRequest.toObject(opt_includeInstance, this);
2450
- };
2451
-
2452
-
2453
- /**
2454
- * Static version of the {@see toObject} method.
2455
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
2456
- * the JSPB instance for transitional soy proto support:
2457
- * http://goto/soy-param-migration
2458
- * @param {!proto.GetListCompanyRequest} msg The msg instance to transform.
2459
- * @return {!Object}
2460
- * @suppress {unusedLocalVariables} f is only used for nested messages
2461
- */
2462
- proto.GetListCompanyRequest.toObject = function(includeInstance, msg) {
2463
- var f, obj = {
2464
- pagination: (f = msg.getPagination()) && prisca_v1_global_meta_meta_pb.PaginationRequest.toObject(includeInstance, f),
2465
- query: (f = msg.getQuery()) && prisca_v1_global_meta_meta_pb.FilterRequest.toObject(includeInstance, f)
2466
- };
2467
-
2468
- if (includeInstance) {
2469
- obj.$jspbMessageInstance = msg;
2470
- }
2471
- return obj;
2472
- };
2473
- }
2474
-
2475
-
2476
- /**
2477
- * Deserializes binary data (in protobuf wire format).
2478
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
2479
- * @return {!proto.GetListCompanyRequest}
2480
- */
2481
- proto.GetListCompanyRequest.deserializeBinary = function(bytes) {
2482
- var reader = new jspb.BinaryReader(bytes);
2483
- var msg = new proto.GetListCompanyRequest;
2484
- return proto.GetListCompanyRequest.deserializeBinaryFromReader(msg, reader);
2485
- };
2486
-
2487
-
2488
- /**
2489
- * Deserializes binary data (in protobuf wire format) from the
2490
- * given reader into the given message object.
2491
- * @param {!proto.GetListCompanyRequest} msg The message object to deserialize into.
2492
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
2493
- * @return {!proto.GetListCompanyRequest}
2494
- */
2495
- proto.GetListCompanyRequest.deserializeBinaryFromReader = function(msg, reader) {
2496
- while (reader.nextField()) {
2497
- if (reader.isEndGroup()) {
2498
- break;
2499
- }
2500
- var field = reader.getFieldNumber();
2501
- switch (field) {
2502
- case 1:
2503
- var value = new prisca_v1_global_meta_meta_pb.PaginationRequest;
2504
- reader.readMessage(value,prisca_v1_global_meta_meta_pb.PaginationRequest.deserializeBinaryFromReader);
2505
- msg.setPagination(value);
2506
- break;
2507
- case 2:
2508
- var value = new prisca_v1_global_meta_meta_pb.FilterRequest;
2509
- reader.readMessage(value,prisca_v1_global_meta_meta_pb.FilterRequest.deserializeBinaryFromReader);
2510
- msg.setQuery(value);
2511
- break;
2512
- default:
2513
- reader.skipField();
2514
- break;
2515
- }
2516
- }
2517
- return msg;
2518
- };
2519
-
2520
-
2521
- /**
2522
- * Serializes the message to binary data (in protobuf wire format).
2523
- * @return {!Uint8Array}
2524
- */
2525
- proto.GetListCompanyRequest.prototype.serializeBinary = function() {
2526
- var writer = new jspb.BinaryWriter();
2527
- proto.GetListCompanyRequest.serializeBinaryToWriter(this, writer);
2528
- return writer.getResultBuffer();
2529
- };
2530
-
2531
-
2532
- /**
2533
- * Serializes the given message to binary data (in protobuf wire
2534
- * format), writing to the given BinaryWriter.
2535
- * @param {!proto.GetListCompanyRequest} message
2536
- * @param {!jspb.BinaryWriter} writer
2537
- * @suppress {unusedLocalVariables} f is only used for nested messages
2538
- */
2539
- proto.GetListCompanyRequest.serializeBinaryToWriter = function(message, writer) {
2540
- var f = undefined;
2541
- f = message.getPagination();
2542
- if (f != null) {
2543
- writer.writeMessage(
2544
- 1,
2545
- f,
2546
- prisca_v1_global_meta_meta_pb.PaginationRequest.serializeBinaryToWriter
2547
- );
2548
- }
2549
- f = message.getQuery();
2550
- if (f != null) {
2551
- writer.writeMessage(
2552
- 2,
2553
- f,
2554
- prisca_v1_global_meta_meta_pb.FilterRequest.serializeBinaryToWriter
2555
- );
2556
- }
2557
- };
2558
-
2559
-
2560
- /**
2561
- * optional prisca.v1.global.meta.PaginationRequest pagination = 1;
2562
- * @return {?proto.prisca.v1.global.meta.PaginationRequest}
2563
- */
2564
- proto.GetListCompanyRequest.prototype.getPagination = function() {
2565
- return /** @type{?proto.prisca.v1.global.meta.PaginationRequest} */ (
2566
- jspb.Message.getWrapperField(this, prisca_v1_global_meta_meta_pb.PaginationRequest, 1));
2567
- };
2568
-
2569
-
2570
- /**
2571
- * @param {?proto.prisca.v1.global.meta.PaginationRequest|undefined} value
2572
- * @return {!proto.GetListCompanyRequest} returns this
2573
- */
2574
- proto.GetListCompanyRequest.prototype.setPagination = function(value) {
2575
- return jspb.Message.setWrapperField(this, 1, value);
2576
- };
2577
-
2578
-
2579
- /**
2580
- * Clears the message field making it undefined.
2581
- * @return {!proto.GetListCompanyRequest} returns this
2582
- */
2583
- proto.GetListCompanyRequest.prototype.clearPagination = function() {
2584
- return this.setPagination(undefined);
2585
- };
2586
-
2587
-
2588
- /**
2589
- * Returns whether this field is set.
2590
- * @return {boolean}
2591
- */
2592
- proto.GetListCompanyRequest.prototype.hasPagination = function() {
2593
- return jspb.Message.getField(this, 1) != null;
2594
- };
2595
-
2596
-
2597
- /**
2598
- * optional prisca.v1.global.meta.FilterRequest query = 2;
2599
- * @return {?proto.prisca.v1.global.meta.FilterRequest}
2600
- */
2601
- proto.GetListCompanyRequest.prototype.getQuery = function() {
2602
- return /** @type{?proto.prisca.v1.global.meta.FilterRequest} */ (
2603
- jspb.Message.getWrapperField(this, prisca_v1_global_meta_meta_pb.FilterRequest, 2));
2604
- };
2605
-
2606
-
2607
- /**
2608
- * @param {?proto.prisca.v1.global.meta.FilterRequest|undefined} value
2609
- * @return {!proto.GetListCompanyRequest} returns this
2610
- */
2611
- proto.GetListCompanyRequest.prototype.setQuery = function(value) {
2612
- return jspb.Message.setWrapperField(this, 2, value);
2613
- };
2614
-
2615
-
2616
- /**
2617
- * Clears the message field making it undefined.
2618
- * @return {!proto.GetListCompanyRequest} returns this
2619
- */
2620
- proto.GetListCompanyRequest.prototype.clearQuery = function() {
2621
- return this.setQuery(undefined);
2622
- };
2623
-
2624
-
2625
- /**
2626
- * Returns whether this field is set.
2627
- * @return {boolean}
2628
- */
2629
- proto.GetListCompanyRequest.prototype.hasQuery = function() {
2630
- return jspb.Message.getField(this, 2) != null;
2631
- };
2632
-
2633
-
2634
-
2635
- /**
2636
- * List of repeated fields within this message type.
2637
- * @private {!Array<number>}
2638
- * @const
2639
- */
2640
- proto.GetListCompanyResponse.repeatedFields_ = [1];
2641
-
2642
-
2643
-
2644
- if (jspb.Message.GENERATE_TO_OBJECT) {
2645
- /**
2646
- * Creates an object representation of this proto.
2647
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
2648
- * Optional fields that are not set will be set to undefined.
2649
- * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
2650
- * For the list of reserved names please see:
2651
- * net/proto2/compiler/js/internal/generator.cc#kKeyword.
2652
- * @param {boolean=} opt_includeInstance Deprecated. whether to include the
2653
- * JSPB instance for transitional soy proto support:
2654
- * http://goto/soy-param-migration
2655
- * @return {!Object}
2656
- */
2657
- proto.GetListCompanyResponse.prototype.toObject = function(opt_includeInstance) {
2658
- return proto.GetListCompanyResponse.toObject(opt_includeInstance, this);
2659
- };
2660
-
2661
-
2662
- /**
2663
- * Static version of the {@see toObject} method.
2664
- * @param {boolean|undefined} includeInstance Deprecated. Whether to include
2665
- * the JSPB instance for transitional soy proto support:
2666
- * http://goto/soy-param-migration
2667
- * @param {!proto.GetListCompanyResponse} msg The msg instance to transform.
2668
- * @return {!Object}
2669
- * @suppress {unusedLocalVariables} f is only used for nested messages
2670
- */
2671
- proto.GetListCompanyResponse.toObject = function(includeInstance, msg) {
2672
- var f, obj = {
2673
- companyList: jspb.Message.toObjectList(msg.getCompanyList(),
2674
- proto.BaseCompany.toObject, includeInstance),
2675
- meta: (f = msg.getMeta()) && prisca_v1_global_meta_meta_pb.Meta.toObject(includeInstance, f)
2676
- };
2677
-
2678
- if (includeInstance) {
2679
- obj.$jspbMessageInstance = msg;
2680
- }
2681
- return obj;
2682
- };
2683
- }
2684
-
2685
-
2686
- /**
2687
- * Deserializes binary data (in protobuf wire format).
2688
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
2689
- * @return {!proto.GetListCompanyResponse}
2690
- */
2691
- proto.GetListCompanyResponse.deserializeBinary = function(bytes) {
2692
- var reader = new jspb.BinaryReader(bytes);
2693
- var msg = new proto.GetListCompanyResponse;
2694
- return proto.GetListCompanyResponse.deserializeBinaryFromReader(msg, reader);
2695
- };
2696
-
2697
-
2698
- /**
2699
- * Deserializes binary data (in protobuf wire format) from the
2700
- * given reader into the given message object.
2701
- * @param {!proto.GetListCompanyResponse} msg The message object to deserialize into.
2702
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
2703
- * @return {!proto.GetListCompanyResponse}
2704
- */
2705
- proto.GetListCompanyResponse.deserializeBinaryFromReader = function(msg, reader) {
2706
- while (reader.nextField()) {
2707
- if (reader.isEndGroup()) {
2708
- break;
2709
- }
2710
- var field = reader.getFieldNumber();
2711
- switch (field) {
2712
- case 1:
2713
- var value = new proto.BaseCompany;
2714
- reader.readMessage(value,proto.BaseCompany.deserializeBinaryFromReader);
2715
- msg.addCompany(value);
2716
- break;
2717
- case 2:
2718
- var value = new prisca_v1_global_meta_meta_pb.Meta;
2719
- reader.readMessage(value,prisca_v1_global_meta_meta_pb.Meta.deserializeBinaryFromReader);
2720
- msg.setMeta(value);
2721
- break;
2722
- default:
2723
- reader.skipField();
2724
- break;
2725
- }
2726
- }
2727
- return msg;
2728
- };
2729
-
2730
-
2731
- /**
2732
- * Serializes the message to binary data (in protobuf wire format).
2733
- * @return {!Uint8Array}
2734
- */
2735
- proto.GetListCompanyResponse.prototype.serializeBinary = function() {
2736
- var writer = new jspb.BinaryWriter();
2737
- proto.GetListCompanyResponse.serializeBinaryToWriter(this, writer);
2738
- return writer.getResultBuffer();
2739
- };
2740
-
2741
-
2742
- /**
2743
- * Serializes the given message to binary data (in protobuf wire
2744
- * format), writing to the given BinaryWriter.
2745
- * @param {!proto.GetListCompanyResponse} message
2746
- * @param {!jspb.BinaryWriter} writer
2747
- * @suppress {unusedLocalVariables} f is only used for nested messages
2748
- */
2749
- proto.GetListCompanyResponse.serializeBinaryToWriter = function(message, writer) {
2750
- var f = undefined;
2751
- f = message.getCompanyList();
2752
- if (f.length > 0) {
2753
- writer.writeRepeatedMessage(
2754
- 1,
2755
- f,
2756
- proto.BaseCompany.serializeBinaryToWriter
2757
- );
2758
- }
2759
- f = message.getMeta();
2760
- if (f != null) {
2761
- writer.writeMessage(
2762
- 2,
2763
- f,
2764
- prisca_v1_global_meta_meta_pb.Meta.serializeBinaryToWriter
2765
- );
2766
- }
2767
- };
2768
-
2769
-
2770
- /**
2771
- * repeated BaseCompany company = 1;
2772
- * @return {!Array<!proto.BaseCompany>}
2773
- */
2774
- proto.GetListCompanyResponse.prototype.getCompanyList = function() {
2775
- return /** @type{!Array<!proto.BaseCompany>} */ (
2776
- jspb.Message.getRepeatedWrapperField(this, proto.BaseCompany, 1));
2777
- };
2778
-
2779
-
2780
- /**
2781
- * @param {!Array<!proto.BaseCompany>} value
2782
- * @return {!proto.GetListCompanyResponse} returns this
2783
- */
2784
- proto.GetListCompanyResponse.prototype.setCompanyList = function(value) {
2785
- return jspb.Message.setRepeatedWrapperField(this, 1, value);
2786
- };
2787
-
2788
-
2789
- /**
2790
- * @param {!proto.BaseCompany=} opt_value
2791
- * @param {number=} opt_index
2792
- * @return {!proto.BaseCompany}
2793
- */
2794
- proto.GetListCompanyResponse.prototype.addCompany = function(opt_value, opt_index) {
2795
- return jspb.Message.addToRepeatedWrapperField(this, 1, opt_value, proto.BaseCompany, opt_index);
2796
- };
2797
-
2798
-
2799
- /**
2800
- * Clears the list making it empty but non-null.
2801
- * @return {!proto.GetListCompanyResponse} returns this
2802
- */
2803
- proto.GetListCompanyResponse.prototype.clearCompanyList = function() {
2804
- return this.setCompanyList([]);
2805
- };
2806
-
2807
-
2808
- /**
2809
- * optional prisca.v1.global.meta.Meta meta = 2;
2810
- * @return {?proto.prisca.v1.global.meta.Meta}
2811
- */
2812
- proto.GetListCompanyResponse.prototype.getMeta = function() {
2813
- return /** @type{?proto.prisca.v1.global.meta.Meta} */ (
2814
- jspb.Message.getWrapperField(this, prisca_v1_global_meta_meta_pb.Meta, 2));
2815
- };
2816
-
2817
-
2818
- /**
2819
- * @param {?proto.prisca.v1.global.meta.Meta|undefined} value
2820
- * @return {!proto.GetListCompanyResponse} returns this
2821
- */
2822
- proto.GetListCompanyResponse.prototype.setMeta = function(value) {
2823
- return jspb.Message.setWrapperField(this, 2, value);
2824
- };
2825
-
2826
-
2827
- /**
2828
- * Clears the message field making it undefined.
2829
- * @return {!proto.GetListCompanyResponse} returns this
2830
- */
2831
- proto.GetListCompanyResponse.prototype.clearMeta = function() {
2832
- return this.setMeta(undefined);
2833
- };
2834
-
2835
-
2836
- /**
2837
- * Returns whether this field is set.
2838
- * @return {boolean}
2839
- */
2840
- proto.GetListCompanyResponse.prototype.hasMeta = function() {
2841
- return jspb.Message.getField(this, 2) != null;
2842
- };
2843
-
2844
-
2845
- goog.object.extend(exports, proto);