UNPKG

grpc-tools-ts

Version:

Generate d.ts definitions for generated js files from grpc_tools_node_protoc

904 lines (776 loc) 26.4 kB
/** * @fileoverview * @enhanceable * @suppress {messageConventions} JS Compiler reports an error if a variable or * field starts with 'MSG_' and isn't a translatable message. * @public */ // GENERATED CODE -- DO NOT EDIT! var jspb = require('google-protobuf'); var goog = jspb; var global = Function('return this')(); goog.exportSymbol('proto.com.book.Book', null, global); goog.exportSymbol('proto.com.book.BookStore', null, global); goog.exportSymbol('proto.com.book.EnumSample', null, global); goog.exportSymbol('proto.com.book.GetBookRequest', null, global); goog.exportSymbol('proto.com.book.GetBookViaAuthor', null, global); goog.exportSymbol('proto.com.book.SpecialCases', null, global); /** * Generated by JsPbCodeGenerator. * @param {Array=} opt_data Optional initial data array, typically from a * server response, or constructed directly in Javascript. The array is used * in place and becomes part of the constructed object. It is not cloned. * If no data is provided, the constructed object will be empty, but still * valid. * @extends {jspb.Message} * @constructor */ proto.com.book.Book = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.com.book.Book, jspb.Message); if (goog.DEBUG && !COMPILED) { proto.com.book.Book.displayName = 'proto.com.book.Book'; } if (jspb.Message.GENERATE_TO_OBJECT) { /** * Creates an object representation of this proto suitable for use in Soy templates. * Field names that are reserved in JavaScript and will be renamed to pb_name. * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default. * For the list of reserved names please see: * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS. * @param {boolean=} opt_includeInstance Whether to include the JSPB instance * for transitional soy proto support: http://goto/soy-param-migration * @return {!Object} */ proto.com.book.Book.prototype.toObject = function(opt_includeInstance) { return proto.com.book.Book.toObject(opt_includeInstance, this); }; /** * Static version of the {@see toObject} method. * @param {boolean|undefined} includeInstance Whether to include the JSPB * instance for transitional soy proto support: * http://goto/soy-param-migration * @param {!proto.com.book.Book} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.com.book.Book.toObject = function(includeInstance, msg) { var f, obj = { isbn: jspb.Message.getFieldWithDefault(msg, 1, 0), title: jspb.Message.getFieldWithDefault(msg, 2, ""), author: jspb.Message.getFieldWithDefault(msg, 3, "") }; if (includeInstance) { obj.$jspbMessageInstance = msg; } return obj; }; } /** * Deserializes binary data (in protobuf wire format). * @param {jspb.ByteSource} bytes The bytes to deserialize. * @return {!proto.com.book.Book} */ proto.com.book.Book.deserializeBinary = function(bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.com.book.Book; return proto.com.book.Book.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.com.book.Book} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.com.book.Book} */ proto.com.book.Book.deserializeBinaryFromReader = function(msg, reader) { while (reader.nextField()) { if (reader.isEndGroup()) { break; } var field = reader.getFieldNumber(); switch (field) { case 1: var value = /** @type {number} */ (reader.readInt64()); msg.setIsbn(value); break; case 2: var value = /** @type {string} */ (reader.readString()); msg.setTitle(value); break; case 3: var value = /** @type {string} */ (reader.readString()); msg.setAuthor(value); break; default: reader.skipField(); break; } } return msg; }; /** * Serializes the message to binary data (in protobuf wire format). * @return {!Uint8Array} */ proto.com.book.Book.prototype.serializeBinary = function() { var writer = new jspb.BinaryWriter(); proto.com.book.Book.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.com.book.Book} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.com.book.Book.serializeBinaryToWriter = function(message, writer) { var f = undefined; f = message.getIsbn(); if (f !== 0) { writer.writeInt64( 1, f ); } f = message.getTitle(); if (f.length > 0) { writer.writeString( 2, f ); } f = message.getAuthor(); if (f.length > 0) { writer.writeString( 3, f ); } }; /** * optional int64 isbn = 1; * @return {number} */ proto.com.book.Book.prototype.getIsbn = function() { return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0)); }; /** @param {number} value */ proto.com.book.Book.prototype.setIsbn = function(value) { jspb.Message.setField(this, 1, value); }; /** * optional string title = 2; * @return {string} */ proto.com.book.Book.prototype.getTitle = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, "")); }; /** @param {string} value */ proto.com.book.Book.prototype.setTitle = function(value) { jspb.Message.setField(this, 2, value); }; /** * optional string author = 3; * @return {string} */ proto.com.book.Book.prototype.getAuthor = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, "")); }; /** @param {string} value */ proto.com.book.Book.prototype.setAuthor = function(value) { jspb.Message.setField(this, 3, value); }; /** * Generated by JsPbCodeGenerator. * @param {Array=} opt_data Optional initial data array, typically from a * server response, or constructed directly in Javascript. The array is used * in place and becomes part of the constructed object. It is not cloned. * If no data is provided, the constructed object will be empty, but still * valid. * @extends {jspb.Message} * @constructor */ proto.com.book.GetBookRequest = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.com.book.GetBookRequest, jspb.Message); if (goog.DEBUG && !COMPILED) { proto.com.book.GetBookRequest.displayName = 'proto.com.book.GetBookRequest'; } if (jspb.Message.GENERATE_TO_OBJECT) { /** * Creates an object representation of this proto suitable for use in Soy templates. * Field names that are reserved in JavaScript and will be renamed to pb_name. * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default. * For the list of reserved names please see: * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS. * @param {boolean=} opt_includeInstance Whether to include the JSPB instance * for transitional soy proto support: http://goto/soy-param-migration * @return {!Object} */ proto.com.book.GetBookRequest.prototype.toObject = function(opt_includeInstance) { return proto.com.book.GetBookRequest.toObject(opt_includeInstance, this); }; /** * Static version of the {@see toObject} method. * @param {boolean|undefined} includeInstance Whether to include the JSPB * instance for transitional soy proto support: * http://goto/soy-param-migration * @param {!proto.com.book.GetBookRequest} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.com.book.GetBookRequest.toObject = function(includeInstance, msg) { var f, obj = { isbn: jspb.Message.getFieldWithDefault(msg, 1, 0) }; if (includeInstance) { obj.$jspbMessageInstance = msg; } return obj; }; } /** * Deserializes binary data (in protobuf wire format). * @param {jspb.ByteSource} bytes The bytes to deserialize. * @return {!proto.com.book.GetBookRequest} */ proto.com.book.GetBookRequest.deserializeBinary = function(bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.com.book.GetBookRequest; return proto.com.book.GetBookRequest.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.com.book.GetBookRequest} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.com.book.GetBookRequest} */ proto.com.book.GetBookRequest.deserializeBinaryFromReader = function(msg, reader) { while (reader.nextField()) { if (reader.isEndGroup()) { break; } var field = reader.getFieldNumber(); switch (field) { case 1: var value = /** @type {number} */ (reader.readInt64()); msg.setIsbn(value); break; default: reader.skipField(); break; } } return msg; }; /** * Serializes the message to binary data (in protobuf wire format). * @return {!Uint8Array} */ proto.com.book.GetBookRequest.prototype.serializeBinary = function() { var writer = new jspb.BinaryWriter(); proto.com.book.GetBookRequest.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.com.book.GetBookRequest} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.com.book.GetBookRequest.serializeBinaryToWriter = function(message, writer) { var f = undefined; f = message.getIsbn(); if (f !== 0) { writer.writeInt64( 1, f ); } }; /** * optional int64 isbn = 1; * @return {number} */ proto.com.book.GetBookRequest.prototype.getIsbn = function() { return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0)); }; /** @param {number} value */ proto.com.book.GetBookRequest.prototype.setIsbn = function(value) { jspb.Message.setField(this, 1, value); }; /** * Generated by JsPbCodeGenerator. * @param {Array=} opt_data Optional initial data array, typically from a * server response, or constructed directly in Javascript. The array is used * in place and becomes part of the constructed object. It is not cloned. * If no data is provided, the constructed object will be empty, but still * valid. * @extends {jspb.Message} * @constructor */ proto.com.book.GetBookViaAuthor = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.com.book.GetBookViaAuthor, jspb.Message); if (goog.DEBUG && !COMPILED) { proto.com.book.GetBookViaAuthor.displayName = 'proto.com.book.GetBookViaAuthor'; } if (jspb.Message.GENERATE_TO_OBJECT) { /** * Creates an object representation of this proto suitable for use in Soy templates. * Field names that are reserved in JavaScript and will be renamed to pb_name. * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default. * For the list of reserved names please see: * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS. * @param {boolean=} opt_includeInstance Whether to include the JSPB instance * for transitional soy proto support: http://goto/soy-param-migration * @return {!Object} */ proto.com.book.GetBookViaAuthor.prototype.toObject = function(opt_includeInstance) { return proto.com.book.GetBookViaAuthor.toObject(opt_includeInstance, this); }; /** * Static version of the {@see toObject} method. * @param {boolean|undefined} includeInstance Whether to include the JSPB * instance for transitional soy proto support: * http://goto/soy-param-migration * @param {!proto.com.book.GetBookViaAuthor} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.com.book.GetBookViaAuthor.toObject = function(includeInstance, msg) { var f, obj = { author: jspb.Message.getFieldWithDefault(msg, 1, "") }; if (includeInstance) { obj.$jspbMessageInstance = msg; } return obj; }; } /** * Deserializes binary data (in protobuf wire format). * @param {jspb.ByteSource} bytes The bytes to deserialize. * @return {!proto.com.book.GetBookViaAuthor} */ proto.com.book.GetBookViaAuthor.deserializeBinary = function(bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.com.book.GetBookViaAuthor; return proto.com.book.GetBookViaAuthor.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.com.book.GetBookViaAuthor} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.com.book.GetBookViaAuthor} */ proto.com.book.GetBookViaAuthor.deserializeBinaryFromReader = function(msg, reader) { while (reader.nextField()) { if (reader.isEndGroup()) { break; } var field = reader.getFieldNumber(); switch (field) { case 1: var value = /** @type {string} */ (reader.readString()); msg.setAuthor(value); break; default: reader.skipField(); break; } } return msg; }; /** * Serializes the message to binary data (in protobuf wire format). * @return {!Uint8Array} */ proto.com.book.GetBookViaAuthor.prototype.serializeBinary = function() { var writer = new jspb.BinaryWriter(); proto.com.book.GetBookViaAuthor.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.com.book.GetBookViaAuthor} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.com.book.GetBookViaAuthor.serializeBinaryToWriter = function(message, writer) { var f = undefined; f = message.getAuthor(); if (f.length > 0) { writer.writeString( 1, f ); } }; /** * optional string author = 1; * @return {string} */ proto.com.book.GetBookViaAuthor.prototype.getAuthor = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); }; /** @param {string} value */ proto.com.book.GetBookViaAuthor.prototype.setAuthor = function(value) { jspb.Message.setField(this, 1, value); }; /** * Generated by JsPbCodeGenerator. * @param {Array=} opt_data Optional initial data array, typically from a * server response, or constructed directly in Javascript. The array is used * in place and becomes part of the constructed object. It is not cloned. * If no data is provided, the constructed object will be empty, but still * valid. * @extends {jspb.Message} * @constructor */ proto.com.book.BookStore = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.com.book.BookStore, jspb.Message); if (goog.DEBUG && !COMPILED) { proto.com.book.BookStore.displayName = 'proto.com.book.BookStore'; } if (jspb.Message.GENERATE_TO_OBJECT) { /** * Creates an object representation of this proto suitable for use in Soy templates. * Field names that are reserved in JavaScript and will be renamed to pb_name. * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default. * For the list of reserved names please see: * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS. * @param {boolean=} opt_includeInstance Whether to include the JSPB instance * for transitional soy proto support: http://goto/soy-param-migration * @return {!Object} */ proto.com.book.BookStore.prototype.toObject = function(opt_includeInstance) { return proto.com.book.BookStore.toObject(opt_includeInstance, this); }; /** * Static version of the {@see toObject} method. * @param {boolean|undefined} includeInstance Whether to include the JSPB * instance for transitional soy proto support: * http://goto/soy-param-migration * @param {!proto.com.book.BookStore} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.com.book.BookStore.toObject = function(includeInstance, msg) { var f, obj = { name: jspb.Message.getFieldWithDefault(msg, 1, ""), booksMap: (f = msg.getBooksMap()) ? f.toObject(includeInstance, undefined) : [] }; if (includeInstance) { obj.$jspbMessageInstance = msg; } return obj; }; } /** * Deserializes binary data (in protobuf wire format). * @param {jspb.ByteSource} bytes The bytes to deserialize. * @return {!proto.com.book.BookStore} */ proto.com.book.BookStore.deserializeBinary = function(bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.com.book.BookStore; return proto.com.book.BookStore.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.com.book.BookStore} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.com.book.BookStore} */ proto.com.book.BookStore.deserializeBinaryFromReader = function(msg, reader) { while (reader.nextField()) { if (reader.isEndGroup()) { break; } var field = reader.getFieldNumber(); switch (field) { case 1: var value = /** @type {string} */ (reader.readString()); msg.setName(value); break; case 2: var value = msg.getBooksMap(); reader.readMessage(value, function(message, reader) { jspb.Map.deserializeBinary(message, reader, jspb.BinaryReader.prototype.readInt64, jspb.BinaryReader.prototype.readString); }); break; default: reader.skipField(); break; } } return msg; }; /** * Serializes the message to binary data (in protobuf wire format). * @return {!Uint8Array} */ proto.com.book.BookStore.prototype.serializeBinary = function() { var writer = new jspb.BinaryWriter(); proto.com.book.BookStore.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.com.book.BookStore} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.com.book.BookStore.serializeBinaryToWriter = function(message, writer) { var f = undefined; f = message.getName(); if (f.length > 0) { writer.writeString( 1, f ); } f = message.getBooksMap(true); if (f && f.getLength() > 0) { f.serializeBinary(2, writer, jspb.BinaryWriter.prototype.writeInt64, jspb.BinaryWriter.prototype.writeString); } }; /** * optional string name = 1; * @return {string} */ proto.com.book.BookStore.prototype.getName = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); }; /** @param {string} value */ proto.com.book.BookStore.prototype.setName = function(value) { jspb.Message.setField(this, 1, value); }; /** * map<int64, string> books = 2; * @param {boolean=} opt_noLazyCreate Do not create the map if * empty, instead returning `undefined` * @return {!jspb.Map<number,string>} */ proto.com.book.BookStore.prototype.getBooksMap = function(opt_noLazyCreate) { return /** @type {!jspb.Map<number,string>} */ ( jspb.Message.getMapField(this, 2, opt_noLazyCreate, null)); }; proto.com.book.BookStore.prototype.clearBooksMap = function() { this.getBooksMap().clear(); }; /** * Generated by JsPbCodeGenerator. * @param {Array=} opt_data Optional initial data array, typically from a * server response, or constructed directly in Javascript. The array is used * in place and becomes part of the constructed object. It is not cloned. * If no data is provided, the constructed object will be empty, but still * valid. * @extends {jspb.Message} * @constructor */ proto.com.book.SpecialCases = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.com.book.SpecialCases, jspb.Message); if (goog.DEBUG && !COMPILED) { proto.com.book.SpecialCases.displayName = 'proto.com.book.SpecialCases'; } if (jspb.Message.GENERATE_TO_OBJECT) { /** * Creates an object representation of this proto suitable for use in Soy templates. * Field names that are reserved in JavaScript and will be renamed to pb_name. * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default. * For the list of reserved names please see: * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS. * @param {boolean=} opt_includeInstance Whether to include the JSPB instance * for transitional soy proto support: http://goto/soy-param-migration * @return {!Object} */ proto.com.book.SpecialCases.prototype.toObject = function(opt_includeInstance) { return proto.com.book.SpecialCases.toObject(opt_includeInstance, this); }; /** * Static version of the {@see toObject} method. * @param {boolean|undefined} includeInstance Whether to include the JSPB * instance for transitional soy proto support: * http://goto/soy-param-migration * @param {!proto.com.book.SpecialCases} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.com.book.SpecialCases.toObject = function(includeInstance, msg) { var f, obj = { normal: jspb.Message.getFieldWithDefault(msg, 1, ""), pb_default: jspb.Message.getFieldWithDefault(msg, 2, ""), pb_function: jspb.Message.getFieldWithDefault(msg, 3, ""), pb_var: jspb.Message.getFieldWithDefault(msg, 4, "") }; if (includeInstance) { obj.$jspbMessageInstance = msg; } return obj; }; } /** * Deserializes binary data (in protobuf wire format). * @param {jspb.ByteSource} bytes The bytes to deserialize. * @return {!proto.com.book.SpecialCases} */ proto.com.book.SpecialCases.deserializeBinary = function(bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.com.book.SpecialCases; return proto.com.book.SpecialCases.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.com.book.SpecialCases} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.com.book.SpecialCases} */ proto.com.book.SpecialCases.deserializeBinaryFromReader = function(msg, reader) { while (reader.nextField()) { if (reader.isEndGroup()) { break; } var field = reader.getFieldNumber(); switch (field) { case 1: var value = /** @type {string} */ (reader.readString()); msg.setNormal(value); break; case 2: var value = /** @type {string} */ (reader.readString()); msg.setDefault(value); break; case 3: var value = /** @type {string} */ (reader.readString()); msg.setFunction(value); break; case 4: var value = /** @type {string} */ (reader.readString()); msg.setVar(value); break; default: reader.skipField(); break; } } return msg; }; /** * Serializes the message to binary data (in protobuf wire format). * @return {!Uint8Array} */ proto.com.book.SpecialCases.prototype.serializeBinary = function() { var writer = new jspb.BinaryWriter(); proto.com.book.SpecialCases.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.com.book.SpecialCases} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.com.book.SpecialCases.serializeBinaryToWriter = function(message, writer) { var f = undefined; f = message.getNormal(); if (f.length > 0) { writer.writeString( 1, f ); } f = message.getDefault(); if (f.length > 0) { writer.writeString( 2, f ); } f = message.getFunction(); if (f.length > 0) { writer.writeString( 3, f ); } f = message.getVar(); if (f.length > 0) { writer.writeString( 4, f ); } }; /** * optional string normal = 1; * @return {string} */ proto.com.book.SpecialCases.prototype.getNormal = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); }; /** @param {string} value */ proto.com.book.SpecialCases.prototype.setNormal = function(value) { jspb.Message.setField(this, 1, value); }; /** * optional string default = 2; * @return {string} */ proto.com.book.SpecialCases.prototype.getDefault = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, "")); }; /** @param {string} value */ proto.com.book.SpecialCases.prototype.setDefault = function(value) { jspb.Message.setField(this, 2, value); }; /** * optional string function = 3; * @return {string} */ proto.com.book.SpecialCases.prototype.getFunction = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, "")); }; /** @param {string} value */ proto.com.book.SpecialCases.prototype.setFunction = function(value) { jspb.Message.setField(this, 3, value); }; /** * optional string var = 4; * @return {string} */ proto.com.book.SpecialCases.prototype.getVar = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, "")); }; /** @param {string} value */ proto.com.book.SpecialCases.prototype.setVar = function(value) { jspb.Message.setField(this, 4, value); }; /** * @enum {number} */ proto.com.book.EnumSample = { UNKNOWN: 0, STARTED: 1, RUNNING: 1 }; goog.object.extend(exports, proto.com.book);