Series_pb.js 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665
  1. // source: proto/Series.proto
  2. /**
  3. * @fileoverview
  4. * @enhanceable
  5. * @suppress {messageConventions} JS Compiler reports an error if a variable or
  6. * field starts with 'MSG_' and isn't a translatable message.
  7. * @public
  8. */
  9. // GENERATED CODE -- DO NOT EDIT!
  10. /* eslint-disable */
  11. // @ts-nocheck
  12. var jspb = require('google-protobuf');
  13. var goog = jspb;
  14. var global = Function('return this')();
  15. goog.exportSymbol('proto.SeasonMetadata', null, global);
  16. goog.exportSymbol('proto.SeriesMetadata', null, global);
  17. /**
  18. * Generated by JsPbCodeGenerator.
  19. * @param {Array=} opt_data Optional initial data array, typically from a
  20. * server response, or constructed directly in Javascript. The array is used
  21. * in place and becomes part of the constructed object. It is not cloned.
  22. * If no data is provided, the constructed object will be empty, but still
  23. * valid.
  24. * @extends {jspb.Message}
  25. * @constructor
  26. */
  27. proto.SeriesMetadata = function(opt_data) {
  28. jspb.Message.initialize(this, opt_data, 0, -1, proto.SeriesMetadata.repeatedFields_, null);
  29. };
  30. goog.inherits(proto.SeriesMetadata, jspb.Message);
  31. if (goog.DEBUG && !COMPILED) {
  32. /**
  33. * @public
  34. * @override
  35. */
  36. proto.SeriesMetadata.displayName = 'proto.SeriesMetadata';
  37. }
  38. /**
  39. * Generated by JsPbCodeGenerator.
  40. * @param {Array=} opt_data Optional initial data array, typically from a
  41. * server response, or constructed directly in Javascript. The array is used
  42. * in place and becomes part of the constructed object. It is not cloned.
  43. * If no data is provided, the constructed object will be empty, but still
  44. * valid.
  45. * @extends {jspb.Message}
  46. * @constructor
  47. */
  48. proto.SeasonMetadata = function(opt_data) {
  49. jspb.Message.initialize(this, opt_data, 0, -1, proto.SeasonMetadata.repeatedFields_, null);
  50. };
  51. goog.inherits(proto.SeasonMetadata, jspb.Message);
  52. if (goog.DEBUG && !COMPILED) {
  53. /**
  54. * @public
  55. * @override
  56. */
  57. proto.SeasonMetadata.displayName = 'proto.SeasonMetadata';
  58. }
  59. /**
  60. * List of repeated fields within this message type.
  61. * @private {!Array<number>}
  62. * @const
  63. */
  64. proto.SeriesMetadata.repeatedFields_ = [4];
  65. if (jspb.Message.GENERATE_TO_OBJECT) {
  66. /**
  67. * Creates an object representation of this proto.
  68. * Field names that are reserved in JavaScript and will be renamed to pb_name.
  69. * Optional fields that are not set will be set to undefined.
  70. * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
  71. * For the list of reserved names please see:
  72. * net/proto2/compiler/js/internal/generator.cc#kKeyword.
  73. * @param {boolean=} opt_includeInstance Deprecated. whether to include the
  74. * JSPB instance for transitional soy proto support:
  75. * http://goto/soy-param-migration
  76. * @return {!Object}
  77. */
  78. proto.SeriesMetadata.prototype.toObject = function(opt_includeInstance) {
  79. return proto.SeriesMetadata.toObject(opt_includeInstance, this);
  80. };
  81. /**
  82. * Static version of the {@see toObject} method.
  83. * @param {boolean|undefined} includeInstance Deprecated. Whether to include
  84. * the JSPB instance for transitional soy proto support:
  85. * http://goto/soy-param-migration
  86. * @param {!proto.SeriesMetadata} msg The msg instance to transform.
  87. * @return {!Object}
  88. * @suppress {unusedLocalVariables} f is only used for nested messages
  89. */
  90. proto.SeriesMetadata.toObject = function(includeInstance, msg) {
  91. var f, obj = {
  92. title: (f = jspb.Message.getField(msg, 1)) == null ? undefined : f,
  93. description: (f = jspb.Message.getField(msg, 2)) == null ? undefined : f,
  94. coverPhoto: (f = jspb.Message.getField(msg, 3)) == null ? undefined : f,
  95. personsList: (f = jspb.Message.getRepeatedField(msg, 4)) == null ? undefined : f
  96. };
  97. if (includeInstance) {
  98. obj.$jspbMessageInstance = msg;
  99. }
  100. return obj;
  101. };
  102. }
  103. /**
  104. * Deserializes binary data (in protobuf wire format).
  105. * @param {jspb.ByteSource} bytes The bytes to deserialize.
  106. * @return {!proto.SeriesMetadata}
  107. */
  108. proto.SeriesMetadata.deserializeBinary = function(bytes) {
  109. var reader = new jspb.BinaryReader(bytes);
  110. var msg = new proto.SeriesMetadata;
  111. return proto.SeriesMetadata.deserializeBinaryFromReader(msg, reader);
  112. };
  113. /**
  114. * Deserializes binary data (in protobuf wire format) from the
  115. * given reader into the given message object.
  116. * @param {!proto.SeriesMetadata} msg The message object to deserialize into.
  117. * @param {!jspb.BinaryReader} reader The BinaryReader to use.
  118. * @return {!proto.SeriesMetadata}
  119. */
  120. proto.SeriesMetadata.deserializeBinaryFromReader = function(msg, reader) {
  121. while (reader.nextField()) {
  122. if (reader.isEndGroup()) {
  123. break;
  124. }
  125. var field = reader.getFieldNumber();
  126. switch (field) {
  127. case 1:
  128. var value = /** @type {string} */ (reader.readString());
  129. msg.setTitle(value);
  130. break;
  131. case 2:
  132. var value = /** @type {string} */ (reader.readString());
  133. msg.setDescription(value);
  134. break;
  135. case 3:
  136. var value = /** @type {number} */ (reader.readUint32());
  137. msg.setCoverPhoto(value);
  138. break;
  139. case 4:
  140. var values = /** @type {!Array<number>} */ (reader.isDelimited() ? reader.readPackedUint64() : [reader.readUint64()]);
  141. for (var i = 0; i < values.length; i++) {
  142. msg.addPersons(values[i]);
  143. }
  144. break;
  145. default:
  146. reader.skipField();
  147. break;
  148. }
  149. }
  150. return msg;
  151. };
  152. /**
  153. * Serializes the message to binary data (in protobuf wire format).
  154. * @return {!Uint8Array}
  155. */
  156. proto.SeriesMetadata.prototype.serializeBinary = function() {
  157. var writer = new jspb.BinaryWriter();
  158. proto.SeriesMetadata.serializeBinaryToWriter(this, writer);
  159. return writer.getResultBuffer();
  160. };
  161. /**
  162. * Serializes the given message to binary data (in protobuf wire
  163. * format), writing to the given BinaryWriter.
  164. * @param {!proto.SeriesMetadata} message
  165. * @param {!jspb.BinaryWriter} writer
  166. * @suppress {unusedLocalVariables} f is only used for nested messages
  167. */
  168. proto.SeriesMetadata.serializeBinaryToWriter = function(message, writer) {
  169. var f = undefined;
  170. f = /** @type {string} */ (jspb.Message.getField(message, 1));
  171. if (f != null) {
  172. writer.writeString(
  173. 1,
  174. f
  175. );
  176. }
  177. f = /** @type {string} */ (jspb.Message.getField(message, 2));
  178. if (f != null) {
  179. writer.writeString(
  180. 2,
  181. f
  182. );
  183. }
  184. f = /** @type {number} */ (jspb.Message.getField(message, 3));
  185. if (f != null) {
  186. writer.writeUint32(
  187. 3,
  188. f
  189. );
  190. }
  191. f = message.getPersonsList();
  192. if (f.length > 0) {
  193. writer.writePackedUint64(
  194. 4,
  195. f
  196. );
  197. }
  198. };
  199. /**
  200. * optional string title = 1;
  201. * @return {string}
  202. */
  203. proto.SeriesMetadata.prototype.getTitle = function() {
  204. return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
  205. };
  206. /**
  207. * @param {string} value
  208. * @return {!proto.SeriesMetadata} returns this
  209. */
  210. proto.SeriesMetadata.prototype.setTitle = function(value) {
  211. return jspb.Message.setField(this, 1, value);
  212. };
  213. /**
  214. * Clears the field making it undefined.
  215. * @return {!proto.SeriesMetadata} returns this
  216. */
  217. proto.SeriesMetadata.prototype.clearTitle = function() {
  218. return jspb.Message.setField(this, 1, undefined);
  219. };
  220. /**
  221. * Returns whether this field is set.
  222. * @return {boolean}
  223. */
  224. proto.SeriesMetadata.prototype.hasTitle = function() {
  225. return jspb.Message.getField(this, 1) != null;
  226. };
  227. /**
  228. * optional string description = 2;
  229. * @return {string}
  230. */
  231. proto.SeriesMetadata.prototype.getDescription = function() {
  232. return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
  233. };
  234. /**
  235. * @param {string} value
  236. * @return {!proto.SeriesMetadata} returns this
  237. */
  238. proto.SeriesMetadata.prototype.setDescription = function(value) {
  239. return jspb.Message.setField(this, 2, value);
  240. };
  241. /**
  242. * Clears the field making it undefined.
  243. * @return {!proto.SeriesMetadata} returns this
  244. */
  245. proto.SeriesMetadata.prototype.clearDescription = function() {
  246. return jspb.Message.setField(this, 2, undefined);
  247. };
  248. /**
  249. * Returns whether this field is set.
  250. * @return {boolean}
  251. */
  252. proto.SeriesMetadata.prototype.hasDescription = function() {
  253. return jspb.Message.getField(this, 2) != null;
  254. };
  255. /**
  256. * optional uint32 cover_photo = 3;
  257. * @return {number}
  258. */
  259. proto.SeriesMetadata.prototype.getCoverPhoto = function() {
  260. return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 3, 0));
  261. };
  262. /**
  263. * @param {number} value
  264. * @return {!proto.SeriesMetadata} returns this
  265. */
  266. proto.SeriesMetadata.prototype.setCoverPhoto = function(value) {
  267. return jspb.Message.setField(this, 3, value);
  268. };
  269. /**
  270. * Clears the field making it undefined.
  271. * @return {!proto.SeriesMetadata} returns this
  272. */
  273. proto.SeriesMetadata.prototype.clearCoverPhoto = function() {
  274. return jspb.Message.setField(this, 3, undefined);
  275. };
  276. /**
  277. * Returns whether this field is set.
  278. * @return {boolean}
  279. */
  280. proto.SeriesMetadata.prototype.hasCoverPhoto = function() {
  281. return jspb.Message.getField(this, 3) != null;
  282. };
  283. /**
  284. * repeated uint64 persons = 4;
  285. * @return {!Array<number>}
  286. */
  287. proto.SeriesMetadata.prototype.getPersonsList = function() {
  288. return /** @type {!Array<number>} */ (jspb.Message.getRepeatedField(this, 4));
  289. };
  290. /**
  291. * @param {!Array<number>} value
  292. * @return {!proto.SeriesMetadata} returns this
  293. */
  294. proto.SeriesMetadata.prototype.setPersonsList = function(value) {
  295. return jspb.Message.setField(this, 4, value || []);
  296. };
  297. /**
  298. * @param {number} value
  299. * @param {number=} opt_index
  300. * @return {!proto.SeriesMetadata} returns this
  301. */
  302. proto.SeriesMetadata.prototype.addPersons = function(value, opt_index) {
  303. return jspb.Message.addToRepeatedField(this, 4, value, opt_index);
  304. };
  305. /**
  306. * Clears the list making it empty but non-null.
  307. * @return {!proto.SeriesMetadata} returns this
  308. */
  309. proto.SeriesMetadata.prototype.clearPersonsList = function() {
  310. return this.setPersonsList([]);
  311. };
  312. /**
  313. * List of repeated fields within this message type.
  314. * @private {!Array<number>}
  315. * @const
  316. */
  317. proto.SeasonMetadata.repeatedFields_ = [4];
  318. if (jspb.Message.GENERATE_TO_OBJECT) {
  319. /**
  320. * Creates an object representation of this proto.
  321. * Field names that are reserved in JavaScript and will be renamed to pb_name.
  322. * Optional fields that are not set will be set to undefined.
  323. * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
  324. * For the list of reserved names please see:
  325. * net/proto2/compiler/js/internal/generator.cc#kKeyword.
  326. * @param {boolean=} opt_includeInstance Deprecated. whether to include the
  327. * JSPB instance for transitional soy proto support:
  328. * http://goto/soy-param-migration
  329. * @return {!Object}
  330. */
  331. proto.SeasonMetadata.prototype.toObject = function(opt_includeInstance) {
  332. return proto.SeasonMetadata.toObject(opt_includeInstance, this);
  333. };
  334. /**
  335. * Static version of the {@see toObject} method.
  336. * @param {boolean|undefined} includeInstance Deprecated. Whether to include
  337. * the JSPB instance for transitional soy proto support:
  338. * http://goto/soy-param-migration
  339. * @param {!proto.SeasonMetadata} msg The msg instance to transform.
  340. * @return {!Object}
  341. * @suppress {unusedLocalVariables} f is only used for nested messages
  342. */
  343. proto.SeasonMetadata.toObject = function(includeInstance, msg) {
  344. var f, obj = {
  345. title: (f = jspb.Message.getField(msg, 1)) == null ? undefined : f,
  346. description: (f = jspb.Message.getField(msg, 2)) == null ? undefined : f,
  347. coverPhoto: (f = jspb.Message.getField(msg, 3)) == null ? undefined : f,
  348. personsList: (f = jspb.Message.getRepeatedField(msg, 4)) == null ? undefined : f
  349. };
  350. if (includeInstance) {
  351. obj.$jspbMessageInstance = msg;
  352. }
  353. return obj;
  354. };
  355. }
  356. /**
  357. * Deserializes binary data (in protobuf wire format).
  358. * @param {jspb.ByteSource} bytes The bytes to deserialize.
  359. * @return {!proto.SeasonMetadata}
  360. */
  361. proto.SeasonMetadata.deserializeBinary = function(bytes) {
  362. var reader = new jspb.BinaryReader(bytes);
  363. var msg = new proto.SeasonMetadata;
  364. return proto.SeasonMetadata.deserializeBinaryFromReader(msg, reader);
  365. };
  366. /**
  367. * Deserializes binary data (in protobuf wire format) from the
  368. * given reader into the given message object.
  369. * @param {!proto.SeasonMetadata} msg The message object to deserialize into.
  370. * @param {!jspb.BinaryReader} reader The BinaryReader to use.
  371. * @return {!proto.SeasonMetadata}
  372. */
  373. proto.SeasonMetadata.deserializeBinaryFromReader = function(msg, reader) {
  374. while (reader.nextField()) {
  375. if (reader.isEndGroup()) {
  376. break;
  377. }
  378. var field = reader.getFieldNumber();
  379. switch (field) {
  380. case 1:
  381. var value = /** @type {string} */ (reader.readString());
  382. msg.setTitle(value);
  383. break;
  384. case 2:
  385. var value = /** @type {string} */ (reader.readString());
  386. msg.setDescription(value);
  387. break;
  388. case 3:
  389. var value = /** @type {number} */ (reader.readUint32());
  390. msg.setCoverPhoto(value);
  391. break;
  392. case 4:
  393. var values = /** @type {!Array<number>} */ (reader.isDelimited() ? reader.readPackedUint64() : [reader.readUint64()]);
  394. for (var i = 0; i < values.length; i++) {
  395. msg.addPersons(values[i]);
  396. }
  397. break;
  398. default:
  399. reader.skipField();
  400. break;
  401. }
  402. }
  403. return msg;
  404. };
  405. /**
  406. * Serializes the message to binary data (in protobuf wire format).
  407. * @return {!Uint8Array}
  408. */
  409. proto.SeasonMetadata.prototype.serializeBinary = function() {
  410. var writer = new jspb.BinaryWriter();
  411. proto.SeasonMetadata.serializeBinaryToWriter(this, writer);
  412. return writer.getResultBuffer();
  413. };
  414. /**
  415. * Serializes the given message to binary data (in protobuf wire
  416. * format), writing to the given BinaryWriter.
  417. * @param {!proto.SeasonMetadata} message
  418. * @param {!jspb.BinaryWriter} writer
  419. * @suppress {unusedLocalVariables} f is only used for nested messages
  420. */
  421. proto.SeasonMetadata.serializeBinaryToWriter = function(message, writer) {
  422. var f = undefined;
  423. f = /** @type {string} */ (jspb.Message.getField(message, 1));
  424. if (f != null) {
  425. writer.writeString(
  426. 1,
  427. f
  428. );
  429. }
  430. f = /** @type {string} */ (jspb.Message.getField(message, 2));
  431. if (f != null) {
  432. writer.writeString(
  433. 2,
  434. f
  435. );
  436. }
  437. f = /** @type {number} */ (jspb.Message.getField(message, 3));
  438. if (f != null) {
  439. writer.writeUint32(
  440. 3,
  441. f
  442. );
  443. }
  444. f = message.getPersonsList();
  445. if (f.length > 0) {
  446. writer.writePackedUint64(
  447. 4,
  448. f
  449. );
  450. }
  451. };
  452. /**
  453. * optional string title = 1;
  454. * @return {string}
  455. */
  456. proto.SeasonMetadata.prototype.getTitle = function() {
  457. return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
  458. };
  459. /**
  460. * @param {string} value
  461. * @return {!proto.SeasonMetadata} returns this
  462. */
  463. proto.SeasonMetadata.prototype.setTitle = function(value) {
  464. return jspb.Message.setField(this, 1, value);
  465. };
  466. /**
  467. * Clears the field making it undefined.
  468. * @return {!proto.SeasonMetadata} returns this
  469. */
  470. proto.SeasonMetadata.prototype.clearTitle = function() {
  471. return jspb.Message.setField(this, 1, undefined);
  472. };
  473. /**
  474. * Returns whether this field is set.
  475. * @return {boolean}
  476. */
  477. proto.SeasonMetadata.prototype.hasTitle = function() {
  478. return jspb.Message.getField(this, 1) != null;
  479. };
  480. /**
  481. * optional string description = 2;
  482. * @return {string}
  483. */
  484. proto.SeasonMetadata.prototype.getDescription = function() {
  485. return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
  486. };
  487. /**
  488. * @param {string} value
  489. * @return {!proto.SeasonMetadata} returns this
  490. */
  491. proto.SeasonMetadata.prototype.setDescription = function(value) {
  492. return jspb.Message.setField(this, 2, value);
  493. };
  494. /**
  495. * Clears the field making it undefined.
  496. * @return {!proto.SeasonMetadata} returns this
  497. */
  498. proto.SeasonMetadata.prototype.clearDescription = function() {
  499. return jspb.Message.setField(this, 2, undefined);
  500. };
  501. /**
  502. * Returns whether this field is set.
  503. * @return {boolean}
  504. */
  505. proto.SeasonMetadata.prototype.hasDescription = function() {
  506. return jspb.Message.getField(this, 2) != null;
  507. };
  508. /**
  509. * optional uint32 cover_photo = 3;
  510. * @return {number}
  511. */
  512. proto.SeasonMetadata.prototype.getCoverPhoto = function() {
  513. return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 3, 0));
  514. };
  515. /**
  516. * @param {number} value
  517. * @return {!proto.SeasonMetadata} returns this
  518. */
  519. proto.SeasonMetadata.prototype.setCoverPhoto = function(value) {
  520. return jspb.Message.setField(this, 3, value);
  521. };
  522. /**
  523. * Clears the field making it undefined.
  524. * @return {!proto.SeasonMetadata} returns this
  525. */
  526. proto.SeasonMetadata.prototype.clearCoverPhoto = function() {
  527. return jspb.Message.setField(this, 3, undefined);
  528. };
  529. /**
  530. * Returns whether this field is set.
  531. * @return {boolean}
  532. */
  533. proto.SeasonMetadata.prototype.hasCoverPhoto = function() {
  534. return jspb.Message.getField(this, 3) != null;
  535. };
  536. /**
  537. * repeated uint64 persons = 4;
  538. * @return {!Array<number>}
  539. */
  540. proto.SeasonMetadata.prototype.getPersonsList = function() {
  541. return /** @type {!Array<number>} */ (jspb.Message.getRepeatedField(this, 4));
  542. };
  543. /**
  544. * @param {!Array<number>} value
  545. * @return {!proto.SeasonMetadata} returns this
  546. */
  547. proto.SeasonMetadata.prototype.setPersonsList = function(value) {
  548. return jspb.Message.setField(this, 4, value || []);
  549. };
  550. /**
  551. * @param {number} value
  552. * @param {number=} opt_index
  553. * @return {!proto.SeasonMetadata} returns this
  554. */
  555. proto.SeasonMetadata.prototype.addPersons = function(value, opt_index) {
  556. return jspb.Message.addToRepeatedField(this, 4, value, opt_index);
  557. };
  558. /**
  559. * Clears the list making it empty but non-null.
  560. * @return {!proto.SeasonMetadata} returns this
  561. */
  562. proto.SeasonMetadata.prototype.clearPersonsList = function() {
  563. return this.setPersonsList([]);
  564. };
  565. goog.object.extend(exports, proto);