plugin.js 39 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267
  1. // source: google/protobuf/compiler/plugin.proto
  2. /**
  3. * @fileoverview
  4. * @enhanceable
  5. * @suppress {missingRequire} reports error on implicit type usages.
  6. * @suppress {messageConventions} JS Compiler reports an error if a variable or
  7. * field starts with 'MSG_' and isn't a translatable message.
  8. * @public
  9. */
  10. // GENERATED CODE -- DO NOT EDIT!
  11. /* eslint-disable */
  12. // @ts-nocheck
  13. goog.provide('proto.google.protobuf.compiler.CodeGeneratorRequest');
  14. goog.provide('proto.google.protobuf.compiler.CodeGeneratorResponse');
  15. goog.provide('proto.google.protobuf.compiler.CodeGeneratorResponse.Feature');
  16. goog.provide('proto.google.protobuf.compiler.CodeGeneratorResponse.File');
  17. goog.provide('proto.google.protobuf.compiler.Version');
  18. goog.require('jspb.BinaryReader');
  19. goog.require('jspb.BinaryWriter');
  20. goog.require('jspb.Message');
  21. goog.require('proto.google.protobuf.FileDescriptorProto');
  22. goog.require('proto.google.protobuf.GeneratedCodeInfo');
  23. /**
  24. * Generated by JsPbCodeGenerator.
  25. * @param {Array=} opt_data Optional initial data array, typically from a
  26. * server response, or constructed directly in Javascript. The array is used
  27. * in place and becomes part of the constructed object. It is not cloned.
  28. * If no data is provided, the constructed object will be empty, but still
  29. * valid.
  30. * @extends {jspb.Message}
  31. * @constructor
  32. */
  33. proto.google.protobuf.compiler.Version = function(opt_data) {
  34. jspb.Message.initialize(this, opt_data, 0, -1, null, null);
  35. };
  36. goog.inherits(proto.google.protobuf.compiler.Version, jspb.Message);
  37. if (goog.DEBUG && !COMPILED) {
  38. /**
  39. * @public
  40. * @override
  41. */
  42. proto.google.protobuf.compiler.Version.displayName = 'proto.google.protobuf.compiler.Version';
  43. }
  44. /**
  45. * Generated by JsPbCodeGenerator.
  46. * @param {Array=} opt_data Optional initial data array, typically from a
  47. * server response, or constructed directly in Javascript. The array is used
  48. * in place and becomes part of the constructed object. It is not cloned.
  49. * If no data is provided, the constructed object will be empty, but still
  50. * valid.
  51. * @extends {jspb.Message}
  52. * @constructor
  53. */
  54. proto.google.protobuf.compiler.CodeGeneratorRequest = function(opt_data) {
  55. jspb.Message.initialize(this, opt_data, 0, -1, proto.google.protobuf.compiler.CodeGeneratorRequest.repeatedFields_, null);
  56. };
  57. goog.inherits(proto.google.protobuf.compiler.CodeGeneratorRequest, jspb.Message);
  58. if (goog.DEBUG && !COMPILED) {
  59. /**
  60. * @public
  61. * @override
  62. */
  63. proto.google.protobuf.compiler.CodeGeneratorRequest.displayName = 'proto.google.protobuf.compiler.CodeGeneratorRequest';
  64. }
  65. /**
  66. * Generated by JsPbCodeGenerator.
  67. * @param {Array=} opt_data Optional initial data array, typically from a
  68. * server response, or constructed directly in Javascript. The array is used
  69. * in place and becomes part of the constructed object. It is not cloned.
  70. * If no data is provided, the constructed object will be empty, but still
  71. * valid.
  72. * @extends {jspb.Message}
  73. * @constructor
  74. */
  75. proto.google.protobuf.compiler.CodeGeneratorResponse = function(opt_data) {
  76. jspb.Message.initialize(this, opt_data, 0, -1, proto.google.protobuf.compiler.CodeGeneratorResponse.repeatedFields_, null);
  77. };
  78. goog.inherits(proto.google.protobuf.compiler.CodeGeneratorResponse, jspb.Message);
  79. if (goog.DEBUG && !COMPILED) {
  80. /**
  81. * @public
  82. * @override
  83. */
  84. proto.google.protobuf.compiler.CodeGeneratorResponse.displayName = 'proto.google.protobuf.compiler.CodeGeneratorResponse';
  85. }
  86. /**
  87. * Generated by JsPbCodeGenerator.
  88. * @param {Array=} opt_data Optional initial data array, typically from a
  89. * server response, or constructed directly in Javascript. The array is used
  90. * in place and becomes part of the constructed object. It is not cloned.
  91. * If no data is provided, the constructed object will be empty, but still
  92. * valid.
  93. * @extends {jspb.Message}
  94. * @constructor
  95. */
  96. proto.google.protobuf.compiler.CodeGeneratorResponse.File = function(opt_data) {
  97. jspb.Message.initialize(this, opt_data, 0, -1, null, null);
  98. };
  99. goog.inherits(proto.google.protobuf.compiler.CodeGeneratorResponse.File, jspb.Message);
  100. if (goog.DEBUG && !COMPILED) {
  101. /**
  102. * @public
  103. * @override
  104. */
  105. proto.google.protobuf.compiler.CodeGeneratorResponse.File.displayName = 'proto.google.protobuf.compiler.CodeGeneratorResponse.File';
  106. }
  107. if (jspb.Message.GENERATE_TO_OBJECT) {
  108. /**
  109. * Creates an object representation of this proto.
  110. * Field names that are reserved in JavaScript and will be renamed to pb_name.
  111. * Optional fields that are not set will be set to undefined.
  112. * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
  113. * For the list of reserved names please see:
  114. * net/proto2/compiler/js/internal/generator.cc#kKeyword.
  115. * @param {boolean=} opt_includeInstance Deprecated. whether to include the
  116. * JSPB instance for transitional soy proto support:
  117. * http://goto/soy-param-migration
  118. * @return {!Object}
  119. */
  120. proto.google.protobuf.compiler.Version.prototype.toObject = function(opt_includeInstance) {
  121. return proto.google.protobuf.compiler.Version.toObject(opt_includeInstance, this);
  122. };
  123. /**
  124. * Static version of the {@see toObject} method.
  125. * @param {boolean|undefined} includeInstance Deprecated. Whether to include
  126. * the JSPB instance for transitional soy proto support:
  127. * http://goto/soy-param-migration
  128. * @param {!proto.google.protobuf.compiler.Version} msg The msg instance to transform.
  129. * @return {!Object}
  130. * @suppress {unusedLocalVariables} f is only used for nested messages
  131. */
  132. proto.google.protobuf.compiler.Version.toObject = function(includeInstance, msg) {
  133. var f, obj = {
  134. major: (f = jspb.Message.getField(msg, 1)) == null ? undefined : f,
  135. minor: (f = jspb.Message.getField(msg, 2)) == null ? undefined : f,
  136. patch: (f = jspb.Message.getField(msg, 3)) == null ? undefined : f,
  137. suffix: (f = jspb.Message.getField(msg, 4)) == null ? undefined : f
  138. };
  139. if (includeInstance) {
  140. obj.$jspbMessageInstance = msg;
  141. }
  142. return obj;
  143. };
  144. }
  145. /**
  146. * Deserializes binary data (in protobuf wire format).
  147. * @param {jspb.ByteSource} bytes The bytes to deserialize.
  148. * @return {!proto.google.protobuf.compiler.Version}
  149. */
  150. proto.google.protobuf.compiler.Version.deserializeBinary = function(bytes) {
  151. var reader = new jspb.BinaryReader(bytes);
  152. var msg = new proto.google.protobuf.compiler.Version;
  153. return proto.google.protobuf.compiler.Version.deserializeBinaryFromReader(msg, reader);
  154. };
  155. /**
  156. * Deserializes binary data (in protobuf wire format) from the
  157. * given reader into the given message object.
  158. * @param {!proto.google.protobuf.compiler.Version} msg The message object to deserialize into.
  159. * @param {!jspb.BinaryReader} reader The BinaryReader to use.
  160. * @return {!proto.google.protobuf.compiler.Version}
  161. */
  162. proto.google.protobuf.compiler.Version.deserializeBinaryFromReader = function(msg, reader) {
  163. while (reader.nextField()) {
  164. if (reader.isEndGroup()) {
  165. break;
  166. }
  167. var field = reader.getFieldNumber();
  168. switch (field) {
  169. case 1:
  170. var value = /** @type {number} */ (reader.readInt32());
  171. msg.setMajor(value);
  172. break;
  173. case 2:
  174. var value = /** @type {number} */ (reader.readInt32());
  175. msg.setMinor(value);
  176. break;
  177. case 3:
  178. var value = /** @type {number} */ (reader.readInt32());
  179. msg.setPatch(value);
  180. break;
  181. case 4:
  182. var value = /** @type {string} */ (reader.readString());
  183. msg.setSuffix(value);
  184. break;
  185. default:
  186. reader.skipField();
  187. break;
  188. }
  189. }
  190. return msg;
  191. };
  192. /**
  193. * Serializes the message to binary data (in protobuf wire format).
  194. * @return {!Uint8Array}
  195. */
  196. proto.google.protobuf.compiler.Version.prototype.serializeBinary = function() {
  197. var writer = new jspb.BinaryWriter();
  198. proto.google.protobuf.compiler.Version.serializeBinaryToWriter(this, writer);
  199. return writer.getResultBuffer();
  200. };
  201. /**
  202. * Serializes the given message to binary data (in protobuf wire
  203. * format), writing to the given BinaryWriter.
  204. * @param {!proto.google.protobuf.compiler.Version} message
  205. * @param {!jspb.BinaryWriter} writer
  206. * @suppress {unusedLocalVariables} f is only used for nested messages
  207. */
  208. proto.google.protobuf.compiler.Version.serializeBinaryToWriter = function(message, writer) {
  209. var f = undefined;
  210. f = /** @type {number} */ (jspb.Message.getField(message, 1));
  211. if (f != null) {
  212. writer.writeInt32(
  213. 1,
  214. f
  215. );
  216. }
  217. f = /** @type {number} */ (jspb.Message.getField(message, 2));
  218. if (f != null) {
  219. writer.writeInt32(
  220. 2,
  221. f
  222. );
  223. }
  224. f = /** @type {number} */ (jspb.Message.getField(message, 3));
  225. if (f != null) {
  226. writer.writeInt32(
  227. 3,
  228. f
  229. );
  230. }
  231. f = /** @type {string} */ (jspb.Message.getField(message, 4));
  232. if (f != null) {
  233. writer.writeString(
  234. 4,
  235. f
  236. );
  237. }
  238. };
  239. /**
  240. * optional int32 major = 1;
  241. * @return {number}
  242. */
  243. proto.google.protobuf.compiler.Version.prototype.getMajor = function() {
  244. return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0));
  245. };
  246. /**
  247. * @param {number} value
  248. * @return {!proto.google.protobuf.compiler.Version} returns this
  249. */
  250. proto.google.protobuf.compiler.Version.prototype.setMajor = function(value) {
  251. return jspb.Message.setField(this, 1, value);
  252. };
  253. /**
  254. * Clears the field making it undefined.
  255. * @return {!proto.google.protobuf.compiler.Version} returns this
  256. */
  257. proto.google.protobuf.compiler.Version.prototype.clearMajor = function() {
  258. return jspb.Message.setField(this, 1, undefined);
  259. };
  260. /**
  261. * Returns whether this field is set.
  262. * @return {boolean}
  263. */
  264. proto.google.protobuf.compiler.Version.prototype.hasMajor = function() {
  265. return jspb.Message.getField(this, 1) != null;
  266. };
  267. /**
  268. * optional int32 minor = 2;
  269. * @return {number}
  270. */
  271. proto.google.protobuf.compiler.Version.prototype.getMinor = function() {
  272. return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 2, 0));
  273. };
  274. /**
  275. * @param {number} value
  276. * @return {!proto.google.protobuf.compiler.Version} returns this
  277. */
  278. proto.google.protobuf.compiler.Version.prototype.setMinor = function(value) {
  279. return jspb.Message.setField(this, 2, value);
  280. };
  281. /**
  282. * Clears the field making it undefined.
  283. * @return {!proto.google.protobuf.compiler.Version} returns this
  284. */
  285. proto.google.protobuf.compiler.Version.prototype.clearMinor = function() {
  286. return jspb.Message.setField(this, 2, undefined);
  287. };
  288. /**
  289. * Returns whether this field is set.
  290. * @return {boolean}
  291. */
  292. proto.google.protobuf.compiler.Version.prototype.hasMinor = function() {
  293. return jspb.Message.getField(this, 2) != null;
  294. };
  295. /**
  296. * optional int32 patch = 3;
  297. * @return {number}
  298. */
  299. proto.google.protobuf.compiler.Version.prototype.getPatch = function() {
  300. return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 3, 0));
  301. };
  302. /**
  303. * @param {number} value
  304. * @return {!proto.google.protobuf.compiler.Version} returns this
  305. */
  306. proto.google.protobuf.compiler.Version.prototype.setPatch = function(value) {
  307. return jspb.Message.setField(this, 3, value);
  308. };
  309. /**
  310. * Clears the field making it undefined.
  311. * @return {!proto.google.protobuf.compiler.Version} returns this
  312. */
  313. proto.google.protobuf.compiler.Version.prototype.clearPatch = function() {
  314. return jspb.Message.setField(this, 3, undefined);
  315. };
  316. /**
  317. * Returns whether this field is set.
  318. * @return {boolean}
  319. */
  320. proto.google.protobuf.compiler.Version.prototype.hasPatch = function() {
  321. return jspb.Message.getField(this, 3) != null;
  322. };
  323. /**
  324. * optional string suffix = 4;
  325. * @return {string}
  326. */
  327. proto.google.protobuf.compiler.Version.prototype.getSuffix = function() {
  328. return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
  329. };
  330. /**
  331. * @param {string} value
  332. * @return {!proto.google.protobuf.compiler.Version} returns this
  333. */
  334. proto.google.protobuf.compiler.Version.prototype.setSuffix = function(value) {
  335. return jspb.Message.setField(this, 4, value);
  336. };
  337. /**
  338. * Clears the field making it undefined.
  339. * @return {!proto.google.protobuf.compiler.Version} returns this
  340. */
  341. proto.google.protobuf.compiler.Version.prototype.clearSuffix = function() {
  342. return jspb.Message.setField(this, 4, undefined);
  343. };
  344. /**
  345. * Returns whether this field is set.
  346. * @return {boolean}
  347. */
  348. proto.google.protobuf.compiler.Version.prototype.hasSuffix = function() {
  349. return jspb.Message.getField(this, 4) != null;
  350. };
  351. /**
  352. * List of repeated fields within this message type.
  353. * @private {!Array<number>}
  354. * @const
  355. */
  356. proto.google.protobuf.compiler.CodeGeneratorRequest.repeatedFields_ = [1,15];
  357. if (jspb.Message.GENERATE_TO_OBJECT) {
  358. /**
  359. * Creates an object representation of this proto.
  360. * Field names that are reserved in JavaScript and will be renamed to pb_name.
  361. * Optional fields that are not set will be set to undefined.
  362. * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
  363. * For the list of reserved names please see:
  364. * net/proto2/compiler/js/internal/generator.cc#kKeyword.
  365. * @param {boolean=} opt_includeInstance Deprecated. whether to include the
  366. * JSPB instance for transitional soy proto support:
  367. * http://goto/soy-param-migration
  368. * @return {!Object}
  369. */
  370. proto.google.protobuf.compiler.CodeGeneratorRequest.prototype.toObject = function(opt_includeInstance) {
  371. return proto.google.protobuf.compiler.CodeGeneratorRequest.toObject(opt_includeInstance, this);
  372. };
  373. /**
  374. * Static version of the {@see toObject} method.
  375. * @param {boolean|undefined} includeInstance Deprecated. Whether to include
  376. * the JSPB instance for transitional soy proto support:
  377. * http://goto/soy-param-migration
  378. * @param {!proto.google.protobuf.compiler.CodeGeneratorRequest} msg The msg instance to transform.
  379. * @return {!Object}
  380. * @suppress {unusedLocalVariables} f is only used for nested messages
  381. */
  382. proto.google.protobuf.compiler.CodeGeneratorRequest.toObject = function(includeInstance, msg) {
  383. var f, obj = {
  384. fileToGenerateList: (f = jspb.Message.getRepeatedField(msg, 1)) == null ? undefined : f,
  385. parameter: (f = jspb.Message.getField(msg, 2)) == null ? undefined : f,
  386. protoFileList: jspb.Message.toObjectList(msg.getProtoFileList(),
  387. proto.google.protobuf.FileDescriptorProto.toObject, includeInstance),
  388. compilerVersion: (f = msg.getCompilerVersion()) && proto.google.protobuf.compiler.Version.toObject(includeInstance, f)
  389. };
  390. if (includeInstance) {
  391. obj.$jspbMessageInstance = msg;
  392. }
  393. return obj;
  394. };
  395. }
  396. /**
  397. * Deserializes binary data (in protobuf wire format).
  398. * @param {jspb.ByteSource} bytes The bytes to deserialize.
  399. * @return {!proto.google.protobuf.compiler.CodeGeneratorRequest}
  400. */
  401. proto.google.protobuf.compiler.CodeGeneratorRequest.deserializeBinary = function(bytes) {
  402. var reader = new jspb.BinaryReader(bytes);
  403. var msg = new proto.google.protobuf.compiler.CodeGeneratorRequest;
  404. return proto.google.protobuf.compiler.CodeGeneratorRequest.deserializeBinaryFromReader(msg, reader);
  405. };
  406. /**
  407. * Deserializes binary data (in protobuf wire format) from the
  408. * given reader into the given message object.
  409. * @param {!proto.google.protobuf.compiler.CodeGeneratorRequest} msg The message object to deserialize into.
  410. * @param {!jspb.BinaryReader} reader The BinaryReader to use.
  411. * @return {!proto.google.protobuf.compiler.CodeGeneratorRequest}
  412. */
  413. proto.google.protobuf.compiler.CodeGeneratorRequest.deserializeBinaryFromReader = function(msg, reader) {
  414. while (reader.nextField()) {
  415. if (reader.isEndGroup()) {
  416. break;
  417. }
  418. var field = reader.getFieldNumber();
  419. switch (field) {
  420. case 1:
  421. var value = /** @type {string} */ (reader.readString());
  422. msg.addFileToGenerate(value);
  423. break;
  424. case 2:
  425. var value = /** @type {string} */ (reader.readString());
  426. msg.setParameter(value);
  427. break;
  428. case 15:
  429. var value = new proto.google.protobuf.FileDescriptorProto;
  430. reader.readMessage(value,proto.google.protobuf.FileDescriptorProto.deserializeBinaryFromReader);
  431. msg.addProtoFile(value);
  432. break;
  433. case 3:
  434. var value = new proto.google.protobuf.compiler.Version;
  435. reader.readMessage(value,proto.google.protobuf.compiler.Version.deserializeBinaryFromReader);
  436. msg.setCompilerVersion(value);
  437. break;
  438. default:
  439. reader.skipField();
  440. break;
  441. }
  442. }
  443. return msg;
  444. };
  445. /**
  446. * Serializes the message to binary data (in protobuf wire format).
  447. * @return {!Uint8Array}
  448. */
  449. proto.google.protobuf.compiler.CodeGeneratorRequest.prototype.serializeBinary = function() {
  450. var writer = new jspb.BinaryWriter();
  451. proto.google.protobuf.compiler.CodeGeneratorRequest.serializeBinaryToWriter(this, writer);
  452. return writer.getResultBuffer();
  453. };
  454. /**
  455. * Serializes the given message to binary data (in protobuf wire
  456. * format), writing to the given BinaryWriter.
  457. * @param {!proto.google.protobuf.compiler.CodeGeneratorRequest} message
  458. * @param {!jspb.BinaryWriter} writer
  459. * @suppress {unusedLocalVariables} f is only used for nested messages
  460. */
  461. proto.google.protobuf.compiler.CodeGeneratorRequest.serializeBinaryToWriter = function(message, writer) {
  462. var f = undefined;
  463. f = message.getFileToGenerateList();
  464. if (f.length > 0) {
  465. writer.writeRepeatedString(
  466. 1,
  467. f
  468. );
  469. }
  470. f = /** @type {string} */ (jspb.Message.getField(message, 2));
  471. if (f != null) {
  472. writer.writeString(
  473. 2,
  474. f
  475. );
  476. }
  477. f = message.getProtoFileList();
  478. if (f.length > 0) {
  479. writer.writeRepeatedMessage(
  480. 15,
  481. f,
  482. proto.google.protobuf.FileDescriptorProto.serializeBinaryToWriter
  483. );
  484. }
  485. f = message.getCompilerVersion();
  486. if (f != null) {
  487. writer.writeMessage(
  488. 3,
  489. f,
  490. proto.google.protobuf.compiler.Version.serializeBinaryToWriter
  491. );
  492. }
  493. };
  494. /**
  495. * repeated string file_to_generate = 1;
  496. * @return {!Array<string>}
  497. */
  498. proto.google.protobuf.compiler.CodeGeneratorRequest.prototype.getFileToGenerateList = function() {
  499. return /** @type {!Array<string>} */ (jspb.Message.getRepeatedField(this, 1));
  500. };
  501. /**
  502. * @param {!Array<string>} value
  503. * @return {!proto.google.protobuf.compiler.CodeGeneratorRequest} returns this
  504. */
  505. proto.google.protobuf.compiler.CodeGeneratorRequest.prototype.setFileToGenerateList = function(value) {
  506. return jspb.Message.setField(this, 1, value || []);
  507. };
  508. /**
  509. * @param {string} value
  510. * @param {number=} opt_index
  511. * @return {!proto.google.protobuf.compiler.CodeGeneratorRequest} returns this
  512. */
  513. proto.google.protobuf.compiler.CodeGeneratorRequest.prototype.addFileToGenerate = function(value, opt_index) {
  514. return jspb.Message.addToRepeatedField(this, 1, value, opt_index);
  515. };
  516. /**
  517. * Clears the list making it empty but non-null.
  518. * @return {!proto.google.protobuf.compiler.CodeGeneratorRequest} returns this
  519. */
  520. proto.google.protobuf.compiler.CodeGeneratorRequest.prototype.clearFileToGenerateList = function() {
  521. return this.setFileToGenerateList([]);
  522. };
  523. /**
  524. * optional string parameter = 2;
  525. * @return {string}
  526. */
  527. proto.google.protobuf.compiler.CodeGeneratorRequest.prototype.getParameter = function() {
  528. return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
  529. };
  530. /**
  531. * @param {string} value
  532. * @return {!proto.google.protobuf.compiler.CodeGeneratorRequest} returns this
  533. */
  534. proto.google.protobuf.compiler.CodeGeneratorRequest.prototype.setParameter = function(value) {
  535. return jspb.Message.setField(this, 2, value);
  536. };
  537. /**
  538. * Clears the field making it undefined.
  539. * @return {!proto.google.protobuf.compiler.CodeGeneratorRequest} returns this
  540. */
  541. proto.google.protobuf.compiler.CodeGeneratorRequest.prototype.clearParameter = function() {
  542. return jspb.Message.setField(this, 2, undefined);
  543. };
  544. /**
  545. * Returns whether this field is set.
  546. * @return {boolean}
  547. */
  548. proto.google.protobuf.compiler.CodeGeneratorRequest.prototype.hasParameter = function() {
  549. return jspb.Message.getField(this, 2) != null;
  550. };
  551. /**
  552. * repeated google.protobuf.FileDescriptorProto proto_file = 15;
  553. * @return {!Array<!proto.google.protobuf.FileDescriptorProto>}
  554. */
  555. proto.google.protobuf.compiler.CodeGeneratorRequest.prototype.getProtoFileList = function() {
  556. return /** @type{!Array<!proto.google.protobuf.FileDescriptorProto>} */ (
  557. jspb.Message.getRepeatedWrapperField(this, proto.google.protobuf.FileDescriptorProto, 15));
  558. };
  559. /**
  560. * @param {!Array<!proto.google.protobuf.FileDescriptorProto>} value
  561. * @return {!proto.google.protobuf.compiler.CodeGeneratorRequest} returns this
  562. */
  563. proto.google.protobuf.compiler.CodeGeneratorRequest.prototype.setProtoFileList = function(value) {
  564. return jspb.Message.setRepeatedWrapperField(this, 15, value);
  565. };
  566. /**
  567. * @param {!proto.google.protobuf.FileDescriptorProto=} opt_value
  568. * @param {number=} opt_index
  569. * @return {!proto.google.protobuf.FileDescriptorProto}
  570. */
  571. proto.google.protobuf.compiler.CodeGeneratorRequest.prototype.addProtoFile = function(opt_value, opt_index) {
  572. return jspb.Message.addToRepeatedWrapperField(this, 15, opt_value, proto.google.protobuf.FileDescriptorProto, opt_index);
  573. };
  574. /**
  575. * Clears the list making it empty but non-null.
  576. * @return {!proto.google.protobuf.compiler.CodeGeneratorRequest} returns this
  577. */
  578. proto.google.protobuf.compiler.CodeGeneratorRequest.prototype.clearProtoFileList = function() {
  579. return this.setProtoFileList([]);
  580. };
  581. /**
  582. * optional Version compiler_version = 3;
  583. * @return {?proto.google.protobuf.compiler.Version}
  584. */
  585. proto.google.protobuf.compiler.CodeGeneratorRequest.prototype.getCompilerVersion = function() {
  586. return /** @type{?proto.google.protobuf.compiler.Version} */ (
  587. jspb.Message.getWrapperField(this, proto.google.protobuf.compiler.Version, 3));
  588. };
  589. /**
  590. * @param {?proto.google.protobuf.compiler.Version|undefined} value
  591. * @return {!proto.google.protobuf.compiler.CodeGeneratorRequest} returns this
  592. */
  593. proto.google.protobuf.compiler.CodeGeneratorRequest.prototype.setCompilerVersion = function(value) {
  594. return jspb.Message.setWrapperField(this, 3, value);
  595. };
  596. /**
  597. * Clears the message field making it undefined.
  598. * @return {!proto.google.protobuf.compiler.CodeGeneratorRequest} returns this
  599. */
  600. proto.google.protobuf.compiler.CodeGeneratorRequest.prototype.clearCompilerVersion = function() {
  601. return this.setCompilerVersion(undefined);
  602. };
  603. /**
  604. * Returns whether this field is set.
  605. * @return {boolean}
  606. */
  607. proto.google.protobuf.compiler.CodeGeneratorRequest.prototype.hasCompilerVersion = function() {
  608. return jspb.Message.getField(this, 3) != null;
  609. };
  610. /**
  611. * List of repeated fields within this message type.
  612. * @private {!Array<number>}
  613. * @const
  614. */
  615. proto.google.protobuf.compiler.CodeGeneratorResponse.repeatedFields_ = [15];
  616. if (jspb.Message.GENERATE_TO_OBJECT) {
  617. /**
  618. * Creates an object representation of this proto.
  619. * Field names that are reserved in JavaScript and will be renamed to pb_name.
  620. * Optional fields that are not set will be set to undefined.
  621. * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
  622. * For the list of reserved names please see:
  623. * net/proto2/compiler/js/internal/generator.cc#kKeyword.
  624. * @param {boolean=} opt_includeInstance Deprecated. whether to include the
  625. * JSPB instance for transitional soy proto support:
  626. * http://goto/soy-param-migration
  627. * @return {!Object}
  628. */
  629. proto.google.protobuf.compiler.CodeGeneratorResponse.prototype.toObject = function(opt_includeInstance) {
  630. return proto.google.protobuf.compiler.CodeGeneratorResponse.toObject(opt_includeInstance, this);
  631. };
  632. /**
  633. * Static version of the {@see toObject} method.
  634. * @param {boolean|undefined} includeInstance Deprecated. Whether to include
  635. * the JSPB instance for transitional soy proto support:
  636. * http://goto/soy-param-migration
  637. * @param {!proto.google.protobuf.compiler.CodeGeneratorResponse} msg The msg instance to transform.
  638. * @return {!Object}
  639. * @suppress {unusedLocalVariables} f is only used for nested messages
  640. */
  641. proto.google.protobuf.compiler.CodeGeneratorResponse.toObject = function(includeInstance, msg) {
  642. var f, obj = {
  643. error: (f = jspb.Message.getField(msg, 1)) == null ? undefined : f,
  644. supportedFeatures: (f = jspb.Message.getField(msg, 2)) == null ? undefined : f,
  645. fileList: jspb.Message.toObjectList(msg.getFileList(),
  646. proto.google.protobuf.compiler.CodeGeneratorResponse.File.toObject, includeInstance)
  647. };
  648. if (includeInstance) {
  649. obj.$jspbMessageInstance = msg;
  650. }
  651. return obj;
  652. };
  653. }
  654. /**
  655. * Deserializes binary data (in protobuf wire format).
  656. * @param {jspb.ByteSource} bytes The bytes to deserialize.
  657. * @return {!proto.google.protobuf.compiler.CodeGeneratorResponse}
  658. */
  659. proto.google.protobuf.compiler.CodeGeneratorResponse.deserializeBinary = function(bytes) {
  660. var reader = new jspb.BinaryReader(bytes);
  661. var msg = new proto.google.protobuf.compiler.CodeGeneratorResponse;
  662. return proto.google.protobuf.compiler.CodeGeneratorResponse.deserializeBinaryFromReader(msg, reader);
  663. };
  664. /**
  665. * Deserializes binary data (in protobuf wire format) from the
  666. * given reader into the given message object.
  667. * @param {!proto.google.protobuf.compiler.CodeGeneratorResponse} msg The message object to deserialize into.
  668. * @param {!jspb.BinaryReader} reader The BinaryReader to use.
  669. * @return {!proto.google.protobuf.compiler.CodeGeneratorResponse}
  670. */
  671. proto.google.protobuf.compiler.CodeGeneratorResponse.deserializeBinaryFromReader = function(msg, reader) {
  672. while (reader.nextField()) {
  673. if (reader.isEndGroup()) {
  674. break;
  675. }
  676. var field = reader.getFieldNumber();
  677. switch (field) {
  678. case 1:
  679. var value = /** @type {string} */ (reader.readString());
  680. msg.setError(value);
  681. break;
  682. case 2:
  683. var value = /** @type {number} */ (reader.readUint64());
  684. msg.setSupportedFeatures(value);
  685. break;
  686. case 15:
  687. var value = new proto.google.protobuf.compiler.CodeGeneratorResponse.File;
  688. reader.readMessage(value,proto.google.protobuf.compiler.CodeGeneratorResponse.File.deserializeBinaryFromReader);
  689. msg.addFile(value);
  690. break;
  691. default:
  692. reader.skipField();
  693. break;
  694. }
  695. }
  696. return msg;
  697. };
  698. /**
  699. * Serializes the message to binary data (in protobuf wire format).
  700. * @return {!Uint8Array}
  701. */
  702. proto.google.protobuf.compiler.CodeGeneratorResponse.prototype.serializeBinary = function() {
  703. var writer = new jspb.BinaryWriter();
  704. proto.google.protobuf.compiler.CodeGeneratorResponse.serializeBinaryToWriter(this, writer);
  705. return writer.getResultBuffer();
  706. };
  707. /**
  708. * Serializes the given message to binary data (in protobuf wire
  709. * format), writing to the given BinaryWriter.
  710. * @param {!proto.google.protobuf.compiler.CodeGeneratorResponse} message
  711. * @param {!jspb.BinaryWriter} writer
  712. * @suppress {unusedLocalVariables} f is only used for nested messages
  713. */
  714. proto.google.protobuf.compiler.CodeGeneratorResponse.serializeBinaryToWriter = function(message, writer) {
  715. var f = undefined;
  716. f = /** @type {string} */ (jspb.Message.getField(message, 1));
  717. if (f != null) {
  718. writer.writeString(
  719. 1,
  720. f
  721. );
  722. }
  723. f = /** @type {number} */ (jspb.Message.getField(message, 2));
  724. if (f != null) {
  725. writer.writeUint64(
  726. 2,
  727. f
  728. );
  729. }
  730. f = message.getFileList();
  731. if (f.length > 0) {
  732. writer.writeRepeatedMessage(
  733. 15,
  734. f,
  735. proto.google.protobuf.compiler.CodeGeneratorResponse.File.serializeBinaryToWriter
  736. );
  737. }
  738. };
  739. /**
  740. * @enum {number}
  741. */
  742. proto.google.protobuf.compiler.CodeGeneratorResponse.Feature = {
  743. FEATURE_NONE: 0,
  744. FEATURE_PROTO3_OPTIONAL: 1
  745. };
  746. if (jspb.Message.GENERATE_TO_OBJECT) {
  747. /**
  748. * Creates an object representation of this proto.
  749. * Field names that are reserved in JavaScript and will be renamed to pb_name.
  750. * Optional fields that are not set will be set to undefined.
  751. * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
  752. * For the list of reserved names please see:
  753. * net/proto2/compiler/js/internal/generator.cc#kKeyword.
  754. * @param {boolean=} opt_includeInstance Deprecated. whether to include the
  755. * JSPB instance for transitional soy proto support:
  756. * http://goto/soy-param-migration
  757. * @return {!Object}
  758. */
  759. proto.google.protobuf.compiler.CodeGeneratorResponse.File.prototype.toObject = function(opt_includeInstance) {
  760. return proto.google.protobuf.compiler.CodeGeneratorResponse.File.toObject(opt_includeInstance, this);
  761. };
  762. /**
  763. * Static version of the {@see toObject} method.
  764. * @param {boolean|undefined} includeInstance Deprecated. Whether to include
  765. * the JSPB instance for transitional soy proto support:
  766. * http://goto/soy-param-migration
  767. * @param {!proto.google.protobuf.compiler.CodeGeneratorResponse.File} msg The msg instance to transform.
  768. * @return {!Object}
  769. * @suppress {unusedLocalVariables} f is only used for nested messages
  770. */
  771. proto.google.protobuf.compiler.CodeGeneratorResponse.File.toObject = function(includeInstance, msg) {
  772. var f, obj = {
  773. name: (f = jspb.Message.getField(msg, 1)) == null ? undefined : f,
  774. insertionPoint: (f = jspb.Message.getField(msg, 2)) == null ? undefined : f,
  775. content: (f = jspb.Message.getField(msg, 15)) == null ? undefined : f,
  776. generatedCodeInfo: (f = msg.getGeneratedCodeInfo()) && proto.google.protobuf.GeneratedCodeInfo.toObject(includeInstance, f)
  777. };
  778. if (includeInstance) {
  779. obj.$jspbMessageInstance = msg;
  780. }
  781. return obj;
  782. };
  783. }
  784. /**
  785. * Deserializes binary data (in protobuf wire format).
  786. * @param {jspb.ByteSource} bytes The bytes to deserialize.
  787. * @return {!proto.google.protobuf.compiler.CodeGeneratorResponse.File}
  788. */
  789. proto.google.protobuf.compiler.CodeGeneratorResponse.File.deserializeBinary = function(bytes) {
  790. var reader = new jspb.BinaryReader(bytes);
  791. var msg = new proto.google.protobuf.compiler.CodeGeneratorResponse.File;
  792. return proto.google.protobuf.compiler.CodeGeneratorResponse.File.deserializeBinaryFromReader(msg, reader);
  793. };
  794. /**
  795. * Deserializes binary data (in protobuf wire format) from the
  796. * given reader into the given message object.
  797. * @param {!proto.google.protobuf.compiler.CodeGeneratorResponse.File} msg The message object to deserialize into.
  798. * @param {!jspb.BinaryReader} reader The BinaryReader to use.
  799. * @return {!proto.google.protobuf.compiler.CodeGeneratorResponse.File}
  800. */
  801. proto.google.protobuf.compiler.CodeGeneratorResponse.File.deserializeBinaryFromReader = function(msg, reader) {
  802. while (reader.nextField()) {
  803. if (reader.isEndGroup()) {
  804. break;
  805. }
  806. var field = reader.getFieldNumber();
  807. switch (field) {
  808. case 1:
  809. var value = /** @type {string} */ (reader.readString());
  810. msg.setName(value);
  811. break;
  812. case 2:
  813. var value = /** @type {string} */ (reader.readString());
  814. msg.setInsertionPoint(value);
  815. break;
  816. case 15:
  817. var value = /** @type {string} */ (reader.readString());
  818. msg.setContent(value);
  819. break;
  820. case 16:
  821. var value = new proto.google.protobuf.GeneratedCodeInfo;
  822. reader.readMessage(value,proto.google.protobuf.GeneratedCodeInfo.deserializeBinaryFromReader);
  823. msg.setGeneratedCodeInfo(value);
  824. break;
  825. default:
  826. reader.skipField();
  827. break;
  828. }
  829. }
  830. return msg;
  831. };
  832. /**
  833. * Serializes the message to binary data (in protobuf wire format).
  834. * @return {!Uint8Array}
  835. */
  836. proto.google.protobuf.compiler.CodeGeneratorResponse.File.prototype.serializeBinary = function() {
  837. var writer = new jspb.BinaryWriter();
  838. proto.google.protobuf.compiler.CodeGeneratorResponse.File.serializeBinaryToWriter(this, writer);
  839. return writer.getResultBuffer();
  840. };
  841. /**
  842. * Serializes the given message to binary data (in protobuf wire
  843. * format), writing to the given BinaryWriter.
  844. * @param {!proto.google.protobuf.compiler.CodeGeneratorResponse.File} message
  845. * @param {!jspb.BinaryWriter} writer
  846. * @suppress {unusedLocalVariables} f is only used for nested messages
  847. */
  848. proto.google.protobuf.compiler.CodeGeneratorResponse.File.serializeBinaryToWriter = function(message, writer) {
  849. var f = undefined;
  850. f = /** @type {string} */ (jspb.Message.getField(message, 1));
  851. if (f != null) {
  852. writer.writeString(
  853. 1,
  854. f
  855. );
  856. }
  857. f = /** @type {string} */ (jspb.Message.getField(message, 2));
  858. if (f != null) {
  859. writer.writeString(
  860. 2,
  861. f
  862. );
  863. }
  864. f = /** @type {string} */ (jspb.Message.getField(message, 15));
  865. if (f != null) {
  866. writer.writeString(
  867. 15,
  868. f
  869. );
  870. }
  871. f = message.getGeneratedCodeInfo();
  872. if (f != null) {
  873. writer.writeMessage(
  874. 16,
  875. f,
  876. proto.google.protobuf.GeneratedCodeInfo.serializeBinaryToWriter
  877. );
  878. }
  879. };
  880. /**
  881. * optional string name = 1;
  882. * @return {string}
  883. */
  884. proto.google.protobuf.compiler.CodeGeneratorResponse.File.prototype.getName = function() {
  885. return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
  886. };
  887. /**
  888. * @param {string} value
  889. * @return {!proto.google.protobuf.compiler.CodeGeneratorResponse.File} returns this
  890. */
  891. proto.google.protobuf.compiler.CodeGeneratorResponse.File.prototype.setName = function(value) {
  892. return jspb.Message.setField(this, 1, value);
  893. };
  894. /**
  895. * Clears the field making it undefined.
  896. * @return {!proto.google.protobuf.compiler.CodeGeneratorResponse.File} returns this
  897. */
  898. proto.google.protobuf.compiler.CodeGeneratorResponse.File.prototype.clearName = function() {
  899. return jspb.Message.setField(this, 1, undefined);
  900. };
  901. /**
  902. * Returns whether this field is set.
  903. * @return {boolean}
  904. */
  905. proto.google.protobuf.compiler.CodeGeneratorResponse.File.prototype.hasName = function() {
  906. return jspb.Message.getField(this, 1) != null;
  907. };
  908. /**
  909. * optional string insertion_point = 2;
  910. * @return {string}
  911. */
  912. proto.google.protobuf.compiler.CodeGeneratorResponse.File.prototype.getInsertionPoint = function() {
  913. return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
  914. };
  915. /**
  916. * @param {string} value
  917. * @return {!proto.google.protobuf.compiler.CodeGeneratorResponse.File} returns this
  918. */
  919. proto.google.protobuf.compiler.CodeGeneratorResponse.File.prototype.setInsertionPoint = function(value) {
  920. return jspb.Message.setField(this, 2, value);
  921. };
  922. /**
  923. * Clears the field making it undefined.
  924. * @return {!proto.google.protobuf.compiler.CodeGeneratorResponse.File} returns this
  925. */
  926. proto.google.protobuf.compiler.CodeGeneratorResponse.File.prototype.clearInsertionPoint = function() {
  927. return jspb.Message.setField(this, 2, undefined);
  928. };
  929. /**
  930. * Returns whether this field is set.
  931. * @return {boolean}
  932. */
  933. proto.google.protobuf.compiler.CodeGeneratorResponse.File.prototype.hasInsertionPoint = function() {
  934. return jspb.Message.getField(this, 2) != null;
  935. };
  936. /**
  937. * optional string content = 15;
  938. * @return {string}
  939. */
  940. proto.google.protobuf.compiler.CodeGeneratorResponse.File.prototype.getContent = function() {
  941. return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 15, ""));
  942. };
  943. /**
  944. * @param {string} value
  945. * @return {!proto.google.protobuf.compiler.CodeGeneratorResponse.File} returns this
  946. */
  947. proto.google.protobuf.compiler.CodeGeneratorResponse.File.prototype.setContent = function(value) {
  948. return jspb.Message.setField(this, 15, value);
  949. };
  950. /**
  951. * Clears the field making it undefined.
  952. * @return {!proto.google.protobuf.compiler.CodeGeneratorResponse.File} returns this
  953. */
  954. proto.google.protobuf.compiler.CodeGeneratorResponse.File.prototype.clearContent = function() {
  955. return jspb.Message.setField(this, 15, undefined);
  956. };
  957. /**
  958. * Returns whether this field is set.
  959. * @return {boolean}
  960. */
  961. proto.google.protobuf.compiler.CodeGeneratorResponse.File.prototype.hasContent = function() {
  962. return jspb.Message.getField(this, 15) != null;
  963. };
  964. /**
  965. * optional google.protobuf.GeneratedCodeInfo generated_code_info = 16;
  966. * @return {?proto.google.protobuf.GeneratedCodeInfo}
  967. */
  968. proto.google.protobuf.compiler.CodeGeneratorResponse.File.prototype.getGeneratedCodeInfo = function() {
  969. return /** @type{?proto.google.protobuf.GeneratedCodeInfo} */ (
  970. jspb.Message.getWrapperField(this, proto.google.protobuf.GeneratedCodeInfo, 16));
  971. };
  972. /**
  973. * @param {?proto.google.protobuf.GeneratedCodeInfo|undefined} value
  974. * @return {!proto.google.protobuf.compiler.CodeGeneratorResponse.File} returns this
  975. */
  976. proto.google.protobuf.compiler.CodeGeneratorResponse.File.prototype.setGeneratedCodeInfo = function(value) {
  977. return jspb.Message.setWrapperField(this, 16, value);
  978. };
  979. /**
  980. * Clears the message field making it undefined.
  981. * @return {!proto.google.protobuf.compiler.CodeGeneratorResponse.File} returns this
  982. */
  983. proto.google.protobuf.compiler.CodeGeneratorResponse.File.prototype.clearGeneratedCodeInfo = function() {
  984. return this.setGeneratedCodeInfo(undefined);
  985. };
  986. /**
  987. * Returns whether this field is set.
  988. * @return {boolean}
  989. */
  990. proto.google.protobuf.compiler.CodeGeneratorResponse.File.prototype.hasGeneratedCodeInfo = function() {
  991. return jspb.Message.getField(this, 16) != null;
  992. };
  993. /**
  994. * optional string error = 1;
  995. * @return {string}
  996. */
  997. proto.google.protobuf.compiler.CodeGeneratorResponse.prototype.getError = function() {
  998. return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
  999. };
  1000. /**
  1001. * @param {string} value
  1002. * @return {!proto.google.protobuf.compiler.CodeGeneratorResponse} returns this
  1003. */
  1004. proto.google.protobuf.compiler.CodeGeneratorResponse.prototype.setError = function(value) {
  1005. return jspb.Message.setField(this, 1, value);
  1006. };
  1007. /**
  1008. * Clears the field making it undefined.
  1009. * @return {!proto.google.protobuf.compiler.CodeGeneratorResponse} returns this
  1010. */
  1011. proto.google.protobuf.compiler.CodeGeneratorResponse.prototype.clearError = function() {
  1012. return jspb.Message.setField(this, 1, undefined);
  1013. };
  1014. /**
  1015. * Returns whether this field is set.
  1016. * @return {boolean}
  1017. */
  1018. proto.google.protobuf.compiler.CodeGeneratorResponse.prototype.hasError = function() {
  1019. return jspb.Message.getField(this, 1) != null;
  1020. };
  1021. /**
  1022. * optional uint64 supported_features = 2;
  1023. * @return {number}
  1024. */
  1025. proto.google.protobuf.compiler.CodeGeneratorResponse.prototype.getSupportedFeatures = function() {
  1026. return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 2, 0));
  1027. };
  1028. /**
  1029. * @param {number} value
  1030. * @return {!proto.google.protobuf.compiler.CodeGeneratorResponse} returns this
  1031. */
  1032. proto.google.protobuf.compiler.CodeGeneratorResponse.prototype.setSupportedFeatures = function(value) {
  1033. return jspb.Message.setField(this, 2, value);
  1034. };
  1035. /**
  1036. * Clears the field making it undefined.
  1037. * @return {!proto.google.protobuf.compiler.CodeGeneratorResponse} returns this
  1038. */
  1039. proto.google.protobuf.compiler.CodeGeneratorResponse.prototype.clearSupportedFeatures = function() {
  1040. return jspb.Message.setField(this, 2, undefined);
  1041. };
  1042. /**
  1043. * Returns whether this field is set.
  1044. * @return {boolean}
  1045. */
  1046. proto.google.protobuf.compiler.CodeGeneratorResponse.prototype.hasSupportedFeatures = function() {
  1047. return jspb.Message.getField(this, 2) != null;
  1048. };
  1049. /**
  1050. * repeated File file = 15;
  1051. * @return {!Array<!proto.google.protobuf.compiler.CodeGeneratorResponse.File>}
  1052. */
  1053. proto.google.protobuf.compiler.CodeGeneratorResponse.prototype.getFileList = function() {
  1054. return /** @type{!Array<!proto.google.protobuf.compiler.CodeGeneratorResponse.File>} */ (
  1055. jspb.Message.getRepeatedWrapperField(this, proto.google.protobuf.compiler.CodeGeneratorResponse.File, 15));
  1056. };
  1057. /**
  1058. * @param {!Array<!proto.google.protobuf.compiler.CodeGeneratorResponse.File>} value
  1059. * @return {!proto.google.protobuf.compiler.CodeGeneratorResponse} returns this
  1060. */
  1061. proto.google.protobuf.compiler.CodeGeneratorResponse.prototype.setFileList = function(value) {
  1062. return jspb.Message.setRepeatedWrapperField(this, 15, value);
  1063. };
  1064. /**
  1065. * @param {!proto.google.protobuf.compiler.CodeGeneratorResponse.File=} opt_value
  1066. * @param {number=} opt_index
  1067. * @return {!proto.google.protobuf.compiler.CodeGeneratorResponse.File}
  1068. */
  1069. proto.google.protobuf.compiler.CodeGeneratorResponse.prototype.addFile = function(opt_value, opt_index) {
  1070. return jspb.Message.addToRepeatedWrapperField(this, 15, opt_value, proto.google.protobuf.compiler.CodeGeneratorResponse.File, opt_index);
  1071. };
  1072. /**
  1073. * Clears the list making it empty but non-null.
  1074. * @return {!proto.google.protobuf.compiler.CodeGeneratorResponse} returns this
  1075. */
  1076. proto.google.protobuf.compiler.CodeGeneratorResponse.prototype.clearFileList = function() {
  1077. return this.setFileList([]);
  1078. };