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