2025-08-13 17:23:45 +08:00
/*eslint-disable block-scoped-var, id-length, no-control-regex, no-magic-numbers, no-prototype-builtins, no-redeclare, no-shadow, no-var, sort-vars*/
2025-08-14 00:16:28 +08:00
"use strict" ;
var $protobuf = require ( "protobufjs/minimal.js" );
2025-08-13 17:23:45 +08:00
// Common aliases
2025-08-25 11:30:50 +08:00
var $Reader = $protobuf . Reader , $Writer = $protobuf . Writer , $util = $protobuf . util ;
2025-08-13 17:23:45 +08:00
// Exported root namespace
2025-08-14 00:16:28 +08:00
var $root = $protobuf . roots [ "default" ] || ( $protobuf . roots [ "default" ] = {});
2025-08-13 17:23:45 +08:00
2025-08-25 11:30:50 +08:00
$root . cs = ( function () {
2025-08-15 13:55:26 +08:00
/**
2025-08-25 11:30:50 +08:00
* Namespace cs.
* @exports cs
2025-08-15 00:36:38 +08:00
* @namespace
*/
2025-08-25 11:30:50 +08:00
var cs = {};
2025-08-15 00:36:38 +08:00
2025-08-25 11:30:50 +08:00
cs . GirlBrief = ( function () {
2025-08-15 00:36:38 +08:00
2025-08-15 13:55:26 +08:00
/**
2025-08-25 11:30:50 +08:00
* Properties of a GirlBrief.
* @memberof cs
* @interface IGirlBrief
* @property {number|null} [id] GirlBrief id
* @property {string|null} [name] GirlBrief name
* @property {number|null} [age] GirlBrief age
* @property {string|null} [tagKey] GirlBrief tagKey
* @property {number|null} [priceType] GirlBrief priceType
* @property {number|Long|null} [price] GirlBrief price
* @property {string|null} [avatar] GirlBrief avatar
* @property {number|null} [star] GirlBrief star
2025-09-03 11:09:35 +08:00
* @property {number|null} [category] GirlBrief category
* @property {string|null} [listAvatarPath] GirlBrief listAvatarPath
2025-08-15 13:55:26 +08:00
*/
/**
2025-08-25 11:30:50 +08:00
* Constructs a new GirlBrief.
* @memberof cs
* @classdesc Represents a GirlBrief.
* @implements IGirlBrief
2025-08-15 13:55:26 +08:00
* @constructor
2025-08-25 11:30:50 +08:00
* @param {cs.IGirlBrief=} [properties] Properties to set
2025-08-15 13:55:26 +08:00
*/
2025-08-25 11:30:50 +08:00
function GirlBrief ( properties ) {
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
2025-08-15 13:55:26 +08:00
}
/**
2025-08-25 11:30:50 +08:00
* GirlBrief id.
* @member {number} id
* @memberof cs.GirlBrief
2025-08-15 13:55:26 +08:00
* @instance
*/
2025-08-25 11:30:50 +08:00
GirlBrief . prototype . id = 0 ;
2025-08-15 13:55:26 +08:00
/**
2025-08-25 11:30:50 +08:00
* GirlBrief name.
* @member {string} name
* @memberof cs.GirlBrief
2025-08-15 13:55:26 +08:00
* @instance
*/
2025-08-25 11:30:50 +08:00
GirlBrief . prototype . name = "" ;
2025-08-15 13:55:26 +08:00
/**
2025-08-25 11:30:50 +08:00
* GirlBrief age.
* @member {number} age
* @memberof cs.GirlBrief
2025-08-15 13:55:26 +08:00
* @instance
*/
2025-08-25 11:30:50 +08:00
GirlBrief . prototype . age = 0 ;
2025-08-15 13:55:26 +08:00
/**
2025-08-25 11:30:50 +08:00
* GirlBrief tagKey.
* @member {string} tagKey
* @memberof cs.GirlBrief
* @instance
*/
GirlBrief . prototype . tagKey = "" ;
/**
* GirlBrief priceType.
* @member {number} priceType
* @memberof cs.GirlBrief
* @instance
*/
GirlBrief . prototype . priceType = 0 ;
/**
* GirlBrief price.
* @member {number|Long} price
* @memberof cs.GirlBrief
* @instance
*/
GirlBrief . prototype . price = $util . Long ? $util . Long . fromBits ( 0 , 0 , false ) : 0 ;
/**
* GirlBrief avatar.
* @member {string} avatar
* @memberof cs.GirlBrief
* @instance
*/
GirlBrief . prototype . avatar = "" ;
/**
* GirlBrief star.
* @member {number} star
* @memberof cs.GirlBrief
* @instance
*/
GirlBrief . prototype . star = 0 ;
2025-09-03 11:09:35 +08:00
/**
* GirlBrief category.
* @member {number} category
* @memberof cs.GirlBrief
* @instance
*/
GirlBrief . prototype . category = 0 ;
/**
* GirlBrief listAvatarPath.
* @member {string} listAvatarPath
* @memberof cs.GirlBrief
* @instance
*/
GirlBrief . prototype . listAvatarPath = "" ;
2025-08-25 11:30:50 +08:00
/**
* Creates a new GirlBrief instance using the specified properties.
2025-08-15 13:55:26 +08:00
* @function create
2025-08-25 11:30:50 +08:00
* @memberof cs.GirlBrief
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.IGirlBrief=} [properties] Properties to set
* @returns {cs.GirlBrief} GirlBrief instance
2025-08-15 13:55:26 +08:00
*/
2025-08-25 11:30:50 +08:00
GirlBrief . create = function create ( properties ) {
return new GirlBrief ( properties );
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Encodes the specified GirlBrief message. Does not implicitly {@link cs.GirlBrief.verify|verify} messages.
2025-08-15 13:55:26 +08:00
* @function encode
2025-08-25 11:30:50 +08:00
* @memberof cs.GirlBrief
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.IGirlBrief} message GirlBrief message or plain object to encode
2025-08-15 13:55:26 +08:00
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
2025-08-25 11:30:50 +08:00
GirlBrief . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
if ( message . id != null && Object . hasOwnProperty . call ( message , "id" ))
writer . uint32 ( /* id 1, wireType 0 =*/ 8 ). int32 ( message . id );
if ( message . name != null && Object . hasOwnProperty . call ( message , "name" ))
writer . uint32 ( /* id 2, wireType 2 =*/ 18 ). string ( message . name );
if ( message . age != null && Object . hasOwnProperty . call ( message , "age" ))
writer . uint32 ( /* id 3, wireType 0 =*/ 24 ). int32 ( message . age );
if ( message . tagKey != null && Object . hasOwnProperty . call ( message , "tagKey" ))
writer . uint32 ( /* id 4, wireType 2 =*/ 34 ). string ( message . tagKey );
if ( message . priceType != null && Object . hasOwnProperty . call ( message , "priceType" ))
writer . uint32 ( /* id 5, wireType 0 =*/ 40 ). int32 ( message . priceType );
if ( message . price != null && Object . hasOwnProperty . call ( message , "price" ))
writer . uint32 ( /* id 6, wireType 0 =*/ 48 ). int64 ( message . price );
if ( message . avatar != null && Object . hasOwnProperty . call ( message , "avatar" ))
writer . uint32 ( /* id 7, wireType 2 =*/ 58 ). string ( message . avatar );
if ( message . star != null && Object . hasOwnProperty . call ( message , "star" ))
writer . uint32 ( /* id 8, wireType 0 =*/ 64 ). int32 ( message . star );
2025-09-03 11:09:35 +08:00
if ( message . category != null && Object . hasOwnProperty . call ( message , "category" ))
writer . uint32 ( /* id 9, wireType 0 =*/ 72 ). int32 ( message . category );
if ( message . listAvatarPath != null && Object . hasOwnProperty . call ( message , "listAvatarPath" ))
writer . uint32 ( /* id 10, wireType 2 =*/ 82 ). string ( message . listAvatarPath );
2025-08-25 11:30:50 +08:00
return writer ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Encodes the specified GirlBrief message, length delimited. Does not implicitly {@link cs.GirlBrief.verify|verify} messages.
2025-08-15 13:55:26 +08:00
* @function encodeDelimited
2025-08-25 11:30:50 +08:00
* @memberof cs.GirlBrief
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.IGirlBrief} message GirlBrief message or plain object to encode
2025-08-15 13:55:26 +08:00
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
2025-08-25 11:30:50 +08:00
GirlBrief . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Decodes a GirlBrief message from the specified reader or buffer.
2025-08-15 13:55:26 +08:00
* @function decode
2025-08-25 11:30:50 +08:00
* @memberof cs.GirlBrief
2025-08-15 13:55:26 +08:00
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
2025-08-25 11:30:50 +08:00
* @returns {cs.GirlBrief} GirlBrief
2025-08-15 13:55:26 +08:00
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
2025-08-25 11:30:50 +08:00
GirlBrief . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . GirlBrief ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
case 1 : {
message . id = reader . int32 ();
break ;
}
case 2 : {
message . name = reader . string ();
break ;
}
case 3 : {
message . age = reader . int32 ();
break ;
}
case 4 : {
message . tagKey = reader . string ();
break ;
}
case 5 : {
message . priceType = reader . int32 ();
break ;
}
case 6 : {
message . price = reader . int64 ();
break ;
}
case 7 : {
message . avatar = reader . string ();
break ;
}
case 8 : {
message . star = reader . int32 ();
break ;
}
2025-09-03 11:09:35 +08:00
case 9 : {
message . category = reader . int32 ();
break ;
}
case 10 : {
message . listAvatarPath = reader . string ();
break ;
}
2025-08-25 11:30:50 +08:00
default :
reader . skipType ( tag & 7 );
break ;
2025-08-15 13:55:26 +08:00
}
}
2025-08-25 11:30:50 +08:00
return message ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Decodes a GirlBrief message from the specified reader or buffer, length delimited.
2025-08-15 13:55:26 +08:00
* @function decodeDelimited
2025-08-25 11:30:50 +08:00
* @memberof cs.GirlBrief
2025-08-15 13:55:26 +08:00
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
2025-08-25 11:30:50 +08:00
* @returns {cs.GirlBrief} GirlBrief
2025-08-15 13:55:26 +08:00
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
2025-08-25 11:30:50 +08:00
GirlBrief . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Verifies a GirlBrief message.
2025-08-15 13:55:26 +08:00
* @function verify
2025-08-25 11:30:50 +08:00
* @memberof cs.GirlBrief
2025-08-15 13:55:26 +08:00
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
2025-08-25 11:30:50 +08:00
GirlBrief . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
if ( message . id != null && message . hasOwnProperty ( "id" ))
if ( ! $util . isInteger ( message . id ))
return "id: integer expected" ;
if ( message . name != null && message . hasOwnProperty ( "name" ))
if ( ! $util . isString ( message . name ))
return "name: string expected" ;
if ( message . age != null && message . hasOwnProperty ( "age" ))
if ( ! $util . isInteger ( message . age ))
return "age: integer expected" ;
if ( message . tagKey != null && message . hasOwnProperty ( "tagKey" ))
if ( ! $util . isString ( message . tagKey ))
return "tagKey: string expected" ;
if ( message . priceType != null && message . hasOwnProperty ( "priceType" ))
if ( ! $util . isInteger ( message . priceType ))
return "priceType: integer expected" ;
if ( message . price != null && message . hasOwnProperty ( "price" ))
if ( ! $util . isInteger ( message . price ) && ! ( message . price && $util . isInteger ( message . price . low ) && $util . isInteger ( message . price . high )))
return "price: integer|Long expected" ;
if ( message . avatar != null && message . hasOwnProperty ( "avatar" ))
if ( ! $util . isString ( message . avatar ))
return "avatar: string expected" ;
if ( message . star != null && message . hasOwnProperty ( "star" ))
if ( ! $util . isInteger ( message . star ))
return "star: integer expected" ;
2025-09-03 11:09:35 +08:00
if ( message . category != null && message . hasOwnProperty ( "category" ))
if ( ! $util . isInteger ( message . category ))
return "category: integer expected" ;
if ( message . listAvatarPath != null && message . hasOwnProperty ( "listAvatarPath" ))
if ( ! $util . isString ( message . listAvatarPath ))
return "listAvatarPath: string expected" ;
2025-08-25 11:30:50 +08:00
return null ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Creates a GirlBrief message from a plain object. Also converts values to their respective internal types.
2025-08-15 13:55:26 +08:00
* @function fromObject
2025-08-25 11:30:50 +08:00
* @memberof cs.GirlBrief
2025-08-15 13:55:26 +08:00
* @static
* @param {Object.<string,*>} object Plain object
2025-08-25 11:30:50 +08:00
* @returns {cs.GirlBrief} GirlBrief
2025-08-15 13:55:26 +08:00
*/
2025-08-25 11:30:50 +08:00
GirlBrief . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . GirlBrief )
return object ;
var message = new $root . cs . GirlBrief ();
if ( object . id != null )
message . id = object . id | 0 ;
if ( object . name != null )
message . name = String ( object . name );
if ( object . age != null )
message . age = object . age | 0 ;
if ( object . tagKey != null )
message . tagKey = String ( object . tagKey );
if ( object . priceType != null )
message . priceType = object . priceType | 0 ;
if ( object . price != null )
if ( $util . Long )
( message . price = $util . Long . fromValue ( object . price )). unsigned = false ;
else if ( typeof object . price === "string" )
message . price = parseInt ( object . price , 10 );
else if ( typeof object . price === "number" )
message . price = object . price ;
else if ( typeof object . price === "object" )
message . price = new $util . LongBits ( object . price . low >>> 0 , object . price . high >>> 0 ). toNumber ();
if ( object . avatar != null )
message . avatar = String ( object . avatar );
if ( object . star != null )
message . star = object . star | 0 ;
2025-09-03 11:09:35 +08:00
if ( object . category != null )
message . category = object . category | 0 ;
if ( object . listAvatarPath != null )
message . listAvatarPath = String ( object . listAvatarPath );
2025-08-25 11:30:50 +08:00
return message ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Creates a plain object from a GirlBrief message. Also converts values to other types if specified.
2025-08-15 13:55:26 +08:00
* @function toObject
2025-08-25 11:30:50 +08:00
* @memberof cs.GirlBrief
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.GirlBrief} message GirlBrief
2025-08-15 13:55:26 +08:00
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
2025-08-25 11:30:50 +08:00
GirlBrief . toObject = function toObject ( message , options ) {
if ( ! options )
options = {};
var object = {};
if ( options . defaults ) {
object . id = 0 ;
object . name = "" ;
object . age = 0 ;
object . tagKey = "" ;
object . priceType = 0 ;
if ( $util . Long ) {
var long = new $util . Long ( 0 , 0 , false );
object . price = options . longs === String ? long . toString () : options . longs === Number ? long . toNumber () : long ;
} else
object . price = options . longs === String ? "0" : 0 ;
object . avatar = "" ;
object . star = 0 ;
2025-09-03 11:09:35 +08:00
object . category = 0 ;
object . listAvatarPath = "" ;
2025-08-25 11:30:50 +08:00
}
if ( message . id != null && message . hasOwnProperty ( "id" ))
object . id = message . id ;
if ( message . name != null && message . hasOwnProperty ( "name" ))
object . name = message . name ;
if ( message . age != null && message . hasOwnProperty ( "age" ))
object . age = message . age ;
if ( message . tagKey != null && message . hasOwnProperty ( "tagKey" ))
object . tagKey = message . tagKey ;
if ( message . priceType != null && message . hasOwnProperty ( "priceType" ))
object . priceType = message . priceType ;
if ( message . price != null && message . hasOwnProperty ( "price" ))
if ( typeof message . price === "number" )
object . price = options . longs === String ? String ( message . price ) : message . price ;
else
object . price = options . longs === String ? $util . Long . prototype . toString . call ( message . price ) : options . longs === Number ? new $util . LongBits ( message . price . low >>> 0 , message . price . high >>> 0 ). toNumber () : message . price ;
if ( message . avatar != null && message . hasOwnProperty ( "avatar" ))
object . avatar = message . avatar ;
if ( message . star != null && message . hasOwnProperty ( "star" ))
object . star = message . star ;
2025-09-03 11:09:35 +08:00
if ( message . category != null && message . hasOwnProperty ( "category" ))
object . category = message . category ;
if ( message . listAvatarPath != null && message . hasOwnProperty ( "listAvatarPath" ))
object . listAvatarPath = message . listAvatarPath ;
2025-08-25 11:30:50 +08:00
return object ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Converts this GirlBrief to JSON.
2025-08-15 13:55:26 +08:00
* @function toJSON
2025-08-25 11:30:50 +08:00
* @memberof cs.GirlBrief
2025-08-15 13:55:26 +08:00
* @instance
* @returns {Object.<string,*>} JSON object
*/
2025-08-25 11:30:50 +08:00
GirlBrief . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Gets the default type url for GirlBrief
2025-08-15 13:55:26 +08:00
* @function getTypeUrl
2025-08-25 11:30:50 +08:00
* @memberof cs.GirlBrief
2025-08-15 13:55:26 +08:00
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
2025-08-25 11:30:50 +08:00
GirlBrief . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.GirlBrief" ;
2025-08-15 13:55:26 +08:00
};
2025-08-25 11:30:50 +08:00
return GirlBrief ;
})();
2025-08-25 16:27:18 +08:00
cs . GirlPhoto = ( function () {
/**
* Properties of a GirlPhoto.
* @memberof cs
* @interface IGirlPhoto
* @property {string|null} [pic] GirlPhoto pic
* @property {boolean|null} [isRelease] GirlPhoto isRelease
* @property {number|null} [price] GirlPhoto price
*/
/**
* Constructs a new GirlPhoto.
* @memberof cs
* @classdesc Represents a GirlPhoto.
* @implements IGirlPhoto
* @constructor
* @param {cs.IGirlPhoto=} [properties] Properties to set
*/
function GirlPhoto ( properties ) {
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
}
/**
* GirlPhoto pic.
* @member {string} pic
* @memberof cs.GirlPhoto
* @instance
*/
GirlPhoto . prototype . pic = "" ;
/**
* GirlPhoto isRelease.
* @member {boolean} isRelease
* @memberof cs.GirlPhoto
* @instance
*/
GirlPhoto . prototype . isRelease = false ;
/**
* GirlPhoto price.
* @member {number} price
* @memberof cs.GirlPhoto
* @instance
*/
GirlPhoto . prototype . price = 0 ;
/**
* Creates a new GirlPhoto instance using the specified properties.
* @function create
* @memberof cs.GirlPhoto
* @static
* @param {cs.IGirlPhoto=} [properties] Properties to set
* @returns {cs.GirlPhoto} GirlPhoto instance
*/
GirlPhoto . create = function create ( properties ) {
return new GirlPhoto ( properties );
};
/**
* Encodes the specified GirlPhoto message. Does not implicitly {@link cs.GirlPhoto.verify|verify} messages.
* @function encode
* @memberof cs.GirlPhoto
* @static
* @param {cs.IGirlPhoto} message GirlPhoto message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
GirlPhoto . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
if ( message . pic != null && Object . hasOwnProperty . call ( message , "pic" ))
writer . uint32 ( /* id 1, wireType 2 =*/ 10 ). string ( message . pic );
if ( message . isRelease != null && Object . hasOwnProperty . call ( message , "isRelease" ))
writer . uint32 ( /* id 2, wireType 0 =*/ 16 ). bool ( message . isRelease );
if ( message . price != null && Object . hasOwnProperty . call ( message , "price" ))
writer . uint32 ( /* id 3, wireType 0 =*/ 24 ). int32 ( message . price );
return writer ;
};
/**
* Encodes the specified GirlPhoto message, length delimited. Does not implicitly {@link cs.GirlPhoto.verify|verify} messages.
* @function encodeDelimited
* @memberof cs.GirlPhoto
* @static
* @param {cs.IGirlPhoto} message GirlPhoto message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
GirlPhoto . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
};
/**
* Decodes a GirlPhoto message from the specified reader or buffer.
* @function decode
* @memberof cs.GirlPhoto
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
* @returns {cs.GirlPhoto} GirlPhoto
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
GirlPhoto . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . GirlPhoto ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
case 1 : {
message . pic = reader . string ();
break ;
}
case 2 : {
message . isRelease = reader . bool ();
break ;
}
case 3 : {
message . price = reader . int32 ();
break ;
}
default :
reader . skipType ( tag & 7 );
break ;
}
}
return message ;
};
/**
* Decodes a GirlPhoto message from the specified reader or buffer, length delimited.
* @function decodeDelimited
* @memberof cs.GirlPhoto
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @returns {cs.GirlPhoto} GirlPhoto
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
GirlPhoto . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
};
/**
* Verifies a GirlPhoto message.
* @function verify
* @memberof cs.GirlPhoto
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
GirlPhoto . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
if ( message . pic != null && message . hasOwnProperty ( "pic" ))
if ( ! $util . isString ( message . pic ))
return "pic: string expected" ;
if ( message . isRelease != null && message . hasOwnProperty ( "isRelease" ))
if ( typeof message . isRelease !== "boolean" )
return "isRelease: boolean expected" ;
if ( message . price != null && message . hasOwnProperty ( "price" ))
if ( ! $util . isInteger ( message . price ))
return "price: integer expected" ;
return null ;
};
/**
* Creates a GirlPhoto message from a plain object. Also converts values to their respective internal types.
* @function fromObject
* @memberof cs.GirlPhoto
* @static
* @param {Object.<string,*>} object Plain object
* @returns {cs.GirlPhoto} GirlPhoto
*/
GirlPhoto . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . GirlPhoto )
return object ;
var message = new $root . cs . GirlPhoto ();
if ( object . pic != null )
message . pic = String ( object . pic );
if ( object . isRelease != null )
message . isRelease = Boolean ( object . isRelease );
if ( object . price != null )
message . price = object . price | 0 ;
return message ;
};
/**
* Creates a plain object from a GirlPhoto message. Also converts values to other types if specified.
* @function toObject
* @memberof cs.GirlPhoto
* @static
* @param {cs.GirlPhoto} message GirlPhoto
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
GirlPhoto . toObject = function toObject ( message , options ) {
if ( ! options )
options = {};
var object = {};
if ( options . defaults ) {
object . pic = "" ;
object . isRelease = false ;
object . price = 0 ;
}
if ( message . pic != null && message . hasOwnProperty ( "pic" ))
object . pic = message . pic ;
if ( message . isRelease != null && message . hasOwnProperty ( "isRelease" ))
object . isRelease = message . isRelease ;
if ( message . price != null && message . hasOwnProperty ( "price" ))
object . price = message . price ;
return object ;
};
/**
* Converts this GirlPhoto to JSON.
* @function toJSON
* @memberof cs.GirlPhoto
* @instance
* @returns {Object.<string,*>} JSON object
*/
GirlPhoto . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
};
/**
* Gets the default type url for GirlPhoto
* @function getTypeUrl
* @memberof cs.GirlPhoto
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
GirlPhoto . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.GirlPhoto" ;
};
return GirlPhoto ;
})();
2025-09-03 11:09:35 +08:00
cs . PurchaseCommercialImage = ( function () {
/**
* Properties of a PurchaseCommercialImage.
* @memberof cs
* @interface IPurchaseCommercialImage
* @property {number|null} [imageType] PurchaseCommercialImage imageType
* @property {number|null} [imagePrice] PurchaseCommercialImage imagePrice
* @property {string|null} [path] PurchaseCommercialImage path
* @property {boolean|null} [isRelease] PurchaseCommercialImage isRelease
*/
/**
* Constructs a new PurchaseCommercialImage.
* @memberof cs
* @classdesc Represents a PurchaseCommercialImage.
* @implements IPurchaseCommercialImage
* @constructor
* @param {cs.IPurchaseCommercialImage=} [properties] Properties to set
*/
function PurchaseCommercialImage ( properties ) {
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
}
/**
* PurchaseCommercialImage imageType.
* @member {number} imageType
* @memberof cs.PurchaseCommercialImage
* @instance
*/
PurchaseCommercialImage . prototype . imageType = 0 ;
/**
* PurchaseCommercialImage imagePrice.
* @member {number} imagePrice
* @memberof cs.PurchaseCommercialImage
* @instance
*/
PurchaseCommercialImage . prototype . imagePrice = 0 ;
/**
* PurchaseCommercialImage path.
* @member {string} path
* @memberof cs.PurchaseCommercialImage
* @instance
*/
PurchaseCommercialImage . prototype . path = "" ;
/**
* PurchaseCommercialImage isRelease.
* @member {boolean} isRelease
* @memberof cs.PurchaseCommercialImage
* @instance
*/
PurchaseCommercialImage . prototype . isRelease = false ;
/**
* Creates a new PurchaseCommercialImage instance using the specified properties.
* @function create
* @memberof cs.PurchaseCommercialImage
* @static
* @param {cs.IPurchaseCommercialImage=} [properties] Properties to set
* @returns {cs.PurchaseCommercialImage} PurchaseCommercialImage instance
*/
PurchaseCommercialImage . create = function create ( properties ) {
return new PurchaseCommercialImage ( properties );
};
/**
* Encodes the specified PurchaseCommercialImage message. Does not implicitly {@link cs.PurchaseCommercialImage.verify|verify} messages.
* @function encode
* @memberof cs.PurchaseCommercialImage
* @static
* @param {cs.IPurchaseCommercialImage} message PurchaseCommercialImage message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
PurchaseCommercialImage . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
if ( message . imageType != null && Object . hasOwnProperty . call ( message , "imageType" ))
writer . uint32 ( /* id 1, wireType 0 =*/ 8 ). int32 ( message . imageType );
if ( message . imagePrice != null && Object . hasOwnProperty . call ( message , "imagePrice" ))
writer . uint32 ( /* id 2, wireType 0 =*/ 16 ). int32 ( message . imagePrice );
if ( message . path != null && Object . hasOwnProperty . call ( message , "path" ))
writer . uint32 ( /* id 3, wireType 2 =*/ 26 ). string ( message . path );
if ( message . isRelease != null && Object . hasOwnProperty . call ( message , "isRelease" ))
writer . uint32 ( /* id 4, wireType 0 =*/ 32 ). bool ( message . isRelease );
return writer ;
};
/**
* Encodes the specified PurchaseCommercialImage message, length delimited. Does not implicitly {@link cs.PurchaseCommercialImage.verify|verify} messages.
* @function encodeDelimited
* @memberof cs.PurchaseCommercialImage
* @static
* @param {cs.IPurchaseCommercialImage} message PurchaseCommercialImage message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
PurchaseCommercialImage . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
};
/**
* Decodes a PurchaseCommercialImage message from the specified reader or buffer.
* @function decode
* @memberof cs.PurchaseCommercialImage
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
* @returns {cs.PurchaseCommercialImage} PurchaseCommercialImage
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
PurchaseCommercialImage . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . PurchaseCommercialImage ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
case 1 : {
message . imageType = reader . int32 ();
break ;
}
case 2 : {
message . imagePrice = reader . int32 ();
break ;
}
case 3 : {
message . path = reader . string ();
break ;
}
case 4 : {
message . isRelease = reader . bool ();
break ;
}
default :
reader . skipType ( tag & 7 );
break ;
}
}
return message ;
};
/**
* Decodes a PurchaseCommercialImage message from the specified reader or buffer, length delimited.
* @function decodeDelimited
* @memberof cs.PurchaseCommercialImage
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @returns {cs.PurchaseCommercialImage} PurchaseCommercialImage
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
PurchaseCommercialImage . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
};
/**
* Verifies a PurchaseCommercialImage message.
* @function verify
* @memberof cs.PurchaseCommercialImage
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
PurchaseCommercialImage . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
if ( message . imageType != null && message . hasOwnProperty ( "imageType" ))
if ( ! $util . isInteger ( message . imageType ))
return "imageType: integer expected" ;
if ( message . imagePrice != null && message . hasOwnProperty ( "imagePrice" ))
if ( ! $util . isInteger ( message . imagePrice ))
return "imagePrice: integer expected" ;
if ( message . path != null && message . hasOwnProperty ( "path" ))
if ( ! $util . isString ( message . path ))
return "path: string expected" ;
if ( message . isRelease != null && message . hasOwnProperty ( "isRelease" ))
if ( typeof message . isRelease !== "boolean" )
return "isRelease: boolean expected" ;
return null ;
};
/**
* Creates a PurchaseCommercialImage message from a plain object. Also converts values to their respective internal types.
* @function fromObject
* @memberof cs.PurchaseCommercialImage
* @static
* @param {Object.<string,*>} object Plain object
* @returns {cs.PurchaseCommercialImage} PurchaseCommercialImage
*/
PurchaseCommercialImage . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . PurchaseCommercialImage )
return object ;
var message = new $root . cs . PurchaseCommercialImage ();
if ( object . imageType != null )
message . imageType = object . imageType | 0 ;
if ( object . imagePrice != null )
message . imagePrice = object . imagePrice | 0 ;
if ( object . path != null )
message . path = String ( object . path );
if ( object . isRelease != null )
message . isRelease = Boolean ( object . isRelease );
return message ;
};
/**
* Creates a plain object from a PurchaseCommercialImage message. Also converts values to other types if specified.
* @function toObject
* @memberof cs.PurchaseCommercialImage
* @static
* @param {cs.PurchaseCommercialImage} message PurchaseCommercialImage
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
PurchaseCommercialImage . toObject = function toObject ( message , options ) {
if ( ! options )
options = {};
var object = {};
if ( options . defaults ) {
object . imageType = 0 ;
object . imagePrice = 0 ;
object . path = "" ;
object . isRelease = false ;
}
if ( message . imageType != null && message . hasOwnProperty ( "imageType" ))
object . imageType = message . imageType ;
if ( message . imagePrice != null && message . hasOwnProperty ( "imagePrice" ))
object . imagePrice = message . imagePrice ;
if ( message . path != null && message . hasOwnProperty ( "path" ))
object . path = message . path ;
if ( message . isRelease != null && message . hasOwnProperty ( "isRelease" ))
object . isRelease = message . isRelease ;
return object ;
};
/**
* Converts this PurchaseCommercialImage to JSON.
* @function toJSON
* @memberof cs.PurchaseCommercialImage
* @instance
* @returns {Object.<string,*>} JSON object
*/
PurchaseCommercialImage . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
};
/**
* Gets the default type url for PurchaseCommercialImage
* @function getTypeUrl
* @memberof cs.PurchaseCommercialImage
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
PurchaseCommercialImage . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.PurchaseCommercialImage" ;
};
return PurchaseCommercialImage ;
})();
cs . PurchaseCommercialVideo = ( function () {
/**
* Properties of a PurchaseCommercialVideo.
* @memberof cs
* @interface IPurchaseCommercialVideo
* @property {string|null} [path] PurchaseCommercialVideo path
* @property {number|null} [emotion] PurchaseCommercialVideo emotion
* @property {number|null} [videoPrice] PurchaseCommercialVideo videoPrice
* @property {boolean|null} [isRelease] PurchaseCommercialVideo isRelease
*/
/**
* Constructs a new PurchaseCommercialVideo.
* @memberof cs
* @classdesc Represents a PurchaseCommercialVideo.
* @implements IPurchaseCommercialVideo
* @constructor
* @param {cs.IPurchaseCommercialVideo=} [properties] Properties to set
*/
function PurchaseCommercialVideo ( properties ) {
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
}
/**
* PurchaseCommercialVideo path.
* @member {string} path
* @memberof cs.PurchaseCommercialVideo
* @instance
*/
PurchaseCommercialVideo . prototype . path = "" ;
/**
* PurchaseCommercialVideo emotion.
* @member {number} emotion
* @memberof cs.PurchaseCommercialVideo
* @instance
*/
PurchaseCommercialVideo . prototype . emotion = 0 ;
/**
* PurchaseCommercialVideo videoPrice.
* @member {number} videoPrice
* @memberof cs.PurchaseCommercialVideo
* @instance
*/
PurchaseCommercialVideo . prototype . videoPrice = 0 ;
/**
* PurchaseCommercialVideo isRelease.
* @member {boolean} isRelease
* @memberof cs.PurchaseCommercialVideo
* @instance
*/
PurchaseCommercialVideo . prototype . isRelease = false ;
/**
* Creates a new PurchaseCommercialVideo instance using the specified properties.
* @function create
* @memberof cs.PurchaseCommercialVideo
* @static
* @param {cs.IPurchaseCommercialVideo=} [properties] Properties to set
* @returns {cs.PurchaseCommercialVideo} PurchaseCommercialVideo instance
*/
PurchaseCommercialVideo . create = function create ( properties ) {
return new PurchaseCommercialVideo ( properties );
};
/**
* Encodes the specified PurchaseCommercialVideo message. Does not implicitly {@link cs.PurchaseCommercialVideo.verify|verify} messages.
* @function encode
* @memberof cs.PurchaseCommercialVideo
* @static
* @param {cs.IPurchaseCommercialVideo} message PurchaseCommercialVideo message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
PurchaseCommercialVideo . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
if ( message . path != null && Object . hasOwnProperty . call ( message , "path" ))
writer . uint32 ( /* id 1, wireType 2 =*/ 10 ). string ( message . path );
if ( message . emotion != null && Object . hasOwnProperty . call ( message , "emotion" ))
writer . uint32 ( /* id 2, wireType 0 =*/ 16 ). int32 ( message . emotion );
if ( message . videoPrice != null && Object . hasOwnProperty . call ( message , "videoPrice" ))
writer . uint32 ( /* id 3, wireType 0 =*/ 24 ). int32 ( message . videoPrice );
if ( message . isRelease != null && Object . hasOwnProperty . call ( message , "isRelease" ))
writer . uint32 ( /* id 4, wireType 0 =*/ 32 ). bool ( message . isRelease );
return writer ;
};
/**
* Encodes the specified PurchaseCommercialVideo message, length delimited. Does not implicitly {@link cs.PurchaseCommercialVideo.verify|verify} messages.
* @function encodeDelimited
* @memberof cs.PurchaseCommercialVideo
* @static
* @param {cs.IPurchaseCommercialVideo} message PurchaseCommercialVideo message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
PurchaseCommercialVideo . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
};
/**
* Decodes a PurchaseCommercialVideo message from the specified reader or buffer.
* @function decode
* @memberof cs.PurchaseCommercialVideo
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
* @returns {cs.PurchaseCommercialVideo} PurchaseCommercialVideo
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
PurchaseCommercialVideo . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . PurchaseCommercialVideo ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
case 1 : {
message . path = reader . string ();
break ;
}
case 2 : {
message . emotion = reader . int32 ();
break ;
}
case 3 : {
message . videoPrice = reader . int32 ();
break ;
}
case 4 : {
message . isRelease = reader . bool ();
break ;
}
default :
reader . skipType ( tag & 7 );
break ;
}
}
return message ;
};
/**
* Decodes a PurchaseCommercialVideo message from the specified reader or buffer, length delimited.
* @function decodeDelimited
* @memberof cs.PurchaseCommercialVideo
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @returns {cs.PurchaseCommercialVideo} PurchaseCommercialVideo
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
PurchaseCommercialVideo . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
};
/**
* Verifies a PurchaseCommercialVideo message.
* @function verify
* @memberof cs.PurchaseCommercialVideo
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
PurchaseCommercialVideo . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
if ( message . path != null && message . hasOwnProperty ( "path" ))
if ( ! $util . isString ( message . path ))
return "path: string expected" ;
if ( message . emotion != null && message . hasOwnProperty ( "emotion" ))
if ( ! $util . isInteger ( message . emotion ))
return "emotion: integer expected" ;
if ( message . videoPrice != null && message . hasOwnProperty ( "videoPrice" ))
if ( ! $util . isInteger ( message . videoPrice ))
return "videoPrice: integer expected" ;
if ( message . isRelease != null && message . hasOwnProperty ( "isRelease" ))
if ( typeof message . isRelease !== "boolean" )
return "isRelease: boolean expected" ;
return null ;
};
/**
* Creates a PurchaseCommercialVideo message from a plain object. Also converts values to their respective internal types.
* @function fromObject
* @memberof cs.PurchaseCommercialVideo
* @static
* @param {Object.<string,*>} object Plain object
* @returns {cs.PurchaseCommercialVideo} PurchaseCommercialVideo
*/
PurchaseCommercialVideo . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . PurchaseCommercialVideo )
return object ;
var message = new $root . cs . PurchaseCommercialVideo ();
if ( object . path != null )
message . path = String ( object . path );
if ( object . emotion != null )
message . emotion = object . emotion | 0 ;
if ( object . videoPrice != null )
message . videoPrice = object . videoPrice | 0 ;
if ( object . isRelease != null )
message . isRelease = Boolean ( object . isRelease );
return message ;
};
/**
* Creates a plain object from a PurchaseCommercialVideo message. Also converts values to other types if specified.
* @function toObject
* @memberof cs.PurchaseCommercialVideo
* @static
* @param {cs.PurchaseCommercialVideo} message PurchaseCommercialVideo
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
PurchaseCommercialVideo . toObject = function toObject ( message , options ) {
if ( ! options )
options = {};
var object = {};
if ( options . defaults ) {
object . path = "" ;
object . emotion = 0 ;
object . videoPrice = 0 ;
object . isRelease = false ;
}
if ( message . path != null && message . hasOwnProperty ( "path" ))
object . path = message . path ;
if ( message . emotion != null && message . hasOwnProperty ( "emotion" ))
object . emotion = message . emotion ;
if ( message . videoPrice != null && message . hasOwnProperty ( "videoPrice" ))
object . videoPrice = message . videoPrice ;
if ( message . isRelease != null && message . hasOwnProperty ( "isRelease" ))
object . isRelease = message . isRelease ;
return object ;
};
/**
* Converts this PurchaseCommercialVideo to JSON.
* @function toJSON
* @memberof cs.PurchaseCommercialVideo
* @instance
* @returns {Object.<string,*>} JSON object
*/
PurchaseCommercialVideo . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
};
/**
* Gets the default type url for PurchaseCommercialVideo
* @function getTypeUrl
* @memberof cs.PurchaseCommercialVideo
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
PurchaseCommercialVideo . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.PurchaseCommercialVideo" ;
};
return PurchaseCommercialVideo ;
})();
2025-08-25 11:30:50 +08:00
cs . GirlDetail = ( function () {
2025-08-15 13:55:26 +08:00
/**
2025-08-25 11:30:50 +08:00
* Properties of a GirlDetail.
* @memberof cs
* @interface IGirlDetail
* @property {cs.IGirlBrief|null} [brief] GirlDetail brief
* @property {string|null} [desc] GirlDetail desc
2025-08-25 16:27:18 +08:00
* @property {boolean|null} [isRelease] GirlDetail isRelease
* @property {number|null} [chatCount] GirlDetail chatCount
2025-09-03 11:09:35 +08:00
* @property {Array.<cs.IPurchaseCommercialImage>|null} [images] GirlDetail images
* @property {Array.<cs.IPurchaseCommercialVideo>|null} [videos] GirlDetail videos
2025-08-15 13:55:26 +08:00
*/
/**
2025-08-25 11:30:50 +08:00
* Constructs a new GirlDetail.
* @memberof cs
* @classdesc Represents a GirlDetail.
* @implements IGirlDetail
2025-08-15 13:55:26 +08:00
* @constructor
2025-08-25 11:30:50 +08:00
* @param {cs.IGirlDetail=} [properties] Properties to set
2025-08-15 13:55:26 +08:00
*/
2025-08-25 11:30:50 +08:00
function GirlDetail ( properties ) {
2025-09-03 11:09:35 +08:00
this . images = [];
this . videos = [];
2025-08-25 11:30:50 +08:00
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
2025-08-15 13:55:26 +08:00
}
/**
2025-08-25 11:30:50 +08:00
* GirlDetail brief.
* @member {cs.IGirlBrief|null|undefined} brief
* @memberof cs.GirlDetail
2025-08-15 13:55:26 +08:00
* @instance
*/
2025-08-25 11:30:50 +08:00
GirlDetail . prototype . brief = null ;
2025-08-15 13:55:26 +08:00
/**
2025-08-25 11:30:50 +08:00
* GirlDetail desc.
* @member {string} desc
* @memberof cs.GirlDetail
2025-08-15 13:55:26 +08:00
* @instance
*/
2025-08-25 11:30:50 +08:00
GirlDetail . prototype . desc = "" ;
2025-08-15 13:55:26 +08:00
2025-08-25 16:27:18 +08:00
/**
* GirlDetail isRelease.
* @member {boolean} isRelease
* @memberof cs.GirlDetail
* @instance
*/
GirlDetail . prototype . isRelease = false ;
/**
* GirlDetail chatCount.
* @member {number} chatCount
* @memberof cs.GirlDetail
* @instance
*/
GirlDetail . prototype . chatCount = 0 ;
2025-08-15 13:55:26 +08:00
2025-09-03 11:09:35 +08:00
/**
* GirlDetail images.
* @member {Array.<cs.IPurchaseCommercialImage>} images
* @memberof cs.GirlDetail
* @instance
*/
GirlDetail . prototype . images = $util . emptyArray ;
/**
* GirlDetail videos.
* @member {Array.<cs.IPurchaseCommercialVideo>} videos
* @memberof cs.GirlDetail
* @instance
*/
GirlDetail . prototype . videos = $util . emptyArray ;
2025-08-15 13:55:26 +08:00
/**
2025-08-25 11:30:50 +08:00
* Creates a new GirlDetail instance using the specified properties.
2025-08-15 13:55:26 +08:00
* @function create
2025-08-25 11:30:50 +08:00
* @memberof cs.GirlDetail
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.IGirlDetail=} [properties] Properties to set
* @returns {cs.GirlDetail} GirlDetail instance
2025-08-15 13:55:26 +08:00
*/
2025-08-25 11:30:50 +08:00
GirlDetail . create = function create ( properties ) {
return new GirlDetail ( properties );
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Encodes the specified GirlDetail message. Does not implicitly {@link cs.GirlDetail.verify|verify} messages.
2025-08-15 13:55:26 +08:00
* @function encode
2025-08-25 11:30:50 +08:00
* @memberof cs.GirlDetail
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.IGirlDetail} message GirlDetail message or plain object to encode
2025-08-15 13:55:26 +08:00
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
2025-08-25 11:30:50 +08:00
GirlDetail . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
if ( message . brief != null && Object . hasOwnProperty . call ( message , "brief" ))
$root . cs . GirlBrief . encode ( message . brief , writer . uint32 ( /* id 1, wireType 2 =*/ 10 ). fork ()). ldelim ();
if ( message . desc != null && Object . hasOwnProperty . call ( message , "desc" ))
writer . uint32 ( /* id 2, wireType 2 =*/ 18 ). string ( message . desc );
2025-08-25 16:27:18 +08:00
if ( message . isRelease != null && Object . hasOwnProperty . call ( message , "isRelease" ))
writer . uint32 ( /* id 4, wireType 0 =*/ 32 ). bool ( message . isRelease );
if ( message . chatCount != null && Object . hasOwnProperty . call ( message , "chatCount" ))
writer . uint32 ( /* id 5, wireType 0 =*/ 40 ). int32 ( message . chatCount );
2025-09-03 11:09:35 +08:00
if ( message . images != null && message . images . length )
for ( var i = 0 ; i < message . images . length ; ++ i )
$root . cs . PurchaseCommercialImage . encode ( message . images [ i ], writer . uint32 ( /* id 6, wireType 2 =*/ 50 ). fork ()). ldelim ();
if ( message . videos != null && message . videos . length )
for ( var i = 0 ; i < message . videos . length ; ++ i )
$root . cs . PurchaseCommercialVideo . encode ( message . videos [ i ], writer . uint32 ( /* id 7, wireType 2 =*/ 58 ). fork ()). ldelim ();
2025-08-25 11:30:50 +08:00
return writer ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Encodes the specified GirlDetail message, length delimited. Does not implicitly {@link cs.GirlDetail.verify|verify} messages.
2025-08-15 13:55:26 +08:00
* @function encodeDelimited
2025-08-25 11:30:50 +08:00
* @memberof cs.GirlDetail
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.IGirlDetail} message GirlDetail message or plain object to encode
2025-08-15 13:55:26 +08:00
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
2025-08-25 11:30:50 +08:00
GirlDetail . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Decodes a GirlDetail message from the specified reader or buffer.
2025-08-15 13:55:26 +08:00
* @function decode
2025-08-25 11:30:50 +08:00
* @memberof cs.GirlDetail
2025-08-15 13:55:26 +08:00
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
2025-08-25 11:30:50 +08:00
* @returns {cs.GirlDetail} GirlDetail
2025-08-15 13:55:26 +08:00
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
2025-08-25 11:30:50 +08:00
GirlDetail . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . GirlDetail ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
case 1 : {
message . brief = $root . cs . GirlBrief . decode ( reader , reader . uint32 ());
break ;
}
case 2 : {
message . desc = reader . string ();
break ;
}
2025-08-25 16:27:18 +08:00
case 4 : {
message . isRelease = reader . bool ();
break ;
}
case 5 : {
message . chatCount = reader . int32 ();
2025-08-25 11:30:50 +08:00
break ;
}
2025-09-03 11:09:35 +08:00
case 6 : {
if ( ! ( message . images && message . images . length ))
message . images = [];
message . images . push ( $root . cs . PurchaseCommercialImage . decode ( reader , reader . uint32 ()));
break ;
}
case 7 : {
if ( ! ( message . videos && message . videos . length ))
message . videos = [];
message . videos . push ( $root . cs . PurchaseCommercialVideo . decode ( reader , reader . uint32 ()));
break ;
}
2025-08-25 11:30:50 +08:00
default :
reader . skipType ( tag & 7 );
break ;
}
2025-08-15 13:55:26 +08:00
}
2025-08-25 11:30:50 +08:00
return message ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Decodes a GirlDetail message from the specified reader or buffer, length delimited.
2025-08-15 13:55:26 +08:00
* @function decodeDelimited
2025-08-25 11:30:50 +08:00
* @memberof cs.GirlDetail
2025-08-15 13:55:26 +08:00
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
2025-08-25 11:30:50 +08:00
* @returns {cs.GirlDetail} GirlDetail
2025-08-15 13:55:26 +08:00
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
2025-08-25 11:30:50 +08:00
GirlDetail . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Verifies a GirlDetail message.
2025-08-15 13:55:26 +08:00
* @function verify
2025-08-25 11:30:50 +08:00
* @memberof cs.GirlDetail
2025-08-15 13:55:26 +08:00
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
2025-08-25 11:30:50 +08:00
GirlDetail . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
if ( message . brief != null && message . hasOwnProperty ( "brief" )) {
var error = $root . cs . GirlBrief . verify ( message . brief );
if ( error )
return "brief." + error ;
2025-08-15 13:55:26 +08:00
}
2025-08-25 11:30:50 +08:00
if ( message . desc != null && message . hasOwnProperty ( "desc" ))
if ( ! $util . isString ( message . desc ))
return "desc: string expected" ;
2025-08-25 16:27:18 +08:00
if ( message . isRelease != null && message . hasOwnProperty ( "isRelease" ))
if ( typeof message . isRelease !== "boolean" )
return "isRelease: boolean expected" ;
if ( message . chatCount != null && message . hasOwnProperty ( "chatCount" ))
if ( ! $util . isInteger ( message . chatCount ))
return "chatCount: integer expected" ;
2025-09-03 11:09:35 +08:00
if ( message . images != null && message . hasOwnProperty ( "images" )) {
if ( ! Array . isArray ( message . images ))
return "images: array expected" ;
for ( var i = 0 ; i < message . images . length ; ++ i ) {
var error = $root . cs . PurchaseCommercialImage . verify ( message . images [ i ]);
if ( error )
return "images." + error ;
}
}
if ( message . videos != null && message . hasOwnProperty ( "videos" )) {
if ( ! Array . isArray ( message . videos ))
return "videos: array expected" ;
for ( var i = 0 ; i < message . videos . length ; ++ i ) {
var error = $root . cs . PurchaseCommercialVideo . verify ( message . videos [ i ]);
if ( error )
return "videos." + error ;
}
}
2025-08-25 11:30:50 +08:00
return null ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Creates a GirlDetail message from a plain object. Also converts values to their respective internal types.
2025-08-15 13:55:26 +08:00
* @function fromObject
2025-08-25 11:30:50 +08:00
* @memberof cs.GirlDetail
2025-08-15 13:55:26 +08:00
* @static
* @param {Object.<string,*>} object Plain object
2025-08-25 11:30:50 +08:00
* @returns {cs.GirlDetail} GirlDetail
2025-08-15 13:55:26 +08:00
*/
2025-08-25 11:30:50 +08:00
GirlDetail . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . GirlDetail )
return object ;
var message = new $root . cs . GirlDetail ();
if ( object . brief != null ) {
if ( typeof object . brief !== "object" )
throw TypeError ( ".cs.GirlDetail.brief: object expected" );
message . brief = $root . cs . GirlBrief . fromObject ( object . brief );
}
if ( object . desc != null )
message . desc = String ( object . desc );
2025-08-25 16:27:18 +08:00
if ( object . isRelease != null )
message . isRelease = Boolean ( object . isRelease );
if ( object . chatCount != null )
message . chatCount = object . chatCount | 0 ;
2025-09-03 11:09:35 +08:00
if ( object . images ) {
if ( ! Array . isArray ( object . images ))
throw TypeError ( ".cs.GirlDetail.images: array expected" );
message . images = [];
for ( var i = 0 ; i < object . images . length ; ++ i ) {
if ( typeof object . images [ i ] !== "object" )
throw TypeError ( ".cs.GirlDetail.images: object expected" );
message . images [ i ] = $root . cs . PurchaseCommercialImage . fromObject ( object . images [ i ]);
}
}
if ( object . videos ) {
if ( ! Array . isArray ( object . videos ))
throw TypeError ( ".cs.GirlDetail.videos: array expected" );
message . videos = [];
for ( var i = 0 ; i < object . videos . length ; ++ i ) {
if ( typeof object . videos [ i ] !== "object" )
throw TypeError ( ".cs.GirlDetail.videos: object expected" );
message . videos [ i ] = $root . cs . PurchaseCommercialVideo . fromObject ( object . videos [ i ]);
}
}
2025-08-25 11:30:50 +08:00
return message ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Creates a plain object from a GirlDetail message. Also converts values to other types if specified.
2025-08-15 13:55:26 +08:00
* @function toObject
2025-08-25 11:30:50 +08:00
* @memberof cs.GirlDetail
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.GirlDetail} message GirlDetail
2025-08-15 13:55:26 +08:00
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
2025-08-25 11:30:50 +08:00
GirlDetail . toObject = function toObject ( message , options ) {
if ( ! options )
options = {};
var object = {};
2025-09-03 11:09:35 +08:00
if ( options . arrays || options . defaults ) {
object . images = [];
object . videos = [];
}
2025-08-25 11:30:50 +08:00
if ( options . defaults ) {
object . brief = null ;
object . desc = "" ;
2025-08-25 16:27:18 +08:00
object . isRelease = false ;
object . chatCount = 0 ;
2025-08-25 11:30:50 +08:00
}
if ( message . brief != null && message . hasOwnProperty ( "brief" ))
object . brief = $root . cs . GirlBrief . toObject ( message . brief , options );
if ( message . desc != null && message . hasOwnProperty ( "desc" ))
object . desc = message . desc ;
2025-08-25 16:27:18 +08:00
if ( message . isRelease != null && message . hasOwnProperty ( "isRelease" ))
object . isRelease = message . isRelease ;
if ( message . chatCount != null && message . hasOwnProperty ( "chatCount" ))
object . chatCount = message . chatCount ;
2025-09-03 11:09:35 +08:00
if ( message . images && message . images . length ) {
object . images = [];
for ( var j = 0 ; j < message . images . length ; ++ j )
object . images [ j ] = $root . cs . PurchaseCommercialImage . toObject ( message . images [ j ], options );
}
if ( message . videos && message . videos . length ) {
object . videos = [];
for ( var j = 0 ; j < message . videos . length ; ++ j )
object . videos [ j ] = $root . cs . PurchaseCommercialVideo . toObject ( message . videos [ j ], options );
}
2025-08-25 11:30:50 +08:00
return object ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Converts this GirlDetail to JSON.
2025-08-15 13:55:26 +08:00
* @function toJSON
2025-08-25 11:30:50 +08:00
* @memberof cs.GirlDetail
2025-08-15 13:55:26 +08:00
* @instance
* @returns {Object.<string,*>} JSON object
*/
2025-08-25 11:30:50 +08:00
GirlDetail . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Gets the default type url for GirlDetail
2025-08-15 13:55:26 +08:00
* @function getTypeUrl
2025-08-25 11:30:50 +08:00
* @memberof cs.GirlDetail
2025-08-15 13:55:26 +08:00
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
2025-08-25 11:30:50 +08:00
GirlDetail . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.GirlDetail" ;
2025-08-15 13:55:26 +08:00
};
2025-08-25 11:30:50 +08:00
return GirlDetail ;
2025-08-15 13:55:26 +08:00
})();
2025-08-25 11:30:50 +08:00
cs . CSDailyRecommendReq = ( function () {
2025-08-15 13:55:26 +08:00
/**
2025-08-25 11:30:50 +08:00
* Properties of a CSDailyRecommendReq.
* @memberof cs
* @interface ICSDailyRecommendReq
2025-08-15 13:55:26 +08:00
*/
/**
2025-08-25 11:30:50 +08:00
* Constructs a new CSDailyRecommendReq.
* @memberof cs
* @classdesc Represents a CSDailyRecommendReq.
* @implements ICSDailyRecommendReq
2025-08-15 13:55:26 +08:00
* @constructor
2025-08-25 11:30:50 +08:00
* @param {cs.ICSDailyRecommendReq=} [properties] Properties to set
2025-08-15 13:55:26 +08:00
*/
2025-08-25 11:30:50 +08:00
function CSDailyRecommendReq ( properties ) {
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
2025-08-15 13:55:26 +08:00
}
/**
2025-08-25 11:30:50 +08:00
* Creates a new CSDailyRecommendReq instance using the specified properties.
2025-08-15 13:55:26 +08:00
* @function create
2025-08-25 11:30:50 +08:00
* @memberof cs.CSDailyRecommendReq
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.ICSDailyRecommendReq=} [properties] Properties to set
* @returns {cs.CSDailyRecommendReq} CSDailyRecommendReq instance
2025-08-15 13:55:26 +08:00
*/
2025-08-25 11:30:50 +08:00
CSDailyRecommendReq . create = function create ( properties ) {
return new CSDailyRecommendReq ( properties );
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Encodes the specified CSDailyRecommendReq message. Does not implicitly {@link cs.CSDailyRecommendReq.verify|verify} messages.
2025-08-15 13:55:26 +08:00
* @function encode
2025-08-25 11:30:50 +08:00
* @memberof cs.CSDailyRecommendReq
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.ICSDailyRecommendReq} message CSDailyRecommendReq message or plain object to encode
2025-08-15 13:55:26 +08:00
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
2025-08-25 11:30:50 +08:00
CSDailyRecommendReq . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
return writer ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Encodes the specified CSDailyRecommendReq message, length delimited. Does not implicitly {@link cs.CSDailyRecommendReq.verify|verify} messages.
2025-08-15 13:55:26 +08:00
* @function encodeDelimited
2025-08-25 11:30:50 +08:00
* @memberof cs.CSDailyRecommendReq
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.ICSDailyRecommendReq} message CSDailyRecommendReq message or plain object to encode
2025-08-15 13:55:26 +08:00
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
2025-08-25 11:30:50 +08:00
CSDailyRecommendReq . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Decodes a CSDailyRecommendReq message from the specified reader or buffer.
2025-08-15 13:55:26 +08:00
* @function decode
2025-08-25 11:30:50 +08:00
* @memberof cs.CSDailyRecommendReq
2025-08-15 13:55:26 +08:00
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
2025-08-25 11:30:50 +08:00
* @returns {cs.CSDailyRecommendReq} CSDailyRecommendReq
2025-08-15 13:55:26 +08:00
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
2025-08-25 11:30:50 +08:00
CSDailyRecommendReq . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . CSDailyRecommendReq ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
default :
reader . skipType ( tag & 7 );
break ;
}
2025-08-15 13:55:26 +08:00
}
2025-08-25 11:30:50 +08:00
return message ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Decodes a CSDailyRecommendReq message from the specified reader or buffer, length delimited.
2025-08-15 13:55:26 +08:00
* @function decodeDelimited
2025-08-25 11:30:50 +08:00
* @memberof cs.CSDailyRecommendReq
2025-08-15 13:55:26 +08:00
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
2025-08-25 11:30:50 +08:00
* @returns {cs.CSDailyRecommendReq} CSDailyRecommendReq
2025-08-15 13:55:26 +08:00
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
2025-08-25 11:30:50 +08:00
CSDailyRecommendReq . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Verifies a CSDailyRecommendReq message.
2025-08-15 13:55:26 +08:00
* @function verify
2025-08-25 11:30:50 +08:00
* @memberof cs.CSDailyRecommendReq
2025-08-15 13:55:26 +08:00
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
2025-08-25 11:30:50 +08:00
CSDailyRecommendReq . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
return null ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Creates a CSDailyRecommendReq message from a plain object. Also converts values to their respective internal types.
2025-08-15 13:55:26 +08:00
* @function fromObject
2025-08-25 11:30:50 +08:00
* @memberof cs.CSDailyRecommendReq
2025-08-15 13:55:26 +08:00
* @static
* @param {Object.<string,*>} object Plain object
2025-08-25 11:30:50 +08:00
* @returns {cs.CSDailyRecommendReq} CSDailyRecommendReq
2025-08-15 13:55:26 +08:00
*/
2025-08-25 11:30:50 +08:00
CSDailyRecommendReq . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . CSDailyRecommendReq )
return object ;
return new $root . cs . CSDailyRecommendReq ();
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Creates a plain object from a CSDailyRecommendReq message. Also converts values to other types if specified.
2025-08-15 13:55:26 +08:00
* @function toObject
2025-08-25 11:30:50 +08:00
* @memberof cs.CSDailyRecommendReq
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.CSDailyRecommendReq} message CSDailyRecommendReq
2025-08-15 13:55:26 +08:00
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
2025-08-25 11:30:50 +08:00
CSDailyRecommendReq . toObject = function toObject () {
return {};
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Converts this CSDailyRecommendReq to JSON.
2025-08-15 13:55:26 +08:00
* @function toJSON
2025-08-25 11:30:50 +08:00
* @memberof cs.CSDailyRecommendReq
2025-08-15 13:55:26 +08:00
* @instance
* @returns {Object.<string,*>} JSON object
*/
2025-08-25 11:30:50 +08:00
CSDailyRecommendReq . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Gets the default type url for CSDailyRecommendReq
2025-08-15 13:55:26 +08:00
* @function getTypeUrl
2025-08-25 11:30:50 +08:00
* @memberof cs.CSDailyRecommendReq
2025-08-15 13:55:26 +08:00
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
2025-08-25 11:30:50 +08:00
CSDailyRecommendReq . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.CSDailyRecommendReq" ;
2025-08-15 13:55:26 +08:00
};
2025-08-25 11:30:50 +08:00
return CSDailyRecommendReq ;
2025-08-15 13:55:26 +08:00
})();
2025-08-25 11:30:50 +08:00
cs . CSDailyRecommendRes = ( function () {
2025-08-15 13:55:26 +08:00
/**
2025-08-25 11:30:50 +08:00
* Properties of a CSDailyRecommendRes.
* @memberof cs
* @interface ICSDailyRecommendRes
* @property {Array.<cs.IGirlBrief>|null} [girls] CSDailyRecommendRes girls
2025-08-15 13:55:26 +08:00
*/
/**
2025-08-25 11:30:50 +08:00
* Constructs a new CSDailyRecommendRes.
* @memberof cs
* @classdesc Represents a CSDailyRecommendRes.
* @implements ICSDailyRecommendRes
2025-08-15 13:55:26 +08:00
* @constructor
2025-08-25 11:30:50 +08:00
* @param {cs.ICSDailyRecommendRes=} [properties] Properties to set
2025-08-15 13:55:26 +08:00
*/
2025-08-25 11:30:50 +08:00
function CSDailyRecommendRes ( properties ) {
this . girls = [];
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
2025-08-15 13:55:26 +08:00
}
/**
2025-08-25 11:30:50 +08:00
* CSDailyRecommendRes girls.
* @member {Array.<cs.IGirlBrief>} girls
* @memberof cs.CSDailyRecommendRes
* @instance
*/
CSDailyRecommendRes . prototype . girls = $util . emptyArray ;
/**
* Creates a new CSDailyRecommendRes instance using the specified properties.
2025-08-15 13:55:26 +08:00
* @function create
2025-08-25 11:30:50 +08:00
* @memberof cs.CSDailyRecommendRes
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.ICSDailyRecommendRes=} [properties] Properties to set
* @returns {cs.CSDailyRecommendRes} CSDailyRecommendRes instance
2025-08-15 13:55:26 +08:00
*/
2025-08-25 11:30:50 +08:00
CSDailyRecommendRes . create = function create ( properties ) {
return new CSDailyRecommendRes ( properties );
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Encodes the specified CSDailyRecommendRes message. Does not implicitly {@link cs.CSDailyRecommendRes.verify|verify} messages.
2025-08-15 13:55:26 +08:00
* @function encode
2025-08-25 11:30:50 +08:00
* @memberof cs.CSDailyRecommendRes
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.ICSDailyRecommendRes} message CSDailyRecommendRes message or plain object to encode
2025-08-15 13:55:26 +08:00
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
2025-08-25 11:30:50 +08:00
CSDailyRecommendRes . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
if ( message . girls != null && message . girls . length )
for ( var i = 0 ; i < message . girls . length ; ++ i )
$root . cs . GirlBrief . encode ( message . girls [ i ], writer . uint32 ( /* id 1, wireType 2 =*/ 10 ). fork ()). ldelim ();
return writer ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Encodes the specified CSDailyRecommendRes message, length delimited. Does not implicitly {@link cs.CSDailyRecommendRes.verify|verify} messages.
2025-08-15 13:55:26 +08:00
* @function encodeDelimited
2025-08-25 11:30:50 +08:00
* @memberof cs.CSDailyRecommendRes
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.ICSDailyRecommendRes} message CSDailyRecommendRes message or plain object to encode
2025-08-15 13:55:26 +08:00
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
2025-08-25 11:30:50 +08:00
CSDailyRecommendRes . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Decodes a CSDailyRecommendRes message from the specified reader or buffer.
2025-08-15 13:55:26 +08:00
* @function decode
2025-08-25 11:30:50 +08:00
* @memberof cs.CSDailyRecommendRes
2025-08-15 13:55:26 +08:00
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
2025-08-25 11:30:50 +08:00
* @returns {cs.CSDailyRecommendRes} CSDailyRecommendRes
2025-08-15 13:55:26 +08:00
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
2025-08-25 11:30:50 +08:00
CSDailyRecommendRes . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . CSDailyRecommendRes ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
case 1 : {
if ( ! ( message . girls && message . girls . length ))
message . girls = [];
message . girls . push ( $root . cs . GirlBrief . decode ( reader , reader . uint32 ()));
break ;
}
default :
reader . skipType ( tag & 7 );
break ;
}
2025-08-15 13:55:26 +08:00
}
2025-08-25 11:30:50 +08:00
return message ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Decodes a CSDailyRecommendRes message from the specified reader or buffer, length delimited.
2025-08-15 13:55:26 +08:00
* @function decodeDelimited
2025-08-25 11:30:50 +08:00
* @memberof cs.CSDailyRecommendRes
2025-08-15 13:55:26 +08:00
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
2025-08-25 11:30:50 +08:00
* @returns {cs.CSDailyRecommendRes} CSDailyRecommendRes
2025-08-15 13:55:26 +08:00
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
2025-08-25 11:30:50 +08:00
CSDailyRecommendRes . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Verifies a CSDailyRecommendRes message.
2025-08-15 13:55:26 +08:00
* @function verify
2025-08-25 11:30:50 +08:00
* @memberof cs.CSDailyRecommendRes
2025-08-15 13:55:26 +08:00
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
2025-08-25 11:30:50 +08:00
CSDailyRecommendRes . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
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 . GirlBrief . verify ( message . girls [ i ]);
if ( error )
return "girls." + error ;
}
}
return null ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Creates a CSDailyRecommendRes message from a plain object. Also converts values to their respective internal types.
2025-08-15 13:55:26 +08:00
* @function fromObject
2025-08-25 11:30:50 +08:00
* @memberof cs.CSDailyRecommendRes
2025-08-15 13:55:26 +08:00
* @static
* @param {Object.<string,*>} object Plain object
2025-08-25 11:30:50 +08:00
* @returns {cs.CSDailyRecommendRes} CSDailyRecommendRes
2025-08-15 13:55:26 +08:00
*/
2025-08-25 11:30:50 +08:00
CSDailyRecommendRes . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . CSDailyRecommendRes )
return object ;
var message = new $root . cs . CSDailyRecommendRes ();
if ( object . girls ) {
if ( ! Array . isArray ( object . girls ))
throw TypeError ( ".cs.CSDailyRecommendRes.girls: array expected" );
message . girls = [];
for ( var i = 0 ; i < object . girls . length ; ++ i ) {
if ( typeof object . girls [ i ] !== "object" )
throw TypeError ( ".cs.CSDailyRecommendRes.girls: object expected" );
message . girls [ i ] = $root . cs . GirlBrief . fromObject ( object . girls [ i ]);
}
}
return message ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Creates a plain object from a CSDailyRecommendRes message. Also converts values to other types if specified.
2025-08-15 13:55:26 +08:00
* @function toObject
2025-08-25 11:30:50 +08:00
* @memberof cs.CSDailyRecommendRes
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.CSDailyRecommendRes} message CSDailyRecommendRes
2025-08-15 13:55:26 +08:00
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
2025-08-25 11:30:50 +08:00
CSDailyRecommendRes . toObject = function toObject ( message , options ) {
if ( ! options )
options = {};
var object = {};
if ( options . arrays || options . defaults )
object . girls = [];
if ( message . girls && message . girls . length ) {
object . girls = [];
for ( var j = 0 ; j < message . girls . length ; ++ j )
object . girls [ j ] = $root . cs . GirlBrief . toObject ( message . girls [ j ], options );
}
return object ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Converts this CSDailyRecommendRes to JSON.
2025-08-15 13:55:26 +08:00
* @function toJSON
2025-08-25 11:30:50 +08:00
* @memberof cs.CSDailyRecommendRes
2025-08-15 13:55:26 +08:00
* @instance
* @returns {Object.<string,*>} JSON object
*/
2025-08-25 11:30:50 +08:00
CSDailyRecommendRes . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Gets the default type url for CSDailyRecommendRes
2025-08-15 13:55:26 +08:00
* @function getTypeUrl
2025-08-25 11:30:50 +08:00
* @memberof cs.CSDailyRecommendRes
2025-08-15 13:55:26 +08:00
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
2025-08-25 11:30:50 +08:00
CSDailyRecommendRes . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.CSDailyRecommendRes" ;
2025-08-15 13:55:26 +08:00
};
2025-08-25 11:30:50 +08:00
return CSDailyRecommendRes ;
2025-08-15 13:55:26 +08:00
})();
2025-08-25 11:30:50 +08:00
cs . CSHallThemeReq = ( function () {
2025-08-15 13:55:26 +08:00
/**
2025-08-25 11:30:50 +08:00
* Properties of a CSHallThemeReq.
* @memberof cs
* @interface ICSHallThemeReq
2025-08-15 13:55:26 +08:00
*/
/**
2025-08-25 11:30:50 +08:00
* Constructs a new CSHallThemeReq.
* @memberof cs
* @classdesc Represents a CSHallThemeReq.
* @implements ICSHallThemeReq
2025-08-15 13:55:26 +08:00
* @constructor
2025-08-25 11:30:50 +08:00
* @param {cs.ICSHallThemeReq=} [properties] Properties to set
2025-08-15 13:55:26 +08:00
*/
2025-08-25 11:30:50 +08:00
function CSHallThemeReq ( properties ) {
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
2025-08-15 13:55:26 +08:00
}
/**
2025-08-25 11:30:50 +08:00
* Creates a new CSHallThemeReq instance using the specified properties.
2025-08-15 13:55:26 +08:00
* @function create
2025-08-25 11:30:50 +08:00
* @memberof cs.CSHallThemeReq
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.ICSHallThemeReq=} [properties] Properties to set
* @returns {cs.CSHallThemeReq} CSHallThemeReq instance
2025-08-15 13:55:26 +08:00
*/
2025-08-25 11:30:50 +08:00
CSHallThemeReq . create = function create ( properties ) {
return new CSHallThemeReq ( properties );
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Encodes the specified CSHallThemeReq message. Does not implicitly {@link cs.CSHallThemeReq.verify|verify} messages.
2025-08-15 13:55:26 +08:00
* @function encode
2025-08-25 11:30:50 +08:00
* @memberof cs.CSHallThemeReq
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.ICSHallThemeReq} message CSHallThemeReq message or plain object to encode
2025-08-15 13:55:26 +08:00
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
2025-08-25 11:30:50 +08:00
CSHallThemeReq . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
return writer ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Encodes the specified CSHallThemeReq message, length delimited. Does not implicitly {@link cs.CSHallThemeReq.verify|verify} messages.
2025-08-15 13:55:26 +08:00
* @function encodeDelimited
2025-08-25 11:30:50 +08:00
* @memberof cs.CSHallThemeReq
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.ICSHallThemeReq} message CSHallThemeReq message or plain object to encode
2025-08-15 13:55:26 +08:00
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
2025-08-25 11:30:50 +08:00
CSHallThemeReq . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Decodes a CSHallThemeReq message from the specified reader or buffer.
2025-08-15 13:55:26 +08:00
* @function decode
2025-08-25 11:30:50 +08:00
* @memberof cs.CSHallThemeReq
2025-08-15 13:55:26 +08:00
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
2025-08-25 11:30:50 +08:00
* @returns {cs.CSHallThemeReq} CSHallThemeReq
2025-08-15 13:55:26 +08:00
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
2025-08-25 11:30:50 +08:00
CSHallThemeReq . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . CSHallThemeReq ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
default :
reader . skipType ( tag & 7 );
break ;
}
2025-08-15 13:55:26 +08:00
}
2025-08-25 11:30:50 +08:00
return message ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Decodes a CSHallThemeReq message from the specified reader or buffer, length delimited.
2025-08-15 13:55:26 +08:00
* @function decodeDelimited
2025-08-25 11:30:50 +08:00
* @memberof cs.CSHallThemeReq
2025-08-15 13:55:26 +08:00
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
2025-08-25 11:30:50 +08:00
* @returns {cs.CSHallThemeReq} CSHallThemeReq
2025-08-15 13:55:26 +08:00
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
2025-08-25 11:30:50 +08:00
CSHallThemeReq . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Verifies a CSHallThemeReq message.
2025-08-15 13:55:26 +08:00
* @function verify
2025-08-25 11:30:50 +08:00
* @memberof cs.CSHallThemeReq
2025-08-15 13:55:26 +08:00
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
2025-08-25 11:30:50 +08:00
CSHallThemeReq . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
return null ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Creates a CSHallThemeReq message from a plain object. Also converts values to their respective internal types.
2025-08-15 13:55:26 +08:00
* @function fromObject
2025-08-25 11:30:50 +08:00
* @memberof cs.CSHallThemeReq
2025-08-15 13:55:26 +08:00
* @static
* @param {Object.<string,*>} object Plain object
2025-08-25 11:30:50 +08:00
* @returns {cs.CSHallThemeReq} CSHallThemeReq
2025-08-15 13:55:26 +08:00
*/
2025-08-25 11:30:50 +08:00
CSHallThemeReq . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . CSHallThemeReq )
return object ;
return new $root . cs . CSHallThemeReq ();
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Creates a plain object from a CSHallThemeReq message. Also converts values to other types if specified.
2025-08-15 13:55:26 +08:00
* @function toObject
2025-08-25 11:30:50 +08:00
* @memberof cs.CSHallThemeReq
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.CSHallThemeReq} message CSHallThemeReq
2025-08-15 13:55:26 +08:00
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
2025-08-25 11:30:50 +08:00
CSHallThemeReq . toObject = function toObject () {
return {};
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Converts this CSHallThemeReq to JSON.
2025-08-15 13:55:26 +08:00
* @function toJSON
2025-08-25 11:30:50 +08:00
* @memberof cs.CSHallThemeReq
2025-08-15 13:55:26 +08:00
* @instance
* @returns {Object.<string,*>} JSON object
*/
2025-08-25 11:30:50 +08:00
CSHallThemeReq . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Gets the default type url for CSHallThemeReq
2025-08-15 13:55:26 +08:00
* @function getTypeUrl
2025-08-25 11:30:50 +08:00
* @memberof cs.CSHallThemeReq
2025-08-15 13:55:26 +08:00
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
2025-08-25 11:30:50 +08:00
CSHallThemeReq . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.CSHallThemeReq" ;
2025-08-15 13:55:26 +08:00
};
2025-08-25 11:30:50 +08:00
return CSHallThemeReq ;
2025-08-15 13:55:26 +08:00
})();
2025-08-25 11:30:50 +08:00
cs . HallTheme = ( function () {
2025-08-15 13:55:26 +08:00
/**
2025-08-25 11:30:50 +08:00
* Properties of a HallTheme.
* @memberof cs
* @interface IHallTheme
* @property {number|null} [id] HallTheme id
* @property {string|null} [key] HallTheme key
* @property {string|null} [name] HallTheme name
* @property {number|null} [category] HallTheme category
2025-08-25 16:27:18 +08:00
* @property {boolean|null} [isRelease] HallTheme isRelease
2025-08-25 11:30:50 +08:00
* @property {string|null} [path] HallTheme path
2025-08-15 13:55:26 +08:00
*/
/**
2025-08-25 11:30:50 +08:00
* Constructs a new HallTheme.
* @memberof cs
* @classdesc Represents a HallTheme.
* @implements IHallTheme
2025-08-15 13:55:26 +08:00
* @constructor
2025-08-25 11:30:50 +08:00
* @param {cs.IHallTheme=} [properties] Properties to set
2025-08-15 13:55:26 +08:00
*/
2025-08-25 11:30:50 +08:00
function HallTheme ( properties ) {
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
2025-08-15 13:55:26 +08:00
}
/**
2025-08-25 11:30:50 +08:00
* HallTheme id.
* @member {number} id
* @memberof cs.HallTheme
2025-08-15 13:55:26 +08:00
* @instance
*/
2025-08-25 11:30:50 +08:00
HallTheme . prototype . id = 0 ;
2025-08-15 13:55:26 +08:00
/**
2025-08-25 11:30:50 +08:00
* HallTheme key.
* @member {string} key
* @memberof cs.HallTheme
2025-08-15 13:55:26 +08:00
* @instance
*/
2025-08-25 11:30:50 +08:00
HallTheme . prototype . key = "" ;
2025-08-15 13:55:26 +08:00
/**
2025-08-25 11:30:50 +08:00
* HallTheme name.
* @member {string} name
* @memberof cs.HallTheme
2025-08-15 13:55:26 +08:00
* @instance
*/
2025-08-25 11:30:50 +08:00
HallTheme . prototype . name = "" ;
2025-08-15 13:55:26 +08:00
/**
2025-08-25 11:30:50 +08:00
* HallTheme category.
* @member {number} category
* @memberof cs.HallTheme
2025-08-15 13:55:26 +08:00
* @instance
*/
2025-08-25 11:30:50 +08:00
HallTheme . prototype . category = 0 ;
2025-08-15 13:55:26 +08:00
/**
2025-08-25 16:27:18 +08:00
* HallTheme isRelease.
* @member {boolean} isRelease
2025-08-25 11:30:50 +08:00
* @memberof cs.HallTheme
2025-08-15 13:55:26 +08:00
* @instance
*/
2025-08-25 16:27:18 +08:00
HallTheme . prototype . isRelease = false ;
2025-08-15 13:55:26 +08:00
/**
2025-08-25 11:30:50 +08:00
* HallTheme path.
* @member {string} path
* @memberof cs.HallTheme
* @instance
*/
HallTheme . prototype . path = "" ;
/**
* Creates a new HallTheme instance using the specified properties.
2025-08-15 13:55:26 +08:00
* @function create
2025-08-25 11:30:50 +08:00
* @memberof cs.HallTheme
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.IHallTheme=} [properties] Properties to set
* @returns {cs.HallTheme} HallTheme instance
2025-08-15 13:55:26 +08:00
*/
2025-08-25 11:30:50 +08:00
HallTheme . create = function create ( properties ) {
return new HallTheme ( properties );
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Encodes the specified HallTheme message. Does not implicitly {@link cs.HallTheme.verify|verify} messages.
2025-08-15 13:55:26 +08:00
* @function encode
2025-08-25 11:30:50 +08:00
* @memberof cs.HallTheme
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.IHallTheme} message HallTheme message or plain object to encode
2025-08-15 13:55:26 +08:00
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
2025-08-25 11:30:50 +08:00
HallTheme . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
if ( message . id != null && Object . hasOwnProperty . call ( message , "id" ))
writer . uint32 ( /* id 1, wireType 0 =*/ 8 ). int32 ( message . id );
if ( message . key != null && Object . hasOwnProperty . call ( message , "key" ))
writer . uint32 ( /* id 2, wireType 2 =*/ 18 ). string ( message . key );
if ( message . name != null && Object . hasOwnProperty . call ( message , "name" ))
writer . uint32 ( /* id 3, wireType 2 =*/ 26 ). string ( message . name );
if ( message . category != null && Object . hasOwnProperty . call ( message , "category" ))
writer . uint32 ( /* id 4, wireType 0 =*/ 32 ). int32 ( message . category );
2025-08-25 16:27:18 +08:00
if ( message . isRelease != null && Object . hasOwnProperty . call ( message , "isRelease" ))
writer . uint32 ( /* id 5, wireType 0 =*/ 40 ). bool ( message . isRelease );
2025-08-25 11:30:50 +08:00
if ( message . path != null && Object . hasOwnProperty . call ( message , "path" ))
writer . uint32 ( /* id 6, wireType 2 =*/ 50 ). string ( message . path );
return writer ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Encodes the specified HallTheme message, length delimited. Does not implicitly {@link cs.HallTheme.verify|verify} messages.
2025-08-15 13:55:26 +08:00
* @function encodeDelimited
2025-08-25 11:30:50 +08:00
* @memberof cs.HallTheme
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.IHallTheme} message HallTheme message or plain object to encode
2025-08-15 13:55:26 +08:00
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
2025-08-25 11:30:50 +08:00
HallTheme . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Decodes a HallTheme message from the specified reader or buffer.
2025-08-15 13:55:26 +08:00
* @function decode
2025-08-25 11:30:50 +08:00
* @memberof cs.HallTheme
2025-08-15 13:55:26 +08:00
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
2025-08-25 11:30:50 +08:00
* @returns {cs.HallTheme} HallTheme
2025-08-15 13:55:26 +08:00
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
2025-08-25 11:30:50 +08:00
HallTheme . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . HallTheme ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
case 1 : {
message . id = reader . int32 ();
break ;
}
case 2 : {
message . key = reader . string ();
break ;
}
case 3 : {
message . name = reader . string ();
break ;
}
case 4 : {
message . category = reader . int32 ();
break ;
}
case 5 : {
2025-08-25 16:27:18 +08:00
message . isRelease = reader . bool ();
2025-08-25 11:30:50 +08:00
break ;
}
case 6 : {
message . path = reader . string ();
break ;
}
default :
reader . skipType ( tag & 7 );
break ;
}
2025-08-15 13:55:26 +08:00
}
2025-08-25 11:30:50 +08:00
return message ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Decodes a HallTheme message from the specified reader or buffer, length delimited.
2025-08-15 13:55:26 +08:00
* @function decodeDelimited
2025-08-25 11:30:50 +08:00
* @memberof cs.HallTheme
2025-08-15 13:55:26 +08:00
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
2025-08-25 11:30:50 +08:00
* @returns {cs.HallTheme} HallTheme
2025-08-15 13:55:26 +08:00
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
2025-08-25 11:30:50 +08:00
HallTheme . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Verifies a HallTheme message.
2025-08-15 13:55:26 +08:00
* @function verify
2025-08-25 11:30:50 +08:00
* @memberof cs.HallTheme
2025-08-15 13:55:26 +08:00
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
2025-08-25 11:30:50 +08:00
HallTheme . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
if ( message . id != null && message . hasOwnProperty ( "id" ))
if ( ! $util . isInteger ( message . id ))
return "id: integer expected" ;
if ( message . key != null && message . hasOwnProperty ( "key" ))
if ( ! $util . isString ( message . key ))
return "key: string expected" ;
if ( message . name != null && message . hasOwnProperty ( "name" ))
if ( ! $util . isString ( message . name ))
return "name: string expected" ;
if ( message . category != null && message . hasOwnProperty ( "category" ))
if ( ! $util . isInteger ( message . category ))
return "category: integer expected" ;
2025-08-25 16:27:18 +08:00
if ( message . isRelease != null && message . hasOwnProperty ( "isRelease" ))
if ( typeof message . isRelease !== "boolean" )
return "isRelease: boolean expected" ;
2025-08-25 11:30:50 +08:00
if ( message . path != null && message . hasOwnProperty ( "path" ))
if ( ! $util . isString ( message . path ))
return "path: string expected" ;
return null ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Creates a HallTheme message from a plain object. Also converts values to their respective internal types.
2025-08-15 13:55:26 +08:00
* @function fromObject
2025-08-25 11:30:50 +08:00
* @memberof cs.HallTheme
2025-08-15 13:55:26 +08:00
* @static
* @param {Object.<string,*>} object Plain object
2025-08-25 11:30:50 +08:00
* @returns {cs.HallTheme} HallTheme
2025-08-15 13:55:26 +08:00
*/
2025-08-25 11:30:50 +08:00
HallTheme . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . HallTheme )
return object ;
var message = new $root . cs . HallTheme ();
if ( object . id != null )
message . id = object . id | 0 ;
if ( object . key != null )
message . key = String ( object . key );
if ( object . name != null )
message . name = String ( object . name );
if ( object . category != null )
message . category = object . category | 0 ;
2025-08-25 16:27:18 +08:00
if ( object . isRelease != null )
message . isRelease = Boolean ( object . isRelease );
2025-08-25 11:30:50 +08:00
if ( object . path != null )
message . path = String ( object . path );
return message ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Creates a plain object from a HallTheme message. Also converts values to other types if specified.
2025-08-15 13:55:26 +08:00
* @function toObject
2025-08-25 11:30:50 +08:00
* @memberof cs.HallTheme
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.HallTheme} message HallTheme
2025-08-15 13:55:26 +08:00
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
2025-08-25 11:30:50 +08:00
HallTheme . toObject = function toObject ( message , options ) {
if ( ! options )
options = {};
var object = {};
if ( options . defaults ) {
object . id = 0 ;
object . key = "" ;
object . name = "" ;
object . category = 0 ;
2025-08-25 16:27:18 +08:00
object . isRelease = false ;
2025-08-25 11:30:50 +08:00
object . path = "" ;
}
if ( message . id != null && message . hasOwnProperty ( "id" ))
object . id = message . id ;
if ( message . key != null && message . hasOwnProperty ( "key" ))
object . key = message . key ;
if ( message . name != null && message . hasOwnProperty ( "name" ))
object . name = message . name ;
if ( message . category != null && message . hasOwnProperty ( "category" ))
object . category = message . category ;
2025-08-25 16:27:18 +08:00
if ( message . isRelease != null && message . hasOwnProperty ( "isRelease" ))
object . isRelease = message . isRelease ;
2025-08-25 11:30:50 +08:00
if ( message . path != null && message . hasOwnProperty ( "path" ))
object . path = message . path ;
return object ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Converts this HallTheme to JSON.
2025-08-15 13:55:26 +08:00
* @function toJSON
2025-08-25 11:30:50 +08:00
* @memberof cs.HallTheme
2025-08-15 13:55:26 +08:00
* @instance
* @returns {Object.<string,*>} JSON object
*/
2025-08-25 11:30:50 +08:00
HallTheme . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Gets the default type url for HallTheme
2025-08-15 13:55:26 +08:00
* @function getTypeUrl
2025-08-25 11:30:50 +08:00
* @memberof cs.HallTheme
2025-08-15 13:55:26 +08:00
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
2025-08-25 11:30:50 +08:00
HallTheme . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.HallTheme" ;
2025-08-15 13:55:26 +08:00
};
2025-08-25 11:30:50 +08:00
return HallTheme ;
2025-08-15 13:55:26 +08:00
})();
2025-08-25 11:30:50 +08:00
cs . CSHallThemeRes = ( function () {
2025-08-15 13:55:26 +08:00
/**
2025-08-25 11:30:50 +08:00
* Properties of a CSHallThemeRes.
* @memberof cs
* @interface ICSHallThemeRes
* @property {Array.<cs.IHallTheme>|null} [themes] CSHallThemeRes themes
2025-08-15 13:55:26 +08:00
*/
/**
2025-08-25 11:30:50 +08:00
* Constructs a new CSHallThemeRes.
* @memberof cs
* @classdesc Represents a CSHallThemeRes.
* @implements ICSHallThemeRes
2025-08-15 13:55:26 +08:00
* @constructor
2025-08-25 11:30:50 +08:00
* @param {cs.ICSHallThemeRes=} [properties] Properties to set
2025-08-15 13:55:26 +08:00
*/
2025-08-25 11:30:50 +08:00
function CSHallThemeRes ( properties ) {
this . themes = [];
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
2025-08-15 13:55:26 +08:00
}
/**
2025-08-25 11:30:50 +08:00
* CSHallThemeRes themes.
* @member {Array.<cs.IHallTheme>} themes
* @memberof cs.CSHallThemeRes
2025-08-15 13:55:26 +08:00
* @instance
*/
2025-08-25 11:30:50 +08:00
CSHallThemeRes . prototype . themes = $util . emptyArray ;
2025-08-15 13:55:26 +08:00
/**
2025-08-25 11:30:50 +08:00
* Creates a new CSHallThemeRes instance using the specified properties.
2025-08-15 13:55:26 +08:00
* @function create
2025-08-25 11:30:50 +08:00
* @memberof cs.CSHallThemeRes
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.ICSHallThemeRes=} [properties] Properties to set
* @returns {cs.CSHallThemeRes} CSHallThemeRes instance
2025-08-15 13:55:26 +08:00
*/
2025-08-25 11:30:50 +08:00
CSHallThemeRes . create = function create ( properties ) {
return new CSHallThemeRes ( properties );
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Encodes the specified CSHallThemeRes message. Does not implicitly {@link cs.CSHallThemeRes.verify|verify} messages.
2025-08-15 13:55:26 +08:00
* @function encode
2025-08-25 11:30:50 +08:00
* @memberof cs.CSHallThemeRes
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.ICSHallThemeRes} message CSHallThemeRes message or plain object to encode
2025-08-15 13:55:26 +08:00
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
2025-08-25 11:30:50 +08:00
CSHallThemeRes . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
if ( message . themes != null && message . themes . length )
for ( var i = 0 ; i < message . themes . length ; ++ i )
2025-08-25 16:27:18 +08:00
$root . cs . HallTheme . encode ( message . themes [ i ], writer . uint32 ( /* id 1, wireType 2 =*/ 10 ). fork ()). ldelim ();
2025-08-25 11:30:50 +08:00
return writer ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Encodes the specified CSHallThemeRes message, length delimited. Does not implicitly {@link cs.CSHallThemeRes.verify|verify} messages.
2025-08-15 13:55:26 +08:00
* @function encodeDelimited
2025-08-25 11:30:50 +08:00
* @memberof cs.CSHallThemeRes
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.ICSHallThemeRes} message CSHallThemeRes message or plain object to encode
2025-08-15 13:55:26 +08:00
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
2025-08-25 11:30:50 +08:00
CSHallThemeRes . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Decodes a CSHallThemeRes message from the specified reader or buffer.
2025-08-15 13:55:26 +08:00
* @function decode
2025-08-25 11:30:50 +08:00
* @memberof cs.CSHallThemeRes
2025-08-15 13:55:26 +08:00
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
2025-08-25 11:30:50 +08:00
* @returns {cs.CSHallThemeRes} CSHallThemeRes
2025-08-15 13:55:26 +08:00
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
2025-08-25 11:30:50 +08:00
CSHallThemeRes . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . CSHallThemeRes ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
2025-08-25 16:27:18 +08:00
case 1 : {
2025-08-25 11:30:50 +08:00
if ( ! ( message . themes && message . themes . length ))
message . themes = [];
message . themes . push ( $root . cs . HallTheme . decode ( reader , reader . uint32 ()));
break ;
}
default :
reader . skipType ( tag & 7 );
break ;
}
2025-08-15 13:55:26 +08:00
}
2025-08-25 11:30:50 +08:00
return message ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Decodes a CSHallThemeRes message from the specified reader or buffer, length delimited.
2025-08-15 13:55:26 +08:00
* @function decodeDelimited
2025-08-25 11:30:50 +08:00
* @memberof cs.CSHallThemeRes
2025-08-15 13:55:26 +08:00
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
2025-08-25 11:30:50 +08:00
* @returns {cs.CSHallThemeRes} CSHallThemeRes
2025-08-15 13:55:26 +08:00
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
2025-08-25 11:30:50 +08:00
CSHallThemeRes . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Verifies a CSHallThemeRes message.
2025-08-15 13:55:26 +08:00
* @function verify
2025-08-25 11:30:50 +08:00
* @memberof cs.CSHallThemeRes
2025-08-15 13:55:26 +08:00
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
2025-08-25 11:30:50 +08:00
CSHallThemeRes . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
if ( message . themes != null && message . hasOwnProperty ( "themes" )) {
if ( ! Array . isArray ( message . themes ))
return "themes: array expected" ;
for ( var i = 0 ; i < message . themes . length ; ++ i ) {
var error = $root . cs . HallTheme . verify ( message . themes [ i ]);
if ( error )
return "themes." + error ;
}
2025-08-15 13:55:26 +08:00
}
2025-08-25 11:30:50 +08:00
return null ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Creates a CSHallThemeRes message from a plain object. Also converts values to their respective internal types.
2025-08-15 13:55:26 +08:00
* @function fromObject
2025-08-25 11:30:50 +08:00
* @memberof cs.CSHallThemeRes
2025-08-15 13:55:26 +08:00
* @static
* @param {Object.<string,*>} object Plain object
2025-08-25 11:30:50 +08:00
* @returns {cs.CSHallThemeRes} CSHallThemeRes
2025-08-15 13:55:26 +08:00
*/
2025-08-25 11:30:50 +08:00
CSHallThemeRes . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . CSHallThemeRes )
return object ;
var message = new $root . cs . CSHallThemeRes ();
if ( object . themes ) {
if ( ! Array . isArray ( object . themes ))
throw TypeError ( ".cs.CSHallThemeRes.themes: array expected" );
message . themes = [];
for ( var i = 0 ; i < object . themes . length ; ++ i ) {
if ( typeof object . themes [ i ] !== "object" )
throw TypeError ( ".cs.CSHallThemeRes.themes: object expected" );
message . themes [ i ] = $root . cs . HallTheme . fromObject ( object . themes [ i ]);
}
}
return message ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Creates a plain object from a CSHallThemeRes message. Also converts values to other types if specified.
2025-08-15 13:55:26 +08:00
* @function toObject
2025-08-25 11:30:50 +08:00
* @memberof cs.CSHallThemeRes
2025-08-15 13:55:26 +08:00
* @static
2025-08-25 11:30:50 +08:00
* @param {cs.CSHallThemeRes} message CSHallThemeRes
2025-08-15 13:55:26 +08:00
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
2025-08-25 11:30:50 +08:00
CSHallThemeRes . toObject = function toObject ( message , options ) {
if ( ! options )
options = {};
var object = {};
if ( options . arrays || options . defaults )
object . themes = [];
if ( message . themes && message . themes . length ) {
object . themes = [];
for ( var j = 0 ; j < message . themes . length ; ++ j )
object . themes [ j ] = $root . cs . HallTheme . toObject ( message . themes [ j ], options );
}
return object ;
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Converts this CSHallThemeRes to JSON.
2025-08-15 13:55:26 +08:00
* @function toJSON
2025-08-25 11:30:50 +08:00
* @memberof cs.CSHallThemeRes
2025-08-15 13:55:26 +08:00
* @instance
* @returns {Object.<string,*>} JSON object
*/
2025-08-25 11:30:50 +08:00
CSHallThemeRes . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Gets the default type url for CSHallThemeRes
2025-08-15 13:55:26 +08:00
* @function getTypeUrl
2025-08-25 11:30:50 +08:00
* @memberof cs.CSHallThemeRes
2025-08-15 13:55:26 +08:00
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
2025-08-25 11:30:50 +08:00
CSHallThemeRes . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.CSHallThemeRes" ;
};
return CSHallThemeRes ;
})();
cs . CSGetGirlListReq = ( function () {
/**
* Properties of a CSGetGirlListReq.
* @memberof cs
* @interface ICSGetGirlListReq
2025-08-25 16:27:18 +08:00
* @property {number|null} [category] CSGetGirlListReq category
2025-08-25 11:30:50 +08:00
* @property {number|null} [page] CSGetGirlListReq page
* @property {number|null} [limit] CSGetGirlListReq limit
*/
/**
* Constructs a new CSGetGirlListReq.
* @memberof cs
* @classdesc Represents a CSGetGirlListReq.
* @implements ICSGetGirlListReq
* @constructor
* @param {cs.ICSGetGirlListReq=} [properties] Properties to set
*/
function CSGetGirlListReq ( properties ) {
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
}
/**
* CSGetGirlListReq category.
2025-08-25 16:27:18 +08:00
* @member {number} category
2025-08-25 11:30:50 +08:00
* @memberof cs.CSGetGirlListReq
* @instance
*/
2025-08-25 16:27:18 +08:00
CSGetGirlListReq . prototype . category = 0 ;
2025-08-25 11:30:50 +08:00
/**
* CSGetGirlListReq page.
* @member {number} page
* @memberof cs.CSGetGirlListReq
* @instance
*/
CSGetGirlListReq . prototype . page = 0 ;
/**
* CSGetGirlListReq limit.
* @member {number} limit
* @memberof cs.CSGetGirlListReq
* @instance
*/
CSGetGirlListReq . prototype . limit = 0 ;
/**
* Creates a new CSGetGirlListReq instance using the specified properties.
* @function create
* @memberof cs.CSGetGirlListReq
* @static
* @param {cs.ICSGetGirlListReq=} [properties] Properties to set
* @returns {cs.CSGetGirlListReq} CSGetGirlListReq instance
*/
CSGetGirlListReq . create = function create ( properties ) {
return new CSGetGirlListReq ( properties );
2025-08-15 13:55:26 +08:00
};
/**
2025-08-25 11:30:50 +08:00
* Encodes the specified CSGetGirlListReq message. Does not implicitly {@link cs.CSGetGirlListReq.verify|verify} messages.
* @function encode
* @memberof cs.CSGetGirlListReq
* @static
* @param {cs.ICSGetGirlListReq} message CSGetGirlListReq message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
2025-08-15 13:55:26 +08:00
*/
2025-08-25 11:30:50 +08:00
CSGetGirlListReq . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
if ( message . category != null && Object . hasOwnProperty . call ( message , "category" ))
2025-08-25 16:27:18 +08:00
writer . uint32 ( /* id 1, wireType 0 =*/ 8 ). int32 ( message . category );
2025-08-25 11:30:50 +08:00
if ( message . page != null && Object . hasOwnProperty . call ( message , "page" ))
writer . uint32 ( /* id 2, wireType 0 =*/ 16 ). int32 ( message . page );
if ( message . limit != null && Object . hasOwnProperty . call ( message , "limit" ))
writer . uint32 ( /* id 3, wireType 0 =*/ 24 ). int32 ( message . limit );
return writer ;
};
2025-08-15 13:55:26 +08:00
2025-08-25 11:30:50 +08:00
/**
* Encodes the specified CSGetGirlListReq message, length delimited. Does not implicitly {@link cs.CSGetGirlListReq.verify|verify} messages.
* @function encodeDelimited
* @memberof cs.CSGetGirlListReq
* @static
* @param {cs.ICSGetGirlListReq} message CSGetGirlListReq message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSGetGirlListReq . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
};
2025-08-15 13:55:26 +08:00
2025-08-25 11:30:50 +08:00
/**
* Decodes a CSGetGirlListReq message from the specified reader or buffer.
* @function decode
* @memberof cs.CSGetGirlListReq
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
* @returns {cs.CSGetGirlListReq} CSGetGirlListReq
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSGetGirlListReq . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . CSGetGirlListReq ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
case 1 : {
2025-08-25 16:27:18 +08:00
message . category = reader . int32 ();
2025-08-25 11:30:50 +08:00
break ;
}
case 2 : {
message . page = reader . int32 ();
break ;
}
case 3 : {
message . limit = reader . int32 ();
break ;
}
default :
reader . skipType ( tag & 7 );
break ;
}
}
return message ;
};
/**
* Decodes a CSGetGirlListReq message from the specified reader or buffer, length delimited.
* @function decodeDelimited
* @memberof cs.CSGetGirlListReq
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @returns {cs.CSGetGirlListReq} CSGetGirlListReq
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSGetGirlListReq . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
};
/**
* Verifies a CSGetGirlListReq message.
* @function verify
* @memberof cs.CSGetGirlListReq
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
CSGetGirlListReq . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
if ( message . category != null && message . hasOwnProperty ( "category" ))
2025-08-25 16:27:18 +08:00
if ( ! $util . isInteger ( message . category ))
return "category: integer expected" ;
2025-08-25 11:30:50 +08:00
if ( message . page != null && message . hasOwnProperty ( "page" ))
if ( ! $util . isInteger ( message . page ))
return "page: integer expected" ;
if ( message . limit != null && message . hasOwnProperty ( "limit" ))
if ( ! $util . isInteger ( message . limit ))
return "limit: integer expected" ;
return null ;
};
/**
* Creates a CSGetGirlListReq message from a plain object. Also converts values to their respective internal types.
* @function fromObject
* @memberof cs.CSGetGirlListReq
* @static
* @param {Object.<string,*>} object Plain object
* @returns {cs.CSGetGirlListReq} CSGetGirlListReq
*/
CSGetGirlListReq . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . CSGetGirlListReq )
return object ;
var message = new $root . cs . CSGetGirlListReq ();
if ( object . category != null )
2025-08-25 16:27:18 +08:00
message . category = object . category | 0 ;
2025-08-25 11:30:50 +08:00
if ( object . page != null )
message . page = object . page | 0 ;
if ( object . limit != null )
message . limit = object . limit | 0 ;
return message ;
};
/**
* Creates a plain object from a CSGetGirlListReq message. Also converts values to other types if specified.
* @function toObject
* @memberof cs.CSGetGirlListReq
* @static
* @param {cs.CSGetGirlListReq} message CSGetGirlListReq
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
CSGetGirlListReq . toObject = function toObject ( message , options ) {
if ( ! options )
options = {};
var object = {};
if ( options . defaults ) {
2025-08-25 16:27:18 +08:00
object . category = 0 ;
2025-08-25 11:30:50 +08:00
object . page = 0 ;
object . limit = 0 ;
}
if ( message . category != null && message . hasOwnProperty ( "category" ))
object . category = message . category ;
if ( message . page != null && message . hasOwnProperty ( "page" ))
object . page = message . page ;
if ( message . limit != null && message . hasOwnProperty ( "limit" ))
object . limit = message . limit ;
return object ;
};
/**
* Converts this CSGetGirlListReq to JSON.
* @function toJSON
* @memberof cs.CSGetGirlListReq
* @instance
* @returns {Object.<string,*>} JSON object
*/
CSGetGirlListReq . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
};
/**
* Gets the default type url for CSGetGirlListReq
* @function getTypeUrl
* @memberof cs.CSGetGirlListReq
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
CSGetGirlListReq . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.CSGetGirlListReq" ;
};
return CSGetGirlListReq ;
})();
cs . CSGetGirlListRes = ( function () {
/**
* Properties of a CSGetGirlListRes.
* @memberof cs
* @interface ICSGetGirlListRes
* @property {Array.<cs.IGirlBrief>|null} [girls] CSGetGirlListRes girls
*/
/**
* Constructs a new CSGetGirlListRes.
* @memberof cs
* @classdesc Represents a CSGetGirlListRes.
* @implements ICSGetGirlListRes
* @constructor
* @param {cs.ICSGetGirlListRes=} [properties] Properties to set
*/
function CSGetGirlListRes ( properties ) {
this . girls = [];
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
}
/**
* CSGetGirlListRes girls.
* @member {Array.<cs.IGirlBrief>} girls
* @memberof cs.CSGetGirlListRes
* @instance
*/
CSGetGirlListRes . prototype . girls = $util . emptyArray ;
/**
* Creates a new CSGetGirlListRes instance using the specified properties.
* @function create
* @memberof cs.CSGetGirlListRes
* @static
* @param {cs.ICSGetGirlListRes=} [properties] Properties to set
* @returns {cs.CSGetGirlListRes} CSGetGirlListRes instance
*/
CSGetGirlListRes . create = function create ( properties ) {
return new CSGetGirlListRes ( properties );
};
/**
* Encodes the specified CSGetGirlListRes message. Does not implicitly {@link cs.CSGetGirlListRes.verify|verify} messages.
* @function encode
* @memberof cs.CSGetGirlListRes
* @static
* @param {cs.ICSGetGirlListRes} message CSGetGirlListRes message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSGetGirlListRes . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
if ( message . girls != null && message . girls . length )
for ( var i = 0 ; i < message . girls . length ; ++ i )
$root . cs . GirlBrief . encode ( message . girls [ i ], writer . uint32 ( /* id 1, wireType 2 =*/ 10 ). fork ()). ldelim ();
return writer ;
};
/**
* Encodes the specified CSGetGirlListRes message, length delimited. Does not implicitly {@link cs.CSGetGirlListRes.verify|verify} messages.
* @function encodeDelimited
* @memberof cs.CSGetGirlListRes
* @static
* @param {cs.ICSGetGirlListRes} message CSGetGirlListRes message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSGetGirlListRes . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
};
/**
* Decodes a CSGetGirlListRes message from the specified reader or buffer.
* @function decode
* @memberof cs.CSGetGirlListRes
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
* @returns {cs.CSGetGirlListRes} CSGetGirlListRes
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSGetGirlListRes . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . CSGetGirlListRes ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
case 1 : {
if ( ! ( message . girls && message . girls . length ))
message . girls = [];
message . girls . push ( $root . cs . GirlBrief . decode ( reader , reader . uint32 ()));
break ;
}
default :
reader . skipType ( tag & 7 );
break ;
}
}
return message ;
};
/**
* Decodes a CSGetGirlListRes message from the specified reader or buffer, length delimited.
* @function decodeDelimited
* @memberof cs.CSGetGirlListRes
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @returns {cs.CSGetGirlListRes} CSGetGirlListRes
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSGetGirlListRes . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
};
/**
* Verifies a CSGetGirlListRes message.
* @function verify
* @memberof cs.CSGetGirlListRes
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
CSGetGirlListRes . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
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 . GirlBrief . verify ( message . girls [ i ]);
if ( error )
return "girls." + error ;
}
}
return null ;
};
/**
* Creates a CSGetGirlListRes message from a plain object. Also converts values to their respective internal types.
* @function fromObject
* @memberof cs.CSGetGirlListRes
* @static
* @param {Object.<string,*>} object Plain object
* @returns {cs.CSGetGirlListRes} CSGetGirlListRes
*/
CSGetGirlListRes . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . CSGetGirlListRes )
return object ;
var message = new $root . cs . CSGetGirlListRes ();
if ( object . girls ) {
if ( ! Array . isArray ( object . girls ))
throw TypeError ( ".cs.CSGetGirlListRes.girls: array expected" );
message . girls = [];
for ( var i = 0 ; i < object . girls . length ; ++ i ) {
if ( typeof object . girls [ i ] !== "object" )
throw TypeError ( ".cs.CSGetGirlListRes.girls: object expected" );
message . girls [ i ] = $root . cs . GirlBrief . fromObject ( object . girls [ i ]);
}
}
return message ;
};
/**
* Creates a plain object from a CSGetGirlListRes message. Also converts values to other types if specified.
* @function toObject
* @memberof cs.CSGetGirlListRes
* @static
* @param {cs.CSGetGirlListRes} message CSGetGirlListRes
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
CSGetGirlListRes . toObject = function toObject ( message , options ) {
if ( ! options )
options = {};
var object = {};
if ( options . arrays || options . defaults )
object . girls = [];
if ( message . girls && message . girls . length ) {
object . girls = [];
for ( var j = 0 ; j < message . girls . length ; ++ j )
object . girls [ j ] = $root . cs . GirlBrief . toObject ( message . girls [ j ], options );
}
return object ;
};
/**
* Converts this CSGetGirlListRes to JSON.
* @function toJSON
* @memberof cs.CSGetGirlListRes
* @instance
* @returns {Object.<string,*>} JSON object
*/
CSGetGirlListRes . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
};
/**
* Gets the default type url for CSGetGirlListRes
* @function getTypeUrl
* @memberof cs.CSGetGirlListRes
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
CSGetGirlListRes . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.CSGetGirlListRes" ;
};
return CSGetGirlListRes ;
})();
cs . CSGetGirlDetailReq = ( function () {
/**
* Properties of a CSGetGirlDetailReq.
* @memberof cs
* @interface ICSGetGirlDetailReq
* @property {number|null} [id] CSGetGirlDetailReq id
*/
/**
* Constructs a new CSGetGirlDetailReq.
* @memberof cs
* @classdesc Represents a CSGetGirlDetailReq.
* @implements ICSGetGirlDetailReq
* @constructor
* @param {cs.ICSGetGirlDetailReq=} [properties] Properties to set
*/
function CSGetGirlDetailReq ( properties ) {
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
}
/**
* CSGetGirlDetailReq id.
* @member {number} id
* @memberof cs.CSGetGirlDetailReq
* @instance
*/
CSGetGirlDetailReq . prototype . id = 0 ;
/**
* Creates a new CSGetGirlDetailReq instance using the specified properties.
* @function create
* @memberof cs.CSGetGirlDetailReq
* @static
* @param {cs.ICSGetGirlDetailReq=} [properties] Properties to set
* @returns {cs.CSGetGirlDetailReq} CSGetGirlDetailReq instance
*/
CSGetGirlDetailReq . create = function create ( properties ) {
return new CSGetGirlDetailReq ( properties );
};
/**
* Encodes the specified CSGetGirlDetailReq message. Does not implicitly {@link cs.CSGetGirlDetailReq.verify|verify} messages.
* @function encode
* @memberof cs.CSGetGirlDetailReq
* @static
* @param {cs.ICSGetGirlDetailReq} message CSGetGirlDetailReq message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSGetGirlDetailReq . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
if ( message . id != null && Object . hasOwnProperty . call ( message , "id" ))
writer . uint32 ( /* id 1, wireType 0 =*/ 8 ). int32 ( message . id );
return writer ;
};
/**
* Encodes the specified CSGetGirlDetailReq message, length delimited. Does not implicitly {@link cs.CSGetGirlDetailReq.verify|verify} messages.
* @function encodeDelimited
* @memberof cs.CSGetGirlDetailReq
* @static
* @param {cs.ICSGetGirlDetailReq} message CSGetGirlDetailReq message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSGetGirlDetailReq . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
};
/**
* Decodes a CSGetGirlDetailReq message from the specified reader or buffer.
* @function decode
* @memberof cs.CSGetGirlDetailReq
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
* @returns {cs.CSGetGirlDetailReq} CSGetGirlDetailReq
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSGetGirlDetailReq . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . CSGetGirlDetailReq ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
case 1 : {
message . id = reader . int32 ();
break ;
}
default :
reader . skipType ( tag & 7 );
break ;
}
}
return message ;
};
/**
* Decodes a CSGetGirlDetailReq message from the specified reader or buffer, length delimited.
* @function decodeDelimited
* @memberof cs.CSGetGirlDetailReq
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @returns {cs.CSGetGirlDetailReq} CSGetGirlDetailReq
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSGetGirlDetailReq . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
};
/**
* Verifies a CSGetGirlDetailReq message.
* @function verify
* @memberof cs.CSGetGirlDetailReq
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
CSGetGirlDetailReq . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
if ( message . id != null && message . hasOwnProperty ( "id" ))
if ( ! $util . isInteger ( message . id ))
return "id: integer expected" ;
return null ;
};
/**
* Creates a CSGetGirlDetailReq message from a plain object. Also converts values to their respective internal types.
* @function fromObject
* @memberof cs.CSGetGirlDetailReq
* @static
* @param {Object.<string,*>} object Plain object
* @returns {cs.CSGetGirlDetailReq} CSGetGirlDetailReq
*/
CSGetGirlDetailReq . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . CSGetGirlDetailReq )
return object ;
var message = new $root . cs . CSGetGirlDetailReq ();
if ( object . id != null )
message . id = object . id | 0 ;
return message ;
};
/**
* Creates a plain object from a CSGetGirlDetailReq message. Also converts values to other types if specified.
* @function toObject
* @memberof cs.CSGetGirlDetailReq
* @static
* @param {cs.CSGetGirlDetailReq} message CSGetGirlDetailReq
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
CSGetGirlDetailReq . toObject = function toObject ( message , options ) {
if ( ! options )
options = {};
var object = {};
if ( options . defaults )
object . id = 0 ;
if ( message . id != null && message . hasOwnProperty ( "id" ))
object . id = message . id ;
return object ;
};
/**
* Converts this CSGetGirlDetailReq to JSON.
* @function toJSON
* @memberof cs.CSGetGirlDetailReq
* @instance
* @returns {Object.<string,*>} JSON object
*/
CSGetGirlDetailReq . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
};
/**
* Gets the default type url for CSGetGirlDetailReq
* @function getTypeUrl
* @memberof cs.CSGetGirlDetailReq
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
CSGetGirlDetailReq . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.CSGetGirlDetailReq" ;
};
return CSGetGirlDetailReq ;
})();
cs . CSGetGirlDetailRes = ( function () {
/**
* Properties of a CSGetGirlDetailRes.
* @memberof cs
* @interface ICSGetGirlDetailRes
* @property {cs.IGirlDetail|null} [detail] CSGetGirlDetailRes detail
*/
/**
* Constructs a new CSGetGirlDetailRes.
* @memberof cs
* @classdesc Represents a CSGetGirlDetailRes.
* @implements ICSGetGirlDetailRes
* @constructor
* @param {cs.ICSGetGirlDetailRes=} [properties] Properties to set
*/
function CSGetGirlDetailRes ( properties ) {
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
}
/**
* CSGetGirlDetailRes detail.
* @member {cs.IGirlDetail|null|undefined} detail
* @memberof cs.CSGetGirlDetailRes
* @instance
*/
CSGetGirlDetailRes . prototype . detail = null ;
/**
* Creates a new CSGetGirlDetailRes instance using the specified properties.
* @function create
* @memberof cs.CSGetGirlDetailRes
* @static
* @param {cs.ICSGetGirlDetailRes=} [properties] Properties to set
* @returns {cs.CSGetGirlDetailRes} CSGetGirlDetailRes instance
*/
CSGetGirlDetailRes . create = function create ( properties ) {
return new CSGetGirlDetailRes ( properties );
};
/**
* Encodes the specified CSGetGirlDetailRes message. Does not implicitly {@link cs.CSGetGirlDetailRes.verify|verify} messages.
* @function encode
* @memberof cs.CSGetGirlDetailRes
* @static
* @param {cs.ICSGetGirlDetailRes} message CSGetGirlDetailRes message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSGetGirlDetailRes . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
if ( message . detail != null && Object . hasOwnProperty . call ( message , "detail" ))
$root . cs . GirlDetail . encode ( message . detail , writer . uint32 ( /* id 1, wireType 2 =*/ 10 ). fork ()). ldelim ();
return writer ;
};
/**
* Encodes the specified CSGetGirlDetailRes message, length delimited. Does not implicitly {@link cs.CSGetGirlDetailRes.verify|verify} messages.
* @function encodeDelimited
* @memberof cs.CSGetGirlDetailRes
* @static
* @param {cs.ICSGetGirlDetailRes} message CSGetGirlDetailRes message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSGetGirlDetailRes . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
};
/**
* Decodes a CSGetGirlDetailRes message from the specified reader or buffer.
* @function decode
* @memberof cs.CSGetGirlDetailRes
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
* @returns {cs.CSGetGirlDetailRes} CSGetGirlDetailRes
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSGetGirlDetailRes . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . CSGetGirlDetailRes ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
case 1 : {
message . detail = $root . cs . GirlDetail . decode ( reader , reader . uint32 ());
break ;
}
default :
reader . skipType ( tag & 7 );
break ;
}
}
return message ;
};
/**
* Decodes a CSGetGirlDetailRes message from the specified reader or buffer, length delimited.
* @function decodeDelimited
* @memberof cs.CSGetGirlDetailRes
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @returns {cs.CSGetGirlDetailRes} CSGetGirlDetailRes
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSGetGirlDetailRes . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
};
/**
* Verifies a CSGetGirlDetailRes message.
* @function verify
* @memberof cs.CSGetGirlDetailRes
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
CSGetGirlDetailRes . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
if ( message . detail != null && message . hasOwnProperty ( "detail" )) {
var error = $root . cs . GirlDetail . verify ( message . detail );
if ( error )
return "detail." + error ;
}
return null ;
};
/**
* Creates a CSGetGirlDetailRes message from a plain object. Also converts values to their respective internal types.
* @function fromObject
* @memberof cs.CSGetGirlDetailRes
* @static
* @param {Object.<string,*>} object Plain object
* @returns {cs.CSGetGirlDetailRes} CSGetGirlDetailRes
*/
CSGetGirlDetailRes . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . CSGetGirlDetailRes )
return object ;
var message = new $root . cs . CSGetGirlDetailRes ();
if ( object . detail != null ) {
if ( typeof object . detail !== "object" )
throw TypeError ( ".cs.CSGetGirlDetailRes.detail: object expected" );
message . detail = $root . cs . GirlDetail . fromObject ( object . detail );
}
return message ;
};
/**
* Creates a plain object from a CSGetGirlDetailRes message. Also converts values to other types if specified.
* @function toObject
* @memberof cs.CSGetGirlDetailRes
* @static
* @param {cs.CSGetGirlDetailRes} message CSGetGirlDetailRes
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
CSGetGirlDetailRes . toObject = function toObject ( message , options ) {
if ( ! options )
options = {};
var object = {};
if ( options . defaults )
object . detail = null ;
if ( message . detail != null && message . hasOwnProperty ( "detail" ))
object . detail = $root . cs . GirlDetail . toObject ( message . detail , options );
return object ;
};
/**
* Converts this CSGetGirlDetailRes to JSON.
* @function toJSON
* @memberof cs.CSGetGirlDetailRes
* @instance
* @returns {Object.<string,*>} JSON object
*/
CSGetGirlDetailRes . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
};
/**
* Gets the default type url for CSGetGirlDetailRes
* @function getTypeUrl
* @memberof cs.CSGetGirlDetailRes
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
CSGetGirlDetailRes . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.CSGetGirlDetailRes" ;
};
return CSGetGirlDetailRes ;
})();
2025-08-25 16:27:18 +08:00
cs . Good = ( function () {
2025-08-25 11:30:50 +08:00
/**
2025-08-25 16:27:18 +08:00
* Properties of a Good.
2025-08-25 11:30:50 +08:00
* @memberof cs
2025-08-25 16:27:18 +08:00
* @interface IGood
* @property {number|null} [id] Good id
* @property {string|null} [name] Good name
* @property {string|null} [desc] Good desc
* @property {string|null} [price] Good price
* @property {number|null} [count] Good count
2025-08-25 11:30:50 +08:00
*/
/**
2025-08-25 16:27:18 +08:00
* Constructs a new Good.
2025-08-25 11:30:50 +08:00
* @memberof cs
2025-08-25 16:27:18 +08:00
* @classdesc Represents a Good.
* @implements IGood
2025-08-25 11:30:50 +08:00
* @constructor
2025-08-25 16:27:18 +08:00
* @param {cs.IGood=} [properties] Properties to set
2025-08-25 11:30:50 +08:00
*/
2025-08-25 16:27:18 +08:00
function Good ( properties ) {
2025-08-25 11:30:50 +08:00
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
}
/**
2025-08-25 16:27:18 +08:00
* Good id.
2025-08-25 11:30:50 +08:00
* @member {number} id
2025-08-25 16:27:18 +08:00
* @memberof cs.Good
2025-08-25 11:30:50 +08:00
* @instance
*/
2025-08-25 16:27:18 +08:00
Good . prototype . id = 0 ;
2025-08-25 11:30:50 +08:00
/**
2025-08-25 16:27:18 +08:00
* Good name.
2025-08-25 11:30:50 +08:00
* @member {string} name
2025-08-25 16:27:18 +08:00
* @memberof cs.Good
2025-08-25 11:30:50 +08:00
* @instance
*/
2025-08-25 16:27:18 +08:00
Good . prototype . name = "" ;
2025-08-25 11:30:50 +08:00
/**
2025-08-25 16:27:18 +08:00
* Good desc.
2025-08-25 11:30:50 +08:00
* @member {string} desc
2025-08-25 16:27:18 +08:00
* @memberof cs.Good
2025-08-25 11:30:50 +08:00
* @instance
*/
2025-08-25 16:27:18 +08:00
Good . prototype . desc = "" ;
2025-08-25 11:30:50 +08:00
/**
2025-08-25 16:27:18 +08:00
* Good price.
2025-08-25 11:30:50 +08:00
* @member {string} price
2025-08-25 16:27:18 +08:00
* @memberof cs.Good
2025-08-25 11:30:50 +08:00
* @instance
*/
2025-08-25 16:27:18 +08:00
Good . prototype . price = "" ;
2025-08-25 11:30:50 +08:00
/**
2025-08-25 16:27:18 +08:00
* Good count.
* @member {number} count
* @memberof cs.Good
* @instance
2025-08-25 11:30:50 +08:00
*/
2025-08-25 16:27:18 +08:00
Good . prototype . count = 0 ;
/**
* Creates a new Good instance using the specified properties.
* @function create
* @memberof cs.Good
* @static
* @param {cs.IGood=} [properties] Properties to set
* @returns {cs.Good} Good instance
*/
Good . create = function create ( properties ) {
return new Good ( properties );
2025-08-25 11:30:50 +08:00
};
/**
2025-08-25 16:27:18 +08:00
* Encodes the specified Good message. Does not implicitly {@link cs.Good.verify|verify} messages.
2025-08-25 11:30:50 +08:00
* @function encode
2025-08-25 16:27:18 +08:00
* @memberof cs.Good
2025-08-25 11:30:50 +08:00
* @static
2025-08-25 16:27:18 +08:00
* @param {cs.IGood} message Good message or plain object to encode
2025-08-25 11:30:50 +08:00
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
2025-08-25 16:27:18 +08:00
Good . encode = function encode ( message , writer ) {
2025-08-25 11:30:50 +08:00
if ( ! writer )
writer = $Writer . create ();
if ( message . id != null && Object . hasOwnProperty . call ( message , "id" ))
writer . uint32 ( /* id 1, wireType 0 =*/ 8 ). int32 ( message . id );
if ( message . name != null && Object . hasOwnProperty . call ( message , "name" ))
writer . uint32 ( /* id 2, wireType 2 =*/ 18 ). string ( message . name );
if ( message . desc != null && Object . hasOwnProperty . call ( message , "desc" ))
writer . uint32 ( /* id 3, wireType 2 =*/ 26 ). string ( message . desc );
if ( message . price != null && Object . hasOwnProperty . call ( message , "price" ))
writer . uint32 ( /* id 4, wireType 2 =*/ 34 ). string ( message . price );
2025-08-25 16:27:18 +08:00
if ( message . count != null && Object . hasOwnProperty . call ( message , "count" ))
writer . uint32 ( /* id 5, wireType 0 =*/ 40 ). int32 ( message . count );
2025-08-25 11:30:50 +08:00
return writer ;
};
/**
2025-08-25 16:27:18 +08:00
* Encodes the specified Good message, length delimited. Does not implicitly {@link cs.Good.verify|verify} messages.
2025-08-25 11:30:50 +08:00
* @function encodeDelimited
2025-08-25 16:27:18 +08:00
* @memberof cs.Good
2025-08-25 11:30:50 +08:00
* @static
2025-08-25 16:27:18 +08:00
* @param {cs.IGood} message Good message or plain object to encode
2025-08-25 11:30:50 +08:00
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
2025-08-25 16:27:18 +08:00
Good . encodeDelimited = function encodeDelimited ( message , writer ) {
2025-08-25 11:30:50 +08:00
return this . encode ( message , writer ). ldelim ();
};
/**
2025-08-25 16:27:18 +08:00
* Decodes a Good message from the specified reader or buffer.
2025-08-25 11:30:50 +08:00
* @function decode
2025-08-25 16:27:18 +08:00
* @memberof cs.Good
2025-08-25 11:30:50 +08:00
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
2025-08-25 16:27:18 +08:00
* @returns {cs.Good} Good
2025-08-25 11:30:50 +08:00
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
2025-08-25 16:27:18 +08:00
Good . decode = function decode ( reader , length , error ) {
2025-08-25 11:30:50 +08:00
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
2025-08-25 16:27:18 +08:00
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . Good ();
2025-08-25 11:30:50 +08:00
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
case 1 : {
message . id = reader . int32 ();
break ;
}
case 2 : {
message . name = reader . string ();
break ;
}
case 3 : {
message . desc = reader . string ();
break ;
}
case 4 : {
message . price = reader . string ();
break ;
}
2025-08-25 16:27:18 +08:00
case 5 : {
message . count = reader . int32 ();
break ;
}
2025-08-25 11:30:50 +08:00
default :
reader . skipType ( tag & 7 );
break ;
}
}
return message ;
};
/**
2025-08-25 16:27:18 +08:00
* Decodes a Good message from the specified reader or buffer, length delimited.
2025-08-25 11:30:50 +08:00
* @function decodeDelimited
2025-08-25 16:27:18 +08:00
* @memberof cs.Good
2025-08-25 11:30:50 +08:00
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
2025-08-25 16:27:18 +08:00
* @returns {cs.Good} Good
2025-08-25 11:30:50 +08:00
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
2025-08-25 16:27:18 +08:00
Good . decodeDelimited = function decodeDelimited ( reader ) {
2025-08-25 11:30:50 +08:00
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
};
/**
2025-08-25 16:27:18 +08:00
* Verifies a Good message.
2025-08-25 11:30:50 +08:00
* @function verify
2025-08-25 16:27:18 +08:00
* @memberof cs.Good
2025-08-25 11:30:50 +08:00
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
2025-08-25 16:27:18 +08:00
Good . verify = function verify ( message ) {
2025-08-25 11:30:50 +08:00
if ( typeof message !== "object" || message === null )
return "object expected" ;
if ( message . id != null && message . hasOwnProperty ( "id" ))
if ( ! $util . isInteger ( message . id ))
return "id: integer expected" ;
if ( message . name != null && message . hasOwnProperty ( "name" ))
if ( ! $util . isString ( message . name ))
return "name: string expected" ;
if ( message . desc != null && message . hasOwnProperty ( "desc" ))
if ( ! $util . isString ( message . desc ))
return "desc: string expected" ;
if ( message . price != null && message . hasOwnProperty ( "price" ))
if ( ! $util . isString ( message . price ))
return "price: string expected" ;
2025-08-25 16:27:18 +08:00
if ( message . count != null && message . hasOwnProperty ( "count" ))
if ( ! $util . isInteger ( message . count ))
return "count: integer expected" ;
2025-08-25 11:30:50 +08:00
return null ;
};
/**
2025-08-25 16:27:18 +08:00
* Creates a Good message from a plain object. Also converts values to their respective internal types.
2025-08-25 11:30:50 +08:00
* @function fromObject
2025-08-25 16:27:18 +08:00
* @memberof cs.Good
2025-08-25 11:30:50 +08:00
* @static
* @param {Object.<string,*>} object Plain object
2025-08-25 16:27:18 +08:00
* @returns {cs.Good} Good
2025-08-25 11:30:50 +08:00
*/
2025-08-25 16:27:18 +08:00
Good . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . Good )
2025-08-25 11:30:50 +08:00
return object ;
2025-08-25 16:27:18 +08:00
var message = new $root . cs . Good ();
2025-08-25 11:30:50 +08:00
if ( object . id != null )
message . id = object . id | 0 ;
if ( object . name != null )
message . name = String ( object . name );
if ( object . desc != null )
message . desc = String ( object . desc );
if ( object . price != null )
message . price = String ( object . price );
2025-08-25 16:27:18 +08:00
if ( object . count != null )
message . count = object . count | 0 ;
2025-08-25 11:30:50 +08:00
return message ;
};
/**
2025-08-25 16:27:18 +08:00
* Creates a plain object from a Good message. Also converts values to other types if specified.
2025-08-25 11:30:50 +08:00
* @function toObject
2025-08-25 16:27:18 +08:00
* @memberof cs.Good
2025-08-25 11:30:50 +08:00
* @static
2025-08-25 16:27:18 +08:00
* @param {cs.Good} message Good
2025-08-25 11:30:50 +08:00
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
2025-08-25 16:27:18 +08:00
Good . toObject = function toObject ( message , options ) {
2025-08-25 11:30:50 +08:00
if ( ! options )
options = {};
var object = {};
if ( options . defaults ) {
object . id = 0 ;
object . name = "" ;
object . desc = "" ;
object . price = "" ;
2025-08-25 16:27:18 +08:00
object . count = 0 ;
2025-08-25 11:30:50 +08:00
}
if ( message . id != null && message . hasOwnProperty ( "id" ))
object . id = message . id ;
if ( message . name != null && message . hasOwnProperty ( "name" ))
object . name = message . name ;
if ( message . desc != null && message . hasOwnProperty ( "desc" ))
object . desc = message . desc ;
if ( message . price != null && message . hasOwnProperty ( "price" ))
object . price = message . price ;
2025-08-25 16:27:18 +08:00
if ( message . count != null && message . hasOwnProperty ( "count" ))
object . count = message . count ;
2025-08-25 11:30:50 +08:00
return object ;
};
/**
2025-08-25 16:27:18 +08:00
* Converts this Good to JSON.
2025-08-25 11:30:50 +08:00
* @function toJSON
2025-08-25 16:27:18 +08:00
* @memberof cs.Good
2025-08-25 11:30:50 +08:00
* @instance
* @returns {Object.<string,*>} JSON object
*/
2025-08-25 16:27:18 +08:00
Good . prototype . toJSON = function toJSON () {
2025-08-25 11:30:50 +08:00
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
};
/**
2025-08-25 16:27:18 +08:00
* Gets the default type url for Good
2025-08-25 11:30:50 +08:00
* @function getTypeUrl
2025-08-25 16:27:18 +08:00
* @memberof cs.Good
2025-08-25 11:30:50 +08:00
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
2025-08-25 16:27:18 +08:00
Good . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
2025-08-25 11:30:50 +08:00
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
2025-08-25 16:27:18 +08:00
return typeUrlPrefix + "/cs.Good" ;
2025-08-25 11:30:50 +08:00
};
2025-08-25 16:27:18 +08:00
return Good ;
2025-08-25 11:30:50 +08:00
})();
cs . CSGetShopReq = ( function () {
/**
* Properties of a CSGetShopReq.
* @memberof cs
* @interface ICSGetShopReq
*/
/**
* Constructs a new CSGetShopReq.
* @memberof cs
* @classdesc Represents a CSGetShopReq.
* @implements ICSGetShopReq
* @constructor
* @param {cs.ICSGetShopReq=} [properties] Properties to set
*/
function CSGetShopReq ( properties ) {
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
}
/**
* Creates a new CSGetShopReq instance using the specified properties.
* @function create
* @memberof cs.CSGetShopReq
* @static
* @param {cs.ICSGetShopReq=} [properties] Properties to set
* @returns {cs.CSGetShopReq} CSGetShopReq instance
*/
CSGetShopReq . create = function create ( properties ) {
return new CSGetShopReq ( properties );
};
/**
* Encodes the specified CSGetShopReq message. Does not implicitly {@link cs.CSGetShopReq.verify|verify} messages.
* @function encode
* @memberof cs.CSGetShopReq
* @static
* @param {cs.ICSGetShopReq} message CSGetShopReq message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSGetShopReq . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
return writer ;
};
/**
* Encodes the specified CSGetShopReq message, length delimited. Does not implicitly {@link cs.CSGetShopReq.verify|verify} messages.
* @function encodeDelimited
* @memberof cs.CSGetShopReq
* @static
* @param {cs.ICSGetShopReq} message CSGetShopReq message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSGetShopReq . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
};
/**
* Decodes a CSGetShopReq message from the specified reader or buffer.
* @function decode
* @memberof cs.CSGetShopReq
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
* @returns {cs.CSGetShopReq} CSGetShopReq
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSGetShopReq . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . CSGetShopReq ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
default :
reader . skipType ( tag & 7 );
break ;
}
}
return message ;
};
/**
* Decodes a CSGetShopReq message from the specified reader or buffer, length delimited.
* @function decodeDelimited
* @memberof cs.CSGetShopReq
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @returns {cs.CSGetShopReq} CSGetShopReq
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSGetShopReq . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
};
/**
* Verifies a CSGetShopReq message.
* @function verify
* @memberof cs.CSGetShopReq
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
CSGetShopReq . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
return null ;
};
/**
* Creates a CSGetShopReq message from a plain object. Also converts values to their respective internal types.
* @function fromObject
* @memberof cs.CSGetShopReq
* @static
* @param {Object.<string,*>} object Plain object
* @returns {cs.CSGetShopReq} CSGetShopReq
*/
CSGetShopReq . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . CSGetShopReq )
return object ;
return new $root . cs . CSGetShopReq ();
};
/**
* Creates a plain object from a CSGetShopReq message. Also converts values to other types if specified.
* @function toObject
* @memberof cs.CSGetShopReq
* @static
* @param {cs.CSGetShopReq} message CSGetShopReq
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
CSGetShopReq . toObject = function toObject () {
return {};
};
/**
* Converts this CSGetShopReq to JSON.
* @function toJSON
* @memberof cs.CSGetShopReq
* @instance
* @returns {Object.<string,*>} JSON object
*/
CSGetShopReq . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
};
/**
* Gets the default type url for CSGetShopReq
* @function getTypeUrl
* @memberof cs.CSGetShopReq
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
CSGetShopReq . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.CSGetShopReq" ;
};
return CSGetShopReq ;
})();
cs . CSGetShopRes = ( function () {
/**
* Properties of a CSGetShopRes.
* @memberof cs
* @interface ICSGetShopRes
2025-08-25 16:27:18 +08:00
* @property {Array.<cs.IGood>|null} [Goods] CSGetShopRes Goods
2025-08-25 11:30:50 +08:00
*/
/**
* Constructs a new CSGetShopRes.
* @memberof cs
* @classdesc Represents a CSGetShopRes.
* @implements ICSGetShopRes
* @constructor
* @param {cs.ICSGetShopRes=} [properties] Properties to set
*/
function CSGetShopRes ( properties ) {
2025-08-25 16:27:18 +08:00
this . Goods = [];
2025-08-25 11:30:50 +08:00
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
}
/**
2025-08-25 16:27:18 +08:00
* CSGetShopRes Goods.
* @member {Array.<cs.IGood>} Goods
2025-08-25 11:30:50 +08:00
* @memberof cs.CSGetShopRes
* @instance
*/
2025-08-25 16:27:18 +08:00
CSGetShopRes . prototype . Goods = $util . emptyArray ;
2025-08-25 11:30:50 +08:00
/**
* Creates a new CSGetShopRes instance using the specified properties.
* @function create
* @memberof cs.CSGetShopRes
* @static
* @param {cs.ICSGetShopRes=} [properties] Properties to set
* @returns {cs.CSGetShopRes} CSGetShopRes instance
*/
CSGetShopRes . create = function create ( properties ) {
return new CSGetShopRes ( properties );
};
/**
* Encodes the specified CSGetShopRes message. Does not implicitly {@link cs.CSGetShopRes.verify|verify} messages.
* @function encode
* @memberof cs.CSGetShopRes
* @static
* @param {cs.ICSGetShopRes} message CSGetShopRes message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSGetShopRes . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
2025-08-25 16:27:18 +08:00
if ( message . Goods != null && message . Goods . length )
for ( var i = 0 ; i < message . Goods . length ; ++ i )
$root . cs . Good . encode ( message . Goods [ i ], writer . uint32 ( /* id 1, wireType 2 =*/ 10 ). fork ()). ldelim ();
2025-08-25 11:30:50 +08:00
return writer ;
};
/**
* Encodes the specified CSGetShopRes message, length delimited. Does not implicitly {@link cs.CSGetShopRes.verify|verify} messages.
* @function encodeDelimited
* @memberof cs.CSGetShopRes
* @static
* @param {cs.ICSGetShopRes} message CSGetShopRes message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSGetShopRes . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
};
/**
* Decodes a CSGetShopRes message from the specified reader or buffer.
* @function decode
* @memberof cs.CSGetShopRes
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
* @returns {cs.CSGetShopRes} CSGetShopRes
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSGetShopRes . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . CSGetShopRes ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
case 1 : {
2025-08-25 16:27:18 +08:00
if ( ! ( message . Goods && message . Goods . length ))
message . Goods = [];
message . Goods . push ( $root . cs . Good . decode ( reader , reader . uint32 ()));
2025-08-25 11:30:50 +08:00
break ;
}
default :
reader . skipType ( tag & 7 );
break ;
}
}
return message ;
};
/**
* Decodes a CSGetShopRes message from the specified reader or buffer, length delimited.
* @function decodeDelimited
* @memberof cs.CSGetShopRes
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @returns {cs.CSGetShopRes} CSGetShopRes
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSGetShopRes . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
};
/**
* Verifies a CSGetShopRes message.
* @function verify
* @memberof cs.CSGetShopRes
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
CSGetShopRes . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
2025-08-25 16:27:18 +08:00
if ( message . Goods != null && message . hasOwnProperty ( "Goods" )) {
if ( ! Array . isArray ( message . Goods ))
return "Goods: array expected" ;
for ( var i = 0 ; i < message . Goods . length ; ++ i ) {
var error = $root . cs . Good . verify ( message . Goods [ i ]);
2025-08-25 11:30:50 +08:00
if ( error )
2025-08-25 16:27:18 +08:00
return "Goods." + error ;
2025-08-25 11:30:50 +08:00
}
}
return null ;
};
/**
* Creates a CSGetShopRes message from a plain object. Also converts values to their respective internal types.
* @function fromObject
* @memberof cs.CSGetShopRes
* @static
* @param {Object.<string,*>} object Plain object
* @returns {cs.CSGetShopRes} CSGetShopRes
*/
CSGetShopRes . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . CSGetShopRes )
return object ;
var message = new $root . cs . CSGetShopRes ();
2025-08-25 16:27:18 +08:00
if ( object . Goods ) {
if ( ! Array . isArray ( object . Goods ))
throw TypeError ( ".cs.CSGetShopRes.Goods: array expected" );
message . Goods = [];
for ( var i = 0 ; i < object . Goods . length ; ++ i ) {
if ( typeof object . Goods [ i ] !== "object" )
throw TypeError ( ".cs.CSGetShopRes.Goods: object expected" );
message . Goods [ i ] = $root . cs . Good . fromObject ( object . Goods [ i ]);
2025-08-25 11:30:50 +08:00
}
}
return message ;
};
/**
* Creates a plain object from a CSGetShopRes message. Also converts values to other types if specified.
* @function toObject
* @memberof cs.CSGetShopRes
* @static
* @param {cs.CSGetShopRes} message CSGetShopRes
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
CSGetShopRes . toObject = function toObject ( message , options ) {
if ( ! options )
options = {};
var object = {};
2025-08-25 16:27:18 +08:00
if ( options . arrays || options . defaults )
object . Goods = [];
if ( message . Goods && message . Goods . length ) {
object . Goods = [];
for ( var j = 0 ; j < message . Goods . length ; ++ j )
object . Goods [ j ] = $root . cs . Good . toObject ( message . Goods [ j ], options );
2025-08-25 11:30:50 +08:00
}
return object ;
};
/**
* Converts this CSGetShopRes to JSON.
* @function toJSON
* @memberof cs.CSGetShopRes
* @instance
* @returns {Object.<string,*>} JSON object
*/
CSGetShopRes . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
};
/**
* Gets the default type url for CSGetShopRes
* @function getTypeUrl
* @memberof cs.CSGetShopRes
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
CSGetShopRes . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.CSGetShopRes" ;
};
return CSGetShopRes ;
})();
cs . CSBuyChatReq = ( function () {
/**
* Properties of a CSBuyChatReq.
* @memberof cs
* @interface ICSBuyChatReq
* @property {number|null} [girlId] CSBuyChatReq girlId
* @property {number|null} [times] CSBuyChatReq times
*/
/**
* Constructs a new CSBuyChatReq.
* @memberof cs
* @classdesc Represents a CSBuyChatReq.
* @implements ICSBuyChatReq
* @constructor
* @param {cs.ICSBuyChatReq=} [properties] Properties to set
*/
function CSBuyChatReq ( properties ) {
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
}
/**
* CSBuyChatReq girlId.
* @member {number} girlId
* @memberof cs.CSBuyChatReq
* @instance
*/
CSBuyChatReq . prototype . girlId = 0 ;
/**
* CSBuyChatReq times.
* @member {number} times
* @memberof cs.CSBuyChatReq
* @instance
*/
CSBuyChatReq . prototype . times = 0 ;
/**
* Creates a new CSBuyChatReq instance using the specified properties.
* @function create
* @memberof cs.CSBuyChatReq
* @static
* @param {cs.ICSBuyChatReq=} [properties] Properties to set
* @returns {cs.CSBuyChatReq} CSBuyChatReq instance
*/
CSBuyChatReq . create = function create ( properties ) {
return new CSBuyChatReq ( properties );
};
/**
* Encodes the specified CSBuyChatReq message. Does not implicitly {@link cs.CSBuyChatReq.verify|verify} messages.
* @function encode
* @memberof cs.CSBuyChatReq
* @static
* @param {cs.ICSBuyChatReq} message CSBuyChatReq message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSBuyChatReq . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
if ( message . girlId != null && Object . hasOwnProperty . call ( message , "girlId" ))
writer . uint32 ( /* id 1, wireType 0 =*/ 8 ). int32 ( message . girlId );
if ( message . times != null && Object . hasOwnProperty . call ( message , "times" ))
writer . uint32 ( /* id 2, wireType 0 =*/ 16 ). int32 ( message . times );
return writer ;
};
/**
* Encodes the specified CSBuyChatReq message, length delimited. Does not implicitly {@link cs.CSBuyChatReq.verify|verify} messages.
* @function encodeDelimited
* @memberof cs.CSBuyChatReq
* @static
* @param {cs.ICSBuyChatReq} message CSBuyChatReq message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSBuyChatReq . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
};
/**
* Decodes a CSBuyChatReq message from the specified reader or buffer.
* @function decode
* @memberof cs.CSBuyChatReq
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
* @returns {cs.CSBuyChatReq} CSBuyChatReq
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSBuyChatReq . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . CSBuyChatReq ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
case 1 : {
message . girlId = reader . int32 ();
break ;
}
case 2 : {
message . times = reader . int32 ();
break ;
}
default :
reader . skipType ( tag & 7 );
break ;
}
}
return message ;
};
/**
* Decodes a CSBuyChatReq message from the specified reader or buffer, length delimited.
* @function decodeDelimited
* @memberof cs.CSBuyChatReq
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @returns {cs.CSBuyChatReq} CSBuyChatReq
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSBuyChatReq . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
};
/**
* Verifies a CSBuyChatReq message.
* @function verify
* @memberof cs.CSBuyChatReq
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
CSBuyChatReq . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
if ( message . girlId != null && message . hasOwnProperty ( "girlId" ))
if ( ! $util . isInteger ( message . girlId ))
return "girlId: integer expected" ;
if ( message . times != null && message . hasOwnProperty ( "times" ))
if ( ! $util . isInteger ( message . times ))
return "times: integer expected" ;
return null ;
};
/**
* Creates a CSBuyChatReq message from a plain object. Also converts values to their respective internal types.
* @function fromObject
* @memberof cs.CSBuyChatReq
* @static
* @param {Object.<string,*>} object Plain object
* @returns {cs.CSBuyChatReq} CSBuyChatReq
*/
CSBuyChatReq . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . CSBuyChatReq )
return object ;
var message = new $root . cs . CSBuyChatReq ();
if ( object . girlId != null )
message . girlId = object . girlId | 0 ;
if ( object . times != null )
message . times = object . times | 0 ;
return message ;
};
/**
* Creates a plain object from a CSBuyChatReq message. Also converts values to other types if specified.
* @function toObject
* @memberof cs.CSBuyChatReq
* @static
* @param {cs.CSBuyChatReq} message CSBuyChatReq
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
CSBuyChatReq . toObject = function toObject ( message , options ) {
if ( ! options )
options = {};
var object = {};
if ( options . defaults ) {
object . girlId = 0 ;
object . times = 0 ;
}
if ( message . girlId != null && message . hasOwnProperty ( "girlId" ))
object . girlId = message . girlId ;
if ( message . times != null && message . hasOwnProperty ( "times" ))
object . times = message . times ;
return object ;
};
/**
* Converts this CSBuyChatReq to JSON.
* @function toJSON
* @memberof cs.CSBuyChatReq
* @instance
* @returns {Object.<string,*>} JSON object
*/
CSBuyChatReq . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
};
/**
* Gets the default type url for CSBuyChatReq
* @function getTypeUrl
* @memberof cs.CSBuyChatReq
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
CSBuyChatReq . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.CSBuyChatReq" ;
};
return CSBuyChatReq ;
})();
cs . CSBuyChatRes = ( function () {
/**
* Properties of a CSBuyChatRes.
* @memberof cs
* @interface ICSBuyChatRes
*/
/**
* Constructs a new CSBuyChatRes.
* @memberof cs
* @classdesc Represents a CSBuyChatRes.
* @implements ICSBuyChatRes
* @constructor
* @param {cs.ICSBuyChatRes=} [properties] Properties to set
*/
function CSBuyChatRes ( properties ) {
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
}
/**
* Creates a new CSBuyChatRes instance using the specified properties.
* @function create
* @memberof cs.CSBuyChatRes
* @static
* @param {cs.ICSBuyChatRes=} [properties] Properties to set
* @returns {cs.CSBuyChatRes} CSBuyChatRes instance
*/
CSBuyChatRes . create = function create ( properties ) {
return new CSBuyChatRes ( properties );
};
/**
* Encodes the specified CSBuyChatRes message. Does not implicitly {@link cs.CSBuyChatRes.verify|verify} messages.
* @function encode
* @memberof cs.CSBuyChatRes
* @static
* @param {cs.ICSBuyChatRes} message CSBuyChatRes message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSBuyChatRes . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
return writer ;
};
/**
* Encodes the specified CSBuyChatRes message, length delimited. Does not implicitly {@link cs.CSBuyChatRes.verify|verify} messages.
* @function encodeDelimited
* @memberof cs.CSBuyChatRes
* @static
* @param {cs.ICSBuyChatRes} message CSBuyChatRes message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSBuyChatRes . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
};
/**
* Decodes a CSBuyChatRes message from the specified reader or buffer.
* @function decode
* @memberof cs.CSBuyChatRes
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
* @returns {cs.CSBuyChatRes} CSBuyChatRes
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSBuyChatRes . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . CSBuyChatRes ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
default :
reader . skipType ( tag & 7 );
break ;
}
}
return message ;
};
/**
* Decodes a CSBuyChatRes message from the specified reader or buffer, length delimited.
* @function decodeDelimited
* @memberof cs.CSBuyChatRes
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @returns {cs.CSBuyChatRes} CSBuyChatRes
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSBuyChatRes . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
};
/**
* Verifies a CSBuyChatRes message.
* @function verify
* @memberof cs.CSBuyChatRes
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
CSBuyChatRes . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
return null ;
};
/**
* Creates a CSBuyChatRes message from a plain object. Also converts values to their respective internal types.
* @function fromObject
* @memberof cs.CSBuyChatRes
* @static
* @param {Object.<string,*>} object Plain object
* @returns {cs.CSBuyChatRes} CSBuyChatRes
*/
CSBuyChatRes . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . CSBuyChatRes )
return object ;
return new $root . cs . CSBuyChatRes ();
};
/**
* Creates a plain object from a CSBuyChatRes message. Also converts values to other types if specified.
* @function toObject
* @memberof cs.CSBuyChatRes
* @static
* @param {cs.CSBuyChatRes} message CSBuyChatRes
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
CSBuyChatRes . toObject = function toObject () {
return {};
};
/**
* Converts this CSBuyChatRes to JSON.
* @function toJSON
* @memberof cs.CSBuyChatRes
* @instance
* @returns {Object.<string,*>} JSON object
*/
CSBuyChatRes . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
};
/**
* Gets the default type url for CSBuyChatRes
* @function getTypeUrl
* @memberof cs.CSBuyChatRes
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
CSBuyChatRes . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.CSBuyChatRes" ;
};
return CSBuyChatRes ;
})();
cs . CSCreateOrderReq = ( function () {
/**
* Properties of a CSCreateOrderReq.
* @memberof cs
* @interface ICSCreateOrderReq
* @property {number|null} [id] CSCreateOrderReq id
*/
/**
* Constructs a new CSCreateOrderReq.
* @memberof cs
* @classdesc Represents a CSCreateOrderReq.
* @implements ICSCreateOrderReq
* @constructor
* @param {cs.ICSCreateOrderReq=} [properties] Properties to set
*/
function CSCreateOrderReq ( properties ) {
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
}
/**
* CSCreateOrderReq id.
* @member {number} id
* @memberof cs.CSCreateOrderReq
* @instance
*/
CSCreateOrderReq . prototype . id = 0 ;
/**
* Creates a new CSCreateOrderReq instance using the specified properties.
* @function create
* @memberof cs.CSCreateOrderReq
* @static
* @param {cs.ICSCreateOrderReq=} [properties] Properties to set
* @returns {cs.CSCreateOrderReq} CSCreateOrderReq instance
*/
CSCreateOrderReq . create = function create ( properties ) {
return new CSCreateOrderReq ( properties );
};
/**
* Encodes the specified CSCreateOrderReq message. Does not implicitly {@link cs.CSCreateOrderReq.verify|verify} messages.
* @function encode
* @memberof cs.CSCreateOrderReq
* @static
* @param {cs.ICSCreateOrderReq} message CSCreateOrderReq message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSCreateOrderReq . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
if ( message . id != null && Object . hasOwnProperty . call ( message , "id" ))
writer . uint32 ( /* id 1, wireType 0 =*/ 8 ). int32 ( message . id );
return writer ;
};
/**
* Encodes the specified CSCreateOrderReq message, length delimited. Does not implicitly {@link cs.CSCreateOrderReq.verify|verify} messages.
* @function encodeDelimited
* @memberof cs.CSCreateOrderReq
* @static
* @param {cs.ICSCreateOrderReq} message CSCreateOrderReq message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSCreateOrderReq . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
};
/**
* Decodes a CSCreateOrderReq message from the specified reader or buffer.
* @function decode
* @memberof cs.CSCreateOrderReq
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
* @returns {cs.CSCreateOrderReq} CSCreateOrderReq
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSCreateOrderReq . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . CSCreateOrderReq ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
case 1 : {
message . id = reader . int32 ();
break ;
}
default :
reader . skipType ( tag & 7 );
break ;
}
}
return message ;
};
/**
* Decodes a CSCreateOrderReq message from the specified reader or buffer, length delimited.
* @function decodeDelimited
* @memberof cs.CSCreateOrderReq
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @returns {cs.CSCreateOrderReq} CSCreateOrderReq
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSCreateOrderReq . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
};
/**
* Verifies a CSCreateOrderReq message.
* @function verify
* @memberof cs.CSCreateOrderReq
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
CSCreateOrderReq . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
if ( message . id != null && message . hasOwnProperty ( "id" ))
if ( ! $util . isInteger ( message . id ))
return "id: integer expected" ;
return null ;
};
/**
* Creates a CSCreateOrderReq message from a plain object. Also converts values to their respective internal types.
* @function fromObject
* @memberof cs.CSCreateOrderReq
* @static
* @param {Object.<string,*>} object Plain object
* @returns {cs.CSCreateOrderReq} CSCreateOrderReq
*/
CSCreateOrderReq . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . CSCreateOrderReq )
return object ;
var message = new $root . cs . CSCreateOrderReq ();
if ( object . id != null )
message . id = object . id | 0 ;
return message ;
};
/**
* Creates a plain object from a CSCreateOrderReq message. Also converts values to other types if specified.
* @function toObject
* @memberof cs.CSCreateOrderReq
* @static
* @param {cs.CSCreateOrderReq} message CSCreateOrderReq
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
CSCreateOrderReq . toObject = function toObject ( message , options ) {
if ( ! options )
options = {};
var object = {};
if ( options . defaults )
object . id = 0 ;
if ( message . id != null && message . hasOwnProperty ( "id" ))
object . id = message . id ;
return object ;
};
/**
* Converts this CSCreateOrderReq to JSON.
* @function toJSON
* @memberof cs.CSCreateOrderReq
* @instance
* @returns {Object.<string,*>} JSON object
*/
CSCreateOrderReq . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
};
/**
* Gets the default type url for CSCreateOrderReq
* @function getTypeUrl
* @memberof cs.CSCreateOrderReq
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
CSCreateOrderReq . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.CSCreateOrderReq" ;
};
return CSCreateOrderReq ;
})();
cs . CSCreateOrderRes = ( function () {
/**
* Properties of a CSCreateOrderRes.
* @memberof cs
* @interface ICSCreateOrderRes
* @property {string|null} [payUrl] CSCreateOrderRes payUrl
2025-08-25 16:27:18 +08:00
* @property {string|null} [orderId] CSCreateOrderRes orderId
2025-08-25 11:30:50 +08:00
*/
/**
* Constructs a new CSCreateOrderRes.
* @memberof cs
* @classdesc Represents a CSCreateOrderRes.
* @implements ICSCreateOrderRes
* @constructor
* @param {cs.ICSCreateOrderRes=} [properties] Properties to set
*/
function CSCreateOrderRes ( properties ) {
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
}
/**
* CSCreateOrderRes payUrl.
* @member {string} payUrl
* @memberof cs.CSCreateOrderRes
* @instance
*/
CSCreateOrderRes . prototype . payUrl = "" ;
2025-08-25 16:27:18 +08:00
/**
* CSCreateOrderRes orderId.
* @member {string} orderId
* @memberof cs.CSCreateOrderRes
* @instance
*/
CSCreateOrderRes . prototype . orderId = "" ;
2025-08-25 11:30:50 +08:00
/**
* Creates a new CSCreateOrderRes instance using the specified properties.
* @function create
* @memberof cs.CSCreateOrderRes
* @static
* @param {cs.ICSCreateOrderRes=} [properties] Properties to set
* @returns {cs.CSCreateOrderRes} CSCreateOrderRes instance
*/
CSCreateOrderRes . create = function create ( properties ) {
return new CSCreateOrderRes ( properties );
};
/**
* Encodes the specified CSCreateOrderRes message. Does not implicitly {@link cs.CSCreateOrderRes.verify|verify} messages.
* @function encode
* @memberof cs.CSCreateOrderRes
* @static
* @param {cs.ICSCreateOrderRes} message CSCreateOrderRes message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSCreateOrderRes . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
if ( message . payUrl != null && Object . hasOwnProperty . call ( message , "payUrl" ))
writer . uint32 ( /* id 1, wireType 2 =*/ 10 ). string ( message . payUrl );
2025-08-25 16:27:18 +08:00
if ( message . orderId != null && Object . hasOwnProperty . call ( message , "orderId" ))
writer . uint32 ( /* id 2, wireType 2 =*/ 18 ). string ( message . orderId );
2025-08-25 11:30:50 +08:00
return writer ;
};
/**
* Encodes the specified CSCreateOrderRes message, length delimited. Does not implicitly {@link cs.CSCreateOrderRes.verify|verify} messages.
* @function encodeDelimited
* @memberof cs.CSCreateOrderRes
* @static
* @param {cs.ICSCreateOrderRes} message CSCreateOrderRes message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSCreateOrderRes . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
};
/**
* Decodes a CSCreateOrderRes message from the specified reader or buffer.
* @function decode
* @memberof cs.CSCreateOrderRes
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
* @returns {cs.CSCreateOrderRes} CSCreateOrderRes
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSCreateOrderRes . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . CSCreateOrderRes ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
case 1 : {
message . payUrl = reader . string ();
break ;
}
2025-08-25 16:27:18 +08:00
case 2 : {
message . orderId = reader . string ();
break ;
}
2025-08-25 11:30:50 +08:00
default :
reader . skipType ( tag & 7 );
break ;
}
}
return message ;
};
/**
* Decodes a CSCreateOrderRes message from the specified reader or buffer, length delimited.
* @function decodeDelimited
* @memberof cs.CSCreateOrderRes
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @returns {cs.CSCreateOrderRes} CSCreateOrderRes
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSCreateOrderRes . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
};
/**
* Verifies a CSCreateOrderRes message.
* @function verify
* @memberof cs.CSCreateOrderRes
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
CSCreateOrderRes . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
if ( message . payUrl != null && message . hasOwnProperty ( "payUrl" ))
if ( ! $util . isString ( message . payUrl ))
return "payUrl: string expected" ;
2025-08-25 16:27:18 +08:00
if ( message . orderId != null && message . hasOwnProperty ( "orderId" ))
if ( ! $util . isString ( message . orderId ))
return "orderId: string expected" ;
2025-08-25 11:30:50 +08:00
return null ;
};
/**
* Creates a CSCreateOrderRes message from a plain object. Also converts values to their respective internal types.
* @function fromObject
* @memberof cs.CSCreateOrderRes
* @static
* @param {Object.<string,*>} object Plain object
* @returns {cs.CSCreateOrderRes} CSCreateOrderRes
*/
CSCreateOrderRes . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . CSCreateOrderRes )
return object ;
var message = new $root . cs . CSCreateOrderRes ();
if ( object . payUrl != null )
message . payUrl = String ( object . payUrl );
2025-08-25 16:27:18 +08:00
if ( object . orderId != null )
message . orderId = String ( object . orderId );
2025-08-25 11:30:50 +08:00
return message ;
};
/**
* Creates a plain object from a CSCreateOrderRes message. Also converts values to other types if specified.
* @function toObject
* @memberof cs.CSCreateOrderRes
* @static
* @param {cs.CSCreateOrderRes} message CSCreateOrderRes
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
CSCreateOrderRes . toObject = function toObject ( message , options ) {
if ( ! options )
options = {};
var object = {};
2025-08-25 16:27:18 +08:00
if ( options . defaults ) {
2025-08-25 11:30:50 +08:00
object . payUrl = "" ;
2025-08-25 16:27:18 +08:00
object . orderId = "" ;
}
2025-08-25 11:30:50 +08:00
if ( message . payUrl != null && message . hasOwnProperty ( "payUrl" ))
object . payUrl = message . payUrl ;
2025-08-25 16:27:18 +08:00
if ( message . orderId != null && message . hasOwnProperty ( "orderId" ))
object . orderId = message . orderId ;
2025-08-25 11:30:50 +08:00
return object ;
};
/**
* Converts this CSCreateOrderRes to JSON.
* @function toJSON
* @memberof cs.CSCreateOrderRes
* @instance
* @returns {Object.<string,*>} JSON object
*/
CSCreateOrderRes . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
};
/**
* Gets the default type url for CSCreateOrderRes
* @function getTypeUrl
* @memberof cs.CSCreateOrderRes
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
CSCreateOrderRes . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.CSCreateOrderRes" ;
};
return CSCreateOrderRes ;
})();
2025-08-25 16:27:18 +08:00
cs . CSQueryOrderReq = ( function () {
/**
* Properties of a CSQueryOrderReq.
* @memberof cs
* @interface ICSQueryOrderReq
* @property {string|null} [orderId] CSQueryOrderReq orderId
*/
/**
* Constructs a new CSQueryOrderReq.
* @memberof cs
* @classdesc Represents a CSQueryOrderReq.
* @implements ICSQueryOrderReq
* @constructor
* @param {cs.ICSQueryOrderReq=} [properties] Properties to set
*/
function CSQueryOrderReq ( properties ) {
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
}
/**
* CSQueryOrderReq orderId.
* @member {string} orderId
* @memberof cs.CSQueryOrderReq
* @instance
*/
CSQueryOrderReq . prototype . orderId = "" ;
/**
* Creates a new CSQueryOrderReq instance using the specified properties.
* @function create
* @memberof cs.CSQueryOrderReq
* @static
* @param {cs.ICSQueryOrderReq=} [properties] Properties to set
* @returns {cs.CSQueryOrderReq} CSQueryOrderReq instance
*/
CSQueryOrderReq . create = function create ( properties ) {
return new CSQueryOrderReq ( properties );
};
/**
* Encodes the specified CSQueryOrderReq message. Does not implicitly {@link cs.CSQueryOrderReq.verify|verify} messages.
* @function encode
* @memberof cs.CSQueryOrderReq
* @static
* @param {cs.ICSQueryOrderReq} message CSQueryOrderReq message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSQueryOrderReq . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
if ( message . orderId != null && Object . hasOwnProperty . call ( message , "orderId" ))
writer . uint32 ( /* id 1, wireType 2 =*/ 10 ). string ( message . orderId );
return writer ;
};
/**
* Encodes the specified CSQueryOrderReq message, length delimited. Does not implicitly {@link cs.CSQueryOrderReq.verify|verify} messages.
* @function encodeDelimited
* @memberof cs.CSQueryOrderReq
* @static
* @param {cs.ICSQueryOrderReq} message CSQueryOrderReq message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSQueryOrderReq . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
};
/**
* Decodes a CSQueryOrderReq message from the specified reader or buffer.
* @function decode
* @memberof cs.CSQueryOrderReq
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
* @returns {cs.CSQueryOrderReq} CSQueryOrderReq
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSQueryOrderReq . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . CSQueryOrderReq ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
case 1 : {
message . orderId = reader . string ();
break ;
}
default :
reader . skipType ( tag & 7 );
break ;
}
}
return message ;
};
/**
* Decodes a CSQueryOrderReq message from the specified reader or buffer, length delimited.
* @function decodeDelimited
* @memberof cs.CSQueryOrderReq
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @returns {cs.CSQueryOrderReq} CSQueryOrderReq
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSQueryOrderReq . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
};
/**
* Verifies a CSQueryOrderReq message.
* @function verify
* @memberof cs.CSQueryOrderReq
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
CSQueryOrderReq . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
if ( message . orderId != null && message . hasOwnProperty ( "orderId" ))
if ( ! $util . isString ( message . orderId ))
return "orderId: string expected" ;
return null ;
};
/**
* Creates a CSQueryOrderReq message from a plain object. Also converts values to their respective internal types.
* @function fromObject
* @memberof cs.CSQueryOrderReq
* @static
* @param {Object.<string,*>} object Plain object
* @returns {cs.CSQueryOrderReq} CSQueryOrderReq
*/
CSQueryOrderReq . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . CSQueryOrderReq )
return object ;
var message = new $root . cs . CSQueryOrderReq ();
if ( object . orderId != null )
message . orderId = String ( object . orderId );
return message ;
};
/**
* Creates a plain object from a CSQueryOrderReq message. Also converts values to other types if specified.
* @function toObject
* @memberof cs.CSQueryOrderReq
* @static
* @param {cs.CSQueryOrderReq} message CSQueryOrderReq
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
CSQueryOrderReq . toObject = function toObject ( message , options ) {
if ( ! options )
options = {};
var object = {};
if ( options . defaults )
object . orderId = "" ;
if ( message . orderId != null && message . hasOwnProperty ( "orderId" ))
object . orderId = message . orderId ;
return object ;
};
/**
* Converts this CSQueryOrderReq to JSON.
* @function toJSON
* @memberof cs.CSQueryOrderReq
* @instance
* @returns {Object.<string,*>} JSON object
*/
CSQueryOrderReq . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
};
/**
* Gets the default type url for CSQueryOrderReq
* @function getTypeUrl
* @memberof cs.CSQueryOrderReq
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
CSQueryOrderReq . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.CSQueryOrderReq" ;
};
return CSQueryOrderReq ;
})();
cs . CSQueryOrderRes = ( function () {
/**
* Properties of a CSQueryOrderRes.
* @memberof cs
* @interface ICSQueryOrderRes
* @property {number|null} [status] CSQueryOrderRes status
* @property {number|null} [retCode] CSQueryOrderRes retCode
* @property {number|Long|null} [diamond] CSQueryOrderRes diamond
* @property {number|Long|null} [vipExpire] CSQueryOrderRes vipExpire
*/
/**
* Constructs a new CSQueryOrderRes.
* @memberof cs
* @classdesc Represents a CSQueryOrderRes.
* @implements ICSQueryOrderRes
* @constructor
* @param {cs.ICSQueryOrderRes=} [properties] Properties to set
*/
function CSQueryOrderRes ( properties ) {
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
}
/**
* CSQueryOrderRes status.
* @member {number} status
* @memberof cs.CSQueryOrderRes
* @instance
*/
CSQueryOrderRes . prototype . status = 0 ;
/**
* CSQueryOrderRes retCode.
* @member {number} retCode
* @memberof cs.CSQueryOrderRes
* @instance
*/
CSQueryOrderRes . prototype . retCode = 0 ;
/**
* CSQueryOrderRes diamond.
* @member {number|Long} diamond
* @memberof cs.CSQueryOrderRes
* @instance
*/
CSQueryOrderRes . prototype . diamond = $util . Long ? $util . Long . fromBits ( 0 , 0 , false ) : 0 ;
/**
* CSQueryOrderRes vipExpire.
* @member {number|Long} vipExpire
* @memberof cs.CSQueryOrderRes
* @instance
*/
CSQueryOrderRes . prototype . vipExpire = $util . Long ? $util . Long . fromBits ( 0 , 0 , false ) : 0 ;
/**
* Creates a new CSQueryOrderRes instance using the specified properties.
* @function create
* @memberof cs.CSQueryOrderRes
* @static
* @param {cs.ICSQueryOrderRes=} [properties] Properties to set
* @returns {cs.CSQueryOrderRes} CSQueryOrderRes instance
*/
CSQueryOrderRes . create = function create ( properties ) {
return new CSQueryOrderRes ( properties );
};
/**
* Encodes the specified CSQueryOrderRes message. Does not implicitly {@link cs.CSQueryOrderRes.verify|verify} messages.
* @function encode
* @memberof cs.CSQueryOrderRes
* @static
* @param {cs.ICSQueryOrderRes} message CSQueryOrderRes message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSQueryOrderRes . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
if ( message . status != null && Object . hasOwnProperty . call ( message , "status" ))
writer . uint32 ( /* id 1, wireType 0 =*/ 8 ). int32 ( message . status );
if ( message . retCode != null && Object . hasOwnProperty . call ( message , "retCode" ))
writer . uint32 ( /* id 2, wireType 0 =*/ 16 ). int32 ( message . retCode );
if ( message . diamond != null && Object . hasOwnProperty . call ( message , "diamond" ))
writer . uint32 ( /* id 3, wireType 0 =*/ 24 ). int64 ( message . diamond );
if ( message . vipExpire != null && Object . hasOwnProperty . call ( message , "vipExpire" ))
writer . uint32 ( /* id 4, wireType 0 =*/ 32 ). int64 ( message . vipExpire );
return writer ;
};
/**
* Encodes the specified CSQueryOrderRes message, length delimited. Does not implicitly {@link cs.CSQueryOrderRes.verify|verify} messages.
* @function encodeDelimited
* @memberof cs.CSQueryOrderRes
* @static
* @param {cs.ICSQueryOrderRes} message CSQueryOrderRes message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSQueryOrderRes . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
};
/**
* Decodes a CSQueryOrderRes message from the specified reader or buffer.
* @function decode
* @memberof cs.CSQueryOrderRes
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
* @returns {cs.CSQueryOrderRes} CSQueryOrderRes
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSQueryOrderRes . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . CSQueryOrderRes ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
case 1 : {
message . status = reader . int32 ();
break ;
}
case 2 : {
message . retCode = reader . int32 ();
break ;
}
case 3 : {
message . diamond = reader . int64 ();
break ;
}
case 4 : {
message . vipExpire = reader . int64 ();
break ;
}
default :
reader . skipType ( tag & 7 );
break ;
}
}
return message ;
};
/**
* Decodes a CSQueryOrderRes message from the specified reader or buffer, length delimited.
* @function decodeDelimited
* @memberof cs.CSQueryOrderRes
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @returns {cs.CSQueryOrderRes} CSQueryOrderRes
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSQueryOrderRes . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
};
/**
* Verifies a CSQueryOrderRes message.
* @function verify
* @memberof cs.CSQueryOrderRes
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
CSQueryOrderRes . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
if ( message . status != null && message . hasOwnProperty ( "status" ))
if ( ! $util . isInteger ( message . status ))
return "status: integer expected" ;
if ( message . retCode != null && message . hasOwnProperty ( "retCode" ))
if ( ! $util . isInteger ( message . retCode ))
return "retCode: integer expected" ;
if ( message . diamond != null && message . hasOwnProperty ( "diamond" ))
if ( ! $util . isInteger ( message . diamond ) && ! ( message . diamond && $util . isInteger ( message . diamond . low ) && $util . isInteger ( message . diamond . high )))
return "diamond: integer|Long expected" ;
if ( message . vipExpire != null && message . hasOwnProperty ( "vipExpire" ))
if ( ! $util . isInteger ( message . vipExpire ) && ! ( message . vipExpire && $util . isInteger ( message . vipExpire . low ) && $util . isInteger ( message . vipExpire . high )))
return "vipExpire: integer|Long expected" ;
return null ;
};
/**
* Creates a CSQueryOrderRes message from a plain object. Also converts values to their respective internal types.
* @function fromObject
* @memberof cs.CSQueryOrderRes
* @static
* @param {Object.<string,*>} object Plain object
* @returns {cs.CSQueryOrderRes} CSQueryOrderRes
*/
CSQueryOrderRes . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . CSQueryOrderRes )
return object ;
var message = new $root . cs . CSQueryOrderRes ();
if ( object . status != null )
message . status = object . status | 0 ;
if ( object . retCode != null )
message . retCode = object . retCode | 0 ;
if ( object . diamond != null )
if ( $util . Long )
( message . diamond = $util . Long . fromValue ( object . diamond )). unsigned = false ;
else if ( typeof object . diamond === "string" )
message . diamond = parseInt ( object . diamond , 10 );
else if ( typeof object . diamond === "number" )
message . diamond = object . diamond ;
else if ( typeof object . diamond === "object" )
message . diamond = new $util . LongBits ( object . diamond . low >>> 0 , object . diamond . high >>> 0 ). toNumber ();
if ( object . vipExpire != null )
if ( $util . Long )
( message . vipExpire = $util . Long . fromValue ( object . vipExpire )). unsigned = false ;
else if ( typeof object . vipExpire === "string" )
message . vipExpire = parseInt ( object . vipExpire , 10 );
else if ( typeof object . vipExpire === "number" )
message . vipExpire = object . vipExpire ;
else if ( typeof object . vipExpire === "object" )
message . vipExpire = new $util . LongBits ( object . vipExpire . low >>> 0 , object . vipExpire . high >>> 0 ). toNumber ();
return message ;
};
/**
* Creates a plain object from a CSQueryOrderRes message. Also converts values to other types if specified.
* @function toObject
* @memberof cs.CSQueryOrderRes
* @static
* @param {cs.CSQueryOrderRes} message CSQueryOrderRes
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
CSQueryOrderRes . toObject = function toObject ( message , options ) {
if ( ! options )
options = {};
var object = {};
if ( options . defaults ) {
object . status = 0 ;
object . retCode = 0 ;
if ( $util . Long ) {
var long = new $util . Long ( 0 , 0 , false );
object . diamond = options . longs === String ? long . toString () : options . longs === Number ? long . toNumber () : long ;
} else
object . diamond = options . longs === String ? "0" : 0 ;
if ( $util . Long ) {
var long = new $util . Long ( 0 , 0 , false );
object . vipExpire = options . longs === String ? long . toString () : options . longs === Number ? long . toNumber () : long ;
} else
object . vipExpire = options . longs === String ? "0" : 0 ;
}
if ( message . status != null && message . hasOwnProperty ( "status" ))
object . status = message . status ;
if ( message . retCode != null && message . hasOwnProperty ( "retCode" ))
object . retCode = message . retCode ;
if ( message . diamond != null && message . hasOwnProperty ( "diamond" ))
if ( typeof message . diamond === "number" )
object . diamond = options . longs === String ? String ( message . diamond ) : message . diamond ;
else
object . diamond = options . longs === String ? $util . Long . prototype . toString . call ( message . diamond ) : options . longs === Number ? new $util . LongBits ( message . diamond . low >>> 0 , message . diamond . high >>> 0 ). toNumber () : message . diamond ;
if ( message . vipExpire != null && message . hasOwnProperty ( "vipExpire" ))
if ( typeof message . vipExpire === "number" )
object . vipExpire = options . longs === String ? String ( message . vipExpire ) : message . vipExpire ;
else
object . vipExpire = options . longs === String ? $util . Long . prototype . toString . call ( message . vipExpire ) : options . longs === Number ? new $util . LongBits ( message . vipExpire . low >>> 0 , message . vipExpire . high >>> 0 ). toNumber () : message . vipExpire ;
return object ;
};
/**
* Converts this CSQueryOrderRes to JSON.
* @function toJSON
* @memberof cs.CSQueryOrderRes
* @instance
* @returns {Object.<string,*>} JSON object
*/
CSQueryOrderRes . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
};
/**
* Gets the default type url for CSQueryOrderRes
* @function getTypeUrl
* @memberof cs.CSQueryOrderRes
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
CSQueryOrderRes . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.CSQueryOrderRes" ;
};
return CSQueryOrderRes ;
})();
2025-09-03 11:09:35 +08:00
cs . ChatMsg = ( function () {
/**
* Properties of a ChatMsg.
* @memberof cs
* @interface IChatMsg
* @property {string|null} [msg] ChatMsg msg
* @property {boolean|null} [isAi] ChatMsg isAi
*/
/**
* Constructs a new ChatMsg.
* @memberof cs
* @classdesc Represents a ChatMsg.
* @implements IChatMsg
* @constructor
* @param {cs.IChatMsg=} [properties] Properties to set
*/
function ChatMsg ( properties ) {
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
}
/**
* ChatMsg msg.
* @member {string} msg
* @memberof cs.ChatMsg
* @instance
*/
ChatMsg . prototype . msg = "" ;
/**
* ChatMsg isAi.
* @member {boolean} isAi
* @memberof cs.ChatMsg
* @instance
*/
ChatMsg . prototype . isAi = false ;
/**
* Creates a new ChatMsg instance using the specified properties.
* @function create
* @memberof cs.ChatMsg
* @static
* @param {cs.IChatMsg=} [properties] Properties to set
* @returns {cs.ChatMsg} ChatMsg instance
*/
ChatMsg . create = function create ( properties ) {
return new ChatMsg ( properties );
};
/**
* Encodes the specified ChatMsg message. Does not implicitly {@link cs.ChatMsg.verify|verify} messages.
* @function encode
* @memberof cs.ChatMsg
* @static
* @param {cs.IChatMsg} message ChatMsg message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
ChatMsg . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
if ( message . msg != null && Object . hasOwnProperty . call ( message , "msg" ))
writer . uint32 ( /* id 1, wireType 2 =*/ 10 ). string ( message . msg );
if ( message . isAi != null && Object . hasOwnProperty . call ( message , "isAi" ))
writer . uint32 ( /* id 2, wireType 0 =*/ 16 ). bool ( message . isAi );
return writer ;
};
/**
* Encodes the specified ChatMsg message, length delimited. Does not implicitly {@link cs.ChatMsg.verify|verify} messages.
* @function encodeDelimited
* @memberof cs.ChatMsg
* @static
* @param {cs.IChatMsg} message ChatMsg message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
ChatMsg . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
};
/**
* Decodes a ChatMsg message from the specified reader or buffer.
* @function decode
* @memberof cs.ChatMsg
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
* @returns {cs.ChatMsg} ChatMsg
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
ChatMsg . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . ChatMsg ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
case 1 : {
message . msg = reader . string ();
break ;
}
case 2 : {
message . isAi = reader . bool ();
break ;
}
default :
reader . skipType ( tag & 7 );
break ;
}
}
return message ;
};
/**
* Decodes a ChatMsg message from the specified reader or buffer, length delimited.
* @function decodeDelimited
* @memberof cs.ChatMsg
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @returns {cs.ChatMsg} ChatMsg
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
ChatMsg . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
};
/**
* Verifies a ChatMsg message.
* @function verify
* @memberof cs.ChatMsg
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
ChatMsg . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
if ( message . msg != null && message . hasOwnProperty ( "msg" ))
if ( ! $util . isString ( message . msg ))
return "msg: string expected" ;
if ( message . isAi != null && message . hasOwnProperty ( "isAi" ))
if ( typeof message . isAi !== "boolean" )
return "isAi: boolean expected" ;
return null ;
};
/**
* Creates a ChatMsg message from a plain object. Also converts values to their respective internal types.
* @function fromObject
* @memberof cs.ChatMsg
* @static
* @param {Object.<string,*>} object Plain object
* @returns {cs.ChatMsg} ChatMsg
*/
ChatMsg . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . ChatMsg )
return object ;
var message = new $root . cs . ChatMsg ();
if ( object . msg != null )
message . msg = String ( object . msg );
if ( object . isAi != null )
message . isAi = Boolean ( object . isAi );
return message ;
};
/**
* Creates a plain object from a ChatMsg message. Also converts values to other types if specified.
* @function toObject
* @memberof cs.ChatMsg
* @static
* @param {cs.ChatMsg} message ChatMsg
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
ChatMsg . toObject = function toObject ( message , options ) {
if ( ! options )
options = {};
var object = {};
if ( options . defaults ) {
object . msg = "" ;
object . isAi = false ;
}
if ( message . msg != null && message . hasOwnProperty ( "msg" ))
object . msg = message . msg ;
if ( message . isAi != null && message . hasOwnProperty ( "isAi" ))
object . isAi = message . isAi ;
return object ;
};
/**
* Converts this ChatMsg to JSON.
* @function toJSON
* @memberof cs.ChatMsg
* @instance
* @returns {Object.<string,*>} JSON object
*/
ChatMsg . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
};
/**
* Gets the default type url for ChatMsg
* @function getTypeUrl
* @memberof cs.ChatMsg
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
ChatMsg . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.ChatMsg" ;
};
return ChatMsg ;
})();
cs . CSChatMsgReq = ( function () {
/**
* Properties of a CSChatMsgReq.
* @memberof cs
* @interface ICSChatMsgReq
* @property {Array.<cs.IChatMsg>|null} [msgs] CSChatMsgReq msgs
*/
/**
* Constructs a new CSChatMsgReq.
* @memberof cs
* @classdesc Represents a CSChatMsgReq.
* @implements ICSChatMsgReq
* @constructor
* @param {cs.ICSChatMsgReq=} [properties] Properties to set
*/
function CSChatMsgReq ( properties ) {
this . msgs = [];
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
}
/**
* CSChatMsgReq msgs.
* @member {Array.<cs.IChatMsg>} msgs
* @memberof cs.CSChatMsgReq
* @instance
*/
CSChatMsgReq . prototype . msgs = $util . emptyArray ;
/**
* Creates a new CSChatMsgReq instance using the specified properties.
* @function create
* @memberof cs.CSChatMsgReq
* @static
* @param {cs.ICSChatMsgReq=} [properties] Properties to set
* @returns {cs.CSChatMsgReq} CSChatMsgReq instance
*/
CSChatMsgReq . create = function create ( properties ) {
return new CSChatMsgReq ( properties );
};
/**
* Encodes the specified CSChatMsgReq message. Does not implicitly {@link cs.CSChatMsgReq.verify|verify} messages.
* @function encode
* @memberof cs.CSChatMsgReq
* @static
* @param {cs.ICSChatMsgReq} message CSChatMsgReq message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSChatMsgReq . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
if ( message . msgs != null && message . msgs . length )
for ( var i = 0 ; i < message . msgs . length ; ++ i )
$root . cs . ChatMsg . encode ( message . msgs [ i ], writer . uint32 ( /* id 1, wireType 2 =*/ 10 ). fork ()). ldelim ();
return writer ;
};
/**
* Encodes the specified CSChatMsgReq message, length delimited. Does not implicitly {@link cs.CSChatMsgReq.verify|verify} messages.
* @function encodeDelimited
* @memberof cs.CSChatMsgReq
* @static
* @param {cs.ICSChatMsgReq} message CSChatMsgReq message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSChatMsgReq . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
};
/**
* Decodes a CSChatMsgReq message from the specified reader or buffer.
* @function decode
* @memberof cs.CSChatMsgReq
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
* @returns {cs.CSChatMsgReq} CSChatMsgReq
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSChatMsgReq . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . CSChatMsgReq ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
case 1 : {
if ( ! ( message . msgs && message . msgs . length ))
message . msgs = [];
message . msgs . push ( $root . cs . ChatMsg . decode ( reader , reader . uint32 ()));
break ;
}
default :
reader . skipType ( tag & 7 );
break ;
}
}
return message ;
};
/**
* Decodes a CSChatMsgReq message from the specified reader or buffer, length delimited.
* @function decodeDelimited
* @memberof cs.CSChatMsgReq
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @returns {cs.CSChatMsgReq} CSChatMsgReq
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSChatMsgReq . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
};
/**
* Verifies a CSChatMsgReq message.
* @function verify
* @memberof cs.CSChatMsgReq
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
CSChatMsgReq . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
if ( message . msgs != null && message . hasOwnProperty ( "msgs" )) {
if ( ! Array . isArray ( message . msgs ))
return "msgs: array expected" ;
for ( var i = 0 ; i < message . msgs . length ; ++ i ) {
var error = $root . cs . ChatMsg . verify ( message . msgs [ i ]);
if ( error )
return "msgs." + error ;
}
}
return null ;
};
/**
* Creates a CSChatMsgReq message from a plain object. Also converts values to their respective internal types.
* @function fromObject
* @memberof cs.CSChatMsgReq
* @static
* @param {Object.<string,*>} object Plain object
* @returns {cs.CSChatMsgReq} CSChatMsgReq
*/
CSChatMsgReq . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . CSChatMsgReq )
return object ;
var message = new $root . cs . CSChatMsgReq ();
if ( object . msgs ) {
if ( ! Array . isArray ( object . msgs ))
throw TypeError ( ".cs.CSChatMsgReq.msgs: array expected" );
message . msgs = [];
for ( var i = 0 ; i < object . msgs . length ; ++ i ) {
if ( typeof object . msgs [ i ] !== "object" )
throw TypeError ( ".cs.CSChatMsgReq.msgs: object expected" );
message . msgs [ i ] = $root . cs . ChatMsg . fromObject ( object . msgs [ i ]);
}
}
return message ;
};
/**
* Creates a plain object from a CSChatMsgReq message. Also converts values to other types if specified.
* @function toObject
* @memberof cs.CSChatMsgReq
* @static
* @param {cs.CSChatMsgReq} message CSChatMsgReq
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
CSChatMsgReq . toObject = function toObject ( message , options ) {
if ( ! options )
options = {};
var object = {};
if ( options . arrays || options . defaults )
object . msgs = [];
if ( message . msgs && message . msgs . length ) {
object . msgs = [];
for ( var j = 0 ; j < message . msgs . length ; ++ j )
object . msgs [ j ] = $root . cs . ChatMsg . toObject ( message . msgs [ j ], options );
}
return object ;
};
/**
* Converts this CSChatMsgReq to JSON.
* @function toJSON
* @memberof cs.CSChatMsgReq
* @instance
* @returns {Object.<string,*>} JSON object
*/
CSChatMsgReq . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
};
/**
* Gets the default type url for CSChatMsgReq
* @function getTypeUrl
* @memberof cs.CSChatMsgReq
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
CSChatMsgReq . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.CSChatMsgReq" ;
};
return CSChatMsgReq ;
})();
cs . CSChatMsgRes = ( function () {
/**
* Properties of a CSChatMsgRes.
* @memberof cs
* @interface ICSChatMsgRes
*/
/**
* Constructs a new CSChatMsgRes.
* @memberof cs
* @classdesc Represents a CSChatMsgRes.
* @implements ICSChatMsgRes
* @constructor
* @param {cs.ICSChatMsgRes=} [properties] Properties to set
*/
function CSChatMsgRes ( properties ) {
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
}
/**
* Creates a new CSChatMsgRes instance using the specified properties.
* @function create
* @memberof cs.CSChatMsgRes
* @static
* @param {cs.ICSChatMsgRes=} [properties] Properties to set
* @returns {cs.CSChatMsgRes} CSChatMsgRes instance
*/
CSChatMsgRes . create = function create ( properties ) {
return new CSChatMsgRes ( properties );
};
/**
* Encodes the specified CSChatMsgRes message. Does not implicitly {@link cs.CSChatMsgRes.verify|verify} messages.
* @function encode
* @memberof cs.CSChatMsgRes
* @static
* @param {cs.ICSChatMsgRes} message CSChatMsgRes message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSChatMsgRes . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
return writer ;
};
/**
* Encodes the specified CSChatMsgRes message, length delimited. Does not implicitly {@link cs.CSChatMsgRes.verify|verify} messages.
* @function encodeDelimited
* @memberof cs.CSChatMsgRes
* @static
* @param {cs.ICSChatMsgRes} message CSChatMsgRes message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSChatMsgRes . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
};
/**
* Decodes a CSChatMsgRes message from the specified reader or buffer.
* @function decode
* @memberof cs.CSChatMsgRes
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
* @returns {cs.CSChatMsgRes} CSChatMsgRes
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSChatMsgRes . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . CSChatMsgRes ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
default :
reader . skipType ( tag & 7 );
break ;
}
}
return message ;
};
/**
* Decodes a CSChatMsgRes message from the specified reader or buffer, length delimited.
* @function decodeDelimited
* @memberof cs.CSChatMsgRes
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @returns {cs.CSChatMsgRes} CSChatMsgRes
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSChatMsgRes . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
};
/**
* Verifies a CSChatMsgRes message.
* @function verify
* @memberof cs.CSChatMsgRes
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
CSChatMsgRes . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
return null ;
};
/**
* Creates a CSChatMsgRes message from a plain object. Also converts values to their respective internal types.
* @function fromObject
* @memberof cs.CSChatMsgRes
* @static
* @param {Object.<string,*>} object Plain object
* @returns {cs.CSChatMsgRes} CSChatMsgRes
*/
CSChatMsgRes . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . CSChatMsgRes )
return object ;
return new $root . cs . CSChatMsgRes ();
};
/**
* Creates a plain object from a CSChatMsgRes message. Also converts values to other types if specified.
* @function toObject
* @memberof cs.CSChatMsgRes
* @static
* @param {cs.CSChatMsgRes} message CSChatMsgRes
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
CSChatMsgRes . toObject = function toObject () {
return {};
};
/**
* Converts this CSChatMsgRes to JSON.
* @function toJSON
* @memberof cs.CSChatMsgRes
* @instance
* @returns {Object.<string,*>} JSON object
*/
CSChatMsgRes . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
};
/**
* Gets the default type url for CSChatMsgRes
* @function getTypeUrl
* @memberof cs.CSChatMsgRes
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
CSChatMsgRes . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.CSChatMsgRes" ;
};
return CSChatMsgRes ;
})();
cs . CSGetChatMsgReq = ( function () {
/**
* Properties of a CSGetChatMsgReq.
* @memberof cs
* @interface ICSGetChatMsgReq
* @property {number|null} [page] CSGetChatMsgReq page
* @property {number|null} [limit] CSGetChatMsgReq limit
*/
/**
* Constructs a new CSGetChatMsgReq.
* @memberof cs
* @classdesc Represents a CSGetChatMsgReq.
* @implements ICSGetChatMsgReq
* @constructor
* @param {cs.ICSGetChatMsgReq=} [properties] Properties to set
*/
function CSGetChatMsgReq ( properties ) {
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
}
/**
* CSGetChatMsgReq page.
* @member {number} page
* @memberof cs.CSGetChatMsgReq
* @instance
*/
CSGetChatMsgReq . prototype . page = 0 ;
/**
* CSGetChatMsgReq limit.
* @member {number} limit
* @memberof cs.CSGetChatMsgReq
* @instance
*/
CSGetChatMsgReq . prototype . limit = 0 ;
/**
* Creates a new CSGetChatMsgReq instance using the specified properties.
* @function create
* @memberof cs.CSGetChatMsgReq
* @static
* @param {cs.ICSGetChatMsgReq=} [properties] Properties to set
* @returns {cs.CSGetChatMsgReq} CSGetChatMsgReq instance
*/
CSGetChatMsgReq . create = function create ( properties ) {
return new CSGetChatMsgReq ( properties );
};
/**
* Encodes the specified CSGetChatMsgReq message. Does not implicitly {@link cs.CSGetChatMsgReq.verify|verify} messages.
* @function encode
* @memberof cs.CSGetChatMsgReq
* @static
* @param {cs.ICSGetChatMsgReq} message CSGetChatMsgReq message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSGetChatMsgReq . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
if ( message . page != null && Object . hasOwnProperty . call ( message , "page" ))
writer . uint32 ( /* id 1, wireType 0 =*/ 8 ). int32 ( message . page );
if ( message . limit != null && Object . hasOwnProperty . call ( message , "limit" ))
writer . uint32 ( /* id 2, wireType 0 =*/ 16 ). int32 ( message . limit );
return writer ;
};
/**
* Encodes the specified CSGetChatMsgReq message, length delimited. Does not implicitly {@link cs.CSGetChatMsgReq.verify|verify} messages.
* @function encodeDelimited
* @memberof cs.CSGetChatMsgReq
* @static
* @param {cs.ICSGetChatMsgReq} message CSGetChatMsgReq message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSGetChatMsgReq . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
};
/**
* Decodes a CSGetChatMsgReq message from the specified reader or buffer.
* @function decode
* @memberof cs.CSGetChatMsgReq
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
* @returns {cs.CSGetChatMsgReq} CSGetChatMsgReq
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSGetChatMsgReq . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . CSGetChatMsgReq ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
case 1 : {
message . page = reader . int32 ();
break ;
}
case 2 : {
message . limit = reader . int32 ();
break ;
}
default :
reader . skipType ( tag & 7 );
break ;
}
}
return message ;
};
/**
* Decodes a CSGetChatMsgReq message from the specified reader or buffer, length delimited.
* @function decodeDelimited
* @memberof cs.CSGetChatMsgReq
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @returns {cs.CSGetChatMsgReq} CSGetChatMsgReq
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSGetChatMsgReq . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
};
/**
* Verifies a CSGetChatMsgReq message.
* @function verify
* @memberof cs.CSGetChatMsgReq
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
CSGetChatMsgReq . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
if ( message . page != null && message . hasOwnProperty ( "page" ))
if ( ! $util . isInteger ( message . page ))
return "page: integer expected" ;
if ( message . limit != null && message . hasOwnProperty ( "limit" ))
if ( ! $util . isInteger ( message . limit ))
return "limit: integer expected" ;
return null ;
};
/**
* Creates a CSGetChatMsgReq message from a plain object. Also converts values to their respective internal types.
* @function fromObject
* @memberof cs.CSGetChatMsgReq
* @static
* @param {Object.<string,*>} object Plain object
* @returns {cs.CSGetChatMsgReq} CSGetChatMsgReq
*/
CSGetChatMsgReq . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . CSGetChatMsgReq )
return object ;
var message = new $root . cs . CSGetChatMsgReq ();
if ( object . page != null )
message . page = object . page | 0 ;
if ( object . limit != null )
message . limit = object . limit | 0 ;
return message ;
};
/**
* Creates a plain object from a CSGetChatMsgReq message. Also converts values to other types if specified.
* @function toObject
* @memberof cs.CSGetChatMsgReq
* @static
* @param {cs.CSGetChatMsgReq} message CSGetChatMsgReq
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
CSGetChatMsgReq . toObject = function toObject ( message , options ) {
if ( ! options )
options = {};
var object = {};
if ( options . defaults ) {
object . page = 0 ;
object . limit = 0 ;
}
if ( message . page != null && message . hasOwnProperty ( "page" ))
object . page = message . page ;
if ( message . limit != null && message . hasOwnProperty ( "limit" ))
object . limit = message . limit ;
return object ;
};
/**
* Converts this CSGetChatMsgReq to JSON.
* @function toJSON
* @memberof cs.CSGetChatMsgReq
* @instance
* @returns {Object.<string,*>} JSON object
*/
CSGetChatMsgReq . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
};
/**
* Gets the default type url for CSGetChatMsgReq
* @function getTypeUrl
* @memberof cs.CSGetChatMsgReq
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
CSGetChatMsgReq . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.CSGetChatMsgReq" ;
};
return CSGetChatMsgReq ;
})();
cs . CSGetChatMsgRes = ( function () {
/**
* Properties of a CSGetChatMsgRes.
* @memberof cs
* @interface ICSGetChatMsgRes
* @property {Array.<cs.IChatMsg>|null} [msgs] CSGetChatMsgRes msgs
*/
/**
* Constructs a new CSGetChatMsgRes.
* @memberof cs
* @classdesc Represents a CSGetChatMsgRes.
* @implements ICSGetChatMsgRes
* @constructor
* @param {cs.ICSGetChatMsgRes=} [properties] Properties to set
*/
function CSGetChatMsgRes ( properties ) {
this . msgs = [];
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
}
/**
* CSGetChatMsgRes msgs.
* @member {Array.<cs.IChatMsg>} msgs
* @memberof cs.CSGetChatMsgRes
* @instance
*/
CSGetChatMsgRes . prototype . msgs = $util . emptyArray ;
/**
* Creates a new CSGetChatMsgRes instance using the specified properties.
* @function create
* @memberof cs.CSGetChatMsgRes
* @static
* @param {cs.ICSGetChatMsgRes=} [properties] Properties to set
* @returns {cs.CSGetChatMsgRes} CSGetChatMsgRes instance
*/
CSGetChatMsgRes . create = function create ( properties ) {
return new CSGetChatMsgRes ( properties );
};
/**
* Encodes the specified CSGetChatMsgRes message. Does not implicitly {@link cs.CSGetChatMsgRes.verify|verify} messages.
* @function encode
* @memberof cs.CSGetChatMsgRes
* @static
* @param {cs.ICSGetChatMsgRes} message CSGetChatMsgRes message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSGetChatMsgRes . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
if ( message . msgs != null && message . msgs . length )
for ( var i = 0 ; i < message . msgs . length ; ++ i )
$root . cs . ChatMsg . encode ( message . msgs [ i ], writer . uint32 ( /* id 1, wireType 2 =*/ 10 ). fork ()). ldelim ();
return writer ;
};
/**
* Encodes the specified CSGetChatMsgRes message, length delimited. Does not implicitly {@link cs.CSGetChatMsgRes.verify|verify} messages.
* @function encodeDelimited
* @memberof cs.CSGetChatMsgRes
* @static
* @param {cs.ICSGetChatMsgRes} message CSGetChatMsgRes message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSGetChatMsgRes . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
};
/**
* Decodes a CSGetChatMsgRes message from the specified reader or buffer.
* @function decode
* @memberof cs.CSGetChatMsgRes
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
* @returns {cs.CSGetChatMsgRes} CSGetChatMsgRes
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSGetChatMsgRes . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . CSGetChatMsgRes ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
case 1 : {
if ( ! ( message . msgs && message . msgs . length ))
message . msgs = [];
message . msgs . push ( $root . cs . ChatMsg . decode ( reader , reader . uint32 ()));
break ;
}
default :
reader . skipType ( tag & 7 );
break ;
}
}
return message ;
};
/**
* Decodes a CSGetChatMsgRes message from the specified reader or buffer, length delimited.
* @function decodeDelimited
* @memberof cs.CSGetChatMsgRes
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @returns {cs.CSGetChatMsgRes} CSGetChatMsgRes
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSGetChatMsgRes . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
};
/**
* Verifies a CSGetChatMsgRes message.
* @function verify
* @memberof cs.CSGetChatMsgRes
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
CSGetChatMsgRes . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
if ( message . msgs != null && message . hasOwnProperty ( "msgs" )) {
if ( ! Array . isArray ( message . msgs ))
return "msgs: array expected" ;
for ( var i = 0 ; i < message . msgs . length ; ++ i ) {
var error = $root . cs . ChatMsg . verify ( message . msgs [ i ]);
if ( error )
return "msgs." + error ;
}
}
return null ;
};
/**
* Creates a CSGetChatMsgRes message from a plain object. Also converts values to their respective internal types.
* @function fromObject
* @memberof cs.CSGetChatMsgRes
* @static
* @param {Object.<string,*>} object Plain object
* @returns {cs.CSGetChatMsgRes} CSGetChatMsgRes
*/
CSGetChatMsgRes . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . CSGetChatMsgRes )
return object ;
var message = new $root . cs . CSGetChatMsgRes ();
if ( object . msgs ) {
if ( ! Array . isArray ( object . msgs ))
throw TypeError ( ".cs.CSGetChatMsgRes.msgs: array expected" );
message . msgs = [];
for ( var i = 0 ; i < object . msgs . length ; ++ i ) {
if ( typeof object . msgs [ i ] !== "object" )
throw TypeError ( ".cs.CSGetChatMsgRes.msgs: object expected" );
message . msgs [ i ] = $root . cs . ChatMsg . fromObject ( object . msgs [ i ]);
}
}
return message ;
};
/**
* Creates a plain object from a CSGetChatMsgRes message. Also converts values to other types if specified.
* @function toObject
* @memberof cs.CSGetChatMsgRes
* @static
* @param {cs.CSGetChatMsgRes} message CSGetChatMsgRes
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
CSGetChatMsgRes . toObject = function toObject ( message , options ) {
if ( ! options )
options = {};
var object = {};
if ( options . arrays || options . defaults )
object . msgs = [];
if ( message . msgs && message . msgs . length ) {
object . msgs = [];
for ( var j = 0 ; j < message . msgs . length ; ++ j )
object . msgs [ j ] = $root . cs . ChatMsg . toObject ( message . msgs [ j ], options );
}
return object ;
};
/**
* Converts this CSGetChatMsgRes to JSON.
* @function toJSON
* @memberof cs.CSGetChatMsgRes
* @instance
* @returns {Object.<string,*>} JSON object
*/
CSGetChatMsgRes . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
};
/**
* Gets the default type url for CSGetChatMsgRes
* @function getTypeUrl
* @memberof cs.CSGetChatMsgRes
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
CSGetChatMsgRes . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.CSGetChatMsgRes" ;
};
return CSGetChatMsgRes ;
})();
2025-08-25 11:30:50 +08:00
cs . CSLoginReq = ( function () {
/**
* Properties of a CSLoginReq.
* @memberof cs
* @interface ICSLoginReq
* @property {string|null} [platType] CSLoginReq platType
* @property {string|null} [userId] CSLoginReq userId
* @property {string|null} [device] CSLoginReq device
* @property {number|null} [os] CSLoginReq os
*/
/**
* Constructs a new CSLoginReq.
* @memberof cs
* @classdesc Represents a CSLoginReq.
* @implements ICSLoginReq
* @constructor
* @param {cs.ICSLoginReq=} [properties] Properties to set
*/
function CSLoginReq ( properties ) {
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
}
/**
* CSLoginReq platType.
* @member {string} platType
* @memberof cs.CSLoginReq
* @instance
*/
CSLoginReq . prototype . platType = "" ;
/**
* CSLoginReq userId.
* @member {string} userId
* @memberof cs.CSLoginReq
* @instance
*/
CSLoginReq . prototype . userId = "" ;
/**
* CSLoginReq device.
* @member {string} device
* @memberof cs.CSLoginReq
* @instance
*/
CSLoginReq . prototype . device = "" ;
/**
* CSLoginReq os.
* @member {number} os
* @memberof cs.CSLoginReq
* @instance
*/
CSLoginReq . prototype . os = 0 ;
/**
* Creates a new CSLoginReq instance using the specified properties.
* @function create
* @memberof cs.CSLoginReq
* @static
* @param {cs.ICSLoginReq=} [properties] Properties to set
* @returns {cs.CSLoginReq} CSLoginReq instance
*/
CSLoginReq . create = function create ( properties ) {
return new CSLoginReq ( properties );
};
/**
* Encodes the specified CSLoginReq message. Does not implicitly {@link cs.CSLoginReq.verify|verify} messages.
* @function encode
* @memberof cs.CSLoginReq
* @static
* @param {cs.ICSLoginReq} message CSLoginReq message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSLoginReq . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
if ( message . platType != null && Object . hasOwnProperty . call ( message , "platType" ))
writer . uint32 ( /* id 1, wireType 2 =*/ 10 ). string ( message . platType );
if ( message . userId != null && Object . hasOwnProperty . call ( message , "userId" ))
writer . uint32 ( /* id 2, wireType 2 =*/ 18 ). string ( message . userId );
if ( message . device != null && Object . hasOwnProperty . call ( message , "device" ))
writer . uint32 ( /* id 3, wireType 2 =*/ 26 ). string ( message . device );
if ( message . os != null && Object . hasOwnProperty . call ( message , "os" ))
writer . uint32 ( /* id 4, wireType 0 =*/ 32 ). int32 ( message . os );
return writer ;
};
/**
* Encodes the specified CSLoginReq message, length delimited. Does not implicitly {@link cs.CSLoginReq.verify|verify} messages.
* @function encodeDelimited
* @memberof cs.CSLoginReq
* @static
* @param {cs.ICSLoginReq} message CSLoginReq message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSLoginReq . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
};
/**
* Decodes a CSLoginReq message from the specified reader or buffer.
* @function decode
* @memberof cs.CSLoginReq
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
* @returns {cs.CSLoginReq} CSLoginReq
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSLoginReq . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . CSLoginReq ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
case 1 : {
message . platType = reader . string ();
break ;
}
case 2 : {
message . userId = reader . string ();
break ;
}
case 3 : {
message . device = reader . string ();
break ;
}
case 4 : {
message . os = reader . int32 ();
break ;
}
default :
reader . skipType ( tag & 7 );
break ;
}
}
return message ;
};
/**
* Decodes a CSLoginReq message from the specified reader or buffer, length delimited.
* @function decodeDelimited
* @memberof cs.CSLoginReq
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @returns {cs.CSLoginReq} CSLoginReq
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSLoginReq . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
};
/**
* Verifies a CSLoginReq message.
* @function verify
* @memberof cs.CSLoginReq
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
CSLoginReq . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
if ( message . platType != null && message . hasOwnProperty ( "platType" ))
if ( ! $util . isString ( message . platType ))
return "platType: string expected" ;
if ( message . userId != null && message . hasOwnProperty ( "userId" ))
if ( ! $util . isString ( message . userId ))
return "userId: string expected" ;
if ( message . device != null && message . hasOwnProperty ( "device" ))
if ( ! $util . isString ( message . device ))
return "device: string expected" ;
if ( message . os != null && message . hasOwnProperty ( "os" ))
if ( ! $util . isInteger ( message . os ))
return "os: integer expected" ;
return null ;
};
/**
* Creates a CSLoginReq message from a plain object. Also converts values to their respective internal types.
* @function fromObject
* @memberof cs.CSLoginReq
* @static
* @param {Object.<string,*>} object Plain object
* @returns {cs.CSLoginReq} CSLoginReq
*/
CSLoginReq . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . CSLoginReq )
return object ;
var message = new $root . cs . CSLoginReq ();
if ( object . platType != null )
message . platType = String ( object . platType );
if ( object . userId != null )
message . userId = String ( object . userId );
if ( object . device != null )
message . device = String ( object . device );
if ( object . os != null )
message . os = object . os | 0 ;
return message ;
};
/**
* Creates a plain object from a CSLoginReq message. Also converts values to other types if specified.
* @function toObject
* @memberof cs.CSLoginReq
* @static
* @param {cs.CSLoginReq} message CSLoginReq
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
CSLoginReq . toObject = function toObject ( message , options ) {
if ( ! options )
options = {};
var object = {};
if ( options . defaults ) {
object . platType = "" ;
object . userId = "" ;
object . device = "" ;
object . os = 0 ;
}
if ( message . platType != null && message . hasOwnProperty ( "platType" ))
object . platType = message . platType ;
if ( message . userId != null && message . hasOwnProperty ( "userId" ))
object . userId = message . userId ;
if ( message . device != null && message . hasOwnProperty ( "device" ))
object . device = message . device ;
if ( message . os != null && message . hasOwnProperty ( "os" ))
object . os = message . os ;
return object ;
};
/**
* Converts this CSLoginReq to JSON.
* @function toJSON
* @memberof cs.CSLoginReq
* @instance
* @returns {Object.<string,*>} JSON object
*/
CSLoginReq . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
};
/**
* Gets the default type url for CSLoginReq
* @function getTypeUrl
* @memberof cs.CSLoginReq
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
CSLoginReq . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.CSLoginReq" ;
};
return CSLoginReq ;
})();
cs . CSLoginRes = ( function () {
/**
* Properties of a CSLoginRes.
* @memberof cs
* @interface ICSLoginRes
* @property {string|null} [name] CSLoginRes name
* @property {string|null} [token] CSLoginRes token
* @property {string|null} [refreshToken] CSLoginRes refreshToken
* @property {number|Long|null} [expire] CSLoginRes expire
*/
/**
* Constructs a new CSLoginRes.
* @memberof cs
* @classdesc Represents a CSLoginRes.
* @implements ICSLoginRes
* @constructor
* @param {cs.ICSLoginRes=} [properties] Properties to set
*/
function CSLoginRes ( properties ) {
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
}
/**
* CSLoginRes name.
* @member {string} name
* @memberof cs.CSLoginRes
* @instance
*/
CSLoginRes . prototype . name = "" ;
/**
* CSLoginRes token.
* @member {string} token
* @memberof cs.CSLoginRes
* @instance
*/
CSLoginRes . prototype . token = "" ;
/**
* CSLoginRes refreshToken.
* @member {string} refreshToken
* @memberof cs.CSLoginRes
* @instance
*/
CSLoginRes . prototype . refreshToken = "" ;
/**
* CSLoginRes expire.
* @member {number|Long} expire
* @memberof cs.CSLoginRes
* @instance
*/
CSLoginRes . prototype . expire = $util . Long ? $util . Long . fromBits ( 0 , 0 , false ) : 0 ;
/**
* Creates a new CSLoginRes instance using the specified properties.
* @function create
* @memberof cs.CSLoginRes
* @static
* @param {cs.ICSLoginRes=} [properties] Properties to set
* @returns {cs.CSLoginRes} CSLoginRes instance
*/
CSLoginRes . create = function create ( properties ) {
return new CSLoginRes ( properties );
};
/**
* Encodes the specified CSLoginRes message. Does not implicitly {@link cs.CSLoginRes.verify|verify} messages.
* @function encode
* @memberof cs.CSLoginRes
* @static
* @param {cs.ICSLoginRes} message CSLoginRes message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSLoginRes . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
if ( message . name != null && Object . hasOwnProperty . call ( message , "name" ))
writer . uint32 ( /* id 1, wireType 2 =*/ 10 ). string ( message . name );
if ( message . token != null && Object . hasOwnProperty . call ( message , "token" ))
writer . uint32 ( /* id 2, wireType 2 =*/ 18 ). string ( message . token );
if ( message . refreshToken != null && Object . hasOwnProperty . call ( message , "refreshToken" ))
writer . uint32 ( /* id 3, wireType 2 =*/ 26 ). string ( message . refreshToken );
if ( message . expire != null && Object . hasOwnProperty . call ( message , "expire" ))
writer . uint32 ( /* id 4, wireType 0 =*/ 32 ). int64 ( message . expire );
return writer ;
};
/**
* Encodes the specified CSLoginRes message, length delimited. Does not implicitly {@link cs.CSLoginRes.verify|verify} messages.
* @function encodeDelimited
* @memberof cs.CSLoginRes
* @static
* @param {cs.ICSLoginRes} message CSLoginRes message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSLoginRes . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
};
/**
* Decodes a CSLoginRes message from the specified reader or buffer.
* @function decode
* @memberof cs.CSLoginRes
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
* @returns {cs.CSLoginRes} CSLoginRes
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSLoginRes . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . CSLoginRes ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
case 1 : {
message . name = reader . string ();
break ;
}
case 2 : {
message . token = reader . string ();
break ;
}
case 3 : {
message . refreshToken = reader . string ();
break ;
}
case 4 : {
message . expire = reader . int64 ();
break ;
}
default :
reader . skipType ( tag & 7 );
break ;
}
}
return message ;
};
/**
* Decodes a CSLoginRes message from the specified reader or buffer, length delimited.
* @function decodeDelimited
* @memberof cs.CSLoginRes
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @returns {cs.CSLoginRes} CSLoginRes
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSLoginRes . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
};
/**
* Verifies a CSLoginRes message.
* @function verify
* @memberof cs.CSLoginRes
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
CSLoginRes . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
if ( message . name != null && message . hasOwnProperty ( "name" ))
if ( ! $util . isString ( message . name ))
return "name: string expected" ;
if ( message . token != null && message . hasOwnProperty ( "token" ))
if ( ! $util . isString ( message . token ))
return "token: string expected" ;
if ( message . refreshToken != null && message . hasOwnProperty ( "refreshToken" ))
if ( ! $util . isString ( message . refreshToken ))
return "refreshToken: string expected" ;
if ( message . expire != null && message . hasOwnProperty ( "expire" ))
if ( ! $util . isInteger ( message . expire ) && ! ( message . expire && $util . isInteger ( message . expire . low ) && $util . isInteger ( message . expire . high )))
return "expire: integer|Long expected" ;
return null ;
};
/**
* Creates a CSLoginRes message from a plain object. Also converts values to their respective internal types.
* @function fromObject
* @memberof cs.CSLoginRes
* @static
* @param {Object.<string,*>} object Plain object
* @returns {cs.CSLoginRes} CSLoginRes
*/
CSLoginRes . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . CSLoginRes )
return object ;
var message = new $root . cs . CSLoginRes ();
if ( object . name != null )
message . name = String ( object . name );
if ( object . token != null )
message . token = String ( object . token );
if ( object . refreshToken != null )
message . refreshToken = String ( object . refreshToken );
if ( object . expire != null )
if ( $util . Long )
( message . expire = $util . Long . fromValue ( object . expire )). unsigned = false ;
else if ( typeof object . expire === "string" )
message . expire = parseInt ( object . expire , 10 );
else if ( typeof object . expire === "number" )
message . expire = object . expire ;
else if ( typeof object . expire === "object" )
message . expire = new $util . LongBits ( object . expire . low >>> 0 , object . expire . high >>> 0 ). toNumber ();
return message ;
};
/**
* Creates a plain object from a CSLoginRes message. Also converts values to other types if specified.
* @function toObject
* @memberof cs.CSLoginRes
* @static
* @param {cs.CSLoginRes} message CSLoginRes
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
CSLoginRes . toObject = function toObject ( message , options ) {
if ( ! options )
options = {};
var object = {};
if ( options . defaults ) {
object . name = "" ;
object . token = "" ;
object . refreshToken = "" ;
if ( $util . Long ) {
var long = new $util . Long ( 0 , 0 , false );
object . expire = options . longs === String ? long . toString () : options . longs === Number ? long . toNumber () : long ;
} else
object . expire = options . longs === String ? "0" : 0 ;
}
if ( message . name != null && message . hasOwnProperty ( "name" ))
object . name = message . name ;
if ( message . token != null && message . hasOwnProperty ( "token" ))
object . token = message . token ;
if ( message . refreshToken != null && message . hasOwnProperty ( "refreshToken" ))
object . refreshToken = message . refreshToken ;
if ( message . expire != null && message . hasOwnProperty ( "expire" ))
if ( typeof message . expire === "number" )
object . expire = options . longs === String ? String ( message . expire ) : message . expire ;
else
object . expire = options . longs === String ? $util . Long . prototype . toString . call ( message . expire ) : options . longs === Number ? new $util . LongBits ( message . expire . low >>> 0 , message . expire . high >>> 0 ). toNumber () : message . expire ;
return object ;
};
/**
* Converts this CSLoginRes to JSON.
* @function toJSON
* @memberof cs.CSLoginRes
* @instance
* @returns {Object.<string,*>} JSON object
*/
CSLoginRes . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
};
/**
* Gets the default type url for CSLoginRes
* @function getTypeUrl
* @memberof cs.CSLoginRes
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
CSLoginRes . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.CSLoginRes" ;
};
return CSLoginRes ;
})();
cs . CSMyInfoReq = ( function () {
/**
* Properties of a CSMyInfoReq.
* @memberof cs
* @interface ICSMyInfoReq
*/
/**
* Constructs a new CSMyInfoReq.
* @memberof cs
* @classdesc Represents a CSMyInfoReq.
* @implements ICSMyInfoReq
* @constructor
* @param {cs.ICSMyInfoReq=} [properties] Properties to set
*/
function CSMyInfoReq ( properties ) {
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
}
/**
* Creates a new CSMyInfoReq instance using the specified properties.
* @function create
* @memberof cs.CSMyInfoReq
* @static
* @param {cs.ICSMyInfoReq=} [properties] Properties to set
* @returns {cs.CSMyInfoReq} CSMyInfoReq instance
*/
CSMyInfoReq . create = function create ( properties ) {
return new CSMyInfoReq ( properties );
};
/**
* Encodes the specified CSMyInfoReq message. Does not implicitly {@link cs.CSMyInfoReq.verify|verify} messages.
* @function encode
* @memberof cs.CSMyInfoReq
* @static
* @param {cs.ICSMyInfoReq} message CSMyInfoReq message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSMyInfoReq . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
return writer ;
};
/**
* Encodes the specified CSMyInfoReq message, length delimited. Does not implicitly {@link cs.CSMyInfoReq.verify|verify} messages.
* @function encodeDelimited
* @memberof cs.CSMyInfoReq
* @static
* @param {cs.ICSMyInfoReq} message CSMyInfoReq message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSMyInfoReq . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
};
/**
* Decodes a CSMyInfoReq message from the specified reader or buffer.
* @function decode
* @memberof cs.CSMyInfoReq
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
* @returns {cs.CSMyInfoReq} CSMyInfoReq
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSMyInfoReq . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . CSMyInfoReq ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
default :
reader . skipType ( tag & 7 );
break ;
}
}
return message ;
};
/**
* Decodes a CSMyInfoReq message from the specified reader or buffer, length delimited.
* @function decodeDelimited
* @memberof cs.CSMyInfoReq
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @returns {cs.CSMyInfoReq} CSMyInfoReq
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSMyInfoReq . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
};
/**
* Verifies a CSMyInfoReq message.
* @function verify
* @memberof cs.CSMyInfoReq
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
CSMyInfoReq . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
return null ;
};
/**
* Creates a CSMyInfoReq message from a plain object. Also converts values to their respective internal types.
* @function fromObject
* @memberof cs.CSMyInfoReq
* @static
* @param {Object.<string,*>} object Plain object
* @returns {cs.CSMyInfoReq} CSMyInfoReq
*/
CSMyInfoReq . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . CSMyInfoReq )
return object ;
return new $root . cs . CSMyInfoReq ();
};
/**
* Creates a plain object from a CSMyInfoReq message. Also converts values to other types if specified.
* @function toObject
* @memberof cs.CSMyInfoReq
* @static
* @param {cs.CSMyInfoReq} message CSMyInfoReq
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
CSMyInfoReq . toObject = function toObject () {
return {};
};
/**
* Converts this CSMyInfoReq to JSON.
* @function toJSON
* @memberof cs.CSMyInfoReq
* @instance
* @returns {Object.<string,*>} JSON object
*/
CSMyInfoReq . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
};
/**
* Gets the default type url for CSMyInfoReq
* @function getTypeUrl
* @memberof cs.CSMyInfoReq
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
CSMyInfoReq . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.CSMyInfoReq" ;
};
return CSMyInfoReq ;
})();
cs . CSMyInfoRes = ( function () {
/**
* Properties of a CSMyInfoRes.
* @memberof cs
* @interface ICSMyInfoRes
* @property {number|Long|null} [diamond] CSMyInfoRes diamond
* @property {number|Long|null} [vipExpire] CSMyInfoRes vipExpire
*/
/**
* Constructs a new CSMyInfoRes.
* @memberof cs
* @classdesc Represents a CSMyInfoRes.
* @implements ICSMyInfoRes
* @constructor
* @param {cs.ICSMyInfoRes=} [properties] Properties to set
*/
function CSMyInfoRes ( properties ) {
if ( properties )
for ( var keys = Object . keys ( properties ), i = 0 ; i < keys . length ; ++ i )
if ( properties [ keys [ i ]] != null )
this [ keys [ i ]] = properties [ keys [ i ]];
}
/**
* CSMyInfoRes diamond.
* @member {number|Long} diamond
* @memberof cs.CSMyInfoRes
* @instance
*/
CSMyInfoRes . prototype . diamond = $util . Long ? $util . Long . fromBits ( 0 , 0 , false ) : 0 ;
/**
* CSMyInfoRes vipExpire.
* @member {number|Long} vipExpire
* @memberof cs.CSMyInfoRes
* @instance
*/
CSMyInfoRes . prototype . vipExpire = $util . Long ? $util . Long . fromBits ( 0 , 0 , false ) : 0 ;
/**
* Creates a new CSMyInfoRes instance using the specified properties.
* @function create
* @memberof cs.CSMyInfoRes
* @static
* @param {cs.ICSMyInfoRes=} [properties] Properties to set
* @returns {cs.CSMyInfoRes} CSMyInfoRes instance
*/
CSMyInfoRes . create = function create ( properties ) {
return new CSMyInfoRes ( properties );
};
/**
* Encodes the specified CSMyInfoRes message. Does not implicitly {@link cs.CSMyInfoRes.verify|verify} messages.
* @function encode
* @memberof cs.CSMyInfoRes
* @static
* @param {cs.ICSMyInfoRes} message CSMyInfoRes message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSMyInfoRes . encode = function encode ( message , writer ) {
if ( ! writer )
writer = $Writer . create ();
if ( message . diamond != null && Object . hasOwnProperty . call ( message , "diamond" ))
writer . uint32 ( /* id 1, wireType 0 =*/ 8 ). int64 ( message . diamond );
if ( message . vipExpire != null && Object . hasOwnProperty . call ( message , "vipExpire" ))
writer . uint32 ( /* id 2, wireType 0 =*/ 16 ). int64 ( message . vipExpire );
return writer ;
};
/**
* Encodes the specified CSMyInfoRes message, length delimited. Does not implicitly {@link cs.CSMyInfoRes.verify|verify} messages.
* @function encodeDelimited
* @memberof cs.CSMyInfoRes
* @static
* @param {cs.ICSMyInfoRes} message CSMyInfoRes message or plain object to encode
* @param {$protobuf.Writer} [writer] Writer to encode to
* @returns {$protobuf.Writer} Writer
*/
CSMyInfoRes . encodeDelimited = function encodeDelimited ( message , writer ) {
return this . encode ( message , writer ). ldelim ();
};
/**
* Decodes a CSMyInfoRes message from the specified reader or buffer.
* @function decode
* @memberof cs.CSMyInfoRes
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @param {number} [length] Message length if known beforehand
* @returns {cs.CSMyInfoRes} CSMyInfoRes
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSMyInfoRes . decode = function decode ( reader , length , error ) {
if ( ! ( reader instanceof $Reader ))
reader = $Reader . create ( reader );
var end = length === undefined ? reader . len : reader . pos + length , message = new $root . cs . CSMyInfoRes ();
while ( reader . pos < end ) {
var tag = reader . uint32 ();
if ( tag === error )
break ;
switch ( tag >>> 3 ) {
case 1 : {
message . diamond = reader . int64 ();
break ;
}
case 2 : {
message . vipExpire = reader . int64 ();
break ;
}
default :
reader . skipType ( tag & 7 );
break ;
}
}
return message ;
};
/**
* Decodes a CSMyInfoRes message from the specified reader or buffer, length delimited.
* @function decodeDelimited
* @memberof cs.CSMyInfoRes
* @static
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
* @returns {cs.CSMyInfoRes} CSMyInfoRes
* @throws {Error} If the payload is not a reader or valid buffer
* @throws {$protobuf.util.ProtocolError} If required fields are missing
*/
CSMyInfoRes . decodeDelimited = function decodeDelimited ( reader ) {
if ( ! ( reader instanceof $Reader ))
reader = new $Reader ( reader );
return this . decode ( reader , reader . uint32 ());
};
/**
* Verifies a CSMyInfoRes message.
* @function verify
* @memberof cs.CSMyInfoRes
* @static
* @param {Object.<string,*>} message Plain object to verify
* @returns {string|null} `null` if valid, otherwise the reason why it is not
*/
CSMyInfoRes . verify = function verify ( message ) {
if ( typeof message !== "object" || message === null )
return "object expected" ;
if ( message . diamond != null && message . hasOwnProperty ( "diamond" ))
if ( ! $util . isInteger ( message . diamond ) && ! ( message . diamond && $util . isInteger ( message . diamond . low ) && $util . isInteger ( message . diamond . high )))
return "diamond: integer|Long expected" ;
if ( message . vipExpire != null && message . hasOwnProperty ( "vipExpire" ))
if ( ! $util . isInteger ( message . vipExpire ) && ! ( message . vipExpire && $util . isInteger ( message . vipExpire . low ) && $util . isInteger ( message . vipExpire . high )))
return "vipExpire: integer|Long expected" ;
return null ;
};
/**
* Creates a CSMyInfoRes message from a plain object. Also converts values to their respective internal types.
* @function fromObject
* @memberof cs.CSMyInfoRes
* @static
* @param {Object.<string,*>} object Plain object
* @returns {cs.CSMyInfoRes} CSMyInfoRes
*/
CSMyInfoRes . fromObject = function fromObject ( object ) {
if ( object instanceof $root . cs . CSMyInfoRes )
return object ;
var message = new $root . cs . CSMyInfoRes ();
if ( object . diamond != null )
if ( $util . Long )
( message . diamond = $util . Long . fromValue ( object . diamond )). unsigned = false ;
else if ( typeof object . diamond === "string" )
message . diamond = parseInt ( object . diamond , 10 );
else if ( typeof object . diamond === "number" )
message . diamond = object . diamond ;
else if ( typeof object . diamond === "object" )
message . diamond = new $util . LongBits ( object . diamond . low >>> 0 , object . diamond . high >>> 0 ). toNumber ();
if ( object . vipExpire != null )
if ( $util . Long )
( message . vipExpire = $util . Long . fromValue ( object . vipExpire )). unsigned = false ;
else if ( typeof object . vipExpire === "string" )
message . vipExpire = parseInt ( object . vipExpire , 10 );
else if ( typeof object . vipExpire === "number" )
message . vipExpire = object . vipExpire ;
else if ( typeof object . vipExpire === "object" )
message . vipExpire = new $util . LongBits ( object . vipExpire . low >>> 0 , object . vipExpire . high >>> 0 ). toNumber ();
return message ;
};
/**
* Creates a plain object from a CSMyInfoRes message. Also converts values to other types if specified.
* @function toObject
* @memberof cs.CSMyInfoRes
* @static
* @param {cs.CSMyInfoRes} message CSMyInfoRes
* @param {$protobuf.IConversionOptions} [options] Conversion options
* @returns {Object.<string,*>} Plain object
*/
CSMyInfoRes . toObject = function toObject ( message , options ) {
if ( ! options )
options = {};
var object = {};
if ( options . defaults ) {
if ( $util . Long ) {
var long = new $util . Long ( 0 , 0 , false );
object . diamond = options . longs === String ? long . toString () : options . longs === Number ? long . toNumber () : long ;
} else
object . diamond = options . longs === String ? "0" : 0 ;
if ( $util . Long ) {
var long = new $util . Long ( 0 , 0 , false );
object . vipExpire = options . longs === String ? long . toString () : options . longs === Number ? long . toNumber () : long ;
} else
object . vipExpire = options . longs === String ? "0" : 0 ;
}
if ( message . diamond != null && message . hasOwnProperty ( "diamond" ))
if ( typeof message . diamond === "number" )
object . diamond = options . longs === String ? String ( message . diamond ) : message . diamond ;
else
object . diamond = options . longs === String ? $util . Long . prototype . toString . call ( message . diamond ) : options . longs === Number ? new $util . LongBits ( message . diamond . low >>> 0 , message . diamond . high >>> 0 ). toNumber () : message . diamond ;
if ( message . vipExpire != null && message . hasOwnProperty ( "vipExpire" ))
if ( typeof message . vipExpire === "number" )
object . vipExpire = options . longs === String ? String ( message . vipExpire ) : message . vipExpire ;
else
object . vipExpire = options . longs === String ? $util . Long . prototype . toString . call ( message . vipExpire ) : options . longs === Number ? new $util . LongBits ( message . vipExpire . low >>> 0 , message . vipExpire . high >>> 0 ). toNumber () : message . vipExpire ;
return object ;
};
/**
* Converts this CSMyInfoRes to JSON.
* @function toJSON
* @memberof cs.CSMyInfoRes
* @instance
* @returns {Object.<string,*>} JSON object
*/
CSMyInfoRes . prototype . toJSON = function toJSON () {
return this . constructor . toObject ( this , $protobuf . util . toJSONOptions );
};
/**
* Gets the default type url for CSMyInfoRes
* @function getTypeUrl
* @memberof cs.CSMyInfoRes
* @static
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
* @returns {string} The default type url
*/
CSMyInfoRes . getTypeUrl = function getTypeUrl ( typeUrlPrefix ) {
if ( typeUrlPrefix === undefined ) {
typeUrlPrefix = "type.googleapis.com" ;
}
return typeUrlPrefix + "/cs.CSMyInfoRes" ;
};
return CSMyInfoRes ;
2025-08-15 13:55:26 +08:00
})();
/**
2025-08-25 11:30:50 +08:00
* EnmRetCode enum.
* @name cs.EnmRetCode
2025-08-15 13:55:26 +08:00
* @enum {number}
2025-08-25 11:30:50 +08:00
* @property {number} SUCCESS=0 SUCCESS value
* @property {number} GenJWTFailed=5010 GenJWTFailed value
* @property {number} InvalidArg=5013 InvalidArg value
* @property {number} MySQL=5027 MySQL value
* @property {number} TokenExpire=5046 TokenExpire value
* @property {number} TokenInvalid=5047 TokenInvalid value
2025-08-15 13:55:26 +08:00
*/
2025-08-25 11:30:50 +08:00
cs . EnmRetCode = ( function () {
var valuesById = {}, values = Object . create ( valuesById );
values [ valuesById [ 0 ] = "SUCCESS" ] = 0 ;
values [ valuesById [ 5010 ] = "GenJWTFailed" ] = 5010 ;
values [ valuesById [ 5013 ] = "InvalidArg" ] = 5013 ;
values [ valuesById [ 5027 ] = "MySQL" ] = 5027 ;
values [ valuesById [ 5046 ] = "TokenExpire" ] = 5046 ;
values [ valuesById [ 5047 ] = "TokenInvalid" ] = 5047 ;
return values ;
2025-08-15 13:55:26 +08:00
})();
2025-08-25 11:30:50 +08:00
return cs ;
2025-08-13 17:23:45 +08:00
})();
2025-08-14 00:16:28 +08:00
module . exports = $root ;
2025-08-25 11:30:50 +08:00
module . exports . default = module . exports ;