plugin_pb.js 40 KB

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