UNPKG

jarviscrawlercore

Version:
1,755 lines (1,528 loc) 87.4 kB
// source: alimama.proto /** * @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! /* eslint-disable */ // @ts-nocheck var jspb = require('google-protobuf'); var goog = jspb; var global = Function('return this')(); var searchparam2_pb = require('./searchparam2_pb.js'); goog.object.extend(proto, searchparam2_pb); goog.exportSymbol('proto.jarviscrawlercore.AliProduct', null, global); goog.exportSymbol('proto.jarviscrawlercore.AlimamaMode', null, global); goog.exportSymbol('proto.jarviscrawlercore.AlimamaProduct', null, global); goog.exportSymbol('proto.jarviscrawlercore.AlimamaProducts', null, global); goog.exportSymbol('proto.jarviscrawlercore.AlimamaShop', null, global); goog.exportSymbol('proto.jarviscrawlercore.AlimamaTopInfo', null, global); goog.exportSymbol('proto.jarviscrawlercore.AlimamaTopProducts', null, global); goog.exportSymbol('proto.jarviscrawlercore.ReplyAlimama', null, global); goog.exportSymbol('proto.jarviscrawlercore.ReplyAlimama.ReplyCase', null, global); goog.exportSymbol('proto.jarviscrawlercore.RequestAlimama', 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.jarviscrawlercore.AlimamaProduct = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, proto.jarviscrawlercore.AlimamaProduct.repeatedFields_, null); }; goog.inherits(proto.jarviscrawlercore.AlimamaProduct, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.jarviscrawlercore.AlimamaProduct.displayName = 'proto.jarviscrawlercore.AlimamaProduct'; } /** * 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.jarviscrawlercore.AlimamaShop = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, proto.jarviscrawlercore.AlimamaShop.repeatedFields_, null); }; goog.inherits(proto.jarviscrawlercore.AlimamaShop, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.jarviscrawlercore.AlimamaShop.displayName = 'proto.jarviscrawlercore.AlimamaShop'; } /** * 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.jarviscrawlercore.AliProduct = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, proto.jarviscrawlercore.AliProduct.repeatedFields_, null); }; goog.inherits(proto.jarviscrawlercore.AliProduct, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.jarviscrawlercore.AliProduct.displayName = 'proto.jarviscrawlercore.AliProduct'; } /** * 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.jarviscrawlercore.AlimamaTopProducts = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, proto.jarviscrawlercore.AlimamaTopProducts.repeatedFields_, null); }; goog.inherits(proto.jarviscrawlercore.AlimamaTopProducts, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.jarviscrawlercore.AlimamaTopProducts.displayName = 'proto.jarviscrawlercore.AlimamaTopProducts'; } /** * 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.jarviscrawlercore.AlimamaTopInfo = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, proto.jarviscrawlercore.AlimamaTopInfo.repeatedFields_, null); }; goog.inherits(proto.jarviscrawlercore.AlimamaTopInfo, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.jarviscrawlercore.AlimamaTopInfo.displayName = 'proto.jarviscrawlercore.AlimamaTopInfo'; } /** * 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.jarviscrawlercore.AlimamaProducts = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, proto.jarviscrawlercore.AlimamaProducts.repeatedFields_, null); }; goog.inherits(proto.jarviscrawlercore.AlimamaProducts, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.jarviscrawlercore.AlimamaProducts.displayName = 'proto.jarviscrawlercore.AlimamaProducts'; } /** * 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.jarviscrawlercore.RequestAlimama = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.jarviscrawlercore.RequestAlimama, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.jarviscrawlercore.RequestAlimama.displayName = 'proto.jarviscrawlercore.RequestAlimama'; } /** * 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.jarviscrawlercore.ReplyAlimama = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, proto.jarviscrawlercore.ReplyAlimama.oneofGroups_); }; goog.inherits(proto.jarviscrawlercore.ReplyAlimama, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.jarviscrawlercore.ReplyAlimama.displayName = 'proto.jarviscrawlercore.ReplyAlimama'; } /** * List of repeated fields within this message type. * @private {!Array<number>} * @const */ proto.jarviscrawlercore.AlimamaProduct.repeatedFields_ = [10]; if (jspb.Message.GENERATE_TO_OBJECT) { /** * Creates an object representation of this proto. * Field names that are reserved in JavaScript and will be renamed to pb_name. * Optional fields that are not set will be set to undefined. * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default. * For the list of reserved names please see: * net/proto2/compiler/js/internal/generator.cc#kKeyword. * @param {boolean=} opt_includeInstance Deprecated. whether to include the * JSPB instance for transitional soy proto support: * http://goto/soy-param-migration * @return {!Object} */ proto.jarviscrawlercore.AlimamaProduct.prototype.toObject = function(opt_includeInstance) { return proto.jarviscrawlercore.AlimamaProduct.toObject(opt_includeInstance, this); }; /** * Static version of the {@see toObject} method. * @param {boolean|undefined} includeInstance Deprecated. Whether to include * the JSPB instance for transitional soy proto support: * http://goto/soy-param-migration * @param {!proto.jarviscrawlercore.AlimamaProduct} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.jarviscrawlercore.AlimamaProduct.toObject = function(includeInstance, msg) { var f, obj = { name: jspb.Message.getFieldWithDefault(msg, 1, ""), url: jspb.Message.getFieldWithDefault(msg, 2, ""), shop: jspb.Message.getFieldWithDefault(msg, 3, ""), img: jspb.Message.getFieldWithDefault(msg, 4, ""), lastcoupon: jspb.Message.getFloatingPointFieldWithDefault(msg, 5, 0.0), curprice: jspb.Message.getFloatingPointFieldWithDefault(msg, 6, 0.0), rebate: jspb.Message.getFloatingPointFieldWithDefault(msg, 7, 0.0), commission: jspb.Message.getFloatingPointFieldWithDefault(msg, 8, 0.0), moneyquan: jspb.Message.getFloatingPointFieldWithDefault(msg, 9, 0.0), shoptypeList: (f = jspb.Message.getRepeatedField(msg, 10)) == null ? undefined : f, salesvolume: jspb.Message.getFieldWithDefault(msg, 11, 0), shopurl: jspb.Message.getFieldWithDefault(msg, 12, ""), salesvolume2: jspb.Message.getFieldWithDefault(msg, 13, 0), presale: jspb.Message.getFloatingPointFieldWithDefault(msg, 14, 0.0), presaleprofit: jspb.Message.getFloatingPointFieldWithDefault(msg, 15, 0.0), host: jspb.Message.getFieldWithDefault(msg, 16, ""), itemid: jspb.Message.getFieldWithDefault(msg, 17, "") }; if (includeInstance) { obj.$jspbMessageInstance = msg; } return obj; }; } /** * Deserializes binary data (in protobuf wire format). * @param {jspb.ByteSource} bytes The bytes to deserialize. * @return {!proto.jarviscrawlercore.AlimamaProduct} */ proto.jarviscrawlercore.AlimamaProduct.deserializeBinary = function(bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.jarviscrawlercore.AlimamaProduct; return proto.jarviscrawlercore.AlimamaProduct.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.jarviscrawlercore.AlimamaProduct} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.jarviscrawlercore.AlimamaProduct} */ proto.jarviscrawlercore.AlimamaProduct.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 = /** @type {string} */ (reader.readString()); msg.setUrl(value); break; case 3: var value = /** @type {string} */ (reader.readString()); msg.setShop(value); break; case 4: var value = /** @type {string} */ (reader.readString()); msg.setImg(value); break; case 5: var value = /** @type {number} */ (reader.readFloat()); msg.setLastcoupon(value); break; case 6: var value = /** @type {number} */ (reader.readFloat()); msg.setCurprice(value); break; case 7: var value = /** @type {number} */ (reader.readFloat()); msg.setRebate(value); break; case 8: var value = /** @type {number} */ (reader.readFloat()); msg.setCommission(value); break; case 9: var value = /** @type {number} */ (reader.readFloat()); msg.setMoneyquan(value); break; case 10: var value = /** @type {string} */ (reader.readString()); msg.addShoptype(value); break; case 11: var value = /** @type {number} */ (reader.readInt32()); msg.setSalesvolume(value); break; case 12: var value = /** @type {string} */ (reader.readString()); msg.setShopurl(value); break; case 13: var value = /** @type {number} */ (reader.readInt32()); msg.setSalesvolume2(value); break; case 14: var value = /** @type {number} */ (reader.readFloat()); msg.setPresale(value); break; case 15: var value = /** @type {number} */ (reader.readFloat()); msg.setPresaleprofit(value); break; case 16: var value = /** @type {string} */ (reader.readString()); msg.setHost(value); break; case 17: var value = /** @type {string} */ (reader.readString()); msg.setItemid(value); break; default: reader.skipField(); break; } } return msg; }; /** * Serializes the message to binary data (in protobuf wire format). * @return {!Uint8Array} */ proto.jarviscrawlercore.AlimamaProduct.prototype.serializeBinary = function() { var writer = new jspb.BinaryWriter(); proto.jarviscrawlercore.AlimamaProduct.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.jarviscrawlercore.AlimamaProduct} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.jarviscrawlercore.AlimamaProduct.serializeBinaryToWriter = function(message, writer) { var f = undefined; f = message.getName(); if (f.length > 0) { writer.writeString( 1, f ); } f = message.getUrl(); if (f.length > 0) { writer.writeString( 2, f ); } f = message.getShop(); if (f.length > 0) { writer.writeString( 3, f ); } f = message.getImg(); if (f.length > 0) { writer.writeString( 4, f ); } f = message.getLastcoupon(); if (f !== 0.0) { writer.writeFloat( 5, f ); } f = message.getCurprice(); if (f !== 0.0) { writer.writeFloat( 6, f ); } f = message.getRebate(); if (f !== 0.0) { writer.writeFloat( 7, f ); } f = message.getCommission(); if (f !== 0.0) { writer.writeFloat( 8, f ); } f = message.getMoneyquan(); if (f !== 0.0) { writer.writeFloat( 9, f ); } f = message.getShoptypeList(); if (f.length > 0) { writer.writeRepeatedString( 10, f ); } f = message.getSalesvolume(); if (f !== 0) { writer.writeInt32( 11, f ); } f = message.getShopurl(); if (f.length > 0) { writer.writeString( 12, f ); } f = message.getSalesvolume2(); if (f !== 0) { writer.writeInt32( 13, f ); } f = message.getPresale(); if (f !== 0.0) { writer.writeFloat( 14, f ); } f = message.getPresaleprofit(); if (f !== 0.0) { writer.writeFloat( 15, f ); } f = message.getHost(); if (f.length > 0) { writer.writeString( 16, f ); } f = message.getItemid(); if (f.length > 0) { writer.writeString( 17, f ); } }; /** * optional string name = 1; * @return {string} */ proto.jarviscrawlercore.AlimamaProduct.prototype.getName = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); }; /** * @param {string} value * @return {!proto.jarviscrawlercore.AlimamaProduct} returns this */ proto.jarviscrawlercore.AlimamaProduct.prototype.setName = function(value) { return jspb.Message.setProto3StringField(this, 1, value); }; /** * optional string url = 2; * @return {string} */ proto.jarviscrawlercore.AlimamaProduct.prototype.getUrl = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, "")); }; /** * @param {string} value * @return {!proto.jarviscrawlercore.AlimamaProduct} returns this */ proto.jarviscrawlercore.AlimamaProduct.prototype.setUrl = function(value) { return jspb.Message.setProto3StringField(this, 2, value); }; /** * optional string shop = 3; * @return {string} */ proto.jarviscrawlercore.AlimamaProduct.prototype.getShop = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, "")); }; /** * @param {string} value * @return {!proto.jarviscrawlercore.AlimamaProduct} returns this */ proto.jarviscrawlercore.AlimamaProduct.prototype.setShop = function(value) { return jspb.Message.setProto3StringField(this, 3, value); }; /** * optional string img = 4; * @return {string} */ proto.jarviscrawlercore.AlimamaProduct.prototype.getImg = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, "")); }; /** * @param {string} value * @return {!proto.jarviscrawlercore.AlimamaProduct} returns this */ proto.jarviscrawlercore.AlimamaProduct.prototype.setImg = function(value) { return jspb.Message.setProto3StringField(this, 4, value); }; /** * optional float lastCoupon = 5; * @return {number} */ proto.jarviscrawlercore.AlimamaProduct.prototype.getLastcoupon = function() { return /** @type {number} */ (jspb.Message.getFloatingPointFieldWithDefault(this, 5, 0.0)); }; /** * @param {number} value * @return {!proto.jarviscrawlercore.AlimamaProduct} returns this */ proto.jarviscrawlercore.AlimamaProduct.prototype.setLastcoupon = function(value) { return jspb.Message.setProto3FloatField(this, 5, value); }; /** * optional float curPrice = 6; * @return {number} */ proto.jarviscrawlercore.AlimamaProduct.prototype.getCurprice = function() { return /** @type {number} */ (jspb.Message.getFloatingPointFieldWithDefault(this, 6, 0.0)); }; /** * @param {number} value * @return {!proto.jarviscrawlercore.AlimamaProduct} returns this */ proto.jarviscrawlercore.AlimamaProduct.prototype.setCurprice = function(value) { return jspb.Message.setProto3FloatField(this, 6, value); }; /** * optional float rebate = 7; * @return {number} */ proto.jarviscrawlercore.AlimamaProduct.prototype.getRebate = function() { return /** @type {number} */ (jspb.Message.getFloatingPointFieldWithDefault(this, 7, 0.0)); }; /** * @param {number} value * @return {!proto.jarviscrawlercore.AlimamaProduct} returns this */ proto.jarviscrawlercore.AlimamaProduct.prototype.setRebate = function(value) { return jspb.Message.setProto3FloatField(this, 7, value); }; /** * optional float commission = 8; * @return {number} */ proto.jarviscrawlercore.AlimamaProduct.prototype.getCommission = function() { return /** @type {number} */ (jspb.Message.getFloatingPointFieldWithDefault(this, 8, 0.0)); }; /** * @param {number} value * @return {!proto.jarviscrawlercore.AlimamaProduct} returns this */ proto.jarviscrawlercore.AlimamaProduct.prototype.setCommission = function(value) { return jspb.Message.setProto3FloatField(this, 8, value); }; /** * optional float moneyQuan = 9; * @return {number} */ proto.jarviscrawlercore.AlimamaProduct.prototype.getMoneyquan = function() { return /** @type {number} */ (jspb.Message.getFloatingPointFieldWithDefault(this, 9, 0.0)); }; /** * @param {number} value * @return {!proto.jarviscrawlercore.AlimamaProduct} returns this */ proto.jarviscrawlercore.AlimamaProduct.prototype.setMoneyquan = function(value) { return jspb.Message.setProto3FloatField(this, 9, value); }; /** * repeated string shopType = 10; * @return {!Array<string>} */ proto.jarviscrawlercore.AlimamaProduct.prototype.getShoptypeList = function() { return /** @type {!Array<string>} */ (jspb.Message.getRepeatedField(this, 10)); }; /** * @param {!Array<string>} value * @return {!proto.jarviscrawlercore.AlimamaProduct} returns this */ proto.jarviscrawlercore.AlimamaProduct.prototype.setShoptypeList = function(value) { return jspb.Message.setField(this, 10, value || []); }; /** * @param {string} value * @param {number=} opt_index * @return {!proto.jarviscrawlercore.AlimamaProduct} returns this */ proto.jarviscrawlercore.AlimamaProduct.prototype.addShoptype = function(value, opt_index) { return jspb.Message.addToRepeatedField(this, 10, value, opt_index); }; /** * Clears the list making it empty but non-null. * @return {!proto.jarviscrawlercore.AlimamaProduct} returns this */ proto.jarviscrawlercore.AlimamaProduct.prototype.clearShoptypeList = function() { return this.setShoptypeList([]); }; /** * optional int32 salesVolume = 11; * @return {number} */ proto.jarviscrawlercore.AlimamaProduct.prototype.getSalesvolume = function() { return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 11, 0)); }; /** * @param {number} value * @return {!proto.jarviscrawlercore.AlimamaProduct} returns this */ proto.jarviscrawlercore.AlimamaProduct.prototype.setSalesvolume = function(value) { return jspb.Message.setProto3IntField(this, 11, value); }; /** * optional string shopurl = 12; * @return {string} */ proto.jarviscrawlercore.AlimamaProduct.prototype.getShopurl = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 12, "")); }; /** * @param {string} value * @return {!proto.jarviscrawlercore.AlimamaProduct} returns this */ proto.jarviscrawlercore.AlimamaProduct.prototype.setShopurl = function(value) { return jspb.Message.setProto3StringField(this, 12, value); }; /** * optional int32 salesVolume2 = 13; * @return {number} */ proto.jarviscrawlercore.AlimamaProduct.prototype.getSalesvolume2 = function() { return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 13, 0)); }; /** * @param {number} value * @return {!proto.jarviscrawlercore.AlimamaProduct} returns this */ proto.jarviscrawlercore.AlimamaProduct.prototype.setSalesvolume2 = function(value) { return jspb.Message.setProto3IntField(this, 13, value); }; /** * optional float presale = 14; * @return {number} */ proto.jarviscrawlercore.AlimamaProduct.prototype.getPresale = function() { return /** @type {number} */ (jspb.Message.getFloatingPointFieldWithDefault(this, 14, 0.0)); }; /** * @param {number} value * @return {!proto.jarviscrawlercore.AlimamaProduct} returns this */ proto.jarviscrawlercore.AlimamaProduct.prototype.setPresale = function(value) { return jspb.Message.setProto3FloatField(this, 14, value); }; /** * optional float presaleProfit = 15; * @return {number} */ proto.jarviscrawlercore.AlimamaProduct.prototype.getPresaleprofit = function() { return /** @type {number} */ (jspb.Message.getFloatingPointFieldWithDefault(this, 15, 0.0)); }; /** * @param {number} value * @return {!proto.jarviscrawlercore.AlimamaProduct} returns this */ proto.jarviscrawlercore.AlimamaProduct.prototype.setPresaleprofit = function(value) { return jspb.Message.setProto3FloatField(this, 15, value); }; /** * optional string host = 16; * @return {string} */ proto.jarviscrawlercore.AlimamaProduct.prototype.getHost = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 16, "")); }; /** * @param {string} value * @return {!proto.jarviscrawlercore.AlimamaProduct} returns this */ proto.jarviscrawlercore.AlimamaProduct.prototype.setHost = function(value) { return jspb.Message.setProto3StringField(this, 16, value); }; /** * optional string itemID = 17; * @return {string} */ proto.jarviscrawlercore.AlimamaProduct.prototype.getItemid = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 17, "")); }; /** * @param {string} value * @return {!proto.jarviscrawlercore.AlimamaProduct} returns this */ proto.jarviscrawlercore.AlimamaProduct.prototype.setItemid = function(value) { return jspb.Message.setProto3StringField(this, 17, value); }; /** * List of repeated fields within this message type. * @private {!Array<number>} * @const */ proto.jarviscrawlercore.AlimamaShop.repeatedFields_ = [10,11,13]; if (jspb.Message.GENERATE_TO_OBJECT) { /** * Creates an object representation of this proto. * Field names that are reserved in JavaScript and will be renamed to pb_name. * Optional fields that are not set will be set to undefined. * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default. * For the list of reserved names please see: * net/proto2/compiler/js/internal/generator.cc#kKeyword. * @param {boolean=} opt_includeInstance Deprecated. whether to include the * JSPB instance for transitional soy proto support: * http://goto/soy-param-migration * @return {!Object} */ proto.jarviscrawlercore.AlimamaShop.prototype.toObject = function(opt_includeInstance) { return proto.jarviscrawlercore.AlimamaShop.toObject(opt_includeInstance, this); }; /** * Static version of the {@see toObject} method. * @param {boolean|undefined} includeInstance Deprecated. Whether to include * the JSPB instance for transitional soy proto support: * http://goto/soy-param-migration * @param {!proto.jarviscrawlercore.AlimamaShop} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.jarviscrawlercore.AlimamaShop.toObject = function(includeInstance, msg) { var f, obj = { name: jspb.Message.getFieldWithDefault(msg, 1, ""), url: jspb.Message.getFieldWithDefault(msg, 2, ""), shopid: jspb.Message.getFieldWithDefault(msg, 3, ""), boss: jspb.Message.getFieldWithDefault(msg, 4, ""), credit: jspb.Message.getFieldWithDefault(msg, 5, 0), address: jspb.Message.getFieldWithDefault(msg, 6, ""), sellersum: jspb.Message.getFieldWithDefault(msg, 7, ""), salesvolume: jspb.Message.getFieldWithDefault(msg, 8, 0), majorbusiness: jspb.Message.getFieldWithDefault(msg, 9, ""), servicevolumeList: (f = jspb.Message.getRepeatedFloatingPointField(msg, 10)) == null ? undefined : f, serviceotherList: (f = jspb.Message.getRepeatedFloatingPointField(msg, 11)) == null ? undefined : f, lastupdatedtime: jspb.Message.getFieldWithDefault(msg, 12, 0), sellertitleList: (f = jspb.Message.getRepeatedField(msg, 13)) == null ? undefined : f }; if (includeInstance) { obj.$jspbMessageInstance = msg; } return obj; }; } /** * Deserializes binary data (in protobuf wire format). * @param {jspb.ByteSource} bytes The bytes to deserialize. * @return {!proto.jarviscrawlercore.AlimamaShop} */ proto.jarviscrawlercore.AlimamaShop.deserializeBinary = function(bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.jarviscrawlercore.AlimamaShop; return proto.jarviscrawlercore.AlimamaShop.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.jarviscrawlercore.AlimamaShop} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.jarviscrawlercore.AlimamaShop} */ proto.jarviscrawlercore.AlimamaShop.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 = /** @type {string} */ (reader.readString()); msg.setUrl(value); break; case 3: var value = /** @type {string} */ (reader.readString()); msg.setShopid(value); break; case 4: var value = /** @type {string} */ (reader.readString()); msg.setBoss(value); break; case 5: var value = /** @type {number} */ (reader.readInt32()); msg.setCredit(value); break; case 6: var value = /** @type {string} */ (reader.readString()); msg.setAddress(value); break; case 7: var value = /** @type {string} */ (reader.readString()); msg.setSellersum(value); break; case 8: var value = /** @type {number} */ (reader.readInt32()); msg.setSalesvolume(value); break; case 9: var value = /** @type {string} */ (reader.readString()); msg.setMajorbusiness(value); break; case 10: var values = /** @type {!Array<number>} */ (reader.isDelimited() ? reader.readPackedFloat() : [reader.readFloat()]); for (var i = 0; i < values.length; i++) { msg.addServicevolume(values[i]); } break; case 11: var values = /** @type {!Array<number>} */ (reader.isDelimited() ? reader.readPackedFloat() : [reader.readFloat()]); for (var i = 0; i < values.length; i++) { msg.addServiceother(values[i]); } break; case 12: var value = /** @type {number} */ (reader.readInt64()); msg.setLastupdatedtime(value); break; case 13: var value = /** @type {string} */ (reader.readString()); msg.addSellertitle(value); break; default: reader.skipField(); break; } } return msg; }; /** * Serializes the message to binary data (in protobuf wire format). * @return {!Uint8Array} */ proto.jarviscrawlercore.AlimamaShop.prototype.serializeBinary = function() { var writer = new jspb.BinaryWriter(); proto.jarviscrawlercore.AlimamaShop.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.jarviscrawlercore.AlimamaShop} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.jarviscrawlercore.AlimamaShop.serializeBinaryToWriter = function(message, writer) { var f = undefined; f = message.getName(); if (f.length > 0) { writer.writeString( 1, f ); } f = message.getUrl(); if (f.length > 0) { writer.writeString( 2, f ); } f = message.getShopid(); if (f.length > 0) { writer.writeString( 3, f ); } f = message.getBoss(); if (f.length > 0) { writer.writeString( 4, f ); } f = message.getCredit(); if (f !== 0) { writer.writeInt32( 5, f ); } f = message.getAddress(); if (f.length > 0) { writer.writeString( 6, f ); } f = message.getSellersum(); if (f.length > 0) { writer.writeString( 7, f ); } f = message.getSalesvolume(); if (f !== 0) { writer.writeInt32( 8, f ); } f = message.getMajorbusiness(); if (f.length > 0) { writer.writeString( 9, f ); } f = message.getServicevolumeList(); if (f.length > 0) { writer.writePackedFloat( 10, f ); } f = message.getServiceotherList(); if (f.length > 0) { writer.writePackedFloat( 11, f ); } f = message.getLastupdatedtime(); if (f !== 0) { writer.writeInt64( 12, f ); } f = message.getSellertitleList(); if (f.length > 0) { writer.writeRepeatedString( 13, f ); } }; /** * optional string name = 1; * @return {string} */ proto.jarviscrawlercore.AlimamaShop.prototype.getName = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); }; /** * @param {string} value * @return {!proto.jarviscrawlercore.AlimamaShop} returns this */ proto.jarviscrawlercore.AlimamaShop.prototype.setName = function(value) { return jspb.Message.setProto3StringField(this, 1, value); }; /** * optional string url = 2; * @return {string} */ proto.jarviscrawlercore.AlimamaShop.prototype.getUrl = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, "")); }; /** * @param {string} value * @return {!proto.jarviscrawlercore.AlimamaShop} returns this */ proto.jarviscrawlercore.AlimamaShop.prototype.setUrl = function(value) { return jspb.Message.setProto3StringField(this, 2, value); }; /** * optional string shopID = 3; * @return {string} */ proto.jarviscrawlercore.AlimamaShop.prototype.getShopid = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, "")); }; /** * @param {string} value * @return {!proto.jarviscrawlercore.AlimamaShop} returns this */ proto.jarviscrawlercore.AlimamaShop.prototype.setShopid = function(value) { return jspb.Message.setProto3StringField(this, 3, value); }; /** * optional string boss = 4; * @return {string} */ proto.jarviscrawlercore.AlimamaShop.prototype.getBoss = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, "")); }; /** * @param {string} value * @return {!proto.jarviscrawlercore.AlimamaShop} returns this */ proto.jarviscrawlercore.AlimamaShop.prototype.setBoss = function(value) { return jspb.Message.setProto3StringField(this, 4, value); }; /** * optional int32 credit = 5; * @return {number} */ proto.jarviscrawlercore.AlimamaShop.prototype.getCredit = function() { return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 5, 0)); }; /** * @param {number} value * @return {!proto.jarviscrawlercore.AlimamaShop} returns this */ proto.jarviscrawlercore.AlimamaShop.prototype.setCredit = function(value) { return jspb.Message.setProto3IntField(this, 5, value); }; /** * optional string address = 6; * @return {string} */ proto.jarviscrawlercore.AlimamaShop.prototype.getAddress = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 6, "")); }; /** * @param {string} value * @return {!proto.jarviscrawlercore.AlimamaShop} returns this */ proto.jarviscrawlercore.AlimamaShop.prototype.setAddress = function(value) { return jspb.Message.setProto3StringField(this, 6, value); }; /** * optional string sellerSum = 7; * @return {string} */ proto.jarviscrawlercore.AlimamaShop.prototype.getSellersum = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 7, "")); }; /** * @param {string} value * @return {!proto.jarviscrawlercore.AlimamaShop} returns this */ proto.jarviscrawlercore.AlimamaShop.prototype.setSellersum = function(value) { return jspb.Message.setProto3StringField(this, 7, value); }; /** * optional int32 salesVolume = 8; * @return {number} */ proto.jarviscrawlercore.AlimamaShop.prototype.getSalesvolume = function() { return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 8, 0)); }; /** * @param {number} value * @return {!proto.jarviscrawlercore.AlimamaShop} returns this */ proto.jarviscrawlercore.AlimamaShop.prototype.setSalesvolume = function(value) { return jspb.Message.setProto3IntField(this, 8, value); }; /** * optional string majorBusiness = 9; * @return {string} */ proto.jarviscrawlercore.AlimamaShop.prototype.getMajorbusiness = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 9, "")); }; /** * @param {string} value * @return {!proto.jarviscrawlercore.AlimamaShop} returns this */ proto.jarviscrawlercore.AlimamaShop.prototype.setMajorbusiness = function(value) { return jspb.Message.setProto3StringField(this, 9, value); }; /** * repeated float serviceVolume = 10; * @return {!Array<number>} */ proto.jarviscrawlercore.AlimamaShop.prototype.getServicevolumeList = function() { return /** @type {!Array<number>} */ (jspb.Message.getRepeatedFloatingPointField(this, 10)); }; /** * @param {!Array<number>} value * @return {!proto.jarviscrawlercore.AlimamaShop} returns this */ proto.jarviscrawlercore.AlimamaShop.prototype.setServicevolumeList = function(value) { return jspb.Message.setField(this, 10, value || []); }; /** * @param {number} value * @param {number=} opt_index * @return {!proto.jarviscrawlercore.AlimamaShop} returns this */ proto.jarviscrawlercore.AlimamaShop.prototype.addServicevolume = function(value, opt_index) { return jspb.Message.addToRepeatedField(this, 10, value, opt_index); }; /** * Clears the list making it empty but non-null. * @return {!proto.jarviscrawlercore.AlimamaShop} returns this */ proto.jarviscrawlercore.AlimamaShop.prototype.clearServicevolumeList = function() { return this.setServicevolumeList([]); }; /** * repeated float serviceOther = 11; * @return {!Array<number>} */ proto.jarviscrawlercore.AlimamaShop.prototype.getServiceotherList = function() { return /** @type {!Array<number>} */ (jspb.Message.getRepeatedFloatingPointField(this, 11)); }; /** * @param {!Array<number>} value * @return {!proto.jarviscrawlercore.AlimamaShop} returns this */ proto.jarviscrawlercore.AlimamaShop.prototype.setServiceotherList = function(value) { return jspb.Message.setField(this, 11, value || []); }; /** * @param {number} value * @param {number=} opt_index * @return {!proto.jarviscrawlercore.AlimamaShop} returns this */ proto.jarviscrawlercore.AlimamaShop.prototype.addServiceother = function(value, opt_index) { return jspb.Message.addToRepeatedField(this, 11, value, opt_index); }; /** * Clears the list making it empty but non-null. * @return {!proto.jarviscrawlercore.AlimamaShop} returns this */ proto.jarviscrawlercore.AlimamaShop.prototype.clearServiceotherList = function() { return this.setServiceotherList([]); }; /** * optional int64 lastUpdatedTime = 12; * @return {number} */ proto.jarviscrawlercore.AlimamaShop.prototype.getLastupdatedtime = function() { return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 12, 0)); }; /** * @param {number} value * @return {!proto.jarviscrawlercore.AlimamaShop} returns this */ proto.jarviscrawlercore.AlimamaShop.prototype.setLastupdatedtime = function(value) { return jspb.Message.setProto3IntField(this, 12, value); }; /** * repeated string sellerTitle = 13; * @return {!Array<string>} */ proto.jarviscrawlercore.AlimamaShop.prototype.getSellertitleList = function() { return /** @type {!Array<string>} */ (jspb.Message.getRepeatedField(this, 13)); }; /** * @param {!Array<string>} value * @return {!proto.jarviscrawlercore.AlimamaShop} returns this */ proto.jarviscrawlercore.AlimamaShop.prototype.setSellertitleList = function(value) { return jspb.Message.setField(this, 13, value || []); }; /** * @param {string} value * @param {number=} opt_index * @return {!proto.jarviscrawlercore.AlimamaShop} returns this */ proto.jarviscrawlercore.AlimamaShop.prototype.addSellertitle = function(value, opt_index) { return jspb.Message.addToRepeatedField(this, 13, value, opt_index); }; /** * Clears the list making it empty but non-null. * @return {!proto.jarviscrawlercore.AlimamaShop} returns this */ proto.jarviscrawlercore.AlimamaShop.prototype.clearSellertitleList = function() { return this.setSellertitleList([]); }; /** * List of repeated fields within this message type. * @private {!Array<number>} * @const */ proto.jarviscrawlercore.AliProduct.repeatedFields_ = [3]; if (jspb.Message.GENERATE_TO_OBJECT) { /** * Creates an object representation of this proto. * Field names that are reserved in JavaScript and will be renamed to pb_name. * Optional fields that are not set will be set to undefined. * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default. * For the list of reserved names please see: * net/proto2/compiler/js/internal/generator.cc#kKeyword. * @param {boolean=} opt_includeInstance Deprecated. whether to include the * JSPB instance for transitional soy proto support: * http://goto/soy-param-migration * @return {!Object} */ proto.jarviscrawlercore.AliProduct.prototype.toObject = function(opt_includeInstance) { return proto.jarviscrawlercore.AliProduct.toObject(opt_includeInstance, this); }; /** * Static version of the {@see toObject} method. * @param {boolean|undefined} includeInstance Deprecated. Whether to include * the JSPB instance for transitional soy proto support: * http://goto/soy-param-migration * @param {!proto.jarviscrawlercore.AliProduct} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.jarviscrawlercore.AliProduct.toObject = function(includeInstance, msg) { var f, obj = { id: jspb.Message.getFieldWithDefault(msg, 1, ""), product: (f = msg.getProduct()) && proto.jarviscrawlercore.AlimamaProduct.toObject(includeInstance, f), tagsList: (f = jspb.Message.getRepeatedField(msg, 3)) == null ? undefined : f, img: jspb.Message.getFieldWithDefault(msg, 4, ""), ranktimes: jspb.Message.getFieldWithDefault(msg, 5, 0), ranktimes2: jspb.Message.getFieldWithDefault(msg, 6, 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.jarviscrawlercore.AliProduct} */ proto.jarviscrawlercore.AliProduct.deserializeBinary = function(bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.jarviscrawlercore.AliProduct; return proto.jarviscrawlercore.AliProduct.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.jarviscrawlercore.AliProduct} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.jarviscrawlercore.AliProduct} */ proto.jarviscrawlercore.AliProduct.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.setId(value); break; case 2: var value = new proto.jarviscrawlercore.AlimamaProduct; reader.readMessage(value,proto.jarviscrawlercore.AlimamaProduct.deserializeBinaryFromReader); msg.setProduct(value); break; case 3: var value = /** @type {string} */ (reader.readString()); msg.addTags(value); break; case 4: var value = /** @type {string} */ (reader.readString()); msg.setImg(value); break; case 5: var value = /** @type {number} */ (reader.readInt64()); msg.setRanktimes(value); break; case 6: var value = /** @type {number} */ (reader.readInt64()); msg.setRanktimes2(value); break; default: reader.skipField(); break; } } return msg; }; /** * Serializes the message to binary data (in protobuf wire format). * @return {!Uint8Array} */ proto.jarviscrawlercore.AliProduct.prototype.serializeBinary = function() { var writer = new jspb.BinaryWriter(); proto.jarviscrawlercore.AliProduct.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.jarviscrawlercore.AliProduct} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.jarviscrawlercore.AliProduct.serializeBinaryToWriter = function(message, writer) { var f = undefined; f = message.getId(); if (f.length > 0) { writer.writeString( 1, f ); } f = message.getProduct(); if (f != null) { writer.writeMessage( 2, f, proto.jarviscrawlercore.AlimamaProduct.serializeBinaryToWriter ); } f = message.getTagsList(); if (f.length > 0) { writer.writeRepeatedString( 3, f ); } f = message.getImg(); if (f.length > 0) { writer.writeString( 4, f ); } f = message.getRanktimes(); if (f !== 0) { writer.writeInt64( 5, f ); } f = message.getRanktimes2(); if (f !== 0) { writer.writeInt64( 6, f ); } }; /** * optional string ID = 1; * @return {string} */ proto.jarviscrawlercore.AliProduct.prototype.getId = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); }; /** * @param {string} value * @return {!proto.jarviscrawlercore.AliProduct} returns this */ proto.jarviscrawlercore.AliProduct.prototype.setId = function(value) { return jspb.Message.setProto3StringField(this, 1, value); }; /** * optional AlimamaProduct product = 2; * @return {?proto.jarviscrawlercore.AlimamaProduct} */ proto.jarviscrawlercore.AliProduct.prototype.getProduct = function() { return /** @type{?proto.jarviscrawlercore.AlimamaProduct} */ ( jspb.Message.getWrapperField(this, proto.jarviscrawlercore.AlimamaProduct, 2)); }; /** * @param {?proto.jarviscrawlercore.AlimamaProduct|undefined} value * @return {!proto.jarviscrawlercore.AliProduct} returns this */ proto.jarviscrawlercore.AliProduct.prototype.setProduct = function(value) { return jspb.Message.setWrapperField(this, 2, value); }; /** * Clears the message field making it undefined. * @return {!proto.jarviscrawlercore.AliProduct} returns this */ proto.jarviscrawlercore.AliProduct.prototype.clearProduct = function() { return this.setProduct(undefined); }; /** * Returns whether this field is set. * @return {boolean} */ proto.jarviscrawlercore.AliProduct.prototype.hasProduct = function() { return jspb.Message.getField(this, 2) != null; }; /** * repeated string tags = 3; * @return {!Array<string>} */ proto.jarviscrawlercore.AliProduct.prototype.getTagsList = function() { return /** @type {!Array<string>} */ (jspb.Message.getRepeatedField(this, 3)); }; /** * @param {!Array<string>} value * @return {!proto.jarviscrawlercore.AliProduct} returns this */ proto.jarviscrawlercore.AliProduct.prototype.setTagsList = function(value) { return jspb.Message.setField(this, 3, value || []); }; /** * @param {string} value * @param {number=} opt_index * @return {!proto.jarviscrawlercore.AliProduct} returns this */ proto.jarviscrawlercore.AliProduct.prototype.addTags = function(value, opt_index) { return jspb.Message.addToRepeatedField(this, 3, value, opt_index); }; /** * Clears the list making it empty but non-null. * @return {!proto.jarviscrawlercore.AliProduct} returns this */ proto.jarviscrawlercore.AliProduct.prototype.clearTagsList = function() { return this.setTagsList([]); }; /** * optional string img = 4; * @return {string} */ proto.jarviscrawlercore.AliProduct.prototype.getImg = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, "")); }; /** * @param {string} value * @return {!proto.jarviscrawlercore.AliProduct} returns this */ proto.jarviscrawlercore.AliProduct.prototype.setImg = function(value) { return jspb.Message.setProto3StringField(this, 4, value); }; /** * optional int64 rankTimes = 5; * @return {number} */ proto.jarviscrawlercore.AliProduct.prototype.getRanktimes = function() { return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 5, 0)); }; /** * @param {number} value * @return {!proto.jarviscrawlercore.AliProduct} returns this */ proto.jarviscrawlercore.AliProduct.prototype.setRanktimes = function(value) { return jspb.Message.setProto3IntField(this, 5, value); }; /** * optional int64 rankTimes2 = 6; * @return {number} */ proto.jarviscrawlercore.AliProduct.prototype.getRanktimes2 = function() { return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 6, 0)); }; /** * @param {number} value * @return {!proto.jarviscrawlercore.AliProduct} returns this */ proto.jarviscrawlercore.AliProduct.prototype.setRanktimes2 = function(value) { return jspb.Message.setProto3IntField(this, 6, value); }; /** * List of repeated fields within this message type. * @private {!Array<number>} * @const */ proto.jarviscrawlercore.AlimamaTopProducts.repeatedFields_ = [1,2]; if (jspb.Message.GENERATE_TO_OBJECT) { /** * Creates an object representation of this proto. * Field names that are reserved in JavaScript and will be renamed to pb_name. * Optional fields that are not set will be set to undefined. * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default. * For the list of reserved names please see: * net/proto2/compiler/js/internal/generator.cc#kKeyword. * @param {boolean=} opt_includeInstance Deprecated. whether to include the * JSPB instance for transitional soy proto support: * http://goto/soy-param-migration * @return {!Object} */ proto.jarviscrawlercore.AlimamaTopProducts.prototype.toObject = function(opt_includeInstance) { return proto.jarviscrawlercore.AlimamaTopProducts.toObject(opt_includeInstance, this); }; /** * Static version of the {@see toObject} method. * @param {boolean|undefined} includeInstance Deprecated. Whether to include * the JSPB instance for transitional soy proto support: * http://goto/soy-param-migration * @param {!proto.jarviscrawlercore.AlimamaTopProducts} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ prot