@marleena/trb-proto 1.0.62 → 1.0.64

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.
@@ -0,0 +1,2486 @@
1
+ // source: strategysearch/strategy.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 google_protobuf_timestamp_pb = require('google-protobuf/google/protobuf/timestamp_pb.js');
25
+ goog.object.extend(proto, google_protobuf_timestamp_pb);
26
+ var strategysearch_spec_pb = require('../strategysearch/spec_pb.js');
27
+ goog.object.extend(proto, strategysearch_spec_pb);
28
+ goog.exportSymbol('proto.trb.strategysearch.v1.CreateStrategyRequest', null, global);
29
+ goog.exportSymbol('proto.trb.strategysearch.v1.DeleteStrategyRequest', null, global);
30
+ goog.exportSymbol('proto.trb.strategysearch.v1.DeleteStrategyResponse', null, global);
31
+ goog.exportSymbol('proto.trb.strategysearch.v1.GetStrategyRequest', null, global);
32
+ goog.exportSymbol('proto.trb.strategysearch.v1.ListStrategiesRequest', null, global);
33
+ goog.exportSymbol('proto.trb.strategysearch.v1.ListStrategiesResponse', null, global);
34
+ goog.exportSymbol('proto.trb.strategysearch.v1.Strategy', null, global);
35
+ goog.exportSymbol('proto.trb.strategysearch.v1.UpdateStrategyRequest', null, global);
36
+ goog.exportSymbol('proto.trb.strategysearch.v1.ValidateStrategyRequest', null, global);
37
+ goog.exportSymbol('proto.trb.strategysearch.v1.ValidateStrategyResponse', null, global);
38
+ goog.exportSymbol('proto.trb.strategysearch.v1.ValidationIssue', 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.trb.strategysearch.v1.Strategy = function(opt_data) {
50
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
51
+ };
52
+ goog.inherits(proto.trb.strategysearch.v1.Strategy, jspb.Message);
53
+ if (goog.DEBUG && !COMPILED) {
54
+ /**
55
+ * @public
56
+ * @override
57
+ */
58
+ proto.trb.strategysearch.v1.Strategy.displayName = 'proto.trb.strategysearch.v1.Strategy';
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.trb.strategysearch.v1.CreateStrategyRequest = function(opt_data) {
71
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
72
+ };
73
+ goog.inherits(proto.trb.strategysearch.v1.CreateStrategyRequest, jspb.Message);
74
+ if (goog.DEBUG && !COMPILED) {
75
+ /**
76
+ * @public
77
+ * @override
78
+ */
79
+ proto.trb.strategysearch.v1.CreateStrategyRequest.displayName = 'proto.trb.strategysearch.v1.CreateStrategyRequest';
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.trb.strategysearch.v1.GetStrategyRequest = function(opt_data) {
92
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
93
+ };
94
+ goog.inherits(proto.trb.strategysearch.v1.GetStrategyRequest, jspb.Message);
95
+ if (goog.DEBUG && !COMPILED) {
96
+ /**
97
+ * @public
98
+ * @override
99
+ */
100
+ proto.trb.strategysearch.v1.GetStrategyRequest.displayName = 'proto.trb.strategysearch.v1.GetStrategyRequest';
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.trb.strategysearch.v1.ListStrategiesRequest = function(opt_data) {
113
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
114
+ };
115
+ goog.inherits(proto.trb.strategysearch.v1.ListStrategiesRequest, jspb.Message);
116
+ if (goog.DEBUG && !COMPILED) {
117
+ /**
118
+ * @public
119
+ * @override
120
+ */
121
+ proto.trb.strategysearch.v1.ListStrategiesRequest.displayName = 'proto.trb.strategysearch.v1.ListStrategiesRequest';
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.trb.strategysearch.v1.ListStrategiesResponse = function(opt_data) {
134
+ jspb.Message.initialize(this, opt_data, 0, -1, proto.trb.strategysearch.v1.ListStrategiesResponse.repeatedFields_, null);
135
+ };
136
+ goog.inherits(proto.trb.strategysearch.v1.ListStrategiesResponse, jspb.Message);
137
+ if (goog.DEBUG && !COMPILED) {
138
+ /**
139
+ * @public
140
+ * @override
141
+ */
142
+ proto.trb.strategysearch.v1.ListStrategiesResponse.displayName = 'proto.trb.strategysearch.v1.ListStrategiesResponse';
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.trb.strategysearch.v1.UpdateStrategyRequest = function(opt_data) {
155
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
156
+ };
157
+ goog.inherits(proto.trb.strategysearch.v1.UpdateStrategyRequest, jspb.Message);
158
+ if (goog.DEBUG && !COMPILED) {
159
+ /**
160
+ * @public
161
+ * @override
162
+ */
163
+ proto.trb.strategysearch.v1.UpdateStrategyRequest.displayName = 'proto.trb.strategysearch.v1.UpdateStrategyRequest';
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.trb.strategysearch.v1.DeleteStrategyRequest = function(opt_data) {
176
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
177
+ };
178
+ goog.inherits(proto.trb.strategysearch.v1.DeleteStrategyRequest, jspb.Message);
179
+ if (goog.DEBUG && !COMPILED) {
180
+ /**
181
+ * @public
182
+ * @override
183
+ */
184
+ proto.trb.strategysearch.v1.DeleteStrategyRequest.displayName = 'proto.trb.strategysearch.v1.DeleteStrategyRequest';
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.trb.strategysearch.v1.DeleteStrategyResponse = function(opt_data) {
197
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
198
+ };
199
+ goog.inherits(proto.trb.strategysearch.v1.DeleteStrategyResponse, jspb.Message);
200
+ if (goog.DEBUG && !COMPILED) {
201
+ /**
202
+ * @public
203
+ * @override
204
+ */
205
+ proto.trb.strategysearch.v1.DeleteStrategyResponse.displayName = 'proto.trb.strategysearch.v1.DeleteStrategyResponse';
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.trb.strategysearch.v1.ValidationIssue = function(opt_data) {
218
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
219
+ };
220
+ goog.inherits(proto.trb.strategysearch.v1.ValidationIssue, jspb.Message);
221
+ if (goog.DEBUG && !COMPILED) {
222
+ /**
223
+ * @public
224
+ * @override
225
+ */
226
+ proto.trb.strategysearch.v1.ValidationIssue.displayName = 'proto.trb.strategysearch.v1.ValidationIssue';
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.trb.strategysearch.v1.ValidateStrategyRequest = function(opt_data) {
239
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
240
+ };
241
+ goog.inherits(proto.trb.strategysearch.v1.ValidateStrategyRequest, jspb.Message);
242
+ if (goog.DEBUG && !COMPILED) {
243
+ /**
244
+ * @public
245
+ * @override
246
+ */
247
+ proto.trb.strategysearch.v1.ValidateStrategyRequest.displayName = 'proto.trb.strategysearch.v1.ValidateStrategyRequest';
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.trb.strategysearch.v1.ValidateStrategyResponse = function(opt_data) {
260
+ jspb.Message.initialize(this, opt_data, 0, -1, proto.trb.strategysearch.v1.ValidateStrategyResponse.repeatedFields_, null);
261
+ };
262
+ goog.inherits(proto.trb.strategysearch.v1.ValidateStrategyResponse, jspb.Message);
263
+ if (goog.DEBUG && !COMPILED) {
264
+ /**
265
+ * @public
266
+ * @override
267
+ */
268
+ proto.trb.strategysearch.v1.ValidateStrategyResponse.displayName = 'proto.trb.strategysearch.v1.ValidateStrategyResponse';
269
+ }
270
+
271
+
272
+
273
+ if (jspb.Message.GENERATE_TO_OBJECT) {
274
+ /**
275
+ * Creates an object representation of this proto.
276
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
277
+ * Optional fields that are not set will be set to undefined.
278
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
279
+ * For the list of reserved names please see:
280
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
281
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
282
+ * JSPB instance for transitional soy proto support:
283
+ * http://goto/soy-param-migration
284
+ * @return {!Object}
285
+ */
286
+ proto.trb.strategysearch.v1.Strategy.prototype.toObject = function(opt_includeInstance) {
287
+ return proto.trb.strategysearch.v1.Strategy.toObject(opt_includeInstance, this);
288
+ };
289
+
290
+
291
+ /**
292
+ * Static version of the {@see toObject} method.
293
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
294
+ * the JSPB instance for transitional soy proto support:
295
+ * http://goto/soy-param-migration
296
+ * @param {!proto.trb.strategysearch.v1.Strategy} msg The msg instance to transform.
297
+ * @return {!Object}
298
+ * @suppress {unusedLocalVariables} f is only used for nested messages
299
+ */
300
+ proto.trb.strategysearch.v1.Strategy.toObject = function(includeInstance, msg) {
301
+ var f, obj = {
302
+ id: jspb.Message.getFieldWithDefault(msg, 1, ""),
303
+ name: jspb.Message.getFieldWithDefault(msg, 2, ""),
304
+ description: jspb.Message.getFieldWithDefault(msg, 3, ""),
305
+ spec: (f = msg.getSpec()) && strategysearch_spec_pb.StrategySearchSpec.toObject(includeInstance, f),
306
+ specHash: jspb.Message.getFieldWithDefault(msg, 5, 0),
307
+ specVersion: jspb.Message.getFieldWithDefault(msg, 6, 0),
308
+ archived: jspb.Message.getBooleanFieldWithDefault(msg, 7, false),
309
+ createdAt: (f = msg.getCreatedAt()) && google_protobuf_timestamp_pb.Timestamp.toObject(includeInstance, f),
310
+ updatedAt: (f = msg.getUpdatedAt()) && google_protobuf_timestamp_pb.Timestamp.toObject(includeInstance, f)
311
+ };
312
+
313
+ if (includeInstance) {
314
+ obj.$jspbMessageInstance = msg;
315
+ }
316
+ return obj;
317
+ };
318
+ }
319
+
320
+
321
+ /**
322
+ * Deserializes binary data (in protobuf wire format).
323
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
324
+ * @return {!proto.trb.strategysearch.v1.Strategy}
325
+ */
326
+ proto.trb.strategysearch.v1.Strategy.deserializeBinary = function(bytes) {
327
+ var reader = new jspb.BinaryReader(bytes);
328
+ var msg = new proto.trb.strategysearch.v1.Strategy;
329
+ return proto.trb.strategysearch.v1.Strategy.deserializeBinaryFromReader(msg, reader);
330
+ };
331
+
332
+
333
+ /**
334
+ * Deserializes binary data (in protobuf wire format) from the
335
+ * given reader into the given message object.
336
+ * @param {!proto.trb.strategysearch.v1.Strategy} msg The message object to deserialize into.
337
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
338
+ * @return {!proto.trb.strategysearch.v1.Strategy}
339
+ */
340
+ proto.trb.strategysearch.v1.Strategy.deserializeBinaryFromReader = function(msg, reader) {
341
+ while (reader.nextField()) {
342
+ if (reader.isEndGroup()) {
343
+ break;
344
+ }
345
+ var field = reader.getFieldNumber();
346
+ switch (field) {
347
+ case 1:
348
+ var value = /** @type {string} */ (reader.readString());
349
+ msg.setId(value);
350
+ break;
351
+ case 2:
352
+ var value = /** @type {string} */ (reader.readString());
353
+ msg.setName(value);
354
+ break;
355
+ case 3:
356
+ var value = /** @type {string} */ (reader.readString());
357
+ msg.setDescription(value);
358
+ break;
359
+ case 4:
360
+ var value = new strategysearch_spec_pb.StrategySearchSpec;
361
+ reader.readMessage(value,strategysearch_spec_pb.StrategySearchSpec.deserializeBinaryFromReader);
362
+ msg.setSpec(value);
363
+ break;
364
+ case 5:
365
+ var value = /** @type {number} */ (reader.readUint64());
366
+ msg.setSpecHash(value);
367
+ break;
368
+ case 6:
369
+ var value = /** @type {number} */ (reader.readInt32());
370
+ msg.setSpecVersion(value);
371
+ break;
372
+ case 7:
373
+ var value = /** @type {boolean} */ (reader.readBool());
374
+ msg.setArchived(value);
375
+ break;
376
+ case 8:
377
+ var value = new google_protobuf_timestamp_pb.Timestamp;
378
+ reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
379
+ msg.setCreatedAt(value);
380
+ break;
381
+ case 9:
382
+ var value = new google_protobuf_timestamp_pb.Timestamp;
383
+ reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
384
+ msg.setUpdatedAt(value);
385
+ break;
386
+ default:
387
+ reader.skipField();
388
+ break;
389
+ }
390
+ }
391
+ return msg;
392
+ };
393
+
394
+
395
+ /**
396
+ * Serializes the message to binary data (in protobuf wire format).
397
+ * @return {!Uint8Array}
398
+ */
399
+ proto.trb.strategysearch.v1.Strategy.prototype.serializeBinary = function() {
400
+ var writer = new jspb.BinaryWriter();
401
+ proto.trb.strategysearch.v1.Strategy.serializeBinaryToWriter(this, writer);
402
+ return writer.getResultBuffer();
403
+ };
404
+
405
+
406
+ /**
407
+ * Serializes the given message to binary data (in protobuf wire
408
+ * format), writing to the given BinaryWriter.
409
+ * @param {!proto.trb.strategysearch.v1.Strategy} message
410
+ * @param {!jspb.BinaryWriter} writer
411
+ * @suppress {unusedLocalVariables} f is only used for nested messages
412
+ */
413
+ proto.trb.strategysearch.v1.Strategy.serializeBinaryToWriter = function(message, writer) {
414
+ var f = undefined;
415
+ f = message.getId();
416
+ if (f.length > 0) {
417
+ writer.writeString(
418
+ 1,
419
+ f
420
+ );
421
+ }
422
+ f = message.getName();
423
+ if (f.length > 0) {
424
+ writer.writeString(
425
+ 2,
426
+ f
427
+ );
428
+ }
429
+ f = message.getDescription();
430
+ if (f.length > 0) {
431
+ writer.writeString(
432
+ 3,
433
+ f
434
+ );
435
+ }
436
+ f = message.getSpec();
437
+ if (f != null) {
438
+ writer.writeMessage(
439
+ 4,
440
+ f,
441
+ strategysearch_spec_pb.StrategySearchSpec.serializeBinaryToWriter
442
+ );
443
+ }
444
+ f = message.getSpecHash();
445
+ if (f !== 0) {
446
+ writer.writeUint64(
447
+ 5,
448
+ f
449
+ );
450
+ }
451
+ f = message.getSpecVersion();
452
+ if (f !== 0) {
453
+ writer.writeInt32(
454
+ 6,
455
+ f
456
+ );
457
+ }
458
+ f = message.getArchived();
459
+ if (f) {
460
+ writer.writeBool(
461
+ 7,
462
+ f
463
+ );
464
+ }
465
+ f = message.getCreatedAt();
466
+ if (f != null) {
467
+ writer.writeMessage(
468
+ 8,
469
+ f,
470
+ google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
471
+ );
472
+ }
473
+ f = message.getUpdatedAt();
474
+ if (f != null) {
475
+ writer.writeMessage(
476
+ 9,
477
+ f,
478
+ google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
479
+ );
480
+ }
481
+ };
482
+
483
+
484
+ /**
485
+ * optional string id = 1;
486
+ * @return {string}
487
+ */
488
+ proto.trb.strategysearch.v1.Strategy.prototype.getId = function() {
489
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
490
+ };
491
+
492
+
493
+ /**
494
+ * @param {string} value
495
+ * @return {!proto.trb.strategysearch.v1.Strategy} returns this
496
+ */
497
+ proto.trb.strategysearch.v1.Strategy.prototype.setId = function(value) {
498
+ return jspb.Message.setProto3StringField(this, 1, value);
499
+ };
500
+
501
+
502
+ /**
503
+ * optional string name = 2;
504
+ * @return {string}
505
+ */
506
+ proto.trb.strategysearch.v1.Strategy.prototype.getName = function() {
507
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
508
+ };
509
+
510
+
511
+ /**
512
+ * @param {string} value
513
+ * @return {!proto.trb.strategysearch.v1.Strategy} returns this
514
+ */
515
+ proto.trb.strategysearch.v1.Strategy.prototype.setName = function(value) {
516
+ return jspb.Message.setProto3StringField(this, 2, value);
517
+ };
518
+
519
+
520
+ /**
521
+ * optional string description = 3;
522
+ * @return {string}
523
+ */
524
+ proto.trb.strategysearch.v1.Strategy.prototype.getDescription = function() {
525
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
526
+ };
527
+
528
+
529
+ /**
530
+ * @param {string} value
531
+ * @return {!proto.trb.strategysearch.v1.Strategy} returns this
532
+ */
533
+ proto.trb.strategysearch.v1.Strategy.prototype.setDescription = function(value) {
534
+ return jspb.Message.setProto3StringField(this, 3, value);
535
+ };
536
+
537
+
538
+ /**
539
+ * optional StrategySearchSpec spec = 4;
540
+ * @return {?proto.trb.strategysearch.v1.StrategySearchSpec}
541
+ */
542
+ proto.trb.strategysearch.v1.Strategy.prototype.getSpec = function() {
543
+ return /** @type{?proto.trb.strategysearch.v1.StrategySearchSpec} */ (
544
+ jspb.Message.getWrapperField(this, strategysearch_spec_pb.StrategySearchSpec, 4));
545
+ };
546
+
547
+
548
+ /**
549
+ * @param {?proto.trb.strategysearch.v1.StrategySearchSpec|undefined} value
550
+ * @return {!proto.trb.strategysearch.v1.Strategy} returns this
551
+ */
552
+ proto.trb.strategysearch.v1.Strategy.prototype.setSpec = function(value) {
553
+ return jspb.Message.setWrapperField(this, 4, value);
554
+ };
555
+
556
+
557
+ /**
558
+ * Clears the message field making it undefined.
559
+ * @return {!proto.trb.strategysearch.v1.Strategy} returns this
560
+ */
561
+ proto.trb.strategysearch.v1.Strategy.prototype.clearSpec = function() {
562
+ return this.setSpec(undefined);
563
+ };
564
+
565
+
566
+ /**
567
+ * Returns whether this field is set.
568
+ * @return {boolean}
569
+ */
570
+ proto.trb.strategysearch.v1.Strategy.prototype.hasSpec = function() {
571
+ return jspb.Message.getField(this, 4) != null;
572
+ };
573
+
574
+
575
+ /**
576
+ * optional uint64 spec_hash = 5;
577
+ * @return {number}
578
+ */
579
+ proto.trb.strategysearch.v1.Strategy.prototype.getSpecHash = function() {
580
+ return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 5, 0));
581
+ };
582
+
583
+
584
+ /**
585
+ * @param {number} value
586
+ * @return {!proto.trb.strategysearch.v1.Strategy} returns this
587
+ */
588
+ proto.trb.strategysearch.v1.Strategy.prototype.setSpecHash = function(value) {
589
+ return jspb.Message.setProto3IntField(this, 5, value);
590
+ };
591
+
592
+
593
+ /**
594
+ * optional int32 spec_version = 6;
595
+ * @return {number}
596
+ */
597
+ proto.trb.strategysearch.v1.Strategy.prototype.getSpecVersion = function() {
598
+ return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 6, 0));
599
+ };
600
+
601
+
602
+ /**
603
+ * @param {number} value
604
+ * @return {!proto.trb.strategysearch.v1.Strategy} returns this
605
+ */
606
+ proto.trb.strategysearch.v1.Strategy.prototype.setSpecVersion = function(value) {
607
+ return jspb.Message.setProto3IntField(this, 6, value);
608
+ };
609
+
610
+
611
+ /**
612
+ * optional bool archived = 7;
613
+ * @return {boolean}
614
+ */
615
+ proto.trb.strategysearch.v1.Strategy.prototype.getArchived = function() {
616
+ return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 7, false));
617
+ };
618
+
619
+
620
+ /**
621
+ * @param {boolean} value
622
+ * @return {!proto.trb.strategysearch.v1.Strategy} returns this
623
+ */
624
+ proto.trb.strategysearch.v1.Strategy.prototype.setArchived = function(value) {
625
+ return jspb.Message.setProto3BooleanField(this, 7, value);
626
+ };
627
+
628
+
629
+ /**
630
+ * optional google.protobuf.Timestamp created_at = 8;
631
+ * @return {?proto.google.protobuf.Timestamp}
632
+ */
633
+ proto.trb.strategysearch.v1.Strategy.prototype.getCreatedAt = function() {
634
+ return /** @type{?proto.google.protobuf.Timestamp} */ (
635
+ jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 8));
636
+ };
637
+
638
+
639
+ /**
640
+ * @param {?proto.google.protobuf.Timestamp|undefined} value
641
+ * @return {!proto.trb.strategysearch.v1.Strategy} returns this
642
+ */
643
+ proto.trb.strategysearch.v1.Strategy.prototype.setCreatedAt = function(value) {
644
+ return jspb.Message.setWrapperField(this, 8, value);
645
+ };
646
+
647
+
648
+ /**
649
+ * Clears the message field making it undefined.
650
+ * @return {!proto.trb.strategysearch.v1.Strategy} returns this
651
+ */
652
+ proto.trb.strategysearch.v1.Strategy.prototype.clearCreatedAt = function() {
653
+ return this.setCreatedAt(undefined);
654
+ };
655
+
656
+
657
+ /**
658
+ * Returns whether this field is set.
659
+ * @return {boolean}
660
+ */
661
+ proto.trb.strategysearch.v1.Strategy.prototype.hasCreatedAt = function() {
662
+ return jspb.Message.getField(this, 8) != null;
663
+ };
664
+
665
+
666
+ /**
667
+ * optional google.protobuf.Timestamp updated_at = 9;
668
+ * @return {?proto.google.protobuf.Timestamp}
669
+ */
670
+ proto.trb.strategysearch.v1.Strategy.prototype.getUpdatedAt = function() {
671
+ return /** @type{?proto.google.protobuf.Timestamp} */ (
672
+ jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 9));
673
+ };
674
+
675
+
676
+ /**
677
+ * @param {?proto.google.protobuf.Timestamp|undefined} value
678
+ * @return {!proto.trb.strategysearch.v1.Strategy} returns this
679
+ */
680
+ proto.trb.strategysearch.v1.Strategy.prototype.setUpdatedAt = function(value) {
681
+ return jspb.Message.setWrapperField(this, 9, value);
682
+ };
683
+
684
+
685
+ /**
686
+ * Clears the message field making it undefined.
687
+ * @return {!proto.trb.strategysearch.v1.Strategy} returns this
688
+ */
689
+ proto.trb.strategysearch.v1.Strategy.prototype.clearUpdatedAt = function() {
690
+ return this.setUpdatedAt(undefined);
691
+ };
692
+
693
+
694
+ /**
695
+ * Returns whether this field is set.
696
+ * @return {boolean}
697
+ */
698
+ proto.trb.strategysearch.v1.Strategy.prototype.hasUpdatedAt = function() {
699
+ return jspb.Message.getField(this, 9) != null;
700
+ };
701
+
702
+
703
+
704
+
705
+
706
+ if (jspb.Message.GENERATE_TO_OBJECT) {
707
+ /**
708
+ * Creates an object representation of this proto.
709
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
710
+ * Optional fields that are not set will be set to undefined.
711
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
712
+ * For the list of reserved names please see:
713
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
714
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
715
+ * JSPB instance for transitional soy proto support:
716
+ * http://goto/soy-param-migration
717
+ * @return {!Object}
718
+ */
719
+ proto.trb.strategysearch.v1.CreateStrategyRequest.prototype.toObject = function(opt_includeInstance) {
720
+ return proto.trb.strategysearch.v1.CreateStrategyRequest.toObject(opt_includeInstance, this);
721
+ };
722
+
723
+
724
+ /**
725
+ * Static version of the {@see toObject} method.
726
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
727
+ * the JSPB instance for transitional soy proto support:
728
+ * http://goto/soy-param-migration
729
+ * @param {!proto.trb.strategysearch.v1.CreateStrategyRequest} msg The msg instance to transform.
730
+ * @return {!Object}
731
+ * @suppress {unusedLocalVariables} f is only used for nested messages
732
+ */
733
+ proto.trb.strategysearch.v1.CreateStrategyRequest.toObject = function(includeInstance, msg) {
734
+ var f, obj = {
735
+ name: jspb.Message.getFieldWithDefault(msg, 1, ""),
736
+ description: jspb.Message.getFieldWithDefault(msg, 2, ""),
737
+ spec: (f = msg.getSpec()) && strategysearch_spec_pb.StrategySearchSpec.toObject(includeInstance, f)
738
+ };
739
+
740
+ if (includeInstance) {
741
+ obj.$jspbMessageInstance = msg;
742
+ }
743
+ return obj;
744
+ };
745
+ }
746
+
747
+
748
+ /**
749
+ * Deserializes binary data (in protobuf wire format).
750
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
751
+ * @return {!proto.trb.strategysearch.v1.CreateStrategyRequest}
752
+ */
753
+ proto.trb.strategysearch.v1.CreateStrategyRequest.deserializeBinary = function(bytes) {
754
+ var reader = new jspb.BinaryReader(bytes);
755
+ var msg = new proto.trb.strategysearch.v1.CreateStrategyRequest;
756
+ return proto.trb.strategysearch.v1.CreateStrategyRequest.deserializeBinaryFromReader(msg, reader);
757
+ };
758
+
759
+
760
+ /**
761
+ * Deserializes binary data (in protobuf wire format) from the
762
+ * given reader into the given message object.
763
+ * @param {!proto.trb.strategysearch.v1.CreateStrategyRequest} msg The message object to deserialize into.
764
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
765
+ * @return {!proto.trb.strategysearch.v1.CreateStrategyRequest}
766
+ */
767
+ proto.trb.strategysearch.v1.CreateStrategyRequest.deserializeBinaryFromReader = function(msg, reader) {
768
+ while (reader.nextField()) {
769
+ if (reader.isEndGroup()) {
770
+ break;
771
+ }
772
+ var field = reader.getFieldNumber();
773
+ switch (field) {
774
+ case 1:
775
+ var value = /** @type {string} */ (reader.readString());
776
+ msg.setName(value);
777
+ break;
778
+ case 2:
779
+ var value = /** @type {string} */ (reader.readString());
780
+ msg.setDescription(value);
781
+ break;
782
+ case 3:
783
+ var value = new strategysearch_spec_pb.StrategySearchSpec;
784
+ reader.readMessage(value,strategysearch_spec_pb.StrategySearchSpec.deserializeBinaryFromReader);
785
+ msg.setSpec(value);
786
+ break;
787
+ default:
788
+ reader.skipField();
789
+ break;
790
+ }
791
+ }
792
+ return msg;
793
+ };
794
+
795
+
796
+ /**
797
+ * Serializes the message to binary data (in protobuf wire format).
798
+ * @return {!Uint8Array}
799
+ */
800
+ proto.trb.strategysearch.v1.CreateStrategyRequest.prototype.serializeBinary = function() {
801
+ var writer = new jspb.BinaryWriter();
802
+ proto.trb.strategysearch.v1.CreateStrategyRequest.serializeBinaryToWriter(this, writer);
803
+ return writer.getResultBuffer();
804
+ };
805
+
806
+
807
+ /**
808
+ * Serializes the given message to binary data (in protobuf wire
809
+ * format), writing to the given BinaryWriter.
810
+ * @param {!proto.trb.strategysearch.v1.CreateStrategyRequest} message
811
+ * @param {!jspb.BinaryWriter} writer
812
+ * @suppress {unusedLocalVariables} f is only used for nested messages
813
+ */
814
+ proto.trb.strategysearch.v1.CreateStrategyRequest.serializeBinaryToWriter = function(message, writer) {
815
+ var f = undefined;
816
+ f = message.getName();
817
+ if (f.length > 0) {
818
+ writer.writeString(
819
+ 1,
820
+ f
821
+ );
822
+ }
823
+ f = message.getDescription();
824
+ if (f.length > 0) {
825
+ writer.writeString(
826
+ 2,
827
+ f
828
+ );
829
+ }
830
+ f = message.getSpec();
831
+ if (f != null) {
832
+ writer.writeMessage(
833
+ 3,
834
+ f,
835
+ strategysearch_spec_pb.StrategySearchSpec.serializeBinaryToWriter
836
+ );
837
+ }
838
+ };
839
+
840
+
841
+ /**
842
+ * optional string name = 1;
843
+ * @return {string}
844
+ */
845
+ proto.trb.strategysearch.v1.CreateStrategyRequest.prototype.getName = function() {
846
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
847
+ };
848
+
849
+
850
+ /**
851
+ * @param {string} value
852
+ * @return {!proto.trb.strategysearch.v1.CreateStrategyRequest} returns this
853
+ */
854
+ proto.trb.strategysearch.v1.CreateStrategyRequest.prototype.setName = function(value) {
855
+ return jspb.Message.setProto3StringField(this, 1, value);
856
+ };
857
+
858
+
859
+ /**
860
+ * optional string description = 2;
861
+ * @return {string}
862
+ */
863
+ proto.trb.strategysearch.v1.CreateStrategyRequest.prototype.getDescription = function() {
864
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
865
+ };
866
+
867
+
868
+ /**
869
+ * @param {string} value
870
+ * @return {!proto.trb.strategysearch.v1.CreateStrategyRequest} returns this
871
+ */
872
+ proto.trb.strategysearch.v1.CreateStrategyRequest.prototype.setDescription = function(value) {
873
+ return jspb.Message.setProto3StringField(this, 2, value);
874
+ };
875
+
876
+
877
+ /**
878
+ * optional StrategySearchSpec spec = 3;
879
+ * @return {?proto.trb.strategysearch.v1.StrategySearchSpec}
880
+ */
881
+ proto.trb.strategysearch.v1.CreateStrategyRequest.prototype.getSpec = function() {
882
+ return /** @type{?proto.trb.strategysearch.v1.StrategySearchSpec} */ (
883
+ jspb.Message.getWrapperField(this, strategysearch_spec_pb.StrategySearchSpec, 3));
884
+ };
885
+
886
+
887
+ /**
888
+ * @param {?proto.trb.strategysearch.v1.StrategySearchSpec|undefined} value
889
+ * @return {!proto.trb.strategysearch.v1.CreateStrategyRequest} returns this
890
+ */
891
+ proto.trb.strategysearch.v1.CreateStrategyRequest.prototype.setSpec = function(value) {
892
+ return jspb.Message.setWrapperField(this, 3, value);
893
+ };
894
+
895
+
896
+ /**
897
+ * Clears the message field making it undefined.
898
+ * @return {!proto.trb.strategysearch.v1.CreateStrategyRequest} returns this
899
+ */
900
+ proto.trb.strategysearch.v1.CreateStrategyRequest.prototype.clearSpec = function() {
901
+ return this.setSpec(undefined);
902
+ };
903
+
904
+
905
+ /**
906
+ * Returns whether this field is set.
907
+ * @return {boolean}
908
+ */
909
+ proto.trb.strategysearch.v1.CreateStrategyRequest.prototype.hasSpec = function() {
910
+ return jspb.Message.getField(this, 3) != null;
911
+ };
912
+
913
+
914
+
915
+
916
+
917
+ if (jspb.Message.GENERATE_TO_OBJECT) {
918
+ /**
919
+ * Creates an object representation of this proto.
920
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
921
+ * Optional fields that are not set will be set to undefined.
922
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
923
+ * For the list of reserved names please see:
924
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
925
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
926
+ * JSPB instance for transitional soy proto support:
927
+ * http://goto/soy-param-migration
928
+ * @return {!Object}
929
+ */
930
+ proto.trb.strategysearch.v1.GetStrategyRequest.prototype.toObject = function(opt_includeInstance) {
931
+ return proto.trb.strategysearch.v1.GetStrategyRequest.toObject(opt_includeInstance, this);
932
+ };
933
+
934
+
935
+ /**
936
+ * Static version of the {@see toObject} method.
937
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
938
+ * the JSPB instance for transitional soy proto support:
939
+ * http://goto/soy-param-migration
940
+ * @param {!proto.trb.strategysearch.v1.GetStrategyRequest} msg The msg instance to transform.
941
+ * @return {!Object}
942
+ * @suppress {unusedLocalVariables} f is only used for nested messages
943
+ */
944
+ proto.trb.strategysearch.v1.GetStrategyRequest.toObject = function(includeInstance, msg) {
945
+ var f, obj = {
946
+ id: jspb.Message.getFieldWithDefault(msg, 1, "")
947
+ };
948
+
949
+ if (includeInstance) {
950
+ obj.$jspbMessageInstance = msg;
951
+ }
952
+ return obj;
953
+ };
954
+ }
955
+
956
+
957
+ /**
958
+ * Deserializes binary data (in protobuf wire format).
959
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
960
+ * @return {!proto.trb.strategysearch.v1.GetStrategyRequest}
961
+ */
962
+ proto.trb.strategysearch.v1.GetStrategyRequest.deserializeBinary = function(bytes) {
963
+ var reader = new jspb.BinaryReader(bytes);
964
+ var msg = new proto.trb.strategysearch.v1.GetStrategyRequest;
965
+ return proto.trb.strategysearch.v1.GetStrategyRequest.deserializeBinaryFromReader(msg, reader);
966
+ };
967
+
968
+
969
+ /**
970
+ * Deserializes binary data (in protobuf wire format) from the
971
+ * given reader into the given message object.
972
+ * @param {!proto.trb.strategysearch.v1.GetStrategyRequest} msg The message object to deserialize into.
973
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
974
+ * @return {!proto.trb.strategysearch.v1.GetStrategyRequest}
975
+ */
976
+ proto.trb.strategysearch.v1.GetStrategyRequest.deserializeBinaryFromReader = function(msg, reader) {
977
+ while (reader.nextField()) {
978
+ if (reader.isEndGroup()) {
979
+ break;
980
+ }
981
+ var field = reader.getFieldNumber();
982
+ switch (field) {
983
+ case 1:
984
+ var value = /** @type {string} */ (reader.readString());
985
+ msg.setId(value);
986
+ break;
987
+ default:
988
+ reader.skipField();
989
+ break;
990
+ }
991
+ }
992
+ return msg;
993
+ };
994
+
995
+
996
+ /**
997
+ * Serializes the message to binary data (in protobuf wire format).
998
+ * @return {!Uint8Array}
999
+ */
1000
+ proto.trb.strategysearch.v1.GetStrategyRequest.prototype.serializeBinary = function() {
1001
+ var writer = new jspb.BinaryWriter();
1002
+ proto.trb.strategysearch.v1.GetStrategyRequest.serializeBinaryToWriter(this, writer);
1003
+ return writer.getResultBuffer();
1004
+ };
1005
+
1006
+
1007
+ /**
1008
+ * Serializes the given message to binary data (in protobuf wire
1009
+ * format), writing to the given BinaryWriter.
1010
+ * @param {!proto.trb.strategysearch.v1.GetStrategyRequest} message
1011
+ * @param {!jspb.BinaryWriter} writer
1012
+ * @suppress {unusedLocalVariables} f is only used for nested messages
1013
+ */
1014
+ proto.trb.strategysearch.v1.GetStrategyRequest.serializeBinaryToWriter = function(message, writer) {
1015
+ var f = undefined;
1016
+ f = message.getId();
1017
+ if (f.length > 0) {
1018
+ writer.writeString(
1019
+ 1,
1020
+ f
1021
+ );
1022
+ }
1023
+ };
1024
+
1025
+
1026
+ /**
1027
+ * optional string id = 1;
1028
+ * @return {string}
1029
+ */
1030
+ proto.trb.strategysearch.v1.GetStrategyRequest.prototype.getId = function() {
1031
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
1032
+ };
1033
+
1034
+
1035
+ /**
1036
+ * @param {string} value
1037
+ * @return {!proto.trb.strategysearch.v1.GetStrategyRequest} returns this
1038
+ */
1039
+ proto.trb.strategysearch.v1.GetStrategyRequest.prototype.setId = function(value) {
1040
+ return jspb.Message.setProto3StringField(this, 1, value);
1041
+ };
1042
+
1043
+
1044
+
1045
+
1046
+
1047
+ if (jspb.Message.GENERATE_TO_OBJECT) {
1048
+ /**
1049
+ * Creates an object representation of this proto.
1050
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
1051
+ * Optional fields that are not set will be set to undefined.
1052
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
1053
+ * For the list of reserved names please see:
1054
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
1055
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
1056
+ * JSPB instance for transitional soy proto support:
1057
+ * http://goto/soy-param-migration
1058
+ * @return {!Object}
1059
+ */
1060
+ proto.trb.strategysearch.v1.ListStrategiesRequest.prototype.toObject = function(opt_includeInstance) {
1061
+ return proto.trb.strategysearch.v1.ListStrategiesRequest.toObject(opt_includeInstance, this);
1062
+ };
1063
+
1064
+
1065
+ /**
1066
+ * Static version of the {@see toObject} method.
1067
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
1068
+ * the JSPB instance for transitional soy proto support:
1069
+ * http://goto/soy-param-migration
1070
+ * @param {!proto.trb.strategysearch.v1.ListStrategiesRequest} msg The msg instance to transform.
1071
+ * @return {!Object}
1072
+ * @suppress {unusedLocalVariables} f is only used for nested messages
1073
+ */
1074
+ proto.trb.strategysearch.v1.ListStrategiesRequest.toObject = function(includeInstance, msg) {
1075
+ var f, obj = {
1076
+ q: jspb.Message.getFieldWithDefault(msg, 1, ""),
1077
+ includeArchived: jspb.Message.getBooleanFieldWithDefault(msg, 2, false),
1078
+ limit: jspb.Message.getFieldWithDefault(msg, 3, 0),
1079
+ offset: jspb.Message.getFieldWithDefault(msg, 4, 0)
1080
+ };
1081
+
1082
+ if (includeInstance) {
1083
+ obj.$jspbMessageInstance = msg;
1084
+ }
1085
+ return obj;
1086
+ };
1087
+ }
1088
+
1089
+
1090
+ /**
1091
+ * Deserializes binary data (in protobuf wire format).
1092
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
1093
+ * @return {!proto.trb.strategysearch.v1.ListStrategiesRequest}
1094
+ */
1095
+ proto.trb.strategysearch.v1.ListStrategiesRequest.deserializeBinary = function(bytes) {
1096
+ var reader = new jspb.BinaryReader(bytes);
1097
+ var msg = new proto.trb.strategysearch.v1.ListStrategiesRequest;
1098
+ return proto.trb.strategysearch.v1.ListStrategiesRequest.deserializeBinaryFromReader(msg, reader);
1099
+ };
1100
+
1101
+
1102
+ /**
1103
+ * Deserializes binary data (in protobuf wire format) from the
1104
+ * given reader into the given message object.
1105
+ * @param {!proto.trb.strategysearch.v1.ListStrategiesRequest} msg The message object to deserialize into.
1106
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
1107
+ * @return {!proto.trb.strategysearch.v1.ListStrategiesRequest}
1108
+ */
1109
+ proto.trb.strategysearch.v1.ListStrategiesRequest.deserializeBinaryFromReader = function(msg, reader) {
1110
+ while (reader.nextField()) {
1111
+ if (reader.isEndGroup()) {
1112
+ break;
1113
+ }
1114
+ var field = reader.getFieldNumber();
1115
+ switch (field) {
1116
+ case 1:
1117
+ var value = /** @type {string} */ (reader.readString());
1118
+ msg.setQ(value);
1119
+ break;
1120
+ case 2:
1121
+ var value = /** @type {boolean} */ (reader.readBool());
1122
+ msg.setIncludeArchived(value);
1123
+ break;
1124
+ case 3:
1125
+ var value = /** @type {number} */ (reader.readInt32());
1126
+ msg.setLimit(value);
1127
+ break;
1128
+ case 4:
1129
+ var value = /** @type {number} */ (reader.readInt32());
1130
+ msg.setOffset(value);
1131
+ break;
1132
+ default:
1133
+ reader.skipField();
1134
+ break;
1135
+ }
1136
+ }
1137
+ return msg;
1138
+ };
1139
+
1140
+
1141
+ /**
1142
+ * Serializes the message to binary data (in protobuf wire format).
1143
+ * @return {!Uint8Array}
1144
+ */
1145
+ proto.trb.strategysearch.v1.ListStrategiesRequest.prototype.serializeBinary = function() {
1146
+ var writer = new jspb.BinaryWriter();
1147
+ proto.trb.strategysearch.v1.ListStrategiesRequest.serializeBinaryToWriter(this, writer);
1148
+ return writer.getResultBuffer();
1149
+ };
1150
+
1151
+
1152
+ /**
1153
+ * Serializes the given message to binary data (in protobuf wire
1154
+ * format), writing to the given BinaryWriter.
1155
+ * @param {!proto.trb.strategysearch.v1.ListStrategiesRequest} message
1156
+ * @param {!jspb.BinaryWriter} writer
1157
+ * @suppress {unusedLocalVariables} f is only used for nested messages
1158
+ */
1159
+ proto.trb.strategysearch.v1.ListStrategiesRequest.serializeBinaryToWriter = function(message, writer) {
1160
+ var f = undefined;
1161
+ f = message.getQ();
1162
+ if (f.length > 0) {
1163
+ writer.writeString(
1164
+ 1,
1165
+ f
1166
+ );
1167
+ }
1168
+ f = message.getIncludeArchived();
1169
+ if (f) {
1170
+ writer.writeBool(
1171
+ 2,
1172
+ f
1173
+ );
1174
+ }
1175
+ f = message.getLimit();
1176
+ if (f !== 0) {
1177
+ writer.writeInt32(
1178
+ 3,
1179
+ f
1180
+ );
1181
+ }
1182
+ f = message.getOffset();
1183
+ if (f !== 0) {
1184
+ writer.writeInt32(
1185
+ 4,
1186
+ f
1187
+ );
1188
+ }
1189
+ };
1190
+
1191
+
1192
+ /**
1193
+ * optional string q = 1;
1194
+ * @return {string}
1195
+ */
1196
+ proto.trb.strategysearch.v1.ListStrategiesRequest.prototype.getQ = function() {
1197
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
1198
+ };
1199
+
1200
+
1201
+ /**
1202
+ * @param {string} value
1203
+ * @return {!proto.trb.strategysearch.v1.ListStrategiesRequest} returns this
1204
+ */
1205
+ proto.trb.strategysearch.v1.ListStrategiesRequest.prototype.setQ = function(value) {
1206
+ return jspb.Message.setProto3StringField(this, 1, value);
1207
+ };
1208
+
1209
+
1210
+ /**
1211
+ * optional bool include_archived = 2;
1212
+ * @return {boolean}
1213
+ */
1214
+ proto.trb.strategysearch.v1.ListStrategiesRequest.prototype.getIncludeArchived = function() {
1215
+ return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 2, false));
1216
+ };
1217
+
1218
+
1219
+ /**
1220
+ * @param {boolean} value
1221
+ * @return {!proto.trb.strategysearch.v1.ListStrategiesRequest} returns this
1222
+ */
1223
+ proto.trb.strategysearch.v1.ListStrategiesRequest.prototype.setIncludeArchived = function(value) {
1224
+ return jspb.Message.setProto3BooleanField(this, 2, value);
1225
+ };
1226
+
1227
+
1228
+ /**
1229
+ * optional int32 limit = 3;
1230
+ * @return {number}
1231
+ */
1232
+ proto.trb.strategysearch.v1.ListStrategiesRequest.prototype.getLimit = function() {
1233
+ return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 3, 0));
1234
+ };
1235
+
1236
+
1237
+ /**
1238
+ * @param {number} value
1239
+ * @return {!proto.trb.strategysearch.v1.ListStrategiesRequest} returns this
1240
+ */
1241
+ proto.trb.strategysearch.v1.ListStrategiesRequest.prototype.setLimit = function(value) {
1242
+ return jspb.Message.setProto3IntField(this, 3, value);
1243
+ };
1244
+
1245
+
1246
+ /**
1247
+ * optional int32 offset = 4;
1248
+ * @return {number}
1249
+ */
1250
+ proto.trb.strategysearch.v1.ListStrategiesRequest.prototype.getOffset = function() {
1251
+ return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 4, 0));
1252
+ };
1253
+
1254
+
1255
+ /**
1256
+ * @param {number} value
1257
+ * @return {!proto.trb.strategysearch.v1.ListStrategiesRequest} returns this
1258
+ */
1259
+ proto.trb.strategysearch.v1.ListStrategiesRequest.prototype.setOffset = function(value) {
1260
+ return jspb.Message.setProto3IntField(this, 4, value);
1261
+ };
1262
+
1263
+
1264
+
1265
+ /**
1266
+ * List of repeated fields within this message type.
1267
+ * @private {!Array<number>}
1268
+ * @const
1269
+ */
1270
+ proto.trb.strategysearch.v1.ListStrategiesResponse.repeatedFields_ = [1];
1271
+
1272
+
1273
+
1274
+ if (jspb.Message.GENERATE_TO_OBJECT) {
1275
+ /**
1276
+ * Creates an object representation of this proto.
1277
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
1278
+ * Optional fields that are not set will be set to undefined.
1279
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
1280
+ * For the list of reserved names please see:
1281
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
1282
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
1283
+ * JSPB instance for transitional soy proto support:
1284
+ * http://goto/soy-param-migration
1285
+ * @return {!Object}
1286
+ */
1287
+ proto.trb.strategysearch.v1.ListStrategiesResponse.prototype.toObject = function(opt_includeInstance) {
1288
+ return proto.trb.strategysearch.v1.ListStrategiesResponse.toObject(opt_includeInstance, this);
1289
+ };
1290
+
1291
+
1292
+ /**
1293
+ * Static version of the {@see toObject} method.
1294
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
1295
+ * the JSPB instance for transitional soy proto support:
1296
+ * http://goto/soy-param-migration
1297
+ * @param {!proto.trb.strategysearch.v1.ListStrategiesResponse} msg The msg instance to transform.
1298
+ * @return {!Object}
1299
+ * @suppress {unusedLocalVariables} f is only used for nested messages
1300
+ */
1301
+ proto.trb.strategysearch.v1.ListStrategiesResponse.toObject = function(includeInstance, msg) {
1302
+ var f, obj = {
1303
+ itemsList: jspb.Message.toObjectList(msg.getItemsList(),
1304
+ proto.trb.strategysearch.v1.Strategy.toObject, includeInstance),
1305
+ total: jspb.Message.getFieldWithDefault(msg, 2, 0)
1306
+ };
1307
+
1308
+ if (includeInstance) {
1309
+ obj.$jspbMessageInstance = msg;
1310
+ }
1311
+ return obj;
1312
+ };
1313
+ }
1314
+
1315
+
1316
+ /**
1317
+ * Deserializes binary data (in protobuf wire format).
1318
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
1319
+ * @return {!proto.trb.strategysearch.v1.ListStrategiesResponse}
1320
+ */
1321
+ proto.trb.strategysearch.v1.ListStrategiesResponse.deserializeBinary = function(bytes) {
1322
+ var reader = new jspb.BinaryReader(bytes);
1323
+ var msg = new proto.trb.strategysearch.v1.ListStrategiesResponse;
1324
+ return proto.trb.strategysearch.v1.ListStrategiesResponse.deserializeBinaryFromReader(msg, reader);
1325
+ };
1326
+
1327
+
1328
+ /**
1329
+ * Deserializes binary data (in protobuf wire format) from the
1330
+ * given reader into the given message object.
1331
+ * @param {!proto.trb.strategysearch.v1.ListStrategiesResponse} msg The message object to deserialize into.
1332
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
1333
+ * @return {!proto.trb.strategysearch.v1.ListStrategiesResponse}
1334
+ */
1335
+ proto.trb.strategysearch.v1.ListStrategiesResponse.deserializeBinaryFromReader = function(msg, reader) {
1336
+ while (reader.nextField()) {
1337
+ if (reader.isEndGroup()) {
1338
+ break;
1339
+ }
1340
+ var field = reader.getFieldNumber();
1341
+ switch (field) {
1342
+ case 1:
1343
+ var value = new proto.trb.strategysearch.v1.Strategy;
1344
+ reader.readMessage(value,proto.trb.strategysearch.v1.Strategy.deserializeBinaryFromReader);
1345
+ msg.addItems(value);
1346
+ break;
1347
+ case 2:
1348
+ var value = /** @type {number} */ (reader.readInt32());
1349
+ msg.setTotal(value);
1350
+ break;
1351
+ default:
1352
+ reader.skipField();
1353
+ break;
1354
+ }
1355
+ }
1356
+ return msg;
1357
+ };
1358
+
1359
+
1360
+ /**
1361
+ * Serializes the message to binary data (in protobuf wire format).
1362
+ * @return {!Uint8Array}
1363
+ */
1364
+ proto.trb.strategysearch.v1.ListStrategiesResponse.prototype.serializeBinary = function() {
1365
+ var writer = new jspb.BinaryWriter();
1366
+ proto.trb.strategysearch.v1.ListStrategiesResponse.serializeBinaryToWriter(this, writer);
1367
+ return writer.getResultBuffer();
1368
+ };
1369
+
1370
+
1371
+ /**
1372
+ * Serializes the given message to binary data (in protobuf wire
1373
+ * format), writing to the given BinaryWriter.
1374
+ * @param {!proto.trb.strategysearch.v1.ListStrategiesResponse} message
1375
+ * @param {!jspb.BinaryWriter} writer
1376
+ * @suppress {unusedLocalVariables} f is only used for nested messages
1377
+ */
1378
+ proto.trb.strategysearch.v1.ListStrategiesResponse.serializeBinaryToWriter = function(message, writer) {
1379
+ var f = undefined;
1380
+ f = message.getItemsList();
1381
+ if (f.length > 0) {
1382
+ writer.writeRepeatedMessage(
1383
+ 1,
1384
+ f,
1385
+ proto.trb.strategysearch.v1.Strategy.serializeBinaryToWriter
1386
+ );
1387
+ }
1388
+ f = message.getTotal();
1389
+ if (f !== 0) {
1390
+ writer.writeInt32(
1391
+ 2,
1392
+ f
1393
+ );
1394
+ }
1395
+ };
1396
+
1397
+
1398
+ /**
1399
+ * repeated Strategy items = 1;
1400
+ * @return {!Array<!proto.trb.strategysearch.v1.Strategy>}
1401
+ */
1402
+ proto.trb.strategysearch.v1.ListStrategiesResponse.prototype.getItemsList = function() {
1403
+ return /** @type{!Array<!proto.trb.strategysearch.v1.Strategy>} */ (
1404
+ jspb.Message.getRepeatedWrapperField(this, proto.trb.strategysearch.v1.Strategy, 1));
1405
+ };
1406
+
1407
+
1408
+ /**
1409
+ * @param {!Array<!proto.trb.strategysearch.v1.Strategy>} value
1410
+ * @return {!proto.trb.strategysearch.v1.ListStrategiesResponse} returns this
1411
+ */
1412
+ proto.trb.strategysearch.v1.ListStrategiesResponse.prototype.setItemsList = function(value) {
1413
+ return jspb.Message.setRepeatedWrapperField(this, 1, value);
1414
+ };
1415
+
1416
+
1417
+ /**
1418
+ * @param {!proto.trb.strategysearch.v1.Strategy=} opt_value
1419
+ * @param {number=} opt_index
1420
+ * @return {!proto.trb.strategysearch.v1.Strategy}
1421
+ */
1422
+ proto.trb.strategysearch.v1.ListStrategiesResponse.prototype.addItems = function(opt_value, opt_index) {
1423
+ return jspb.Message.addToRepeatedWrapperField(this, 1, opt_value, proto.trb.strategysearch.v1.Strategy, opt_index);
1424
+ };
1425
+
1426
+
1427
+ /**
1428
+ * Clears the list making it empty but non-null.
1429
+ * @return {!proto.trb.strategysearch.v1.ListStrategiesResponse} returns this
1430
+ */
1431
+ proto.trb.strategysearch.v1.ListStrategiesResponse.prototype.clearItemsList = function() {
1432
+ return this.setItemsList([]);
1433
+ };
1434
+
1435
+
1436
+ /**
1437
+ * optional int32 total = 2;
1438
+ * @return {number}
1439
+ */
1440
+ proto.trb.strategysearch.v1.ListStrategiesResponse.prototype.getTotal = function() {
1441
+ return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 2, 0));
1442
+ };
1443
+
1444
+
1445
+ /**
1446
+ * @param {number} value
1447
+ * @return {!proto.trb.strategysearch.v1.ListStrategiesResponse} returns this
1448
+ */
1449
+ proto.trb.strategysearch.v1.ListStrategiesResponse.prototype.setTotal = function(value) {
1450
+ return jspb.Message.setProto3IntField(this, 2, value);
1451
+ };
1452
+
1453
+
1454
+
1455
+
1456
+
1457
+ if (jspb.Message.GENERATE_TO_OBJECT) {
1458
+ /**
1459
+ * Creates an object representation of this proto.
1460
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
1461
+ * Optional fields that are not set will be set to undefined.
1462
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
1463
+ * For the list of reserved names please see:
1464
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
1465
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
1466
+ * JSPB instance for transitional soy proto support:
1467
+ * http://goto/soy-param-migration
1468
+ * @return {!Object}
1469
+ */
1470
+ proto.trb.strategysearch.v1.UpdateStrategyRequest.prototype.toObject = function(opt_includeInstance) {
1471
+ return proto.trb.strategysearch.v1.UpdateStrategyRequest.toObject(opt_includeInstance, this);
1472
+ };
1473
+
1474
+
1475
+ /**
1476
+ * Static version of the {@see toObject} method.
1477
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
1478
+ * the JSPB instance for transitional soy proto support:
1479
+ * http://goto/soy-param-migration
1480
+ * @param {!proto.trb.strategysearch.v1.UpdateStrategyRequest} msg The msg instance to transform.
1481
+ * @return {!Object}
1482
+ * @suppress {unusedLocalVariables} f is only used for nested messages
1483
+ */
1484
+ proto.trb.strategysearch.v1.UpdateStrategyRequest.toObject = function(includeInstance, msg) {
1485
+ var f, obj = {
1486
+ id: jspb.Message.getFieldWithDefault(msg, 1, ""),
1487
+ name: jspb.Message.getFieldWithDefault(msg, 2, ""),
1488
+ description: jspb.Message.getFieldWithDefault(msg, 3, ""),
1489
+ spec: (f = msg.getSpec()) && strategysearch_spec_pb.StrategySearchSpec.toObject(includeInstance, f)
1490
+ };
1491
+
1492
+ if (includeInstance) {
1493
+ obj.$jspbMessageInstance = msg;
1494
+ }
1495
+ return obj;
1496
+ };
1497
+ }
1498
+
1499
+
1500
+ /**
1501
+ * Deserializes binary data (in protobuf wire format).
1502
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
1503
+ * @return {!proto.trb.strategysearch.v1.UpdateStrategyRequest}
1504
+ */
1505
+ proto.trb.strategysearch.v1.UpdateStrategyRequest.deserializeBinary = function(bytes) {
1506
+ var reader = new jspb.BinaryReader(bytes);
1507
+ var msg = new proto.trb.strategysearch.v1.UpdateStrategyRequest;
1508
+ return proto.trb.strategysearch.v1.UpdateStrategyRequest.deserializeBinaryFromReader(msg, reader);
1509
+ };
1510
+
1511
+
1512
+ /**
1513
+ * Deserializes binary data (in protobuf wire format) from the
1514
+ * given reader into the given message object.
1515
+ * @param {!proto.trb.strategysearch.v1.UpdateStrategyRequest} msg The message object to deserialize into.
1516
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
1517
+ * @return {!proto.trb.strategysearch.v1.UpdateStrategyRequest}
1518
+ */
1519
+ proto.trb.strategysearch.v1.UpdateStrategyRequest.deserializeBinaryFromReader = function(msg, reader) {
1520
+ while (reader.nextField()) {
1521
+ if (reader.isEndGroup()) {
1522
+ break;
1523
+ }
1524
+ var field = reader.getFieldNumber();
1525
+ switch (field) {
1526
+ case 1:
1527
+ var value = /** @type {string} */ (reader.readString());
1528
+ msg.setId(value);
1529
+ break;
1530
+ case 2:
1531
+ var value = /** @type {string} */ (reader.readString());
1532
+ msg.setName(value);
1533
+ break;
1534
+ case 3:
1535
+ var value = /** @type {string} */ (reader.readString());
1536
+ msg.setDescription(value);
1537
+ break;
1538
+ case 4:
1539
+ var value = new strategysearch_spec_pb.StrategySearchSpec;
1540
+ reader.readMessage(value,strategysearch_spec_pb.StrategySearchSpec.deserializeBinaryFromReader);
1541
+ msg.setSpec(value);
1542
+ break;
1543
+ default:
1544
+ reader.skipField();
1545
+ break;
1546
+ }
1547
+ }
1548
+ return msg;
1549
+ };
1550
+
1551
+
1552
+ /**
1553
+ * Serializes the message to binary data (in protobuf wire format).
1554
+ * @return {!Uint8Array}
1555
+ */
1556
+ proto.trb.strategysearch.v1.UpdateStrategyRequest.prototype.serializeBinary = function() {
1557
+ var writer = new jspb.BinaryWriter();
1558
+ proto.trb.strategysearch.v1.UpdateStrategyRequest.serializeBinaryToWriter(this, writer);
1559
+ return writer.getResultBuffer();
1560
+ };
1561
+
1562
+
1563
+ /**
1564
+ * Serializes the given message to binary data (in protobuf wire
1565
+ * format), writing to the given BinaryWriter.
1566
+ * @param {!proto.trb.strategysearch.v1.UpdateStrategyRequest} message
1567
+ * @param {!jspb.BinaryWriter} writer
1568
+ * @suppress {unusedLocalVariables} f is only used for nested messages
1569
+ */
1570
+ proto.trb.strategysearch.v1.UpdateStrategyRequest.serializeBinaryToWriter = function(message, writer) {
1571
+ var f = undefined;
1572
+ f = message.getId();
1573
+ if (f.length > 0) {
1574
+ writer.writeString(
1575
+ 1,
1576
+ f
1577
+ );
1578
+ }
1579
+ f = message.getName();
1580
+ if (f.length > 0) {
1581
+ writer.writeString(
1582
+ 2,
1583
+ f
1584
+ );
1585
+ }
1586
+ f = message.getDescription();
1587
+ if (f.length > 0) {
1588
+ writer.writeString(
1589
+ 3,
1590
+ f
1591
+ );
1592
+ }
1593
+ f = message.getSpec();
1594
+ if (f != null) {
1595
+ writer.writeMessage(
1596
+ 4,
1597
+ f,
1598
+ strategysearch_spec_pb.StrategySearchSpec.serializeBinaryToWriter
1599
+ );
1600
+ }
1601
+ };
1602
+
1603
+
1604
+ /**
1605
+ * optional string id = 1;
1606
+ * @return {string}
1607
+ */
1608
+ proto.trb.strategysearch.v1.UpdateStrategyRequest.prototype.getId = function() {
1609
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
1610
+ };
1611
+
1612
+
1613
+ /**
1614
+ * @param {string} value
1615
+ * @return {!proto.trb.strategysearch.v1.UpdateStrategyRequest} returns this
1616
+ */
1617
+ proto.trb.strategysearch.v1.UpdateStrategyRequest.prototype.setId = function(value) {
1618
+ return jspb.Message.setProto3StringField(this, 1, value);
1619
+ };
1620
+
1621
+
1622
+ /**
1623
+ * optional string name = 2;
1624
+ * @return {string}
1625
+ */
1626
+ proto.trb.strategysearch.v1.UpdateStrategyRequest.prototype.getName = function() {
1627
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
1628
+ };
1629
+
1630
+
1631
+ /**
1632
+ * @param {string} value
1633
+ * @return {!proto.trb.strategysearch.v1.UpdateStrategyRequest} returns this
1634
+ */
1635
+ proto.trb.strategysearch.v1.UpdateStrategyRequest.prototype.setName = function(value) {
1636
+ return jspb.Message.setProto3StringField(this, 2, value);
1637
+ };
1638
+
1639
+
1640
+ /**
1641
+ * optional string description = 3;
1642
+ * @return {string}
1643
+ */
1644
+ proto.trb.strategysearch.v1.UpdateStrategyRequest.prototype.getDescription = function() {
1645
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
1646
+ };
1647
+
1648
+
1649
+ /**
1650
+ * @param {string} value
1651
+ * @return {!proto.trb.strategysearch.v1.UpdateStrategyRequest} returns this
1652
+ */
1653
+ proto.trb.strategysearch.v1.UpdateStrategyRequest.prototype.setDescription = function(value) {
1654
+ return jspb.Message.setProto3StringField(this, 3, value);
1655
+ };
1656
+
1657
+
1658
+ /**
1659
+ * optional StrategySearchSpec spec = 4;
1660
+ * @return {?proto.trb.strategysearch.v1.StrategySearchSpec}
1661
+ */
1662
+ proto.trb.strategysearch.v1.UpdateStrategyRequest.prototype.getSpec = function() {
1663
+ return /** @type{?proto.trb.strategysearch.v1.StrategySearchSpec} */ (
1664
+ jspb.Message.getWrapperField(this, strategysearch_spec_pb.StrategySearchSpec, 4));
1665
+ };
1666
+
1667
+
1668
+ /**
1669
+ * @param {?proto.trb.strategysearch.v1.StrategySearchSpec|undefined} value
1670
+ * @return {!proto.trb.strategysearch.v1.UpdateStrategyRequest} returns this
1671
+ */
1672
+ proto.trb.strategysearch.v1.UpdateStrategyRequest.prototype.setSpec = function(value) {
1673
+ return jspb.Message.setWrapperField(this, 4, value);
1674
+ };
1675
+
1676
+
1677
+ /**
1678
+ * Clears the message field making it undefined.
1679
+ * @return {!proto.trb.strategysearch.v1.UpdateStrategyRequest} returns this
1680
+ */
1681
+ proto.trb.strategysearch.v1.UpdateStrategyRequest.prototype.clearSpec = function() {
1682
+ return this.setSpec(undefined);
1683
+ };
1684
+
1685
+
1686
+ /**
1687
+ * Returns whether this field is set.
1688
+ * @return {boolean}
1689
+ */
1690
+ proto.trb.strategysearch.v1.UpdateStrategyRequest.prototype.hasSpec = function() {
1691
+ return jspb.Message.getField(this, 4) != null;
1692
+ };
1693
+
1694
+
1695
+
1696
+
1697
+
1698
+ if (jspb.Message.GENERATE_TO_OBJECT) {
1699
+ /**
1700
+ * Creates an object representation of this proto.
1701
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
1702
+ * Optional fields that are not set will be set to undefined.
1703
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
1704
+ * For the list of reserved names please see:
1705
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
1706
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
1707
+ * JSPB instance for transitional soy proto support:
1708
+ * http://goto/soy-param-migration
1709
+ * @return {!Object}
1710
+ */
1711
+ proto.trb.strategysearch.v1.DeleteStrategyRequest.prototype.toObject = function(opt_includeInstance) {
1712
+ return proto.trb.strategysearch.v1.DeleteStrategyRequest.toObject(opt_includeInstance, this);
1713
+ };
1714
+
1715
+
1716
+ /**
1717
+ * Static version of the {@see toObject} method.
1718
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
1719
+ * the JSPB instance for transitional soy proto support:
1720
+ * http://goto/soy-param-migration
1721
+ * @param {!proto.trb.strategysearch.v1.DeleteStrategyRequest} msg The msg instance to transform.
1722
+ * @return {!Object}
1723
+ * @suppress {unusedLocalVariables} f is only used for nested messages
1724
+ */
1725
+ proto.trb.strategysearch.v1.DeleteStrategyRequest.toObject = function(includeInstance, msg) {
1726
+ var f, obj = {
1727
+ id: jspb.Message.getFieldWithDefault(msg, 1, "")
1728
+ };
1729
+
1730
+ if (includeInstance) {
1731
+ obj.$jspbMessageInstance = msg;
1732
+ }
1733
+ return obj;
1734
+ };
1735
+ }
1736
+
1737
+
1738
+ /**
1739
+ * Deserializes binary data (in protobuf wire format).
1740
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
1741
+ * @return {!proto.trb.strategysearch.v1.DeleteStrategyRequest}
1742
+ */
1743
+ proto.trb.strategysearch.v1.DeleteStrategyRequest.deserializeBinary = function(bytes) {
1744
+ var reader = new jspb.BinaryReader(bytes);
1745
+ var msg = new proto.trb.strategysearch.v1.DeleteStrategyRequest;
1746
+ return proto.trb.strategysearch.v1.DeleteStrategyRequest.deserializeBinaryFromReader(msg, reader);
1747
+ };
1748
+
1749
+
1750
+ /**
1751
+ * Deserializes binary data (in protobuf wire format) from the
1752
+ * given reader into the given message object.
1753
+ * @param {!proto.trb.strategysearch.v1.DeleteStrategyRequest} msg The message object to deserialize into.
1754
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
1755
+ * @return {!proto.trb.strategysearch.v1.DeleteStrategyRequest}
1756
+ */
1757
+ proto.trb.strategysearch.v1.DeleteStrategyRequest.deserializeBinaryFromReader = function(msg, reader) {
1758
+ while (reader.nextField()) {
1759
+ if (reader.isEndGroup()) {
1760
+ break;
1761
+ }
1762
+ var field = reader.getFieldNumber();
1763
+ switch (field) {
1764
+ case 1:
1765
+ var value = /** @type {string} */ (reader.readString());
1766
+ msg.setId(value);
1767
+ break;
1768
+ default:
1769
+ reader.skipField();
1770
+ break;
1771
+ }
1772
+ }
1773
+ return msg;
1774
+ };
1775
+
1776
+
1777
+ /**
1778
+ * Serializes the message to binary data (in protobuf wire format).
1779
+ * @return {!Uint8Array}
1780
+ */
1781
+ proto.trb.strategysearch.v1.DeleteStrategyRequest.prototype.serializeBinary = function() {
1782
+ var writer = new jspb.BinaryWriter();
1783
+ proto.trb.strategysearch.v1.DeleteStrategyRequest.serializeBinaryToWriter(this, writer);
1784
+ return writer.getResultBuffer();
1785
+ };
1786
+
1787
+
1788
+ /**
1789
+ * Serializes the given message to binary data (in protobuf wire
1790
+ * format), writing to the given BinaryWriter.
1791
+ * @param {!proto.trb.strategysearch.v1.DeleteStrategyRequest} message
1792
+ * @param {!jspb.BinaryWriter} writer
1793
+ * @suppress {unusedLocalVariables} f is only used for nested messages
1794
+ */
1795
+ proto.trb.strategysearch.v1.DeleteStrategyRequest.serializeBinaryToWriter = function(message, writer) {
1796
+ var f = undefined;
1797
+ f = message.getId();
1798
+ if (f.length > 0) {
1799
+ writer.writeString(
1800
+ 1,
1801
+ f
1802
+ );
1803
+ }
1804
+ };
1805
+
1806
+
1807
+ /**
1808
+ * optional string id = 1;
1809
+ * @return {string}
1810
+ */
1811
+ proto.trb.strategysearch.v1.DeleteStrategyRequest.prototype.getId = function() {
1812
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
1813
+ };
1814
+
1815
+
1816
+ /**
1817
+ * @param {string} value
1818
+ * @return {!proto.trb.strategysearch.v1.DeleteStrategyRequest} returns this
1819
+ */
1820
+ proto.trb.strategysearch.v1.DeleteStrategyRequest.prototype.setId = function(value) {
1821
+ return jspb.Message.setProto3StringField(this, 1, value);
1822
+ };
1823
+
1824
+
1825
+
1826
+
1827
+
1828
+ if (jspb.Message.GENERATE_TO_OBJECT) {
1829
+ /**
1830
+ * Creates an object representation of this proto.
1831
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
1832
+ * Optional fields that are not set will be set to undefined.
1833
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
1834
+ * For the list of reserved names please see:
1835
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
1836
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
1837
+ * JSPB instance for transitional soy proto support:
1838
+ * http://goto/soy-param-migration
1839
+ * @return {!Object}
1840
+ */
1841
+ proto.trb.strategysearch.v1.DeleteStrategyResponse.prototype.toObject = function(opt_includeInstance) {
1842
+ return proto.trb.strategysearch.v1.DeleteStrategyResponse.toObject(opt_includeInstance, this);
1843
+ };
1844
+
1845
+
1846
+ /**
1847
+ * Static version of the {@see toObject} method.
1848
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
1849
+ * the JSPB instance for transitional soy proto support:
1850
+ * http://goto/soy-param-migration
1851
+ * @param {!proto.trb.strategysearch.v1.DeleteStrategyResponse} msg The msg instance to transform.
1852
+ * @return {!Object}
1853
+ * @suppress {unusedLocalVariables} f is only used for nested messages
1854
+ */
1855
+ proto.trb.strategysearch.v1.DeleteStrategyResponse.toObject = function(includeInstance, msg) {
1856
+ var f, obj = {
1857
+ id: jspb.Message.getFieldWithDefault(msg, 1, ""),
1858
+ archived: jspb.Message.getBooleanFieldWithDefault(msg, 2, false)
1859
+ };
1860
+
1861
+ if (includeInstance) {
1862
+ obj.$jspbMessageInstance = msg;
1863
+ }
1864
+ return obj;
1865
+ };
1866
+ }
1867
+
1868
+
1869
+ /**
1870
+ * Deserializes binary data (in protobuf wire format).
1871
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
1872
+ * @return {!proto.trb.strategysearch.v1.DeleteStrategyResponse}
1873
+ */
1874
+ proto.trb.strategysearch.v1.DeleteStrategyResponse.deserializeBinary = function(bytes) {
1875
+ var reader = new jspb.BinaryReader(bytes);
1876
+ var msg = new proto.trb.strategysearch.v1.DeleteStrategyResponse;
1877
+ return proto.trb.strategysearch.v1.DeleteStrategyResponse.deserializeBinaryFromReader(msg, reader);
1878
+ };
1879
+
1880
+
1881
+ /**
1882
+ * Deserializes binary data (in protobuf wire format) from the
1883
+ * given reader into the given message object.
1884
+ * @param {!proto.trb.strategysearch.v1.DeleteStrategyResponse} msg The message object to deserialize into.
1885
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
1886
+ * @return {!proto.trb.strategysearch.v1.DeleteStrategyResponse}
1887
+ */
1888
+ proto.trb.strategysearch.v1.DeleteStrategyResponse.deserializeBinaryFromReader = function(msg, reader) {
1889
+ while (reader.nextField()) {
1890
+ if (reader.isEndGroup()) {
1891
+ break;
1892
+ }
1893
+ var field = reader.getFieldNumber();
1894
+ switch (field) {
1895
+ case 1:
1896
+ var value = /** @type {string} */ (reader.readString());
1897
+ msg.setId(value);
1898
+ break;
1899
+ case 2:
1900
+ var value = /** @type {boolean} */ (reader.readBool());
1901
+ msg.setArchived(value);
1902
+ break;
1903
+ default:
1904
+ reader.skipField();
1905
+ break;
1906
+ }
1907
+ }
1908
+ return msg;
1909
+ };
1910
+
1911
+
1912
+ /**
1913
+ * Serializes the message to binary data (in protobuf wire format).
1914
+ * @return {!Uint8Array}
1915
+ */
1916
+ proto.trb.strategysearch.v1.DeleteStrategyResponse.prototype.serializeBinary = function() {
1917
+ var writer = new jspb.BinaryWriter();
1918
+ proto.trb.strategysearch.v1.DeleteStrategyResponse.serializeBinaryToWriter(this, writer);
1919
+ return writer.getResultBuffer();
1920
+ };
1921
+
1922
+
1923
+ /**
1924
+ * Serializes the given message to binary data (in protobuf wire
1925
+ * format), writing to the given BinaryWriter.
1926
+ * @param {!proto.trb.strategysearch.v1.DeleteStrategyResponse} message
1927
+ * @param {!jspb.BinaryWriter} writer
1928
+ * @suppress {unusedLocalVariables} f is only used for nested messages
1929
+ */
1930
+ proto.trb.strategysearch.v1.DeleteStrategyResponse.serializeBinaryToWriter = function(message, writer) {
1931
+ var f = undefined;
1932
+ f = message.getId();
1933
+ if (f.length > 0) {
1934
+ writer.writeString(
1935
+ 1,
1936
+ f
1937
+ );
1938
+ }
1939
+ f = message.getArchived();
1940
+ if (f) {
1941
+ writer.writeBool(
1942
+ 2,
1943
+ f
1944
+ );
1945
+ }
1946
+ };
1947
+
1948
+
1949
+ /**
1950
+ * optional string id = 1;
1951
+ * @return {string}
1952
+ */
1953
+ proto.trb.strategysearch.v1.DeleteStrategyResponse.prototype.getId = function() {
1954
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
1955
+ };
1956
+
1957
+
1958
+ /**
1959
+ * @param {string} value
1960
+ * @return {!proto.trb.strategysearch.v1.DeleteStrategyResponse} returns this
1961
+ */
1962
+ proto.trb.strategysearch.v1.DeleteStrategyResponse.prototype.setId = function(value) {
1963
+ return jspb.Message.setProto3StringField(this, 1, value);
1964
+ };
1965
+
1966
+
1967
+ /**
1968
+ * optional bool archived = 2;
1969
+ * @return {boolean}
1970
+ */
1971
+ proto.trb.strategysearch.v1.DeleteStrategyResponse.prototype.getArchived = function() {
1972
+ return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 2, false));
1973
+ };
1974
+
1975
+
1976
+ /**
1977
+ * @param {boolean} value
1978
+ * @return {!proto.trb.strategysearch.v1.DeleteStrategyResponse} returns this
1979
+ */
1980
+ proto.trb.strategysearch.v1.DeleteStrategyResponse.prototype.setArchived = function(value) {
1981
+ return jspb.Message.setProto3BooleanField(this, 2, value);
1982
+ };
1983
+
1984
+
1985
+
1986
+
1987
+
1988
+ if (jspb.Message.GENERATE_TO_OBJECT) {
1989
+ /**
1990
+ * Creates an object representation of this proto.
1991
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
1992
+ * Optional fields that are not set will be set to undefined.
1993
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
1994
+ * For the list of reserved names please see:
1995
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
1996
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
1997
+ * JSPB instance for transitional soy proto support:
1998
+ * http://goto/soy-param-migration
1999
+ * @return {!Object}
2000
+ */
2001
+ proto.trb.strategysearch.v1.ValidationIssue.prototype.toObject = function(opt_includeInstance) {
2002
+ return proto.trb.strategysearch.v1.ValidationIssue.toObject(opt_includeInstance, this);
2003
+ };
2004
+
2005
+
2006
+ /**
2007
+ * Static version of the {@see toObject} method.
2008
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
2009
+ * the JSPB instance for transitional soy proto support:
2010
+ * http://goto/soy-param-migration
2011
+ * @param {!proto.trb.strategysearch.v1.ValidationIssue} msg The msg instance to transform.
2012
+ * @return {!Object}
2013
+ * @suppress {unusedLocalVariables} f is only used for nested messages
2014
+ */
2015
+ proto.trb.strategysearch.v1.ValidationIssue.toObject = function(includeInstance, msg) {
2016
+ var f, obj = {
2017
+ path: jspb.Message.getFieldWithDefault(msg, 1, ""),
2018
+ message: jspb.Message.getFieldWithDefault(msg, 2, "")
2019
+ };
2020
+
2021
+ if (includeInstance) {
2022
+ obj.$jspbMessageInstance = msg;
2023
+ }
2024
+ return obj;
2025
+ };
2026
+ }
2027
+
2028
+
2029
+ /**
2030
+ * Deserializes binary data (in protobuf wire format).
2031
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
2032
+ * @return {!proto.trb.strategysearch.v1.ValidationIssue}
2033
+ */
2034
+ proto.trb.strategysearch.v1.ValidationIssue.deserializeBinary = function(bytes) {
2035
+ var reader = new jspb.BinaryReader(bytes);
2036
+ var msg = new proto.trb.strategysearch.v1.ValidationIssue;
2037
+ return proto.trb.strategysearch.v1.ValidationIssue.deserializeBinaryFromReader(msg, reader);
2038
+ };
2039
+
2040
+
2041
+ /**
2042
+ * Deserializes binary data (in protobuf wire format) from the
2043
+ * given reader into the given message object.
2044
+ * @param {!proto.trb.strategysearch.v1.ValidationIssue} msg The message object to deserialize into.
2045
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
2046
+ * @return {!proto.trb.strategysearch.v1.ValidationIssue}
2047
+ */
2048
+ proto.trb.strategysearch.v1.ValidationIssue.deserializeBinaryFromReader = function(msg, reader) {
2049
+ while (reader.nextField()) {
2050
+ if (reader.isEndGroup()) {
2051
+ break;
2052
+ }
2053
+ var field = reader.getFieldNumber();
2054
+ switch (field) {
2055
+ case 1:
2056
+ var value = /** @type {string} */ (reader.readString());
2057
+ msg.setPath(value);
2058
+ break;
2059
+ case 2:
2060
+ var value = /** @type {string} */ (reader.readString());
2061
+ msg.setMessage(value);
2062
+ break;
2063
+ default:
2064
+ reader.skipField();
2065
+ break;
2066
+ }
2067
+ }
2068
+ return msg;
2069
+ };
2070
+
2071
+
2072
+ /**
2073
+ * Serializes the message to binary data (in protobuf wire format).
2074
+ * @return {!Uint8Array}
2075
+ */
2076
+ proto.trb.strategysearch.v1.ValidationIssue.prototype.serializeBinary = function() {
2077
+ var writer = new jspb.BinaryWriter();
2078
+ proto.trb.strategysearch.v1.ValidationIssue.serializeBinaryToWriter(this, writer);
2079
+ return writer.getResultBuffer();
2080
+ };
2081
+
2082
+
2083
+ /**
2084
+ * Serializes the given message to binary data (in protobuf wire
2085
+ * format), writing to the given BinaryWriter.
2086
+ * @param {!proto.trb.strategysearch.v1.ValidationIssue} message
2087
+ * @param {!jspb.BinaryWriter} writer
2088
+ * @suppress {unusedLocalVariables} f is only used for nested messages
2089
+ */
2090
+ proto.trb.strategysearch.v1.ValidationIssue.serializeBinaryToWriter = function(message, writer) {
2091
+ var f = undefined;
2092
+ f = message.getPath();
2093
+ if (f.length > 0) {
2094
+ writer.writeString(
2095
+ 1,
2096
+ f
2097
+ );
2098
+ }
2099
+ f = message.getMessage();
2100
+ if (f.length > 0) {
2101
+ writer.writeString(
2102
+ 2,
2103
+ f
2104
+ );
2105
+ }
2106
+ };
2107
+
2108
+
2109
+ /**
2110
+ * optional string path = 1;
2111
+ * @return {string}
2112
+ */
2113
+ proto.trb.strategysearch.v1.ValidationIssue.prototype.getPath = function() {
2114
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
2115
+ };
2116
+
2117
+
2118
+ /**
2119
+ * @param {string} value
2120
+ * @return {!proto.trb.strategysearch.v1.ValidationIssue} returns this
2121
+ */
2122
+ proto.trb.strategysearch.v1.ValidationIssue.prototype.setPath = function(value) {
2123
+ return jspb.Message.setProto3StringField(this, 1, value);
2124
+ };
2125
+
2126
+
2127
+ /**
2128
+ * optional string message = 2;
2129
+ * @return {string}
2130
+ */
2131
+ proto.trb.strategysearch.v1.ValidationIssue.prototype.getMessage = function() {
2132
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
2133
+ };
2134
+
2135
+
2136
+ /**
2137
+ * @param {string} value
2138
+ * @return {!proto.trb.strategysearch.v1.ValidationIssue} returns this
2139
+ */
2140
+ proto.trb.strategysearch.v1.ValidationIssue.prototype.setMessage = function(value) {
2141
+ return jspb.Message.setProto3StringField(this, 2, value);
2142
+ };
2143
+
2144
+
2145
+
2146
+
2147
+
2148
+ if (jspb.Message.GENERATE_TO_OBJECT) {
2149
+ /**
2150
+ * Creates an object representation of this proto.
2151
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
2152
+ * Optional fields that are not set will be set to undefined.
2153
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
2154
+ * For the list of reserved names please see:
2155
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
2156
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
2157
+ * JSPB instance for transitional soy proto support:
2158
+ * http://goto/soy-param-migration
2159
+ * @return {!Object}
2160
+ */
2161
+ proto.trb.strategysearch.v1.ValidateStrategyRequest.prototype.toObject = function(opt_includeInstance) {
2162
+ return proto.trb.strategysearch.v1.ValidateStrategyRequest.toObject(opt_includeInstance, this);
2163
+ };
2164
+
2165
+
2166
+ /**
2167
+ * Static version of the {@see toObject} method.
2168
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
2169
+ * the JSPB instance for transitional soy proto support:
2170
+ * http://goto/soy-param-migration
2171
+ * @param {!proto.trb.strategysearch.v1.ValidateStrategyRequest} msg The msg instance to transform.
2172
+ * @return {!Object}
2173
+ * @suppress {unusedLocalVariables} f is only used for nested messages
2174
+ */
2175
+ proto.trb.strategysearch.v1.ValidateStrategyRequest.toObject = function(includeInstance, msg) {
2176
+ var f, obj = {
2177
+ spec: (f = msg.getSpec()) && strategysearch_spec_pb.StrategySearchSpec.toObject(includeInstance, f)
2178
+ };
2179
+
2180
+ if (includeInstance) {
2181
+ obj.$jspbMessageInstance = msg;
2182
+ }
2183
+ return obj;
2184
+ };
2185
+ }
2186
+
2187
+
2188
+ /**
2189
+ * Deserializes binary data (in protobuf wire format).
2190
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
2191
+ * @return {!proto.trb.strategysearch.v1.ValidateStrategyRequest}
2192
+ */
2193
+ proto.trb.strategysearch.v1.ValidateStrategyRequest.deserializeBinary = function(bytes) {
2194
+ var reader = new jspb.BinaryReader(bytes);
2195
+ var msg = new proto.trb.strategysearch.v1.ValidateStrategyRequest;
2196
+ return proto.trb.strategysearch.v1.ValidateStrategyRequest.deserializeBinaryFromReader(msg, reader);
2197
+ };
2198
+
2199
+
2200
+ /**
2201
+ * Deserializes binary data (in protobuf wire format) from the
2202
+ * given reader into the given message object.
2203
+ * @param {!proto.trb.strategysearch.v1.ValidateStrategyRequest} msg The message object to deserialize into.
2204
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
2205
+ * @return {!proto.trb.strategysearch.v1.ValidateStrategyRequest}
2206
+ */
2207
+ proto.trb.strategysearch.v1.ValidateStrategyRequest.deserializeBinaryFromReader = function(msg, reader) {
2208
+ while (reader.nextField()) {
2209
+ if (reader.isEndGroup()) {
2210
+ break;
2211
+ }
2212
+ var field = reader.getFieldNumber();
2213
+ switch (field) {
2214
+ case 1:
2215
+ var value = new strategysearch_spec_pb.StrategySearchSpec;
2216
+ reader.readMessage(value,strategysearch_spec_pb.StrategySearchSpec.deserializeBinaryFromReader);
2217
+ msg.setSpec(value);
2218
+ break;
2219
+ default:
2220
+ reader.skipField();
2221
+ break;
2222
+ }
2223
+ }
2224
+ return msg;
2225
+ };
2226
+
2227
+
2228
+ /**
2229
+ * Serializes the message to binary data (in protobuf wire format).
2230
+ * @return {!Uint8Array}
2231
+ */
2232
+ proto.trb.strategysearch.v1.ValidateStrategyRequest.prototype.serializeBinary = function() {
2233
+ var writer = new jspb.BinaryWriter();
2234
+ proto.trb.strategysearch.v1.ValidateStrategyRequest.serializeBinaryToWriter(this, writer);
2235
+ return writer.getResultBuffer();
2236
+ };
2237
+
2238
+
2239
+ /**
2240
+ * Serializes the given message to binary data (in protobuf wire
2241
+ * format), writing to the given BinaryWriter.
2242
+ * @param {!proto.trb.strategysearch.v1.ValidateStrategyRequest} message
2243
+ * @param {!jspb.BinaryWriter} writer
2244
+ * @suppress {unusedLocalVariables} f is only used for nested messages
2245
+ */
2246
+ proto.trb.strategysearch.v1.ValidateStrategyRequest.serializeBinaryToWriter = function(message, writer) {
2247
+ var f = undefined;
2248
+ f = message.getSpec();
2249
+ if (f != null) {
2250
+ writer.writeMessage(
2251
+ 1,
2252
+ f,
2253
+ strategysearch_spec_pb.StrategySearchSpec.serializeBinaryToWriter
2254
+ );
2255
+ }
2256
+ };
2257
+
2258
+
2259
+ /**
2260
+ * optional StrategySearchSpec spec = 1;
2261
+ * @return {?proto.trb.strategysearch.v1.StrategySearchSpec}
2262
+ */
2263
+ proto.trb.strategysearch.v1.ValidateStrategyRequest.prototype.getSpec = function() {
2264
+ return /** @type{?proto.trb.strategysearch.v1.StrategySearchSpec} */ (
2265
+ jspb.Message.getWrapperField(this, strategysearch_spec_pb.StrategySearchSpec, 1));
2266
+ };
2267
+
2268
+
2269
+ /**
2270
+ * @param {?proto.trb.strategysearch.v1.StrategySearchSpec|undefined} value
2271
+ * @return {!proto.trb.strategysearch.v1.ValidateStrategyRequest} returns this
2272
+ */
2273
+ proto.trb.strategysearch.v1.ValidateStrategyRequest.prototype.setSpec = function(value) {
2274
+ return jspb.Message.setWrapperField(this, 1, value);
2275
+ };
2276
+
2277
+
2278
+ /**
2279
+ * Clears the message field making it undefined.
2280
+ * @return {!proto.trb.strategysearch.v1.ValidateStrategyRequest} returns this
2281
+ */
2282
+ proto.trb.strategysearch.v1.ValidateStrategyRequest.prototype.clearSpec = function() {
2283
+ return this.setSpec(undefined);
2284
+ };
2285
+
2286
+
2287
+ /**
2288
+ * Returns whether this field is set.
2289
+ * @return {boolean}
2290
+ */
2291
+ proto.trb.strategysearch.v1.ValidateStrategyRequest.prototype.hasSpec = function() {
2292
+ return jspb.Message.getField(this, 1) != null;
2293
+ };
2294
+
2295
+
2296
+
2297
+ /**
2298
+ * List of repeated fields within this message type.
2299
+ * @private {!Array<number>}
2300
+ * @const
2301
+ */
2302
+ proto.trb.strategysearch.v1.ValidateStrategyResponse.repeatedFields_ = [2];
2303
+
2304
+
2305
+
2306
+ if (jspb.Message.GENERATE_TO_OBJECT) {
2307
+ /**
2308
+ * Creates an object representation of this proto.
2309
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
2310
+ * Optional fields that are not set will be set to undefined.
2311
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
2312
+ * For the list of reserved names please see:
2313
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
2314
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
2315
+ * JSPB instance for transitional soy proto support:
2316
+ * http://goto/soy-param-migration
2317
+ * @return {!Object}
2318
+ */
2319
+ proto.trb.strategysearch.v1.ValidateStrategyResponse.prototype.toObject = function(opt_includeInstance) {
2320
+ return proto.trb.strategysearch.v1.ValidateStrategyResponse.toObject(opt_includeInstance, this);
2321
+ };
2322
+
2323
+
2324
+ /**
2325
+ * Static version of the {@see toObject} method.
2326
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
2327
+ * the JSPB instance for transitional soy proto support:
2328
+ * http://goto/soy-param-migration
2329
+ * @param {!proto.trb.strategysearch.v1.ValidateStrategyResponse} msg The msg instance to transform.
2330
+ * @return {!Object}
2331
+ * @suppress {unusedLocalVariables} f is only used for nested messages
2332
+ */
2333
+ proto.trb.strategysearch.v1.ValidateStrategyResponse.toObject = function(includeInstance, msg) {
2334
+ var f, obj = {
2335
+ ok: jspb.Message.getBooleanFieldWithDefault(msg, 1, false),
2336
+ issuesList: jspb.Message.toObjectList(msg.getIssuesList(),
2337
+ proto.trb.strategysearch.v1.ValidationIssue.toObject, includeInstance)
2338
+ };
2339
+
2340
+ if (includeInstance) {
2341
+ obj.$jspbMessageInstance = msg;
2342
+ }
2343
+ return obj;
2344
+ };
2345
+ }
2346
+
2347
+
2348
+ /**
2349
+ * Deserializes binary data (in protobuf wire format).
2350
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
2351
+ * @return {!proto.trb.strategysearch.v1.ValidateStrategyResponse}
2352
+ */
2353
+ proto.trb.strategysearch.v1.ValidateStrategyResponse.deserializeBinary = function(bytes) {
2354
+ var reader = new jspb.BinaryReader(bytes);
2355
+ var msg = new proto.trb.strategysearch.v1.ValidateStrategyResponse;
2356
+ return proto.trb.strategysearch.v1.ValidateStrategyResponse.deserializeBinaryFromReader(msg, reader);
2357
+ };
2358
+
2359
+
2360
+ /**
2361
+ * Deserializes binary data (in protobuf wire format) from the
2362
+ * given reader into the given message object.
2363
+ * @param {!proto.trb.strategysearch.v1.ValidateStrategyResponse} msg The message object to deserialize into.
2364
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
2365
+ * @return {!proto.trb.strategysearch.v1.ValidateStrategyResponse}
2366
+ */
2367
+ proto.trb.strategysearch.v1.ValidateStrategyResponse.deserializeBinaryFromReader = function(msg, reader) {
2368
+ while (reader.nextField()) {
2369
+ if (reader.isEndGroup()) {
2370
+ break;
2371
+ }
2372
+ var field = reader.getFieldNumber();
2373
+ switch (field) {
2374
+ case 1:
2375
+ var value = /** @type {boolean} */ (reader.readBool());
2376
+ msg.setOk(value);
2377
+ break;
2378
+ case 2:
2379
+ var value = new proto.trb.strategysearch.v1.ValidationIssue;
2380
+ reader.readMessage(value,proto.trb.strategysearch.v1.ValidationIssue.deserializeBinaryFromReader);
2381
+ msg.addIssues(value);
2382
+ break;
2383
+ default:
2384
+ reader.skipField();
2385
+ break;
2386
+ }
2387
+ }
2388
+ return msg;
2389
+ };
2390
+
2391
+
2392
+ /**
2393
+ * Serializes the message to binary data (in protobuf wire format).
2394
+ * @return {!Uint8Array}
2395
+ */
2396
+ proto.trb.strategysearch.v1.ValidateStrategyResponse.prototype.serializeBinary = function() {
2397
+ var writer = new jspb.BinaryWriter();
2398
+ proto.trb.strategysearch.v1.ValidateStrategyResponse.serializeBinaryToWriter(this, writer);
2399
+ return writer.getResultBuffer();
2400
+ };
2401
+
2402
+
2403
+ /**
2404
+ * Serializes the given message to binary data (in protobuf wire
2405
+ * format), writing to the given BinaryWriter.
2406
+ * @param {!proto.trb.strategysearch.v1.ValidateStrategyResponse} message
2407
+ * @param {!jspb.BinaryWriter} writer
2408
+ * @suppress {unusedLocalVariables} f is only used for nested messages
2409
+ */
2410
+ proto.trb.strategysearch.v1.ValidateStrategyResponse.serializeBinaryToWriter = function(message, writer) {
2411
+ var f = undefined;
2412
+ f = message.getOk();
2413
+ if (f) {
2414
+ writer.writeBool(
2415
+ 1,
2416
+ f
2417
+ );
2418
+ }
2419
+ f = message.getIssuesList();
2420
+ if (f.length > 0) {
2421
+ writer.writeRepeatedMessage(
2422
+ 2,
2423
+ f,
2424
+ proto.trb.strategysearch.v1.ValidationIssue.serializeBinaryToWriter
2425
+ );
2426
+ }
2427
+ };
2428
+
2429
+
2430
+ /**
2431
+ * optional bool ok = 1;
2432
+ * @return {boolean}
2433
+ */
2434
+ proto.trb.strategysearch.v1.ValidateStrategyResponse.prototype.getOk = function() {
2435
+ return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 1, false));
2436
+ };
2437
+
2438
+
2439
+ /**
2440
+ * @param {boolean} value
2441
+ * @return {!proto.trb.strategysearch.v1.ValidateStrategyResponse} returns this
2442
+ */
2443
+ proto.trb.strategysearch.v1.ValidateStrategyResponse.prototype.setOk = function(value) {
2444
+ return jspb.Message.setProto3BooleanField(this, 1, value);
2445
+ };
2446
+
2447
+
2448
+ /**
2449
+ * repeated ValidationIssue issues = 2;
2450
+ * @return {!Array<!proto.trb.strategysearch.v1.ValidationIssue>}
2451
+ */
2452
+ proto.trb.strategysearch.v1.ValidateStrategyResponse.prototype.getIssuesList = function() {
2453
+ return /** @type{!Array<!proto.trb.strategysearch.v1.ValidationIssue>} */ (
2454
+ jspb.Message.getRepeatedWrapperField(this, proto.trb.strategysearch.v1.ValidationIssue, 2));
2455
+ };
2456
+
2457
+
2458
+ /**
2459
+ * @param {!Array<!proto.trb.strategysearch.v1.ValidationIssue>} value
2460
+ * @return {!proto.trb.strategysearch.v1.ValidateStrategyResponse} returns this
2461
+ */
2462
+ proto.trb.strategysearch.v1.ValidateStrategyResponse.prototype.setIssuesList = function(value) {
2463
+ return jspb.Message.setRepeatedWrapperField(this, 2, value);
2464
+ };
2465
+
2466
+
2467
+ /**
2468
+ * @param {!proto.trb.strategysearch.v1.ValidationIssue=} opt_value
2469
+ * @param {number=} opt_index
2470
+ * @return {!proto.trb.strategysearch.v1.ValidationIssue}
2471
+ */
2472
+ proto.trb.strategysearch.v1.ValidateStrategyResponse.prototype.addIssues = function(opt_value, opt_index) {
2473
+ return jspb.Message.addToRepeatedWrapperField(this, 2, opt_value, proto.trb.strategysearch.v1.ValidationIssue, opt_index);
2474
+ };
2475
+
2476
+
2477
+ /**
2478
+ * Clears the list making it empty but non-null.
2479
+ * @return {!proto.trb.strategysearch.v1.ValidateStrategyResponse} returns this
2480
+ */
2481
+ proto.trb.strategysearch.v1.ValidateStrategyResponse.prototype.clearIssuesList = function() {
2482
+ return this.setIssuesList([]);
2483
+ };
2484
+
2485
+
2486
+ goog.object.extend(exports, proto.trb.strategysearch.v1);