UNPKG

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