新增协议:推荐列表

This commit is contained in:
chen wei bo
2025-10-10 18:15:54 +08:00
parent d59eca2a90
commit 46bf60d09d
11 changed files with 257 additions and 35 deletions
+4 -4
View File
@@ -4509,8 +4509,8 @@ static getTypeUrl(typeUrlPrefix?: string): string;
/** Properties of a CSRecommendRes. */
interface ICSRecommendRes {
/** CSRecommendRes girl */
girl?: (cs.IGirls[]|null);
/** CSRecommendRes girls */
girls?: (cs.IGirlData[]|null);
}
/** Represents a CSRecommendRes. */
@@ -4522,8 +4522,8 @@ static getTypeUrl(typeUrlPrefix?: string): string;
*/
constructor(properties?: cs.ICSRecommendRes);
/** CSRecommendRes girl. */
girl: cs.IGirls[];
/** CSRecommendRes girls. */
girls: cs.IGirlData[];
/**
* Creates a new CSRecommendRes instance using the specified properties.
+30 -30
View File
@@ -10495,7 +10495,7 @@ $root.cs = (function() {
* Properties of a CSRecommendRes.
* @memberof cs
* @interface ICSRecommendRes
* @property {Array.<cs.IGirls>|null} [girl] CSRecommendRes girl
* @property {Array.<cs.IGirlData>|null} [girls] CSRecommendRes girls
*/
/**
@@ -10507,7 +10507,7 @@ $root.cs = (function() {
* @param {cs.ICSRecommendRes=} [properties] Properties to set
*/
function CSRecommendRes(properties) {
this.girl = [];
this.girls = [];
if (properties)
for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
if (properties[keys[i]] != null)
@@ -10515,12 +10515,12 @@ $root.cs = (function() {
}
/**
* CSRecommendRes girl.
* @member {Array.<cs.IGirls>} girl
* CSRecommendRes girls.
* @member {Array.<cs.IGirlData>} girls
* @memberof cs.CSRecommendRes
* @instance
*/
CSRecommendRes.prototype.girl = $util.emptyArray;
CSRecommendRes.prototype.girls = $util.emptyArray;
/**
* Creates a new CSRecommendRes instance using the specified properties.
@@ -10546,9 +10546,9 @@ $root.cs = (function() {
CSRecommendRes.encode = function encode(message, writer) {
if (!writer)
writer = $Writer.create();
if (message.girl != null && message.girl.length)
for (var i = 0; i < message.girl.length; ++i)
$root.cs.Girls.encode(message.girl[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim();
if (message.girls != null && message.girls.length)
for (var i = 0; i < message.girls.length; ++i)
$root.cs.GirlData.encode(message.girls[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim();
return writer;
};
@@ -10586,9 +10586,9 @@ $root.cs = (function() {
break;
switch (tag >>> 3) {
case 1: {
if (!(message.girl && message.girl.length))
message.girl = [];
message.girl.push($root.cs.Girls.decode(reader, reader.uint32()));
if (!(message.girls && message.girls.length))
message.girls = [];
message.girls.push($root.cs.GirlData.decode(reader, reader.uint32()));
break;
}
default:
@@ -10626,13 +10626,13 @@ $root.cs = (function() {
CSRecommendRes.verify = function verify(message) {
if (typeof message !== "object" || message === null)
return "object expected";
if (message.girl != null && message.hasOwnProperty("girl")) {
if (!Array.isArray(message.girl))
return "girl: array expected";
for (var i = 0; i < message.girl.length; ++i) {
var error = $root.cs.Girls.verify(message.girl[i]);
if (message.girls != null && message.hasOwnProperty("girls")) {
if (!Array.isArray(message.girls))
return "girls: array expected";
for (var i = 0; i < message.girls.length; ++i) {
var error = $root.cs.GirlData.verify(message.girls[i]);
if (error)
return "girl." + error;
return "girls." + error;
}
}
return null;
@@ -10650,14 +10650,14 @@ $root.cs = (function() {
if (object instanceof $root.cs.CSRecommendRes)
return object;
var message = new $root.cs.CSRecommendRes();
if (object.girl) {
if (!Array.isArray(object.girl))
throw TypeError(".cs.CSRecommendRes.girl: array expected");
message.girl = [];
for (var i = 0; i < object.girl.length; ++i) {
if (typeof object.girl[i] !== "object")
throw TypeError(".cs.CSRecommendRes.girl: object expected");
message.girl[i] = $root.cs.Girls.fromObject(object.girl[i]);
if (object.girls) {
if (!Array.isArray(object.girls))
throw TypeError(".cs.CSRecommendRes.girls: array expected");
message.girls = [];
for (var i = 0; i < object.girls.length; ++i) {
if (typeof object.girls[i] !== "object")
throw TypeError(".cs.CSRecommendRes.girls: object expected");
message.girls[i] = $root.cs.GirlData.fromObject(object.girls[i]);
}
}
return message;
@@ -10677,11 +10677,11 @@ $root.cs = (function() {
options = {};
var object = {};
if (options.arrays || options.defaults)
object.girl = [];
if (message.girl && message.girl.length) {
object.girl = [];
for (var j = 0; j < message.girl.length; ++j)
object.girl[j] = $root.cs.Girls.toObject(message.girl[j], options);
object.girls = [];
if (message.girls && message.girls.length) {
object.girls = [];
for (var j = 0; j < message.girls.length; ++j)
object.girls[j] = $root.cs.GirlData.toObject(message.girls[j], options);
}
return object;
};