diff --git a/assets/Scripts/Sub/UI/PreloadUI.ts b/assets/Scripts/Sub/UI/PreloadUI.ts index 89df1c77..78b4cd0c 100644 --- a/assets/Scripts/Sub/UI/PreloadUI.ts +++ b/assets/Scripts/Sub/UI/PreloadUI.ts @@ -37,6 +37,7 @@ import MachineInfoService from "db://assets/Scripts/chat18x/foundation/identity/ import { AuthService } from "db://assets/Scripts/chat18x/network/services/AuthService"; import { PlayerDataService } from "db://assets/Scripts/chat18x/network/services/PlayerDataService"; import { ApiCode } from "db://assets/Scripts/chat18x/network/client/types"; +import proto from 'db://assets/Scripts/proto/proto.pb.js'; const { ccclass, property } = _decorator; @@ -260,38 +261,36 @@ export class PreloadUI extends Component { const deviceId = DeviceIdService.I.id; const machineIdentifier = MachineInfoService.I.getMachineIdentifier(); const reqData = { - GameName: ConfigManager.tables.TbGlobalConfig.GameName, - Identifier: deviceId, - IdentityType: 1, - OperateType: 1, - ShareDeposit: '', - MachineIdentifier: machineIdentifier, - SdkUid: '', + platType: 'guset', + userId: deviceId, + device: deviceId, + os: 3, }; console.log("登录请求数据:", reqData); let res = await AuthService.I.login(reqData); console.log("登录响应数据:", res); - if (res && res.code === ApiCode.OK) { + if (res && res.code === proto.cs.EnmRetCode.SUCCESS) { const resData = res.data; // 保存数据 const loginData = DataManager.I.getDataById(DataId.Login); - loginData.operateType = resData.OperateType; - loginData.token = resData.Token; - loginData.ip = resData.Ip; - loginData.machineIdentifier = resData.MachineIdentifier; - loginData.sdkUid = resData.SdkUid; - loginData.lastLoginTime = resData.LastLoginTime; - const accountData = DataManager.I.getDataById(DataId.Account); - accountData.identifier = resData.Identifier; - accountData.identityType = resData.IdentityType; - accountData.uid = resData.Uid; - accountData.isNewGuide = resData.IsNewGuide; - accountData.isNewRegist = resData.IsNewRegist; - const metaData = DataManager.I.getDataById(DataId.Meta); - metaData.gameName = resData.GameName; - const netTimeData = DataManager.I.getDataById(DataId.NetTime); - netTimeData.serverTime = resData.ServerTime; - netTimeData.timezoneOffset = resData.TimezoneOffset; + // loginData.operateType = resData.OperateType; + loginData.token = resData.token; + // loginData.refreshToken = resData.refreshToken; + // loginData.ip = resData.Ip; + // loginData.machineIdentifier = resData.MachineIdentifier; + // loginData.sdkUid = resData.SdkUid; + // loginData.lastLoginTime = resData.LastLoginTime; + // const accountData = DataManager.I.getDataById(DataId.Account); + // accountData.identifier = resData.Identifier; + // accountData.identityType = resData.IdentityType; + // accountData.uid = resData.Uid; + // accountData.isNewGuide = resData.IsNewGuide; + // accountData.isNewRegist = resData.IsNewRegist; + // const metaData = DataManager.I.getDataById(DataId.Meta); + // metaData.gameName = resData.GameName; + // const netTimeData = DataManager.I.getDataById(DataId.NetTime); + // netTimeData.serverTime = resData.ServerTime; + // netTimeData.timezoneOffset = resData.TimezoneOffset; this.loginFinish = true; diff --git a/assets/Scripts/chat18x/config/env/dev.ts b/assets/Scripts/chat18x/config/env/dev.ts index 7b568a4b..3282a673 100644 --- a/assets/Scripts/chat18x/config/env/dev.ts +++ b/assets/Scripts/chat18x/config/env/dev.ts @@ -5,7 +5,7 @@ import { AppConfigShape, Env } from "./env"; export const devConfig: AppConfigShape = { env: Env.Dev, endpoints: { - httpBase: "http://43.139.27.67:8081/", + httpBase: "http://120.25.215.205:20600/", socketBase: "ws://127.0.0.1:9001/ws/", cdn: { bgm: "http://127.0.0.1:8081/BGM/", diff --git a/assets/Scripts/chat18x/config/env/test.ts b/assets/Scripts/chat18x/config/env/test.ts index 65ca48af..ba54ae5c 100644 --- a/assets/Scripts/chat18x/config/env/test.ts +++ b/assets/Scripts/chat18x/config/env/test.ts @@ -5,7 +5,7 @@ import { AppConfigShape, Env } from "./env"; export const testConfig: AppConfigShape = { env: Env.Test, endpoints: { - httpBase: "http://43.139.27.67:8081/", + httpBase: "http://120.25.215.205:20600/", socketBase: "wss://www.confessioncontract.com/test/game/ai/response/", cdn: { bgm: "https://test-cdn.example.com/BGM/", diff --git a/assets/Scripts/chat18x/data/LoginData.ts b/assets/Scripts/chat18x/data/LoginData.ts index fa920bc5..13e17eec 100644 --- a/assets/Scripts/chat18x/data/LoginData.ts +++ b/assets/Scripts/chat18x/data/LoginData.ts @@ -8,6 +8,8 @@ export class LoginData extends BaseData { private _loginState = 0; // token private _token = ""; + // refresh token + private _refreshToken = ""; // 操作类型,1:登录界面;2:断线重连;3:其他 private _operateType = 1; // 公网IP @@ -43,6 +45,17 @@ export class LoginData extends BaseData { public get token(): string { return this._token; } + + /** 设置登录refresh token */ + public set refreshToken(value: string) { + this._refreshToken = value; + console.log("设置登录refresh token", this._refreshToken); + } + + /** 获取登录refresh token */ + public get refreshToken(): string { + return this._refreshToken; + } /** 设置操作类型 */ public set operateType(value: number) { diff --git a/assets/Scripts/chat18x/network/client/ApiClient.ts b/assets/Scripts/chat18x/network/client/ApiClient.ts index 36fdf16d..b23a2346 100644 --- a/assets/Scripts/chat18x/network/client/ApiClient.ts +++ b/assets/Scripts/chat18x/network/client/ApiClient.ts @@ -15,7 +15,7 @@ export class ApiClient { } private constructor(private http = HttpManager.I) {} private get baseUrl() { return AppConfig.I.getHttpBase() } - private get token() { return DataManager.I.getDataById(DataId.Login).getToken();} + private get token() { return DataManager.I.getDataById(DataId.Login).token;} public async call(ep: Endpoint, req: Req): Promise> { const url = `${this.baseUrl}/${ep.path.replace(/^\/+/, "")}`; @@ -67,12 +67,12 @@ export class ApiClient { if (parsed && typeof parsed === "object" && typeof parsed.code === "number") { return { code: parsed.code, - msg: parsed.msg ?? (parsed.code === 1 ? "ok" : "error"), - data: parsed.Data as Res + msg: parsed.msg ?? (parsed.code === 0 ? "ok" : "error"), + data: parsed.data as Res }; } // 否则我们包一层 - return { code: ApiCode.OK, msg: "ok", data: parsed.Data as Res }; + return { code: ApiCode.OK, msg: "ok", data: parsed.data as Res }; } else if (ep.codec === "proto") { const data = ProtoCodec.decode(ep.resType!, r.body); // proto 场景一般没有 {code,msg} 包装,我们统一包一层 diff --git a/assets/Scripts/chat18x/network/client/types.ts b/assets/Scripts/chat18x/network/client/types.ts index b1d95a75..3179950c 100644 --- a/assets/Scripts/chat18x/network/client/types.ts +++ b/assets/Scripts/chat18x/network/client/types.ts @@ -5,7 +5,7 @@ export interface ApiResponse { } export const ApiCode = { - OK: 1, + OK: 0, AUTH_EXPIRED: -401, HTTP_ERROR: -400, TIMEOUT: -408, diff --git a/assets/Scripts/chat18x/network/services/AuthService.ts b/assets/Scripts/chat18x/network/services/AuthService.ts index bfd677da..c9d628cf 100644 --- a/assets/Scripts/chat18x/network/services/AuthService.ts +++ b/assets/Scripts/chat18x/network/services/AuthService.ts @@ -12,9 +12,9 @@ export class AuthService { private constructor(private api = ApiClient.I) {} // 登录 - public async login(req: proto.ProtoMsg.ILoginReq): Promise> { - let epData: Endpoint = { - path: "login", + public async login(req: proto.cs.ICSLoginReq): Promise> { + let epData: Endpoint = { + path: "api/acc/login", method: "POST", codec: "json", needsAuth: false diff --git a/assets/Scripts/chat18x/network/transport/HttpManager.ts b/assets/Scripts/chat18x/network/transport/HttpManager.ts index 032ff008..beaf3dcb 100644 --- a/assets/Scripts/chat18x/network/transport/HttpManager.ts +++ b/assets/Scripts/chat18x/network/transport/HttpManager.ts @@ -48,13 +48,10 @@ export class HttpManager { xhr.open(method, url, true); if (sys.isNative) { xhr.setRequestHeader("Accept-Encoding", "gzip,deflate"); - xhr.setRequestHeader("content-type", "text/html;charset=utf-8"); + xhr.setRequestHeader("Content-type", "text/html;charset=utf-8"); } } else { xhr.open(method, url, true); - if (!opt.rawBody) { - xhr.setRequestHeader("Content-Type", "application/json"); - } } if (opt.headers) { Object.keys(opt.headers).forEach(k => xhr.setRequestHeader(k, opt.headers![k])); diff --git a/assets/Scripts/proto/proto.pb.d.ts b/assets/Scripts/proto/proto.pb.d.ts index adeec451..de80b798 100644 --- a/assets/Scripts/proto/proto.pb.d.ts +++ b/assets/Scripts/proto/proto.pb.d.ts @@ -3,5405 +3,2404 @@ declare namespace proto { // DO NOT EDIT! This is a generated file. Edit the JSDoc in src/*.js instead and run 'npm run build:types'. -/** Namespace ProtoMsg. */ -export namespace ProtoMsg { +/** Namespace cs. */ +export namespace cs { - /** Properties of a CommonRsp. */ - interface ICommonRsp { + /** Properties of a GirlBrief. */ + interface IGirlBrief { - /** CommonRsp RetCode */ - RetCode?: (ProtoMsg.ErrorCode|null); + /** GirlBrief id */ + id?: (number|null); - /** CommonRsp ErrMsg */ - ErrMsg?: (string|null); + /** GirlBrief name */ + name?: (string|null); - /** CommonRsp MsgId */ - MsgId?: (number|null); + /** GirlBrief age */ + age?: (number|null); - /** CommonRsp SubMsgId */ - SubMsgId?: (number|null); + /** GirlBrief tagKey */ + tagKey?: (string|null); - /** CommonRsp DataType */ - DataType?: (number|null); + /** GirlBrief priceType */ + priceType?: (number|null); - /** CommonRsp Data */ - Data?: (string|null); + /** GirlBrief price */ + price?: (number|Long|null); + + /** GirlBrief avatar */ + avatar?: (string|null); + + /** GirlBrief star */ + star?: (number|null); } - /** Represents a CommonRsp. */ - class CommonRsp implements ICommonRsp { + /** Represents a GirlBrief. */ + class GirlBrief implements IGirlBrief { /** - * Constructs a new CommonRsp. + * Constructs a new GirlBrief. * @param [properties] Properties to set */ - constructor(properties?: ProtoMsg.ICommonRsp); + constructor(properties?: cs.IGirlBrief); - /** CommonRsp RetCode. */ -RetCode: ProtoMsg.ErrorCode; + /** GirlBrief id. */ +id: number; - /** CommonRsp ErrMsg. */ -ErrMsg: string; + /** GirlBrief name. */ +name: string; - /** CommonRsp MsgId. */ -MsgId: number; + /** GirlBrief age. */ +age: number; - /** CommonRsp SubMsgId. */ -SubMsgId: number; + /** GirlBrief tagKey. */ +tagKey: string; - /** CommonRsp DataType. */ -DataType: number; + /** GirlBrief priceType. */ +priceType: number; - /** CommonRsp Data. */ -Data: string; + /** GirlBrief price. */ +price: (number|Long); + + /** GirlBrief avatar. */ +avatar: string; + + /** GirlBrief star. */ +star: number; /** - * Creates a new CommonRsp instance using the specified properties. + * Creates a new GirlBrief instance using the specified properties. * @param [properties] Properties to set - * @returns CommonRsp instance + * @returns GirlBrief instance */ -static create(properties?: ProtoMsg.ICommonRsp): ProtoMsg.CommonRsp; +static create(properties?: cs.IGirlBrief): cs.GirlBrief; /** - * Encodes the specified CommonRsp message. Does not implicitly {@link ProtoMsg.CommonRsp.verify|verify} messages. - * @param message CommonRsp message or plain object to encode + * Encodes the specified GirlBrief message. Does not implicitly {@link cs.GirlBrief.verify|verify} messages. + * @param message GirlBrief message or plain object to encode * @param [writer] Writer to encode to * @returns Writer */ -static encode(message: ProtoMsg.ICommonRsp, writer?: $protobuf.Writer): $protobuf.Writer; +static encode(message: cs.IGirlBrief, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Encodes the specified CommonRsp message, length delimited. Does not implicitly {@link ProtoMsg.CommonRsp.verify|verify} messages. - * @param message CommonRsp message or plain object to encode + * Encodes the specified GirlBrief message, length delimited. Does not implicitly {@link cs.GirlBrief.verify|verify} messages. + * @param message GirlBrief message or plain object to encode * @param [writer] Writer to encode to * @returns Writer */ -static encodeDelimited(message: ProtoMsg.ICommonRsp, writer?: $protobuf.Writer): $protobuf.Writer; +static encodeDelimited(message: cs.IGirlBrief, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Decodes a CommonRsp message from the specified reader or buffer. + * Decodes a GirlBrief message from the specified reader or buffer. * @param reader Reader or buffer to decode from * @param [length] Message length if known beforehand - * @returns CommonRsp + * @returns GirlBrief * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): ProtoMsg.CommonRsp; +static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): cs.GirlBrief; /** - * Decodes a CommonRsp message from the specified reader or buffer, length delimited. + * Decodes a GirlBrief message from the specified reader or buffer, length delimited. * @param reader Reader or buffer to decode from - * @returns CommonRsp + * @returns GirlBrief * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): ProtoMsg.CommonRsp; +static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): cs.GirlBrief; /** - * Verifies a CommonRsp message. + * Verifies a GirlBrief message. * @param message Plain object to verify * @returns `null` if valid, otherwise the reason why it is not */ static verify(message: { [k: string]: any }): (string|null); /** - * Creates a CommonRsp message from a plain object. Also converts values to their respective internal types. + * Creates a GirlBrief message from a plain object. Also converts values to their respective internal types. * @param object Plain object - * @returns CommonRsp + * @returns GirlBrief */ -static fromObject(object: { [k: string]: any }): ProtoMsg.CommonRsp; +static fromObject(object: { [k: string]: any }): cs.GirlBrief; /** - * Creates a plain object from a CommonRsp message. Also converts values to other types if specified. - * @param message CommonRsp + * Creates a plain object from a GirlBrief message. Also converts values to other types if specified. + * @param message GirlBrief * @param [options] Conversion options * @returns Plain object */ -static toObject(message: ProtoMsg.CommonRsp, options?: $protobuf.IConversionOptions): { [k: string]: any }; +static toObject(message: cs.GirlBrief, options?: $protobuf.IConversionOptions): { [k: string]: any }; /** - * Converts this CommonRsp to JSON. + * Converts this GirlBrief to JSON. * @returns JSON object */ toJSON(): { [k: string]: any }; /** - * Gets the default type url for CommonRsp + * Gets the default type url for GirlBrief * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns The default type url */ static getTypeUrl(typeUrlPrefix?: string): string; } - /** MsgId enum. */ - enum MsgId { - None = 0, - Account = 1, - PlayerData = 2, - Admin = 99 + /** Properties of a GirlDetail. */ + interface IGirlDetail { + + /** GirlDetail brief */ + brief?: (cs.IGirlBrief|null); + + /** GirlDetail desc */ + desc?: (string|null); + + /** GirlDetail pics */ + pics?: (string[]|null); } - /** SubMsgId_Account enum. */ - enum SubMsgId_Account { - Account_None = 0, - Login = 1 - } - - /** SubMsgId_PlayerData enum. */ - enum SubMsgId_PlayerData { - PlayerData_None = 0, - QueryPlayerData = 1, - SavePlayerData = 2 - } - - /** ErrorCode enum. */ - enum ErrorCode { - Succeed = 0, - TokenWrong = 1, - TokenExpire = 2, - SystemFail = 3, - RequestParamWrong = 4, - HeaderParamWrong = 5, - ConfigError = 6, - MachineIdentifierNotMathch = 7, - ModuleNotOpen = 10, - SystemError = 100, - RewardClaimed = 101, - ItemNotEnough = 102, - ItemConfigNotExist = 103, - PlayerNotExist = 104, - PlayerLevelNotEnough = 105, - PlayerNameAlreadyExist = 106, - RewardNotAchieve = 107 - } - - /** Properties of a LoginReq. */ - interface ILoginReq { - - /** LoginReq GameName */ - GameName?: (string|null); - - /** LoginReq Identifier */ - Identifier?: (string|null); - - /** LoginReq IdentityType */ - IdentityType?: (number|null); - - /** LoginReq OperateType */ - OperateType?: (number|null); - - /** LoginReq ShareDeposit */ - ShareDeposit?: (string|null); - - /** LoginReq MachineIdentifier */ - MachineIdentifier?: (string|null); - - /** LoginReq SdkUid */ - SdkUid?: (string|null); - } - - /** Represents a LoginReq. */ - class LoginReq implements ILoginReq { + /** Represents a GirlDetail. */ + class GirlDetail implements IGirlDetail { /** - * Constructs a new LoginReq. + * Constructs a new GirlDetail. * @param [properties] Properties to set */ - constructor(properties?: ProtoMsg.ILoginReq); + constructor(properties?: cs.IGirlDetail); - /** LoginReq GameName. */ -GameName: string; + /** GirlDetail brief. */ +brief?: (cs.IGirlBrief|null); - /** LoginReq Identifier. */ -Identifier: string; + /** GirlDetail desc. */ +desc: string; - /** LoginReq IdentityType. */ -IdentityType: number; - - /** LoginReq OperateType. */ -OperateType: number; - - /** LoginReq ShareDeposit. */ -ShareDeposit: string; - - /** LoginReq MachineIdentifier. */ -MachineIdentifier?: (string|null); - - /** LoginReq SdkUid. */ -SdkUid?: (string|null); - - /** LoginReq _MachineIdentifier. */ -_MachineIdentifier?: "MachineIdentifier"; - - /** LoginReq _SdkUid. */ -_SdkUid?: "SdkUid"; + /** GirlDetail pics. */ +pics: string[]; /** - * Creates a new LoginReq instance using the specified properties. + * Creates a new GirlDetail instance using the specified properties. * @param [properties] Properties to set - * @returns LoginReq instance + * @returns GirlDetail instance */ -static create(properties?: ProtoMsg.ILoginReq): ProtoMsg.LoginReq; +static create(properties?: cs.IGirlDetail): cs.GirlDetail; /** - * Encodes the specified LoginReq message. Does not implicitly {@link ProtoMsg.LoginReq.verify|verify} messages. - * @param message LoginReq message or plain object to encode + * Encodes the specified GirlDetail message. Does not implicitly {@link cs.GirlDetail.verify|verify} messages. + * @param message GirlDetail message or plain object to encode * @param [writer] Writer to encode to * @returns Writer */ -static encode(message: ProtoMsg.ILoginReq, writer?: $protobuf.Writer): $protobuf.Writer; +static encode(message: cs.IGirlDetail, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Encodes the specified LoginReq message, length delimited. Does not implicitly {@link ProtoMsg.LoginReq.verify|verify} messages. - * @param message LoginReq message or plain object to encode + * Encodes the specified GirlDetail message, length delimited. Does not implicitly {@link cs.GirlDetail.verify|verify} messages. + * @param message GirlDetail message or plain object to encode * @param [writer] Writer to encode to * @returns Writer */ -static encodeDelimited(message: ProtoMsg.ILoginReq, writer?: $protobuf.Writer): $protobuf.Writer; +static encodeDelimited(message: cs.IGirlDetail, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Decodes a LoginReq message from the specified reader or buffer. + * Decodes a GirlDetail message from the specified reader or buffer. * @param reader Reader or buffer to decode from * @param [length] Message length if known beforehand - * @returns LoginReq + * @returns GirlDetail * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): ProtoMsg.LoginReq; +static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): cs.GirlDetail; /** - * Decodes a LoginReq message from the specified reader or buffer, length delimited. + * Decodes a GirlDetail message from the specified reader or buffer, length delimited. * @param reader Reader or buffer to decode from - * @returns LoginReq + * @returns GirlDetail * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): ProtoMsg.LoginReq; +static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): cs.GirlDetail; /** - * Verifies a LoginReq message. + * Verifies a GirlDetail message. * @param message Plain object to verify * @returns `null` if valid, otherwise the reason why it is not */ static verify(message: { [k: string]: any }): (string|null); /** - * Creates a LoginReq message from a plain object. Also converts values to their respective internal types. + * Creates a GirlDetail message from a plain object. Also converts values to their respective internal types. * @param object Plain object - * @returns LoginReq + * @returns GirlDetail */ -static fromObject(object: { [k: string]: any }): ProtoMsg.LoginReq; +static fromObject(object: { [k: string]: any }): cs.GirlDetail; /** - * Creates a plain object from a LoginReq message. Also converts values to other types if specified. - * @param message LoginReq + * Creates a plain object from a GirlDetail message. Also converts values to other types if specified. + * @param message GirlDetail * @param [options] Conversion options * @returns Plain object */ -static toObject(message: ProtoMsg.LoginReq, options?: $protobuf.IConversionOptions): { [k: string]: any }; +static toObject(message: cs.GirlDetail, options?: $protobuf.IConversionOptions): { [k: string]: any }; /** - * Converts this LoginReq to JSON. + * Converts this GirlDetail to JSON. * @returns JSON object */ toJSON(): { [k: string]: any }; /** - * Gets the default type url for LoginReq + * Gets the default type url for GirlDetail * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns The default type url */ static getTypeUrl(typeUrlPrefix?: string): string; } - /** Properties of a LoginRsp. */ - interface ILoginRsp { - - /** LoginRsp GameName */ - GameName?: (string|null); - - /** LoginRsp Identifier */ - Identifier?: (string|null); - - /** LoginRsp IdentityType */ - IdentityType?: (number|null); - - /** LoginRsp OperateType */ - OperateType?: (number|null); - - /** LoginRsp Uid */ - Uid?: (number|Long|null); - - /** LoginRsp Token */ - Token?: (string|null); - - /** LoginRsp ServerTime */ - ServerTime?: (number|Long|null); - - /** LoginRsp TimezoneOffset */ - TimezoneOffset?: (number|null); - - /** LoginRsp Ip */ - Ip?: (string|null); - - /** LoginRsp MachineIdentifier */ - MachineIdentifier?: (string|null); - - /** LoginRsp SdkUid */ - SdkUid?: (string|null); - - /** LoginRsp IsNewGuide */ - IsNewGuide?: (boolean|null); - - /** LoginRsp IsNewRegist */ - IsNewRegist?: (boolean|null); - - /** LoginRsp LastLoginTime */ - LastLoginTime?: (number|Long|null); + /** Properties of a CSDailyRecommendReq. */ + interface ICSDailyRecommendReq { } - /** Represents a LoginRsp. */ - class LoginRsp implements ILoginRsp { + /** Represents a CSDailyRecommendReq. */ + class CSDailyRecommendReq implements ICSDailyRecommendReq { /** - * Constructs a new LoginRsp. + * Constructs a new CSDailyRecommendReq. * @param [properties] Properties to set */ - constructor(properties?: ProtoMsg.ILoginRsp); - - /** LoginRsp GameName. */ -GameName: string; - - /** LoginRsp Identifier. */ -Identifier: string; - - /** LoginRsp IdentityType. */ -IdentityType: number; - - /** LoginRsp OperateType. */ -OperateType: number; - - /** LoginRsp Uid. */ -Uid: (number|Long); - - /** LoginRsp Token. */ -Token: string; - - /** LoginRsp ServerTime. */ -ServerTime: (number|Long); - - /** LoginRsp TimezoneOffset. */ -TimezoneOffset: number; - - /** LoginRsp Ip. */ -Ip: string; - - /** LoginRsp MachineIdentifier. */ -MachineIdentifier?: (string|null); - - /** LoginRsp SdkUid. */ -SdkUid?: (string|null); - - /** LoginRsp IsNewGuide. */ -IsNewGuide?: (boolean|null); - - /** LoginRsp IsNewRegist. */ -IsNewRegist?: (boolean|null); - - /** LoginRsp LastLoginTime. */ -LastLoginTime?: (number|Long|null); - - /** LoginRsp _MachineIdentifier. */ -_MachineIdentifier?: "MachineIdentifier"; - - /** LoginRsp _SdkUid. */ -_SdkUid?: "SdkUid"; - - /** LoginRsp _IsNewGuide. */ -_IsNewGuide?: "IsNewGuide"; - - /** LoginRsp _IsNewRegist. */ -_IsNewRegist?: "IsNewRegist"; - - /** LoginRsp _LastLoginTime. */ -_LastLoginTime?: "LastLoginTime"; + constructor(properties?: cs.ICSDailyRecommendReq); /** - * Creates a new LoginRsp instance using the specified properties. + * Creates a new CSDailyRecommendReq instance using the specified properties. * @param [properties] Properties to set - * @returns LoginRsp instance + * @returns CSDailyRecommendReq instance */ -static create(properties?: ProtoMsg.ILoginRsp): ProtoMsg.LoginRsp; +static create(properties?: cs.ICSDailyRecommendReq): cs.CSDailyRecommendReq; /** - * Encodes the specified LoginRsp message. Does not implicitly {@link ProtoMsg.LoginRsp.verify|verify} messages. - * @param message LoginRsp message or plain object to encode + * Encodes the specified CSDailyRecommendReq message. Does not implicitly {@link cs.CSDailyRecommendReq.verify|verify} messages. + * @param message CSDailyRecommendReq message or plain object to encode * @param [writer] Writer to encode to * @returns Writer */ -static encode(message: ProtoMsg.ILoginRsp, writer?: $protobuf.Writer): $protobuf.Writer; +static encode(message: cs.ICSDailyRecommendReq, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Encodes the specified LoginRsp message, length delimited. Does not implicitly {@link ProtoMsg.LoginRsp.verify|verify} messages. - * @param message LoginRsp message or plain object to encode + * Encodes the specified CSDailyRecommendReq message, length delimited. Does not implicitly {@link cs.CSDailyRecommendReq.verify|verify} messages. + * @param message CSDailyRecommendReq message or plain object to encode * @param [writer] Writer to encode to * @returns Writer */ -static encodeDelimited(message: ProtoMsg.ILoginRsp, writer?: $protobuf.Writer): $protobuf.Writer; +static encodeDelimited(message: cs.ICSDailyRecommendReq, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Decodes a LoginRsp message from the specified reader or buffer. + * Decodes a CSDailyRecommendReq message from the specified reader or buffer. * @param reader Reader or buffer to decode from * @param [length] Message length if known beforehand - * @returns LoginRsp + * @returns CSDailyRecommendReq * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): ProtoMsg.LoginRsp; +static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): cs.CSDailyRecommendReq; /** - * Decodes a LoginRsp message from the specified reader or buffer, length delimited. + * Decodes a CSDailyRecommendReq message from the specified reader or buffer, length delimited. * @param reader Reader or buffer to decode from - * @returns LoginRsp + * @returns CSDailyRecommendReq * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): ProtoMsg.LoginRsp; +static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): cs.CSDailyRecommendReq; /** - * Verifies a LoginRsp message. + * Verifies a CSDailyRecommendReq message. * @param message Plain object to verify * @returns `null` if valid, otherwise the reason why it is not */ static verify(message: { [k: string]: any }): (string|null); /** - * Creates a LoginRsp message from a plain object. Also converts values to their respective internal types. + * Creates a CSDailyRecommendReq message from a plain object. Also converts values to their respective internal types. * @param object Plain object - * @returns LoginRsp + * @returns CSDailyRecommendReq */ -static fromObject(object: { [k: string]: any }): ProtoMsg.LoginRsp; +static fromObject(object: { [k: string]: any }): cs.CSDailyRecommendReq; /** - * Creates a plain object from a LoginRsp message. Also converts values to other types if specified. - * @param message LoginRsp + * Creates a plain object from a CSDailyRecommendReq message. Also converts values to other types if specified. + * @param message CSDailyRecommendReq * @param [options] Conversion options * @returns Plain object */ -static toObject(message: ProtoMsg.LoginRsp, options?: $protobuf.IConversionOptions): { [k: string]: any }; +static toObject(message: cs.CSDailyRecommendReq, options?: $protobuf.IConversionOptions): { [k: string]: any }; /** - * Converts this LoginRsp to JSON. + * Converts this CSDailyRecommendReq to JSON. * @returns JSON object */ toJSON(): { [k: string]: any }; /** - * Gets the default type url for LoginRsp + * Gets the default type url for CSDailyRecommendReq * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns The default type url */ static getTypeUrl(typeUrlPrefix?: string): string; } - /** Properties of a QueryPlayerDataReq. */ - interface IQueryPlayerDataReq { + /** Properties of a CSDailyRecommendRes. */ + interface ICSDailyRecommendRes { - /** QueryPlayerDataReq IsAll */ - IsAll?: (boolean|null); - - /** QueryPlayerDataReq GameName */ - GameName?: (string|null); - - /** QueryPlayerDataReq DataFlagList */ - DataFlagList?: (string[]|null); + /** CSDailyRecommendRes girls */ + girls?: (cs.IGirlBrief[]|null); } - /** Represents a QueryPlayerDataReq. */ - class QueryPlayerDataReq implements IQueryPlayerDataReq { + /** Represents a CSDailyRecommendRes. */ + class CSDailyRecommendRes implements ICSDailyRecommendRes { /** - * Constructs a new QueryPlayerDataReq. + * Constructs a new CSDailyRecommendRes. * @param [properties] Properties to set */ - constructor(properties?: ProtoMsg.IQueryPlayerDataReq); + constructor(properties?: cs.ICSDailyRecommendRes); - /** QueryPlayerDataReq IsAll. */ -IsAll: boolean; - - /** QueryPlayerDataReq GameName. */ -GameName: string; - - /** QueryPlayerDataReq DataFlagList. */ -DataFlagList: string[]; + /** CSDailyRecommendRes girls. */ +girls: cs.IGirlBrief[]; /** - * Creates a new QueryPlayerDataReq instance using the specified properties. + * Creates a new CSDailyRecommendRes instance using the specified properties. * @param [properties] Properties to set - * @returns QueryPlayerDataReq instance + * @returns CSDailyRecommendRes instance */ -static create(properties?: ProtoMsg.IQueryPlayerDataReq): ProtoMsg.QueryPlayerDataReq; +static create(properties?: cs.ICSDailyRecommendRes): cs.CSDailyRecommendRes; /** - * Encodes the specified QueryPlayerDataReq message. Does not implicitly {@link ProtoMsg.QueryPlayerDataReq.verify|verify} messages. - * @param message QueryPlayerDataReq message or plain object to encode + * Encodes the specified CSDailyRecommendRes message. Does not implicitly {@link cs.CSDailyRecommendRes.verify|verify} messages. + * @param message CSDailyRecommendRes message or plain object to encode * @param [writer] Writer to encode to * @returns Writer */ -static encode(message: ProtoMsg.IQueryPlayerDataReq, writer?: $protobuf.Writer): $protobuf.Writer; +static encode(message: cs.ICSDailyRecommendRes, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Encodes the specified QueryPlayerDataReq message, length delimited. Does not implicitly {@link ProtoMsg.QueryPlayerDataReq.verify|verify} messages. - * @param message QueryPlayerDataReq message or plain object to encode + * Encodes the specified CSDailyRecommendRes message, length delimited. Does not implicitly {@link cs.CSDailyRecommendRes.verify|verify} messages. + * @param message CSDailyRecommendRes message or plain object to encode * @param [writer] Writer to encode to * @returns Writer */ -static encodeDelimited(message: ProtoMsg.IQueryPlayerDataReq, writer?: $protobuf.Writer): $protobuf.Writer; +static encodeDelimited(message: cs.ICSDailyRecommendRes, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Decodes a QueryPlayerDataReq message from the specified reader or buffer. + * Decodes a CSDailyRecommendRes message from the specified reader or buffer. * @param reader Reader or buffer to decode from * @param [length] Message length if known beforehand - * @returns QueryPlayerDataReq + * @returns CSDailyRecommendRes * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): ProtoMsg.QueryPlayerDataReq; +static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): cs.CSDailyRecommendRes; /** - * Decodes a QueryPlayerDataReq message from the specified reader or buffer, length delimited. + * Decodes a CSDailyRecommendRes message from the specified reader or buffer, length delimited. * @param reader Reader or buffer to decode from - * @returns QueryPlayerDataReq + * @returns CSDailyRecommendRes * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): ProtoMsg.QueryPlayerDataReq; +static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): cs.CSDailyRecommendRes; /** - * Verifies a QueryPlayerDataReq message. + * Verifies a CSDailyRecommendRes message. * @param message Plain object to verify * @returns `null` if valid, otherwise the reason why it is not */ static verify(message: { [k: string]: any }): (string|null); /** - * Creates a QueryPlayerDataReq message from a plain object. Also converts values to their respective internal types. + * Creates a CSDailyRecommendRes message from a plain object. Also converts values to their respective internal types. * @param object Plain object - * @returns QueryPlayerDataReq + * @returns CSDailyRecommendRes */ -static fromObject(object: { [k: string]: any }): ProtoMsg.QueryPlayerDataReq; +static fromObject(object: { [k: string]: any }): cs.CSDailyRecommendRes; /** - * Creates a plain object from a QueryPlayerDataReq message. Also converts values to other types if specified. - * @param message QueryPlayerDataReq + * Creates a plain object from a CSDailyRecommendRes message. Also converts values to other types if specified. + * @param message CSDailyRecommendRes * @param [options] Conversion options * @returns Plain object */ -static toObject(message: ProtoMsg.QueryPlayerDataReq, options?: $protobuf.IConversionOptions): { [k: string]: any }; +static toObject(message: cs.CSDailyRecommendRes, options?: $protobuf.IConversionOptions): { [k: string]: any }; /** - * Converts this QueryPlayerDataReq to JSON. + * Converts this CSDailyRecommendRes to JSON. * @returns JSON object */ toJSON(): { [k: string]: any }; /** - * Gets the default type url for QueryPlayerDataReq + * Gets the default type url for CSDailyRecommendRes * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns The default type url */ static getTypeUrl(typeUrlPrefix?: string): string; } - /** Properties of a QueryPlayerDataRsp. */ - interface IQueryPlayerDataRsp { - - /** QueryPlayerDataRsp IsAll */ - IsAll?: (boolean|null); - - /** QueryPlayerDataRsp GameName */ - GameName?: (string|null); - - /** QueryPlayerDataRsp PlayerDataList */ - PlayerDataList?: (ProtoMsg.IPlayerDataPair[]|null); + /** Properties of a CSHallThemeReq. */ + interface ICSHallThemeReq { } - /** Represents a QueryPlayerDataRsp. */ - class QueryPlayerDataRsp implements IQueryPlayerDataRsp { + /** Represents a CSHallThemeReq. */ + class CSHallThemeReq implements ICSHallThemeReq { /** - * Constructs a new QueryPlayerDataRsp. + * Constructs a new CSHallThemeReq. * @param [properties] Properties to set */ - constructor(properties?: ProtoMsg.IQueryPlayerDataRsp); - - /** QueryPlayerDataRsp IsAll. */ -IsAll: boolean; - - /** QueryPlayerDataRsp GameName. */ -GameName: string; - - /** QueryPlayerDataRsp PlayerDataList. */ -PlayerDataList: ProtoMsg.IPlayerDataPair[]; + constructor(properties?: cs.ICSHallThemeReq); /** - * Creates a new QueryPlayerDataRsp instance using the specified properties. + * Creates a new CSHallThemeReq instance using the specified properties. * @param [properties] Properties to set - * @returns QueryPlayerDataRsp instance + * @returns CSHallThemeReq instance */ -static create(properties?: ProtoMsg.IQueryPlayerDataRsp): ProtoMsg.QueryPlayerDataRsp; +static create(properties?: cs.ICSHallThemeReq): cs.CSHallThemeReq; /** - * Encodes the specified QueryPlayerDataRsp message. Does not implicitly {@link ProtoMsg.QueryPlayerDataRsp.verify|verify} messages. - * @param message QueryPlayerDataRsp message or plain object to encode + * Encodes the specified CSHallThemeReq message. Does not implicitly {@link cs.CSHallThemeReq.verify|verify} messages. + * @param message CSHallThemeReq message or plain object to encode * @param [writer] Writer to encode to * @returns Writer */ -static encode(message: ProtoMsg.IQueryPlayerDataRsp, writer?: $protobuf.Writer): $protobuf.Writer; +static encode(message: cs.ICSHallThemeReq, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Encodes the specified QueryPlayerDataRsp message, length delimited. Does not implicitly {@link ProtoMsg.QueryPlayerDataRsp.verify|verify} messages. - * @param message QueryPlayerDataRsp message or plain object to encode + * Encodes the specified CSHallThemeReq message, length delimited. Does not implicitly {@link cs.CSHallThemeReq.verify|verify} messages. + * @param message CSHallThemeReq message or plain object to encode * @param [writer] Writer to encode to * @returns Writer */ -static encodeDelimited(message: ProtoMsg.IQueryPlayerDataRsp, writer?: $protobuf.Writer): $protobuf.Writer; +static encodeDelimited(message: cs.ICSHallThemeReq, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Decodes a QueryPlayerDataRsp message from the specified reader or buffer. + * Decodes a CSHallThemeReq message from the specified reader or buffer. * @param reader Reader or buffer to decode from * @param [length] Message length if known beforehand - * @returns QueryPlayerDataRsp + * @returns CSHallThemeReq * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): ProtoMsg.QueryPlayerDataRsp; +static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): cs.CSHallThemeReq; /** - * Decodes a QueryPlayerDataRsp message from the specified reader or buffer, length delimited. + * Decodes a CSHallThemeReq message from the specified reader or buffer, length delimited. * @param reader Reader or buffer to decode from - * @returns QueryPlayerDataRsp + * @returns CSHallThemeReq * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): ProtoMsg.QueryPlayerDataRsp; +static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): cs.CSHallThemeReq; /** - * Verifies a QueryPlayerDataRsp message. + * Verifies a CSHallThemeReq message. * @param message Plain object to verify * @returns `null` if valid, otherwise the reason why it is not */ static verify(message: { [k: string]: any }): (string|null); /** - * Creates a QueryPlayerDataRsp message from a plain object. Also converts values to their respective internal types. + * Creates a CSHallThemeReq message from a plain object. Also converts values to their respective internal types. * @param object Plain object - * @returns QueryPlayerDataRsp + * @returns CSHallThemeReq */ -static fromObject(object: { [k: string]: any }): ProtoMsg.QueryPlayerDataRsp; +static fromObject(object: { [k: string]: any }): cs.CSHallThemeReq; /** - * Creates a plain object from a QueryPlayerDataRsp message. Also converts values to other types if specified. - * @param message QueryPlayerDataRsp + * Creates a plain object from a CSHallThemeReq message. Also converts values to other types if specified. + * @param message CSHallThemeReq * @param [options] Conversion options * @returns Plain object */ -static toObject(message: ProtoMsg.QueryPlayerDataRsp, options?: $protobuf.IConversionOptions): { [k: string]: any }; +static toObject(message: cs.CSHallThemeReq, options?: $protobuf.IConversionOptions): { [k: string]: any }; /** - * Converts this QueryPlayerDataRsp to JSON. + * Converts this CSHallThemeReq to JSON. * @returns JSON object */ toJSON(): { [k: string]: any }; /** - * Gets the default type url for QueryPlayerDataRsp + * Gets the default type url for CSHallThemeReq * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns The default type url */ static getTypeUrl(typeUrlPrefix?: string): string; } - /** Properties of a PlayerDataPair. */ - interface IPlayerDataPair { + /** Properties of a HallTheme. */ + interface IHallTheme { - /** PlayerDataPair DataFlag */ - DataFlag?: (string|null); + /** HallTheme id */ + id?: (number|null); - /** PlayerDataPair Content */ - Content?: (string|null); + /** HallTheme key */ + key?: (string|null); + + /** HallTheme name */ + name?: (string|null); + + /** HallTheme category */ + category?: (number|null); + + /** HallTheme isLock */ + isLock?: (boolean|null); + + /** HallTheme path */ + path?: (string|null); } - /** Represents a PlayerDataPair. */ - class PlayerDataPair implements IPlayerDataPair { + /** Represents a HallTheme. */ + class HallTheme implements IHallTheme { /** - * Constructs a new PlayerDataPair. + * Constructs a new HallTheme. * @param [properties] Properties to set */ - constructor(properties?: ProtoMsg.IPlayerDataPair); + constructor(properties?: cs.IHallTheme); - /** PlayerDataPair DataFlag. */ -DataFlag: string; + /** HallTheme id. */ +id: number; - /** PlayerDataPair Content. */ -Content: string; + /** HallTheme key. */ +key: string; + + /** HallTheme name. */ +name: string; + + /** HallTheme category. */ +category: number; + + /** HallTheme isLock. */ +isLock: boolean; + + /** HallTheme path. */ +path: string; /** - * Creates a new PlayerDataPair instance using the specified properties. + * Creates a new HallTheme instance using the specified properties. * @param [properties] Properties to set - * @returns PlayerDataPair instance + * @returns HallTheme instance */ -static create(properties?: ProtoMsg.IPlayerDataPair): ProtoMsg.PlayerDataPair; +static create(properties?: cs.IHallTheme): cs.HallTheme; /** - * Encodes the specified PlayerDataPair message. Does not implicitly {@link ProtoMsg.PlayerDataPair.verify|verify} messages. - * @param message PlayerDataPair message or plain object to encode + * Encodes the specified HallTheme message. Does not implicitly {@link cs.HallTheme.verify|verify} messages. + * @param message HallTheme message or plain object to encode * @param [writer] Writer to encode to * @returns Writer */ -static encode(message: ProtoMsg.IPlayerDataPair, writer?: $protobuf.Writer): $protobuf.Writer; +static encode(message: cs.IHallTheme, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Encodes the specified PlayerDataPair message, length delimited. Does not implicitly {@link ProtoMsg.PlayerDataPair.verify|verify} messages. - * @param message PlayerDataPair message or plain object to encode + * Encodes the specified HallTheme message, length delimited. Does not implicitly {@link cs.HallTheme.verify|verify} messages. + * @param message HallTheme message or plain object to encode * @param [writer] Writer to encode to * @returns Writer */ -static encodeDelimited(message: ProtoMsg.IPlayerDataPair, writer?: $protobuf.Writer): $protobuf.Writer; +static encodeDelimited(message: cs.IHallTheme, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Decodes a PlayerDataPair message from the specified reader or buffer. + * Decodes a HallTheme message from the specified reader or buffer. * @param reader Reader or buffer to decode from * @param [length] Message length if known beforehand - * @returns PlayerDataPair + * @returns HallTheme * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): ProtoMsg.PlayerDataPair; +static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): cs.HallTheme; /** - * Decodes a PlayerDataPair message from the specified reader or buffer, length delimited. + * Decodes a HallTheme message from the specified reader or buffer, length delimited. * @param reader Reader or buffer to decode from - * @returns PlayerDataPair + * @returns HallTheme * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): ProtoMsg.PlayerDataPair; +static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): cs.HallTheme; /** - * Verifies a PlayerDataPair message. + * Verifies a HallTheme message. * @param message Plain object to verify * @returns `null` if valid, otherwise the reason why it is not */ static verify(message: { [k: string]: any }): (string|null); /** - * Creates a PlayerDataPair message from a plain object. Also converts values to their respective internal types. + * Creates a HallTheme message from a plain object. Also converts values to their respective internal types. * @param object Plain object - * @returns PlayerDataPair + * @returns HallTheme */ -static fromObject(object: { [k: string]: any }): ProtoMsg.PlayerDataPair; +static fromObject(object: { [k: string]: any }): cs.HallTheme; /** - * Creates a plain object from a PlayerDataPair message. Also converts values to other types if specified. - * @param message PlayerDataPair + * Creates a plain object from a HallTheme message. Also converts values to other types if specified. + * @param message HallTheme * @param [options] Conversion options * @returns Plain object */ -static toObject(message: ProtoMsg.PlayerDataPair, options?: $protobuf.IConversionOptions): { [k: string]: any }; +static toObject(message: cs.HallTheme, options?: $protobuf.IConversionOptions): { [k: string]: any }; /** - * Converts this PlayerDataPair to JSON. + * Converts this HallTheme to JSON. * @returns JSON object */ toJSON(): { [k: string]: any }; /** - * Gets the default type url for PlayerDataPair + * Gets the default type url for HallTheme * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns The default type url */ static getTypeUrl(typeUrlPrefix?: string): string; } - /** Properties of a SavePlayerDataReq. */ - interface ISavePlayerDataReq { + /** Properties of a CSHallThemeRes. */ + interface ICSHallThemeRes { - /** SavePlayerDataReq GameName */ - GameName?: (string|null); - - /** SavePlayerDataReq DataFlag */ - DataFlag?: (string|null); - - /** SavePlayerDataReq Content */ - Content?: (string|null); + /** CSHallThemeRes themes */ + themes?: (cs.IHallTheme[]|null); } - /** Represents a SavePlayerDataReq. */ - class SavePlayerDataReq implements ISavePlayerDataReq { + /** Represents a CSHallThemeRes. */ + class CSHallThemeRes implements ICSHallThemeRes { /** - * Constructs a new SavePlayerDataReq. + * Constructs a new CSHallThemeRes. * @param [properties] Properties to set */ - constructor(properties?: ProtoMsg.ISavePlayerDataReq); + constructor(properties?: cs.ICSHallThemeRes); - /** SavePlayerDataReq GameName. */ -GameName: string; - - /** SavePlayerDataReq DataFlag. */ -DataFlag: string; - - /** SavePlayerDataReq Content. */ -Content: string; + /** CSHallThemeRes themes. */ +themes: cs.IHallTheme[]; /** - * Creates a new SavePlayerDataReq instance using the specified properties. + * Creates a new CSHallThemeRes instance using the specified properties. * @param [properties] Properties to set - * @returns SavePlayerDataReq instance + * @returns CSHallThemeRes instance */ -static create(properties?: ProtoMsg.ISavePlayerDataReq): ProtoMsg.SavePlayerDataReq; +static create(properties?: cs.ICSHallThemeRes): cs.CSHallThemeRes; /** - * Encodes the specified SavePlayerDataReq message. Does not implicitly {@link ProtoMsg.SavePlayerDataReq.verify|verify} messages. - * @param message SavePlayerDataReq message or plain object to encode + * Encodes the specified CSHallThemeRes message. Does not implicitly {@link cs.CSHallThemeRes.verify|verify} messages. + * @param message CSHallThemeRes message or plain object to encode * @param [writer] Writer to encode to * @returns Writer */ -static encode(message: ProtoMsg.ISavePlayerDataReq, writer?: $protobuf.Writer): $protobuf.Writer; +static encode(message: cs.ICSHallThemeRes, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Encodes the specified SavePlayerDataReq message, length delimited. Does not implicitly {@link ProtoMsg.SavePlayerDataReq.verify|verify} messages. - * @param message SavePlayerDataReq message or plain object to encode + * Encodes the specified CSHallThemeRes message, length delimited. Does not implicitly {@link cs.CSHallThemeRes.verify|verify} messages. + * @param message CSHallThemeRes message or plain object to encode * @param [writer] Writer to encode to * @returns Writer */ -static encodeDelimited(message: ProtoMsg.ISavePlayerDataReq, writer?: $protobuf.Writer): $protobuf.Writer; +static encodeDelimited(message: cs.ICSHallThemeRes, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Decodes a SavePlayerDataReq message from the specified reader or buffer. + * Decodes a CSHallThemeRes message from the specified reader or buffer. * @param reader Reader or buffer to decode from * @param [length] Message length if known beforehand - * @returns SavePlayerDataReq + * @returns CSHallThemeRes * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): ProtoMsg.SavePlayerDataReq; +static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): cs.CSHallThemeRes; /** - * Decodes a SavePlayerDataReq message from the specified reader or buffer, length delimited. + * Decodes a CSHallThemeRes message from the specified reader or buffer, length delimited. * @param reader Reader or buffer to decode from - * @returns SavePlayerDataReq + * @returns CSHallThemeRes * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): ProtoMsg.SavePlayerDataReq; +static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): cs.CSHallThemeRes; /** - * Verifies a SavePlayerDataReq message. + * Verifies a CSHallThemeRes message. * @param message Plain object to verify * @returns `null` if valid, otherwise the reason why it is not */ static verify(message: { [k: string]: any }): (string|null); /** - * Creates a SavePlayerDataReq message from a plain object. Also converts values to their respective internal types. + * Creates a CSHallThemeRes message from a plain object. Also converts values to their respective internal types. * @param object Plain object - * @returns SavePlayerDataReq + * @returns CSHallThemeRes */ -static fromObject(object: { [k: string]: any }): ProtoMsg.SavePlayerDataReq; +static fromObject(object: { [k: string]: any }): cs.CSHallThemeRes; /** - * Creates a plain object from a SavePlayerDataReq message. Also converts values to other types if specified. - * @param message SavePlayerDataReq + * Creates a plain object from a CSHallThemeRes message. Also converts values to other types if specified. + * @param message CSHallThemeRes * @param [options] Conversion options * @returns Plain object */ -static toObject(message: ProtoMsg.SavePlayerDataReq, options?: $protobuf.IConversionOptions): { [k: string]: any }; +static toObject(message: cs.CSHallThemeRes, options?: $protobuf.IConversionOptions): { [k: string]: any }; /** - * Converts this SavePlayerDataReq to JSON. + * Converts this CSHallThemeRes to JSON. * @returns JSON object */ toJSON(): { [k: string]: any }; /** - * Gets the default type url for SavePlayerDataReq + * Gets the default type url for CSHallThemeRes * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns The default type url */ static getTypeUrl(typeUrlPrefix?: string): string; } - /** Properties of a SavePlayerDataRsp. */ - interface ISavePlayerDataRsp { + /** Properties of a CSGetGirlListReq. */ + interface ICSGetGirlListReq { - /** SavePlayerDataRsp GameName */ - GameName?: (string|null); + /** CSGetGirlListReq category */ + category?: (string|null); - /** SavePlayerDataRsp DataFlag */ - DataFlag?: (string|null); + /** CSGetGirlListReq page */ + page?: (number|null); + + /** CSGetGirlListReq limit */ + limit?: (number|null); } - /** Represents a SavePlayerDataRsp. */ - class SavePlayerDataRsp implements ISavePlayerDataRsp { + /** Represents a CSGetGirlListReq. */ + class CSGetGirlListReq implements ICSGetGirlListReq { /** - * Constructs a new SavePlayerDataRsp. + * Constructs a new CSGetGirlListReq. * @param [properties] Properties to set */ - constructor(properties?: ProtoMsg.ISavePlayerDataRsp); + constructor(properties?: cs.ICSGetGirlListReq); - /** SavePlayerDataRsp GameName. */ -GameName: string; + /** CSGetGirlListReq category. */ +category: string; - /** SavePlayerDataRsp DataFlag. */ -DataFlag: string; + /** CSGetGirlListReq page. */ +page: number; + + /** CSGetGirlListReq limit. */ +limit: number; /** - * Creates a new SavePlayerDataRsp instance using the specified properties. + * Creates a new CSGetGirlListReq instance using the specified properties. * @param [properties] Properties to set - * @returns SavePlayerDataRsp instance + * @returns CSGetGirlListReq instance */ -static create(properties?: ProtoMsg.ISavePlayerDataRsp): ProtoMsg.SavePlayerDataRsp; +static create(properties?: cs.ICSGetGirlListReq): cs.CSGetGirlListReq; /** - * Encodes the specified SavePlayerDataRsp message. Does not implicitly {@link ProtoMsg.SavePlayerDataRsp.verify|verify} messages. - * @param message SavePlayerDataRsp message or plain object to encode + * Encodes the specified CSGetGirlListReq message. Does not implicitly {@link cs.CSGetGirlListReq.verify|verify} messages. + * @param message CSGetGirlListReq message or plain object to encode * @param [writer] Writer to encode to * @returns Writer */ -static encode(message: ProtoMsg.ISavePlayerDataRsp, writer?: $protobuf.Writer): $protobuf.Writer; +static encode(message: cs.ICSGetGirlListReq, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Encodes the specified SavePlayerDataRsp message, length delimited. Does not implicitly {@link ProtoMsg.SavePlayerDataRsp.verify|verify} messages. - * @param message SavePlayerDataRsp message or plain object to encode + * Encodes the specified CSGetGirlListReq message, length delimited. Does not implicitly {@link cs.CSGetGirlListReq.verify|verify} messages. + * @param message CSGetGirlListReq message or plain object to encode * @param [writer] Writer to encode to * @returns Writer */ -static encodeDelimited(message: ProtoMsg.ISavePlayerDataRsp, writer?: $protobuf.Writer): $protobuf.Writer; +static encodeDelimited(message: cs.ICSGetGirlListReq, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Decodes a SavePlayerDataRsp message from the specified reader or buffer. + * Decodes a CSGetGirlListReq message from the specified reader or buffer. * @param reader Reader or buffer to decode from * @param [length] Message length if known beforehand - * @returns SavePlayerDataRsp + * @returns CSGetGirlListReq * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): ProtoMsg.SavePlayerDataRsp; +static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): cs.CSGetGirlListReq; /** - * Decodes a SavePlayerDataRsp message from the specified reader or buffer, length delimited. + * Decodes a CSGetGirlListReq message from the specified reader or buffer, length delimited. * @param reader Reader or buffer to decode from - * @returns SavePlayerDataRsp + * @returns CSGetGirlListReq * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): ProtoMsg.SavePlayerDataRsp; +static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): cs.CSGetGirlListReq; /** - * Verifies a SavePlayerDataRsp message. + * Verifies a CSGetGirlListReq message. * @param message Plain object to verify * @returns `null` if valid, otherwise the reason why it is not */ static verify(message: { [k: string]: any }): (string|null); /** - * Creates a SavePlayerDataRsp message from a plain object. Also converts values to their respective internal types. + * Creates a CSGetGirlListReq message from a plain object. Also converts values to their respective internal types. * @param object Plain object - * @returns SavePlayerDataRsp + * @returns CSGetGirlListReq */ -static fromObject(object: { [k: string]: any }): ProtoMsg.SavePlayerDataRsp; +static fromObject(object: { [k: string]: any }): cs.CSGetGirlListReq; /** - * Creates a plain object from a SavePlayerDataRsp message. Also converts values to other types if specified. - * @param message SavePlayerDataRsp + * Creates a plain object from a CSGetGirlListReq message. Also converts values to other types if specified. + * @param message CSGetGirlListReq * @param [options] Conversion options * @returns Plain object */ -static toObject(message: ProtoMsg.SavePlayerDataRsp, options?: $protobuf.IConversionOptions): { [k: string]: any }; +static toObject(message: cs.CSGetGirlListReq, options?: $protobuf.IConversionOptions): { [k: string]: any }; /** - * Converts this SavePlayerDataRsp to JSON. + * Converts this CSGetGirlListReq to JSON. * @returns JSON object */ toJSON(): { [k: string]: any }; /** - * Gets the default type url for SavePlayerDataRsp + * Gets the default type url for CSGetGirlListReq * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns The default type url */ static getTypeUrl(typeUrlPrefix?: string): string; } -} -/** Namespace google. */ -export namespace google { + /** Properties of a CSGetGirlListRes. */ + interface ICSGetGirlListRes { - /** Namespace protobuf. */ - namespace protobuf { + /** CSGetGirlListRes girls */ + girls?: (cs.IGirlBrief[]|null); + } - /** Properties of a FileDescriptorSet. */ - interface IFileDescriptorSet { + /** Represents a CSGetGirlListRes. */ + class CSGetGirlListRes implements ICSGetGirlListRes { - /** FileDescriptorSet file */ - file?: (google.protobuf.IFileDescriptorProto[]|null); - } + /** + * Constructs a new CSGetGirlListRes. + * @param [properties] Properties to set + */ + constructor(properties?: cs.ICSGetGirlListRes); - /** Represents a FileDescriptorSet. */ - class FileDescriptorSet implements IFileDescriptorSet { + /** CSGetGirlListRes girls. */ +girls: cs.IGirlBrief[]; - /** - * Constructs a new FileDescriptorSet. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.IFileDescriptorSet); + /** + * Creates a new CSGetGirlListRes instance using the specified properties. + * @param [properties] Properties to set + * @returns CSGetGirlListRes instance + */ +static create(properties?: cs.ICSGetGirlListRes): cs.CSGetGirlListRes; - /** FileDescriptorSet file. */ -file: google.protobuf.IFileDescriptorProto[]; + /** + * Encodes the specified CSGetGirlListRes message. Does not implicitly {@link cs.CSGetGirlListRes.verify|verify} messages. + * @param message CSGetGirlListRes message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encode(message: cs.ICSGetGirlListRes, writer?: $protobuf.Writer): $protobuf.Writer; - /** - * Creates a new FileDescriptorSet instance using the specified properties. - * @param [properties] Properties to set - * @returns FileDescriptorSet instance - */ -static create(properties?: google.protobuf.IFileDescriptorSet): google.protobuf.FileDescriptorSet; + /** + * Encodes the specified CSGetGirlListRes message, length delimited. Does not implicitly {@link cs.CSGetGirlListRes.verify|verify} messages. + * @param message CSGetGirlListRes message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encodeDelimited(message: cs.ICSGetGirlListRes, writer?: $protobuf.Writer): $protobuf.Writer; - /** - * Encodes the specified FileDescriptorSet message. Does not implicitly {@link google.protobuf.FileDescriptorSet.verify|verify} messages. - * @param message FileDescriptorSet message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.IFileDescriptorSet, writer?: $protobuf.Writer): $protobuf.Writer; + /** + * Decodes a CSGetGirlListRes message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns CSGetGirlListRes + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): cs.CSGetGirlListRes; - /** - * Encodes the specified FileDescriptorSet message, length delimited. Does not implicitly {@link google.protobuf.FileDescriptorSet.verify|verify} messages. - * @param message FileDescriptorSet message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.IFileDescriptorSet, writer?: $protobuf.Writer): $protobuf.Writer; + /** + * Decodes a CSGetGirlListRes message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns CSGetGirlListRes + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): cs.CSGetGirlListRes; - /** - * Decodes a FileDescriptorSet message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns FileDescriptorSet - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.FileDescriptorSet; - - /** - * Decodes a FileDescriptorSet message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns FileDescriptorSet - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.FileDescriptorSet; - - /** - * Verifies a FileDescriptorSet message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ + /** + * Verifies a CSGetGirlListRes message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ static verify(message: { [k: string]: any }): (string|null); - /** - * Creates a FileDescriptorSet message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns FileDescriptorSet - */ -static fromObject(object: { [k: string]: any }): google.protobuf.FileDescriptorSet; + /** + * Creates a CSGetGirlListRes message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns CSGetGirlListRes + */ +static fromObject(object: { [k: string]: any }): cs.CSGetGirlListRes; - /** - * Creates a plain object from a FileDescriptorSet message. Also converts values to other types if specified. - * @param message FileDescriptorSet - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.FileDescriptorSet, options?: $protobuf.IConversionOptions): { [k: string]: any }; + /** + * Creates a plain object from a CSGetGirlListRes message. Also converts values to other types if specified. + * @param message CSGetGirlListRes + * @param [options] Conversion options + * @returns Plain object + */ +static toObject(message: cs.CSGetGirlListRes, options?: $protobuf.IConversionOptions): { [k: string]: any }; - /** - * Converts this FileDescriptorSet to JSON. - * @returns JSON object - */ + /** + * Converts this CSGetGirlListRes to JSON. + * @returns JSON object + */ toJSON(): { [k: string]: any }; - /** - * Gets the default type url for FileDescriptorSet - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ + /** + * Gets the default type url for CSGetGirlListRes + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ static getTypeUrl(typeUrlPrefix?: string): string; - } + } - /** Edition enum. */ - enum Edition { - EDITION_UNKNOWN = 0, - EDITION_LEGACY = 900, - EDITION_PROTO2 = 998, - EDITION_PROTO3 = 999, - EDITION_2023 = 1000, - EDITION_2024 = 1001, - EDITION_1_TEST_ONLY = 1, - EDITION_2_TEST_ONLY = 2, - EDITION_99997_TEST_ONLY = 99997, - EDITION_99998_TEST_ONLY = 99998, - EDITION_99999_TEST_ONLY = 99999, - EDITION_MAX = 2147483647 - } + /** Properties of a CSGetGirlDetailReq. */ + interface ICSGetGirlDetailReq { - /** Properties of a FileDescriptorProto. */ - interface IFileDescriptorProto { + /** CSGetGirlDetailReq id */ + id?: (number|null); + } - /** FileDescriptorProto name */ - name?: (string|null); + /** Represents a CSGetGirlDetailReq. */ + class CSGetGirlDetailReq implements ICSGetGirlDetailReq { - /** FileDescriptorProto package */ - "package"?: (string|null); + /** + * Constructs a new CSGetGirlDetailReq. + * @param [properties] Properties to set + */ + constructor(properties?: cs.ICSGetGirlDetailReq); - /** FileDescriptorProto dependency */ - dependency?: (string[]|null); + /** CSGetGirlDetailReq id. */ +id: number; - /** FileDescriptorProto publicDependency */ - publicDependency?: (number[]|null); + /** + * Creates a new CSGetGirlDetailReq instance using the specified properties. + * @param [properties] Properties to set + * @returns CSGetGirlDetailReq instance + */ +static create(properties?: cs.ICSGetGirlDetailReq): cs.CSGetGirlDetailReq; - /** FileDescriptorProto weakDependency */ - weakDependency?: (number[]|null); + /** + * Encodes the specified CSGetGirlDetailReq message. Does not implicitly {@link cs.CSGetGirlDetailReq.verify|verify} messages. + * @param message CSGetGirlDetailReq message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encode(message: cs.ICSGetGirlDetailReq, writer?: $protobuf.Writer): $protobuf.Writer; - /** FileDescriptorProto optionDependency */ - optionDependency?: (string[]|null); + /** + * Encodes the specified CSGetGirlDetailReq message, length delimited. Does not implicitly {@link cs.CSGetGirlDetailReq.verify|verify} messages. + * @param message CSGetGirlDetailReq message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encodeDelimited(message: cs.ICSGetGirlDetailReq, writer?: $protobuf.Writer): $protobuf.Writer; - /** FileDescriptorProto messageType */ - messageType?: (google.protobuf.IDescriptorProto[]|null); + /** + * Decodes a CSGetGirlDetailReq message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns CSGetGirlDetailReq + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): cs.CSGetGirlDetailReq; - /** FileDescriptorProto enumType */ - enumType?: (google.protobuf.IEnumDescriptorProto[]|null); + /** + * Decodes a CSGetGirlDetailReq message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns CSGetGirlDetailReq + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): cs.CSGetGirlDetailReq; - /** FileDescriptorProto service */ - service?: (google.protobuf.IServiceDescriptorProto[]|null); + /** + * Verifies a CSGetGirlDetailReq message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ +static verify(message: { [k: string]: any }): (string|null); - /** FileDescriptorProto extension */ - extension?: (google.protobuf.IFieldDescriptorProto[]|null); + /** + * Creates a CSGetGirlDetailReq message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns CSGetGirlDetailReq + */ +static fromObject(object: { [k: string]: any }): cs.CSGetGirlDetailReq; - /** FileDescriptorProto options */ - options?: (google.protobuf.IFileOptions|null); + /** + * Creates a plain object from a CSGetGirlDetailReq message. Also converts values to other types if specified. + * @param message CSGetGirlDetailReq + * @param [options] Conversion options + * @returns Plain object + */ +static toObject(message: cs.CSGetGirlDetailReq, options?: $protobuf.IConversionOptions): { [k: string]: any }; - /** FileDescriptorProto sourceCodeInfo */ - sourceCodeInfo?: (google.protobuf.ISourceCodeInfo|null); + /** + * Converts this CSGetGirlDetailReq to JSON. + * @returns JSON object + */ +toJSON(): { [k: string]: any }; - /** FileDescriptorProto syntax */ - syntax?: (string|null); + /** + * Gets the default type url for CSGetGirlDetailReq + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ +static getTypeUrl(typeUrlPrefix?: string): string; + } - /** FileDescriptorProto edition */ - edition?: (google.protobuf.Edition|null); - } + /** Properties of a CSGetGirlDetailRes. */ + interface ICSGetGirlDetailRes { - /** Represents a FileDescriptorProto. */ - class FileDescriptorProto implements IFileDescriptorProto { + /** CSGetGirlDetailRes detail */ + detail?: (cs.IGirlDetail|null); + } - /** - * Constructs a new FileDescriptorProto. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.IFileDescriptorProto); + /** Represents a CSGetGirlDetailRes. */ + class CSGetGirlDetailRes implements ICSGetGirlDetailRes { - /** FileDescriptorProto name. */ + /** + * Constructs a new CSGetGirlDetailRes. + * @param [properties] Properties to set + */ + constructor(properties?: cs.ICSGetGirlDetailRes); + + /** CSGetGirlDetailRes detail. */ +detail?: (cs.IGirlDetail|null); + + /** + * Creates a new CSGetGirlDetailRes instance using the specified properties. + * @param [properties] Properties to set + * @returns CSGetGirlDetailRes instance + */ +static create(properties?: cs.ICSGetGirlDetailRes): cs.CSGetGirlDetailRes; + + /** + * Encodes the specified CSGetGirlDetailRes message. Does not implicitly {@link cs.CSGetGirlDetailRes.verify|verify} messages. + * @param message CSGetGirlDetailRes message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encode(message: cs.ICSGetGirlDetailRes, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified CSGetGirlDetailRes message, length delimited. Does not implicitly {@link cs.CSGetGirlDetailRes.verify|verify} messages. + * @param message CSGetGirlDetailRes message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encodeDelimited(message: cs.ICSGetGirlDetailRes, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a CSGetGirlDetailRes message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns CSGetGirlDetailRes + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): cs.CSGetGirlDetailRes; + + /** + * Decodes a CSGetGirlDetailRes message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns CSGetGirlDetailRes + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): cs.CSGetGirlDetailRes; + + /** + * Verifies a CSGetGirlDetailRes message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ +static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a CSGetGirlDetailRes message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns CSGetGirlDetailRes + */ +static fromObject(object: { [k: string]: any }): cs.CSGetGirlDetailRes; + + /** + * Creates a plain object from a CSGetGirlDetailRes message. Also converts values to other types if specified. + * @param message CSGetGirlDetailRes + * @param [options] Conversion options + * @returns Plain object + */ +static toObject(message: cs.CSGetGirlDetailRes, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this CSGetGirlDetailRes to JSON. + * @returns JSON object + */ +toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for CSGetGirlDetailRes + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ +static getTypeUrl(typeUrlPrefix?: string): string; + } + + /** Properties of a Diamond. */ + interface IDiamond { + + /** Diamond id */ + id?: (number|null); + + /** Diamond name */ + name?: (string|null); + + /** Diamond price */ + price?: (string|null); + + /** Diamond diamonCount */ + diamonCount?: (number|null); + } + + /** Represents a Diamond. */ + class Diamond implements IDiamond { + + /** + * Constructs a new Diamond. + * @param [properties] Properties to set + */ + constructor(properties?: cs.IDiamond); + + /** Diamond id. */ +id: number; + + /** Diamond name. */ name: string; - /** FileDescriptorProto package. */ -package: string; + /** Diamond price. */ +price: string; - /** FileDescriptorProto dependency. */ -dependency: string[]; + /** Diamond diamonCount. */ +diamonCount: number; - /** FileDescriptorProto publicDependency. */ -publicDependency: number[]; + /** + * Creates a new Diamond instance using the specified properties. + * @param [properties] Properties to set + * @returns Diamond instance + */ +static create(properties?: cs.IDiamond): cs.Diamond; - /** FileDescriptorProto weakDependency. */ -weakDependency: number[]; + /** + * Encodes the specified Diamond message. Does not implicitly {@link cs.Diamond.verify|verify} messages. + * @param message Diamond message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encode(message: cs.IDiamond, writer?: $protobuf.Writer): $protobuf.Writer; - /** FileDescriptorProto optionDependency. */ -optionDependency: string[]; + /** + * Encodes the specified Diamond message, length delimited. Does not implicitly {@link cs.Diamond.verify|verify} messages. + * @param message Diamond message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encodeDelimited(message: cs.IDiamond, writer?: $protobuf.Writer): $protobuf.Writer; - /** FileDescriptorProto messageType. */ -messageType: google.protobuf.IDescriptorProto[]; + /** + * Decodes a Diamond message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns Diamond + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): cs.Diamond; - /** FileDescriptorProto enumType. */ -enumType: google.protobuf.IEnumDescriptorProto[]; + /** + * Decodes a Diamond message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns Diamond + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): cs.Diamond; - /** FileDescriptorProto service. */ -service: google.protobuf.IServiceDescriptorProto[]; - - /** FileDescriptorProto extension. */ -extension: google.protobuf.IFieldDescriptorProto[]; - - /** FileDescriptorProto options. */ -options?: (google.protobuf.IFileOptions|null); - - /** FileDescriptorProto sourceCodeInfo. */ -sourceCodeInfo?: (google.protobuf.ISourceCodeInfo|null); - - /** FileDescriptorProto syntax. */ -syntax: string; - - /** FileDescriptorProto edition. */ -edition: google.protobuf.Edition; - - /** - * Creates a new FileDescriptorProto instance using the specified properties. - * @param [properties] Properties to set - * @returns FileDescriptorProto instance - */ -static create(properties?: google.protobuf.IFileDescriptorProto): google.protobuf.FileDescriptorProto; - - /** - * Encodes the specified FileDescriptorProto message. Does not implicitly {@link google.protobuf.FileDescriptorProto.verify|verify} messages. - * @param message FileDescriptorProto message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.IFileDescriptorProto, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified FileDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.FileDescriptorProto.verify|verify} messages. - * @param message FileDescriptorProto message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.IFileDescriptorProto, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes a FileDescriptorProto message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns FileDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.FileDescriptorProto; - - /** - * Decodes a FileDescriptorProto message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns FileDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.FileDescriptorProto; - - /** - * Verifies a FileDescriptorProto message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ + /** + * Verifies a Diamond message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ static verify(message: { [k: string]: any }): (string|null); - /** - * Creates a FileDescriptorProto message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns FileDescriptorProto - */ -static fromObject(object: { [k: string]: any }): google.protobuf.FileDescriptorProto; + /** + * Creates a Diamond message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns Diamond + */ +static fromObject(object: { [k: string]: any }): cs.Diamond; - /** - * Creates a plain object from a FileDescriptorProto message. Also converts values to other types if specified. - * @param message FileDescriptorProto - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.FileDescriptorProto, options?: $protobuf.IConversionOptions): { [k: string]: any }; + /** + * Creates a plain object from a Diamond message. Also converts values to other types if specified. + * @param message Diamond + * @param [options] Conversion options + * @returns Plain object + */ +static toObject(message: cs.Diamond, options?: $protobuf.IConversionOptions): { [k: string]: any }; - /** - * Converts this FileDescriptorProto to JSON. - * @returns JSON object - */ + /** + * Converts this Diamond to JSON. + * @returns JSON object + */ toJSON(): { [k: string]: any }; - /** - * Gets the default type url for FileDescriptorProto - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ + /** + * Gets the default type url for Diamond + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ static getTypeUrl(typeUrlPrefix?: string): string; - } + } - /** Properties of a DescriptorProto. */ - interface IDescriptorProto { + /** Properties of a Vip. */ + interface IVip { - /** DescriptorProto name */ - name?: (string|null); + /** Vip id */ + id?: (number|null); - /** DescriptorProto field */ - field?: (google.protobuf.IFieldDescriptorProto[]|null); + /** Vip name */ + name?: (string|null); - /** DescriptorProto extension */ - extension?: (google.protobuf.IFieldDescriptorProto[]|null); + /** Vip desc */ + desc?: (string|null); - /** DescriptorProto nestedType */ - nestedType?: (google.protobuf.IDescriptorProto[]|null); + /** Vip price */ + price?: (string|null); + } - /** DescriptorProto enumType */ - enumType?: (google.protobuf.IEnumDescriptorProto[]|null); + /** Represents a Vip. */ + class Vip implements IVip { - /** DescriptorProto extensionRange */ - extensionRange?: (google.protobuf.DescriptorProto.IExtensionRange[]|null); + /** + * Constructs a new Vip. + * @param [properties] Properties to set + */ + constructor(properties?: cs.IVip); - /** DescriptorProto oneofDecl */ - oneofDecl?: (google.protobuf.IOneofDescriptorProto[]|null); + /** Vip id. */ +id: number; - /** DescriptorProto options */ - options?: (google.protobuf.IMessageOptions|null); - - /** DescriptorProto reservedRange */ - reservedRange?: (google.protobuf.DescriptorProto.IReservedRange[]|null); - - /** DescriptorProto reservedName */ - reservedName?: (string[]|null); - - /** DescriptorProto visibility */ - visibility?: (google.protobuf.SymbolVisibility|null); - } - - /** Represents a DescriptorProto. */ - class DescriptorProto implements IDescriptorProto { - - /** - * Constructs a new DescriptorProto. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.IDescriptorProto); - - /** DescriptorProto name. */ + /** Vip name. */ name: string; - /** DescriptorProto field. */ -field: google.protobuf.IFieldDescriptorProto[]; + /** Vip desc. */ +desc: string; - /** DescriptorProto extension. */ -extension: google.protobuf.IFieldDescriptorProto[]; + /** Vip price. */ +price: string; - /** DescriptorProto nestedType. */ -nestedType: google.protobuf.IDescriptorProto[]; + /** + * Creates a new Vip instance using the specified properties. + * @param [properties] Properties to set + * @returns Vip instance + */ +static create(properties?: cs.IVip): cs.Vip; - /** DescriptorProto enumType. */ -enumType: google.protobuf.IEnumDescriptorProto[]; + /** + * Encodes the specified Vip message. Does not implicitly {@link cs.Vip.verify|verify} messages. + * @param message Vip message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encode(message: cs.IVip, writer?: $protobuf.Writer): $protobuf.Writer; - /** DescriptorProto extensionRange. */ -extensionRange: google.protobuf.DescriptorProto.IExtensionRange[]; + /** + * Encodes the specified Vip message, length delimited. Does not implicitly {@link cs.Vip.verify|verify} messages. + * @param message Vip message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encodeDelimited(message: cs.IVip, writer?: $protobuf.Writer): $protobuf.Writer; - /** DescriptorProto oneofDecl. */ -oneofDecl: google.protobuf.IOneofDescriptorProto[]; + /** + * Decodes a Vip message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns Vip + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): cs.Vip; - /** DescriptorProto options. */ -options?: (google.protobuf.IMessageOptions|null); + /** + * Decodes a Vip message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns Vip + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): cs.Vip; - /** DescriptorProto reservedRange. */ -reservedRange: google.protobuf.DescriptorProto.IReservedRange[]; - - /** DescriptorProto reservedName. */ -reservedName: string[]; - - /** DescriptorProto visibility. */ -visibility: google.protobuf.SymbolVisibility; - - /** - * Creates a new DescriptorProto instance using the specified properties. - * @param [properties] Properties to set - * @returns DescriptorProto instance - */ -static create(properties?: google.protobuf.IDescriptorProto): google.protobuf.DescriptorProto; - - /** - * Encodes the specified DescriptorProto message. Does not implicitly {@link google.protobuf.DescriptorProto.verify|verify} messages. - * @param message DescriptorProto message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.IDescriptorProto, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified DescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.DescriptorProto.verify|verify} messages. - * @param message DescriptorProto message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.IDescriptorProto, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes a DescriptorProto message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns DescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.DescriptorProto; - - /** - * Decodes a DescriptorProto message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns DescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.DescriptorProto; - - /** - * Verifies a DescriptorProto message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ + /** + * Verifies a Vip message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ static verify(message: { [k: string]: any }): (string|null); - /** - * Creates a DescriptorProto message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns DescriptorProto - */ -static fromObject(object: { [k: string]: any }): google.protobuf.DescriptorProto; + /** + * Creates a Vip message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns Vip + */ +static fromObject(object: { [k: string]: any }): cs.Vip; - /** - * Creates a plain object from a DescriptorProto message. Also converts values to other types if specified. - * @param message DescriptorProto - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.DescriptorProto, options?: $protobuf.IConversionOptions): { [k: string]: any }; + /** + * Creates a plain object from a Vip message. Also converts values to other types if specified. + * @param message Vip + * @param [options] Conversion options + * @returns Plain object + */ +static toObject(message: cs.Vip, options?: $protobuf.IConversionOptions): { [k: string]: any }; - /** - * Converts this DescriptorProto to JSON. - * @returns JSON object - */ + /** + * Converts this Vip to JSON. + * @returns JSON object + */ toJSON(): { [k: string]: any }; - /** - * Gets the default type url for DescriptorProto - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ + /** + * Gets the default type url for Vip + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ static getTypeUrl(typeUrlPrefix?: string): string; - } + } - namespace DescriptorProto { + /** Properties of a CSGetShopReq. */ + interface ICSGetShopReq { + } - /** Properties of an ExtensionRange. */ - interface IExtensionRange { + /** Represents a CSGetShopReq. */ + class CSGetShopReq implements ICSGetShopReq { - /** ExtensionRange start */ - start?: (number|null); + /** + * Constructs a new CSGetShopReq. + * @param [properties] Properties to set + */ + constructor(properties?: cs.ICSGetShopReq); - /** ExtensionRange end */ - end?: (number|null); + /** + * Creates a new CSGetShopReq instance using the specified properties. + * @param [properties] Properties to set + * @returns CSGetShopReq instance + */ +static create(properties?: cs.ICSGetShopReq): cs.CSGetShopReq; - /** ExtensionRange options */ - options?: (google.protobuf.IExtensionRangeOptions|null); - } + /** + * Encodes the specified CSGetShopReq message. Does not implicitly {@link cs.CSGetShopReq.verify|verify} messages. + * @param message CSGetShopReq message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encode(message: cs.ICSGetShopReq, writer?: $protobuf.Writer): $protobuf.Writer; - /** Represents an ExtensionRange. */ - class ExtensionRange implements IExtensionRange { + /** + * Encodes the specified CSGetShopReq message, length delimited. Does not implicitly {@link cs.CSGetShopReq.verify|verify} messages. + * @param message CSGetShopReq message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encodeDelimited(message: cs.ICSGetShopReq, writer?: $protobuf.Writer): $protobuf.Writer; - /** - * Constructs a new ExtensionRange. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.DescriptorProto.IExtensionRange); + /** + * Decodes a CSGetShopReq message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns CSGetShopReq + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): cs.CSGetShopReq; - /** ExtensionRange start. */ -start: number; + /** + * Decodes a CSGetShopReq message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns CSGetShopReq + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): cs.CSGetShopReq; - /** ExtensionRange end. */ -end: number; - - /** ExtensionRange options. */ -options?: (google.protobuf.IExtensionRangeOptions|null); - - /** - * Creates a new ExtensionRange instance using the specified properties. - * @param [properties] Properties to set - * @returns ExtensionRange instance - */ -static create(properties?: google.protobuf.DescriptorProto.IExtensionRange): google.protobuf.DescriptorProto.ExtensionRange; - - /** - * Encodes the specified ExtensionRange message. Does not implicitly {@link google.protobuf.DescriptorProto.ExtensionRange.verify|verify} messages. - * @param message ExtensionRange message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.DescriptorProto.IExtensionRange, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified ExtensionRange message, length delimited. Does not implicitly {@link google.protobuf.DescriptorProto.ExtensionRange.verify|verify} messages. - * @param message ExtensionRange message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.DescriptorProto.IExtensionRange, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes an ExtensionRange message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns ExtensionRange - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.DescriptorProto.ExtensionRange; - - /** - * Decodes an ExtensionRange message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns ExtensionRange - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.DescriptorProto.ExtensionRange; - - /** - * Verifies an ExtensionRange message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ + /** + * Verifies a CSGetShopReq message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ static verify(message: { [k: string]: any }): (string|null); - /** - * Creates an ExtensionRange message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns ExtensionRange - */ -static fromObject(object: { [k: string]: any }): google.protobuf.DescriptorProto.ExtensionRange; + /** + * Creates a CSGetShopReq message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns CSGetShopReq + */ +static fromObject(object: { [k: string]: any }): cs.CSGetShopReq; - /** - * Creates a plain object from an ExtensionRange message. Also converts values to other types if specified. - * @param message ExtensionRange - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.DescriptorProto.ExtensionRange, options?: $protobuf.IConversionOptions): { [k: string]: any }; + /** + * Creates a plain object from a CSGetShopReq message. Also converts values to other types if specified. + * @param message CSGetShopReq + * @param [options] Conversion options + * @returns Plain object + */ +static toObject(message: cs.CSGetShopReq, options?: $protobuf.IConversionOptions): { [k: string]: any }; - /** - * Converts this ExtensionRange to JSON. - * @returns JSON object - */ + /** + * Converts this CSGetShopReq to JSON. + * @returns JSON object + */ toJSON(): { [k: string]: any }; - /** - * Gets the default type url for ExtensionRange - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ + /** + * Gets the default type url for CSGetShopReq + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ static getTypeUrl(typeUrlPrefix?: string): string; - } + } - /** Properties of a ReservedRange. */ - interface IReservedRange { + /** Properties of a CSGetShopRes. */ + interface ICSGetShopRes { - /** ReservedRange start */ - start?: (number|null); + /** CSGetShopRes diamonds */ + diamonds?: (cs.IDiamond[]|null); - /** ReservedRange end */ - end?: (number|null); - } + /** CSGetShopRes vips */ + vips?: (cs.IVip[]|null); + } - /** Represents a ReservedRange. */ - class ReservedRange implements IReservedRange { + /** Represents a CSGetShopRes. */ + class CSGetShopRes implements ICSGetShopRes { - /** - * Constructs a new ReservedRange. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.DescriptorProto.IReservedRange); + /** + * Constructs a new CSGetShopRes. + * @param [properties] Properties to set + */ + constructor(properties?: cs.ICSGetShopRes); - /** ReservedRange start. */ -start: number; + /** CSGetShopRes diamonds. */ +diamonds: cs.IDiamond[]; - /** ReservedRange end. */ -end: number; + /** CSGetShopRes vips. */ +vips: cs.IVip[]; - /** - * Creates a new ReservedRange instance using the specified properties. - * @param [properties] Properties to set - * @returns ReservedRange instance - */ -static create(properties?: google.protobuf.DescriptorProto.IReservedRange): google.protobuf.DescriptorProto.ReservedRange; + /** + * Creates a new CSGetShopRes instance using the specified properties. + * @param [properties] Properties to set + * @returns CSGetShopRes instance + */ +static create(properties?: cs.ICSGetShopRes): cs.CSGetShopRes; - /** - * Encodes the specified ReservedRange message. Does not implicitly {@link google.protobuf.DescriptorProto.ReservedRange.verify|verify} messages. - * @param message ReservedRange message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.DescriptorProto.IReservedRange, writer?: $protobuf.Writer): $protobuf.Writer; + /** + * Encodes the specified CSGetShopRes message. Does not implicitly {@link cs.CSGetShopRes.verify|verify} messages. + * @param message CSGetShopRes message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encode(message: cs.ICSGetShopRes, writer?: $protobuf.Writer): $protobuf.Writer; - /** - * Encodes the specified ReservedRange message, length delimited. Does not implicitly {@link google.protobuf.DescriptorProto.ReservedRange.verify|verify} messages. - * @param message ReservedRange message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.DescriptorProto.IReservedRange, writer?: $protobuf.Writer): $protobuf.Writer; + /** + * Encodes the specified CSGetShopRes message, length delimited. Does not implicitly {@link cs.CSGetShopRes.verify|verify} messages. + * @param message CSGetShopRes message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encodeDelimited(message: cs.ICSGetShopRes, writer?: $protobuf.Writer): $protobuf.Writer; - /** - * Decodes a ReservedRange message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns ReservedRange - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.DescriptorProto.ReservedRange; + /** + * Decodes a CSGetShopRes message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns CSGetShopRes + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): cs.CSGetShopRes; - /** - * Decodes a ReservedRange message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns ReservedRange - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.DescriptorProto.ReservedRange; + /** + * Decodes a CSGetShopRes message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns CSGetShopRes + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): cs.CSGetShopRes; - /** - * Verifies a ReservedRange message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ + /** + * Verifies a CSGetShopRes message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ static verify(message: { [k: string]: any }): (string|null); - /** - * Creates a ReservedRange message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns ReservedRange - */ -static fromObject(object: { [k: string]: any }): google.protobuf.DescriptorProto.ReservedRange; + /** + * Creates a CSGetShopRes message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns CSGetShopRes + */ +static fromObject(object: { [k: string]: any }): cs.CSGetShopRes; - /** - * Creates a plain object from a ReservedRange message. Also converts values to other types if specified. - * @param message ReservedRange - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.DescriptorProto.ReservedRange, options?: $protobuf.IConversionOptions): { [k: string]: any }; + /** + * Creates a plain object from a CSGetShopRes message. Also converts values to other types if specified. + * @param message CSGetShopRes + * @param [options] Conversion options + * @returns Plain object + */ +static toObject(message: cs.CSGetShopRes, options?: $protobuf.IConversionOptions): { [k: string]: any }; - /** - * Converts this ReservedRange to JSON. - * @returns JSON object - */ + /** + * Converts this CSGetShopRes to JSON. + * @returns JSON object + */ toJSON(): { [k: string]: any }; - /** - * Gets the default type url for ReservedRange - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ + /** + * Gets the default type url for CSGetShopRes + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ static getTypeUrl(typeUrlPrefix?: string): string; - } - } + } - /** Properties of an ExtensionRangeOptions. */ - interface IExtensionRangeOptions { + /** Properties of a CSBuyChatReq. */ + interface ICSBuyChatReq { - /** ExtensionRangeOptions uninterpretedOption */ - uninterpretedOption?: (google.protobuf.IUninterpretedOption[]|null); + /** CSBuyChatReq girlId */ + girlId?: (number|null); - /** ExtensionRangeOptions declaration */ - declaration?: (google.protobuf.ExtensionRangeOptions.IDeclaration[]|null); + /** CSBuyChatReq times */ + times?: (number|null); + } - /** ExtensionRangeOptions features */ - features?: (google.protobuf.IFeatureSet|null); + /** Represents a CSBuyChatReq. */ + class CSBuyChatReq implements ICSBuyChatReq { - /** ExtensionRangeOptions verification */ - verification?: (google.protobuf.ExtensionRangeOptions.VerificationState|null); - } + /** + * Constructs a new CSBuyChatReq. + * @param [properties] Properties to set + */ + constructor(properties?: cs.ICSBuyChatReq); - /** Represents an ExtensionRangeOptions. */ - class ExtensionRangeOptions implements IExtensionRangeOptions { + /** CSBuyChatReq girlId. */ +girlId: number; - /** - * Constructs a new ExtensionRangeOptions. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.IExtensionRangeOptions); + /** CSBuyChatReq times. */ +times: number; - /** ExtensionRangeOptions uninterpretedOption. */ -uninterpretedOption: google.protobuf.IUninterpretedOption[]; + /** + * Creates a new CSBuyChatReq instance using the specified properties. + * @param [properties] Properties to set + * @returns CSBuyChatReq instance + */ +static create(properties?: cs.ICSBuyChatReq): cs.CSBuyChatReq; - /** ExtensionRangeOptions declaration. */ -declaration: google.protobuf.ExtensionRangeOptions.IDeclaration[]; + /** + * Encodes the specified CSBuyChatReq message. Does not implicitly {@link cs.CSBuyChatReq.verify|verify} messages. + * @param message CSBuyChatReq message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encode(message: cs.ICSBuyChatReq, writer?: $protobuf.Writer): $protobuf.Writer; - /** ExtensionRangeOptions features. */ -features?: (google.protobuf.IFeatureSet|null); + /** + * Encodes the specified CSBuyChatReq message, length delimited. Does not implicitly {@link cs.CSBuyChatReq.verify|verify} messages. + * @param message CSBuyChatReq message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encodeDelimited(message: cs.ICSBuyChatReq, writer?: $protobuf.Writer): $protobuf.Writer; - /** ExtensionRangeOptions verification. */ -verification: google.protobuf.ExtensionRangeOptions.VerificationState; + /** + * Decodes a CSBuyChatReq message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns CSBuyChatReq + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): cs.CSBuyChatReq; - /** - * Creates a new ExtensionRangeOptions instance using the specified properties. - * @param [properties] Properties to set - * @returns ExtensionRangeOptions instance - */ -static create(properties?: google.protobuf.IExtensionRangeOptions): google.protobuf.ExtensionRangeOptions; + /** + * Decodes a CSBuyChatReq message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns CSBuyChatReq + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): cs.CSBuyChatReq; - /** - * Encodes the specified ExtensionRangeOptions message. Does not implicitly {@link google.protobuf.ExtensionRangeOptions.verify|verify} messages. - * @param message ExtensionRangeOptions message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.IExtensionRangeOptions, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified ExtensionRangeOptions message, length delimited. Does not implicitly {@link google.protobuf.ExtensionRangeOptions.verify|verify} messages. - * @param message ExtensionRangeOptions message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.IExtensionRangeOptions, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes an ExtensionRangeOptions message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns ExtensionRangeOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.ExtensionRangeOptions; - - /** - * Decodes an ExtensionRangeOptions message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns ExtensionRangeOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.ExtensionRangeOptions; - - /** - * Verifies an ExtensionRangeOptions message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ + /** + * Verifies a CSBuyChatReq message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ static verify(message: { [k: string]: any }): (string|null); - /** - * Creates an ExtensionRangeOptions message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns ExtensionRangeOptions - */ -static fromObject(object: { [k: string]: any }): google.protobuf.ExtensionRangeOptions; + /** + * Creates a CSBuyChatReq message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns CSBuyChatReq + */ +static fromObject(object: { [k: string]: any }): cs.CSBuyChatReq; - /** - * Creates a plain object from an ExtensionRangeOptions message. Also converts values to other types if specified. - * @param message ExtensionRangeOptions - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.ExtensionRangeOptions, options?: $protobuf.IConversionOptions): { [k: string]: any }; + /** + * Creates a plain object from a CSBuyChatReq message. Also converts values to other types if specified. + * @param message CSBuyChatReq + * @param [options] Conversion options + * @returns Plain object + */ +static toObject(message: cs.CSBuyChatReq, options?: $protobuf.IConversionOptions): { [k: string]: any }; - /** - * Converts this ExtensionRangeOptions to JSON. - * @returns JSON object - */ + /** + * Converts this CSBuyChatReq to JSON. + * @returns JSON object + */ toJSON(): { [k: string]: any }; - /** - * Gets the default type url for ExtensionRangeOptions - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ + /** + * Gets the default type url for CSBuyChatReq + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ static getTypeUrl(typeUrlPrefix?: string): string; - } + } - namespace ExtensionRangeOptions { + /** Properties of a CSBuyChatRes. */ + interface ICSBuyChatRes { + } - /** Properties of a Declaration. */ - interface IDeclaration { + /** Represents a CSBuyChatRes. */ + class CSBuyChatRes implements ICSBuyChatRes { - /** Declaration number */ - number?: (number|null); + /** + * Constructs a new CSBuyChatRes. + * @param [properties] Properties to set + */ + constructor(properties?: cs.ICSBuyChatRes); - /** Declaration fullName */ - fullName?: (string|null); + /** + * Creates a new CSBuyChatRes instance using the specified properties. + * @param [properties] Properties to set + * @returns CSBuyChatRes instance + */ +static create(properties?: cs.ICSBuyChatRes): cs.CSBuyChatRes; - /** Declaration type */ - type?: (string|null); + /** + * Encodes the specified CSBuyChatRes message. Does not implicitly {@link cs.CSBuyChatRes.verify|verify} messages. + * @param message CSBuyChatRes message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encode(message: cs.ICSBuyChatRes, writer?: $protobuf.Writer): $protobuf.Writer; - /** Declaration reserved */ - reserved?: (boolean|null); + /** + * Encodes the specified CSBuyChatRes message, length delimited. Does not implicitly {@link cs.CSBuyChatRes.verify|verify} messages. + * @param message CSBuyChatRes message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encodeDelimited(message: cs.ICSBuyChatRes, writer?: $protobuf.Writer): $protobuf.Writer; - /** Declaration repeated */ - repeated?: (boolean|null); - } + /** + * Decodes a CSBuyChatRes message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns CSBuyChatRes + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): cs.CSBuyChatRes; - /** Represents a Declaration. */ - class Declaration implements IDeclaration { + /** + * Decodes a CSBuyChatRes message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns CSBuyChatRes + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): cs.CSBuyChatRes; - /** - * Constructs a new Declaration. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.ExtensionRangeOptions.IDeclaration); - - /** Declaration number. */ -number: number; - - /** Declaration fullName. */ -fullName: string; - - /** Declaration type. */ -type: string; - - /** Declaration reserved. */ -reserved: boolean; - - /** Declaration repeated. */ -repeated: boolean; - - /** - * Creates a new Declaration instance using the specified properties. - * @param [properties] Properties to set - * @returns Declaration instance - */ -static create(properties?: google.protobuf.ExtensionRangeOptions.IDeclaration): google.protobuf.ExtensionRangeOptions.Declaration; - - /** - * Encodes the specified Declaration message. Does not implicitly {@link google.protobuf.ExtensionRangeOptions.Declaration.verify|verify} messages. - * @param message Declaration message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.ExtensionRangeOptions.IDeclaration, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified Declaration message, length delimited. Does not implicitly {@link google.protobuf.ExtensionRangeOptions.Declaration.verify|verify} messages. - * @param message Declaration message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.ExtensionRangeOptions.IDeclaration, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes a Declaration message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns Declaration - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.ExtensionRangeOptions.Declaration; - - /** - * Decodes a Declaration message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns Declaration - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.ExtensionRangeOptions.Declaration; - - /** - * Verifies a Declaration message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ + /** + * Verifies a CSBuyChatRes message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ static verify(message: { [k: string]: any }): (string|null); - /** - * Creates a Declaration message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns Declaration - */ -static fromObject(object: { [k: string]: any }): google.protobuf.ExtensionRangeOptions.Declaration; + /** + * Creates a CSBuyChatRes message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns CSBuyChatRes + */ +static fromObject(object: { [k: string]: any }): cs.CSBuyChatRes; - /** - * Creates a plain object from a Declaration message. Also converts values to other types if specified. - * @param message Declaration - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.ExtensionRangeOptions.Declaration, options?: $protobuf.IConversionOptions): { [k: string]: any }; + /** + * Creates a plain object from a CSBuyChatRes message. Also converts values to other types if specified. + * @param message CSBuyChatRes + * @param [options] Conversion options + * @returns Plain object + */ +static toObject(message: cs.CSBuyChatRes, options?: $protobuf.IConversionOptions): { [k: string]: any }; - /** - * Converts this Declaration to JSON. - * @returns JSON object - */ + /** + * Converts this CSBuyChatRes to JSON. + * @returns JSON object + */ toJSON(): { [k: string]: any }; - /** - * Gets the default type url for Declaration - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ + /** + * Gets the default type url for CSBuyChatRes + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ static getTypeUrl(typeUrlPrefix?: string): string; - } + } - /** VerificationState enum. */ - enum VerificationState { - DECLARATION = 0, - UNVERIFIED = 1 - } - } + /** Properties of a CSCreateOrderReq. */ + interface ICSCreateOrderReq { - /** Properties of a FieldDescriptorProto. */ - interface IFieldDescriptorProto { + /** CSCreateOrderReq id */ + id?: (number|null); + } - /** FieldDescriptorProto name */ - name?: (string|null); + /** Represents a CSCreateOrderReq. */ + class CSCreateOrderReq implements ICSCreateOrderReq { - /** FieldDescriptorProto number */ - number?: (number|null); + /** + * Constructs a new CSCreateOrderReq. + * @param [properties] Properties to set + */ + constructor(properties?: cs.ICSCreateOrderReq); - /** FieldDescriptorProto label */ - label?: (google.protobuf.FieldDescriptorProto.Label|null); + /** CSCreateOrderReq id. */ +id: number; - /** FieldDescriptorProto type */ - type?: (google.protobuf.FieldDescriptorProto.Type|null); + /** + * Creates a new CSCreateOrderReq instance using the specified properties. + * @param [properties] Properties to set + * @returns CSCreateOrderReq instance + */ +static create(properties?: cs.ICSCreateOrderReq): cs.CSCreateOrderReq; - /** FieldDescriptorProto typeName */ - typeName?: (string|null); + /** + * Encodes the specified CSCreateOrderReq message. Does not implicitly {@link cs.CSCreateOrderReq.verify|verify} messages. + * @param message CSCreateOrderReq message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encode(message: cs.ICSCreateOrderReq, writer?: $protobuf.Writer): $protobuf.Writer; - /** FieldDescriptorProto extendee */ - extendee?: (string|null); + /** + * Encodes the specified CSCreateOrderReq message, length delimited. Does not implicitly {@link cs.CSCreateOrderReq.verify|verify} messages. + * @param message CSCreateOrderReq message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encodeDelimited(message: cs.ICSCreateOrderReq, writer?: $protobuf.Writer): $protobuf.Writer; - /** FieldDescriptorProto defaultValue */ - defaultValue?: (string|null); + /** + * Decodes a CSCreateOrderReq message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns CSCreateOrderReq + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): cs.CSCreateOrderReq; - /** FieldDescriptorProto oneofIndex */ - oneofIndex?: (number|null); + /** + * Decodes a CSCreateOrderReq message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns CSCreateOrderReq + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): cs.CSCreateOrderReq; - /** FieldDescriptorProto jsonName */ - jsonName?: (string|null); + /** + * Verifies a CSCreateOrderReq message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ +static verify(message: { [k: string]: any }): (string|null); - /** FieldDescriptorProto options */ - options?: (google.protobuf.IFieldOptions|null); + /** + * Creates a CSCreateOrderReq message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns CSCreateOrderReq + */ +static fromObject(object: { [k: string]: any }): cs.CSCreateOrderReq; - /** FieldDescriptorProto proto3Optional */ - proto3Optional?: (boolean|null); - } + /** + * Creates a plain object from a CSCreateOrderReq message. Also converts values to other types if specified. + * @param message CSCreateOrderReq + * @param [options] Conversion options + * @returns Plain object + */ +static toObject(message: cs.CSCreateOrderReq, options?: $protobuf.IConversionOptions): { [k: string]: any }; - /** Represents a FieldDescriptorProto. */ - class FieldDescriptorProto implements IFieldDescriptorProto { + /** + * Converts this CSCreateOrderReq to JSON. + * @returns JSON object + */ +toJSON(): { [k: string]: any }; - /** - * Constructs a new FieldDescriptorProto. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.IFieldDescriptorProto); + /** + * Gets the default type url for CSCreateOrderReq + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ +static getTypeUrl(typeUrlPrefix?: string): string; + } - /** FieldDescriptorProto name. */ + /** Properties of a CSCreateOrderRes. */ + interface ICSCreateOrderRes { + + /** CSCreateOrderRes payUrl */ + payUrl?: (string|null); + } + + /** Represents a CSCreateOrderRes. */ + class CSCreateOrderRes implements ICSCreateOrderRes { + + /** + * Constructs a new CSCreateOrderRes. + * @param [properties] Properties to set + */ + constructor(properties?: cs.ICSCreateOrderRes); + + /** CSCreateOrderRes payUrl. */ +payUrl: string; + + /** + * Creates a new CSCreateOrderRes instance using the specified properties. + * @param [properties] Properties to set + * @returns CSCreateOrderRes instance + */ +static create(properties?: cs.ICSCreateOrderRes): cs.CSCreateOrderRes; + + /** + * Encodes the specified CSCreateOrderRes message. Does not implicitly {@link cs.CSCreateOrderRes.verify|verify} messages. + * @param message CSCreateOrderRes message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encode(message: cs.ICSCreateOrderRes, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified CSCreateOrderRes message, length delimited. Does not implicitly {@link cs.CSCreateOrderRes.verify|verify} messages. + * @param message CSCreateOrderRes message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encodeDelimited(message: cs.ICSCreateOrderRes, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a CSCreateOrderRes message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns CSCreateOrderRes + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): cs.CSCreateOrderRes; + + /** + * Decodes a CSCreateOrderRes message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns CSCreateOrderRes + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): cs.CSCreateOrderRes; + + /** + * Verifies a CSCreateOrderRes message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ +static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a CSCreateOrderRes message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns CSCreateOrderRes + */ +static fromObject(object: { [k: string]: any }): cs.CSCreateOrderRes; + + /** + * Creates a plain object from a CSCreateOrderRes message. Also converts values to other types if specified. + * @param message CSCreateOrderRes + * @param [options] Conversion options + * @returns Plain object + */ +static toObject(message: cs.CSCreateOrderRes, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this CSCreateOrderRes to JSON. + * @returns JSON object + */ +toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for CSCreateOrderRes + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ +static getTypeUrl(typeUrlPrefix?: string): string; + } + + /** Properties of a CSLoginReq. */ + interface ICSLoginReq { + + /** CSLoginReq platType */ + platType?: (string|null); + + /** CSLoginReq userId */ + userId?: (string|null); + + /** CSLoginReq device */ + device?: (string|null); + + /** CSLoginReq os */ + os?: (number|null); + } + + /** Represents a CSLoginReq. */ + class CSLoginReq implements ICSLoginReq { + + /** + * Constructs a new CSLoginReq. + * @param [properties] Properties to set + */ + constructor(properties?: cs.ICSLoginReq); + + /** CSLoginReq platType. */ +platType: string; + + /** CSLoginReq userId. */ +userId: string; + + /** CSLoginReq device. */ +device: string; + + /** CSLoginReq os. */ +os: number; + + /** + * Creates a new CSLoginReq instance using the specified properties. + * @param [properties] Properties to set + * @returns CSLoginReq instance + */ +static create(properties?: cs.ICSLoginReq): cs.CSLoginReq; + + /** + * Encodes the specified CSLoginReq message. Does not implicitly {@link cs.CSLoginReq.verify|verify} messages. + * @param message CSLoginReq message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encode(message: cs.ICSLoginReq, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified CSLoginReq message, length delimited. Does not implicitly {@link cs.CSLoginReq.verify|verify} messages. + * @param message CSLoginReq message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encodeDelimited(message: cs.ICSLoginReq, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a CSLoginReq message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns CSLoginReq + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): cs.CSLoginReq; + + /** + * Decodes a CSLoginReq message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns CSLoginReq + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): cs.CSLoginReq; + + /** + * Verifies a CSLoginReq message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ +static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a CSLoginReq message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns CSLoginReq + */ +static fromObject(object: { [k: string]: any }): cs.CSLoginReq; + + /** + * Creates a plain object from a CSLoginReq message. Also converts values to other types if specified. + * @param message CSLoginReq + * @param [options] Conversion options + * @returns Plain object + */ +static toObject(message: cs.CSLoginReq, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this CSLoginReq to JSON. + * @returns JSON object + */ +toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for CSLoginReq + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ +static getTypeUrl(typeUrlPrefix?: string): string; + } + + /** Properties of a CSLoginRes. */ + interface ICSLoginRes { + + /** CSLoginRes name */ + name?: (string|null); + + /** CSLoginRes token */ + token?: (string|null); + + /** CSLoginRes refreshToken */ + refreshToken?: (string|null); + + /** CSLoginRes expire */ + expire?: (number|Long|null); + } + + /** Represents a CSLoginRes. */ + class CSLoginRes implements ICSLoginRes { + + /** + * Constructs a new CSLoginRes. + * @param [properties] Properties to set + */ + constructor(properties?: cs.ICSLoginRes); + + /** CSLoginRes name. */ name: string; - /** FieldDescriptorProto number. */ -number: number; + /** CSLoginRes token. */ +token: string; - /** FieldDescriptorProto label. */ -label: google.protobuf.FieldDescriptorProto.Label; + /** CSLoginRes refreshToken. */ +refreshToken: string; - /** FieldDescriptorProto type. */ -type: google.protobuf.FieldDescriptorProto.Type; + /** CSLoginRes expire. */ +expire: (number|Long); - /** FieldDescriptorProto typeName. */ -typeName: string; + /** + * Creates a new CSLoginRes instance using the specified properties. + * @param [properties] Properties to set + * @returns CSLoginRes instance + */ +static create(properties?: cs.ICSLoginRes): cs.CSLoginRes; - /** FieldDescriptorProto extendee. */ -extendee: string; + /** + * Encodes the specified CSLoginRes message. Does not implicitly {@link cs.CSLoginRes.verify|verify} messages. + * @param message CSLoginRes message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encode(message: cs.ICSLoginRes, writer?: $protobuf.Writer): $protobuf.Writer; - /** FieldDescriptorProto defaultValue. */ -defaultValue: string; + /** + * Encodes the specified CSLoginRes message, length delimited. Does not implicitly {@link cs.CSLoginRes.verify|verify} messages. + * @param message CSLoginRes message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encodeDelimited(message: cs.ICSLoginRes, writer?: $protobuf.Writer): $protobuf.Writer; - /** FieldDescriptorProto oneofIndex. */ -oneofIndex: number; + /** + * Decodes a CSLoginRes message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns CSLoginRes + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): cs.CSLoginRes; - /** FieldDescriptorProto jsonName. */ -jsonName: string; + /** + * Decodes a CSLoginRes message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns CSLoginRes + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): cs.CSLoginRes; - /** FieldDescriptorProto options. */ -options?: (google.protobuf.IFieldOptions|null); - - /** FieldDescriptorProto proto3Optional. */ -proto3Optional: boolean; - - /** - * Creates a new FieldDescriptorProto instance using the specified properties. - * @param [properties] Properties to set - * @returns FieldDescriptorProto instance - */ -static create(properties?: google.protobuf.IFieldDescriptorProto): google.protobuf.FieldDescriptorProto; - - /** - * Encodes the specified FieldDescriptorProto message. Does not implicitly {@link google.protobuf.FieldDescriptorProto.verify|verify} messages. - * @param message FieldDescriptorProto message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.IFieldDescriptorProto, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified FieldDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.FieldDescriptorProto.verify|verify} messages. - * @param message FieldDescriptorProto message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.IFieldDescriptorProto, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes a FieldDescriptorProto message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns FieldDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.FieldDescriptorProto; - - /** - * Decodes a FieldDescriptorProto message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns FieldDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.FieldDescriptorProto; - - /** - * Verifies a FieldDescriptorProto message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ + /** + * Verifies a CSLoginRes message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ static verify(message: { [k: string]: any }): (string|null); - /** - * Creates a FieldDescriptorProto message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns FieldDescriptorProto - */ -static fromObject(object: { [k: string]: any }): google.protobuf.FieldDescriptorProto; + /** + * Creates a CSLoginRes message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns CSLoginRes + */ +static fromObject(object: { [k: string]: any }): cs.CSLoginRes; - /** - * Creates a plain object from a FieldDescriptorProto message. Also converts values to other types if specified. - * @param message FieldDescriptorProto - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.FieldDescriptorProto, options?: $protobuf.IConversionOptions): { [k: string]: any }; + /** + * Creates a plain object from a CSLoginRes message. Also converts values to other types if specified. + * @param message CSLoginRes + * @param [options] Conversion options + * @returns Plain object + */ +static toObject(message: cs.CSLoginRes, options?: $protobuf.IConversionOptions): { [k: string]: any }; - /** - * Converts this FieldDescriptorProto to JSON. - * @returns JSON object - */ + /** + * Converts this CSLoginRes to JSON. + * @returns JSON object + */ toJSON(): { [k: string]: any }; - /** - * Gets the default type url for FieldDescriptorProto - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ + /** + * Gets the default type url for CSLoginRes + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ static getTypeUrl(typeUrlPrefix?: string): string; - } + } - namespace FieldDescriptorProto { + /** Properties of a CSMyInfoReq. */ + interface ICSMyInfoReq { + } - /** Type enum. */ - enum Type { - TYPE_DOUBLE = 1, - TYPE_FLOAT = 2, - TYPE_INT64 = 3, - TYPE_UINT64 = 4, - TYPE_INT32 = 5, - TYPE_FIXED64 = 6, - TYPE_FIXED32 = 7, - TYPE_BOOL = 8, - TYPE_STRING = 9, - TYPE_GROUP = 10, - TYPE_MESSAGE = 11, - TYPE_BYTES = 12, - TYPE_UINT32 = 13, - TYPE_ENUM = 14, - TYPE_SFIXED32 = 15, - TYPE_SFIXED64 = 16, - TYPE_SINT32 = 17, - TYPE_SINT64 = 18 - } + /** Represents a CSMyInfoReq. */ + class CSMyInfoReq implements ICSMyInfoReq { - /** Label enum. */ - enum Label { - LABEL_OPTIONAL = 1, - LABEL_REPEATED = 3, - LABEL_REQUIRED = 2 - } - } + /** + * Constructs a new CSMyInfoReq. + * @param [properties] Properties to set + */ + constructor(properties?: cs.ICSMyInfoReq); - /** Properties of an OneofDescriptorProto. */ - interface IOneofDescriptorProto { + /** + * Creates a new CSMyInfoReq instance using the specified properties. + * @param [properties] Properties to set + * @returns CSMyInfoReq instance + */ +static create(properties?: cs.ICSMyInfoReq): cs.CSMyInfoReq; - /** OneofDescriptorProto name */ - name?: (string|null); + /** + * Encodes the specified CSMyInfoReq message. Does not implicitly {@link cs.CSMyInfoReq.verify|verify} messages. + * @param message CSMyInfoReq message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encode(message: cs.ICSMyInfoReq, writer?: $protobuf.Writer): $protobuf.Writer; - /** OneofDescriptorProto options */ - options?: (google.protobuf.IOneofOptions|null); - } + /** + * Encodes the specified CSMyInfoReq message, length delimited. Does not implicitly {@link cs.CSMyInfoReq.verify|verify} messages. + * @param message CSMyInfoReq message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encodeDelimited(message: cs.ICSMyInfoReq, writer?: $protobuf.Writer): $protobuf.Writer; - /** Represents an OneofDescriptorProto. */ - class OneofDescriptorProto implements IOneofDescriptorProto { + /** + * Decodes a CSMyInfoReq message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns CSMyInfoReq + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): cs.CSMyInfoReq; - /** - * Constructs a new OneofDescriptorProto. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.IOneofDescriptorProto); + /** + * Decodes a CSMyInfoReq message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns CSMyInfoReq + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): cs.CSMyInfoReq; - /** OneofDescriptorProto name. */ -name: string; - - /** OneofDescriptorProto options. */ -options?: (google.protobuf.IOneofOptions|null); - - /** - * Creates a new OneofDescriptorProto instance using the specified properties. - * @param [properties] Properties to set - * @returns OneofDescriptorProto instance - */ -static create(properties?: google.protobuf.IOneofDescriptorProto): google.protobuf.OneofDescriptorProto; - - /** - * Encodes the specified OneofDescriptorProto message. Does not implicitly {@link google.protobuf.OneofDescriptorProto.verify|verify} messages. - * @param message OneofDescriptorProto message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.IOneofDescriptorProto, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified OneofDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.OneofDescriptorProto.verify|verify} messages. - * @param message OneofDescriptorProto message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.IOneofDescriptorProto, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes an OneofDescriptorProto message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns OneofDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.OneofDescriptorProto; - - /** - * Decodes an OneofDescriptorProto message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns OneofDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.OneofDescriptorProto; - - /** - * Verifies an OneofDescriptorProto message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ + /** + * Verifies a CSMyInfoReq message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ static verify(message: { [k: string]: any }): (string|null); - /** - * Creates an OneofDescriptorProto message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns OneofDescriptorProto - */ -static fromObject(object: { [k: string]: any }): google.protobuf.OneofDescriptorProto; + /** + * Creates a CSMyInfoReq message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns CSMyInfoReq + */ +static fromObject(object: { [k: string]: any }): cs.CSMyInfoReq; - /** - * Creates a plain object from an OneofDescriptorProto message. Also converts values to other types if specified. - * @param message OneofDescriptorProto - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.OneofDescriptorProto, options?: $protobuf.IConversionOptions): { [k: string]: any }; + /** + * Creates a plain object from a CSMyInfoReq message. Also converts values to other types if specified. + * @param message CSMyInfoReq + * @param [options] Conversion options + * @returns Plain object + */ +static toObject(message: cs.CSMyInfoReq, options?: $protobuf.IConversionOptions): { [k: string]: any }; - /** - * Converts this OneofDescriptorProto to JSON. - * @returns JSON object - */ + /** + * Converts this CSMyInfoReq to JSON. + * @returns JSON object + */ toJSON(): { [k: string]: any }; - /** - * Gets the default type url for OneofDescriptorProto - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ + /** + * Gets the default type url for CSMyInfoReq + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ static getTypeUrl(typeUrlPrefix?: string): string; - } + } - /** Properties of an EnumDescriptorProto. */ - interface IEnumDescriptorProto { + /** Properties of a CSMyInfoRes. */ + interface ICSMyInfoRes { - /** EnumDescriptorProto name */ - name?: (string|null); + /** CSMyInfoRes diamond */ + diamond?: (number|Long|null); - /** EnumDescriptorProto value */ - value?: (google.protobuf.IEnumValueDescriptorProto[]|null); + /** CSMyInfoRes vipExpire */ + vipExpire?: (number|Long|null); + } - /** EnumDescriptorProto options */ - options?: (google.protobuf.IEnumOptions|null); + /** Represents a CSMyInfoRes. */ + class CSMyInfoRes implements ICSMyInfoRes { - /** EnumDescriptorProto reservedRange */ - reservedRange?: (google.protobuf.EnumDescriptorProto.IEnumReservedRange[]|null); + /** + * Constructs a new CSMyInfoRes. + * @param [properties] Properties to set + */ + constructor(properties?: cs.ICSMyInfoRes); - /** EnumDescriptorProto reservedName */ - reservedName?: (string[]|null); + /** CSMyInfoRes diamond. */ +diamond: (number|Long); - /** EnumDescriptorProto visibility */ - visibility?: (google.protobuf.SymbolVisibility|null); - } + /** CSMyInfoRes vipExpire. */ +vipExpire: (number|Long); - /** Represents an EnumDescriptorProto. */ - class EnumDescriptorProto implements IEnumDescriptorProto { + /** + * Creates a new CSMyInfoRes instance using the specified properties. + * @param [properties] Properties to set + * @returns CSMyInfoRes instance + */ +static create(properties?: cs.ICSMyInfoRes): cs.CSMyInfoRes; - /** - * Constructs a new EnumDescriptorProto. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.IEnumDescriptorProto); + /** + * Encodes the specified CSMyInfoRes message. Does not implicitly {@link cs.CSMyInfoRes.verify|verify} messages. + * @param message CSMyInfoRes message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encode(message: cs.ICSMyInfoRes, writer?: $protobuf.Writer): $protobuf.Writer; - /** EnumDescriptorProto name. */ -name: string; + /** + * Encodes the specified CSMyInfoRes message, length delimited. Does not implicitly {@link cs.CSMyInfoRes.verify|verify} messages. + * @param message CSMyInfoRes message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ +static encodeDelimited(message: cs.ICSMyInfoRes, writer?: $protobuf.Writer): $protobuf.Writer; - /** EnumDescriptorProto value. */ -value: google.protobuf.IEnumValueDescriptorProto[]; + /** + * Decodes a CSMyInfoRes message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns CSMyInfoRes + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): cs.CSMyInfoRes; - /** EnumDescriptorProto options. */ -options?: (google.protobuf.IEnumOptions|null); + /** + * Decodes a CSMyInfoRes message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns CSMyInfoRes + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ +static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): cs.CSMyInfoRes; - /** EnumDescriptorProto reservedRange. */ -reservedRange: google.protobuf.EnumDescriptorProto.IEnumReservedRange[]; - - /** EnumDescriptorProto reservedName. */ -reservedName: string[]; - - /** EnumDescriptorProto visibility. */ -visibility: google.protobuf.SymbolVisibility; - - /** - * Creates a new EnumDescriptorProto instance using the specified properties. - * @param [properties] Properties to set - * @returns EnumDescriptorProto instance - */ -static create(properties?: google.protobuf.IEnumDescriptorProto): google.protobuf.EnumDescriptorProto; - - /** - * Encodes the specified EnumDescriptorProto message. Does not implicitly {@link google.protobuf.EnumDescriptorProto.verify|verify} messages. - * @param message EnumDescriptorProto message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.IEnumDescriptorProto, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified EnumDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.EnumDescriptorProto.verify|verify} messages. - * @param message EnumDescriptorProto message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.IEnumDescriptorProto, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes an EnumDescriptorProto message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns EnumDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.EnumDescriptorProto; - - /** - * Decodes an EnumDescriptorProto message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns EnumDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.EnumDescriptorProto; - - /** - * Verifies an EnumDescriptorProto message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ + /** + * Verifies a CSMyInfoRes message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ static verify(message: { [k: string]: any }): (string|null); - /** - * Creates an EnumDescriptorProto message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns EnumDescriptorProto - */ -static fromObject(object: { [k: string]: any }): google.protobuf.EnumDescriptorProto; + /** + * Creates a CSMyInfoRes message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns CSMyInfoRes + */ +static fromObject(object: { [k: string]: any }): cs.CSMyInfoRes; - /** - * Creates a plain object from an EnumDescriptorProto message. Also converts values to other types if specified. - * @param message EnumDescriptorProto - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.EnumDescriptorProto, options?: $protobuf.IConversionOptions): { [k: string]: any }; + /** + * Creates a plain object from a CSMyInfoRes message. Also converts values to other types if specified. + * @param message CSMyInfoRes + * @param [options] Conversion options + * @returns Plain object + */ +static toObject(message: cs.CSMyInfoRes, options?: $protobuf.IConversionOptions): { [k: string]: any }; - /** - * Converts this EnumDescriptorProto to JSON. - * @returns JSON object - */ + /** + * Converts this CSMyInfoRes to JSON. + * @returns JSON object + */ toJSON(): { [k: string]: any }; - /** - * Gets the default type url for EnumDescriptorProto - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ + /** + * Gets the default type url for CSMyInfoRes + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ static getTypeUrl(typeUrlPrefix?: string): string; - } - - namespace EnumDescriptorProto { - - /** Properties of an EnumReservedRange. */ - interface IEnumReservedRange { - - /** EnumReservedRange start */ - start?: (number|null); - - /** EnumReservedRange end */ - end?: (number|null); - } - - /** Represents an EnumReservedRange. */ - class EnumReservedRange implements IEnumReservedRange { - - /** - * Constructs a new EnumReservedRange. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.EnumDescriptorProto.IEnumReservedRange); - - /** EnumReservedRange start. */ -start: number; - - /** EnumReservedRange end. */ -end: number; - - /** - * Creates a new EnumReservedRange instance using the specified properties. - * @param [properties] Properties to set - * @returns EnumReservedRange instance - */ -static create(properties?: google.protobuf.EnumDescriptorProto.IEnumReservedRange): google.protobuf.EnumDescriptorProto.EnumReservedRange; - - /** - * Encodes the specified EnumReservedRange message. Does not implicitly {@link google.protobuf.EnumDescriptorProto.EnumReservedRange.verify|verify} messages. - * @param message EnumReservedRange message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.EnumDescriptorProto.IEnumReservedRange, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified EnumReservedRange message, length delimited. Does not implicitly {@link google.protobuf.EnumDescriptorProto.EnumReservedRange.verify|verify} messages. - * @param message EnumReservedRange message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.EnumDescriptorProto.IEnumReservedRange, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes an EnumReservedRange message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns EnumReservedRange - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.EnumDescriptorProto.EnumReservedRange; - - /** - * Decodes an EnumReservedRange message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns EnumReservedRange - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.EnumDescriptorProto.EnumReservedRange; - - /** - * Verifies an EnumReservedRange message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ -static verify(message: { [k: string]: any }): (string|null); - - /** - * Creates an EnumReservedRange message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns EnumReservedRange - */ -static fromObject(object: { [k: string]: any }): google.protobuf.EnumDescriptorProto.EnumReservedRange; - - /** - * Creates a plain object from an EnumReservedRange message. Also converts values to other types if specified. - * @param message EnumReservedRange - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.EnumDescriptorProto.EnumReservedRange, options?: $protobuf.IConversionOptions): { [k: string]: any }; - - /** - * Converts this EnumReservedRange to JSON. - * @returns JSON object - */ -toJSON(): { [k: string]: any }; - - /** - * Gets the default type url for EnumReservedRange - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ -static getTypeUrl(typeUrlPrefix?: string): string; - } - } - - /** Properties of an EnumValueDescriptorProto. */ - interface IEnumValueDescriptorProto { - - /** EnumValueDescriptorProto name */ - name?: (string|null); - - /** EnumValueDescriptorProto number */ - number?: (number|null); - - /** EnumValueDescriptorProto options */ - options?: (google.protobuf.IEnumValueOptions|null); - } - - /** Represents an EnumValueDescriptorProto. */ - class EnumValueDescriptorProto implements IEnumValueDescriptorProto { - - /** - * Constructs a new EnumValueDescriptorProto. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.IEnumValueDescriptorProto); - - /** EnumValueDescriptorProto name. */ -name: string; - - /** EnumValueDescriptorProto number. */ -number: number; - - /** EnumValueDescriptorProto options. */ -options?: (google.protobuf.IEnumValueOptions|null); - - /** - * Creates a new EnumValueDescriptorProto instance using the specified properties. - * @param [properties] Properties to set - * @returns EnumValueDescriptorProto instance - */ -static create(properties?: google.protobuf.IEnumValueDescriptorProto): google.protobuf.EnumValueDescriptorProto; - - /** - * Encodes the specified EnumValueDescriptorProto message. Does not implicitly {@link google.protobuf.EnumValueDescriptorProto.verify|verify} messages. - * @param message EnumValueDescriptorProto message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.IEnumValueDescriptorProto, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified EnumValueDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.EnumValueDescriptorProto.verify|verify} messages. - * @param message EnumValueDescriptorProto message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.IEnumValueDescriptorProto, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes an EnumValueDescriptorProto message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns EnumValueDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.EnumValueDescriptorProto; - - /** - * Decodes an EnumValueDescriptorProto message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns EnumValueDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.EnumValueDescriptorProto; - - /** - * Verifies an EnumValueDescriptorProto message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ -static verify(message: { [k: string]: any }): (string|null); - - /** - * Creates an EnumValueDescriptorProto message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns EnumValueDescriptorProto - */ -static fromObject(object: { [k: string]: any }): google.protobuf.EnumValueDescriptorProto; - - /** - * Creates a plain object from an EnumValueDescriptorProto message. Also converts values to other types if specified. - * @param message EnumValueDescriptorProto - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.EnumValueDescriptorProto, options?: $protobuf.IConversionOptions): { [k: string]: any }; - - /** - * Converts this EnumValueDescriptorProto to JSON. - * @returns JSON object - */ -toJSON(): { [k: string]: any }; - - /** - * Gets the default type url for EnumValueDescriptorProto - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ -static getTypeUrl(typeUrlPrefix?: string): string; - } - - /** Properties of a ServiceDescriptorProto. */ - interface IServiceDescriptorProto { - - /** ServiceDescriptorProto name */ - name?: (string|null); - - /** ServiceDescriptorProto method */ - method?: (google.protobuf.IMethodDescriptorProto[]|null); - - /** ServiceDescriptorProto options */ - options?: (google.protobuf.IServiceOptions|null); - } - - /** Represents a ServiceDescriptorProto. */ - class ServiceDescriptorProto implements IServiceDescriptorProto { - - /** - * Constructs a new ServiceDescriptorProto. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.IServiceDescriptorProto); - - /** ServiceDescriptorProto name. */ -name: string; - - /** ServiceDescriptorProto method. */ -method: google.protobuf.IMethodDescriptorProto[]; - - /** ServiceDescriptorProto options. */ -options?: (google.protobuf.IServiceOptions|null); - - /** - * Creates a new ServiceDescriptorProto instance using the specified properties. - * @param [properties] Properties to set - * @returns ServiceDescriptorProto instance - */ -static create(properties?: google.protobuf.IServiceDescriptorProto): google.protobuf.ServiceDescriptorProto; - - /** - * Encodes the specified ServiceDescriptorProto message. Does not implicitly {@link google.protobuf.ServiceDescriptorProto.verify|verify} messages. - * @param message ServiceDescriptorProto message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.IServiceDescriptorProto, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified ServiceDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.ServiceDescriptorProto.verify|verify} messages. - * @param message ServiceDescriptorProto message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.IServiceDescriptorProto, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes a ServiceDescriptorProto message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns ServiceDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.ServiceDescriptorProto; - - /** - * Decodes a ServiceDescriptorProto message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns ServiceDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.ServiceDescriptorProto; - - /** - * Verifies a ServiceDescriptorProto message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ -static verify(message: { [k: string]: any }): (string|null); - - /** - * Creates a ServiceDescriptorProto message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns ServiceDescriptorProto - */ -static fromObject(object: { [k: string]: any }): google.protobuf.ServiceDescriptorProto; - - /** - * Creates a plain object from a ServiceDescriptorProto message. Also converts values to other types if specified. - * @param message ServiceDescriptorProto - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.ServiceDescriptorProto, options?: $protobuf.IConversionOptions): { [k: string]: any }; - - /** - * Converts this ServiceDescriptorProto to JSON. - * @returns JSON object - */ -toJSON(): { [k: string]: any }; - - /** - * Gets the default type url for ServiceDescriptorProto - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ -static getTypeUrl(typeUrlPrefix?: string): string; - } - - /** Properties of a MethodDescriptorProto. */ - interface IMethodDescriptorProto { - - /** MethodDescriptorProto name */ - name?: (string|null); - - /** MethodDescriptorProto inputType */ - inputType?: (string|null); - - /** MethodDescriptorProto outputType */ - outputType?: (string|null); - - /** MethodDescriptorProto options */ - options?: (google.protobuf.IMethodOptions|null); - - /** MethodDescriptorProto clientStreaming */ - clientStreaming?: (boolean|null); - - /** MethodDescriptorProto serverStreaming */ - serverStreaming?: (boolean|null); - } - - /** Represents a MethodDescriptorProto. */ - class MethodDescriptorProto implements IMethodDescriptorProto { - - /** - * Constructs a new MethodDescriptorProto. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.IMethodDescriptorProto); - - /** MethodDescriptorProto name. */ -name: string; - - /** MethodDescriptorProto inputType. */ -inputType: string; - - /** MethodDescriptorProto outputType. */ -outputType: string; - - /** MethodDescriptorProto options. */ -options?: (google.protobuf.IMethodOptions|null); - - /** MethodDescriptorProto clientStreaming. */ -clientStreaming: boolean; - - /** MethodDescriptorProto serverStreaming. */ -serverStreaming: boolean; - - /** - * Creates a new MethodDescriptorProto instance using the specified properties. - * @param [properties] Properties to set - * @returns MethodDescriptorProto instance - */ -static create(properties?: google.protobuf.IMethodDescriptorProto): google.protobuf.MethodDescriptorProto; - - /** - * Encodes the specified MethodDescriptorProto message. Does not implicitly {@link google.protobuf.MethodDescriptorProto.verify|verify} messages. - * @param message MethodDescriptorProto message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.IMethodDescriptorProto, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified MethodDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.MethodDescriptorProto.verify|verify} messages. - * @param message MethodDescriptorProto message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.IMethodDescriptorProto, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes a MethodDescriptorProto message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns MethodDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.MethodDescriptorProto; - - /** - * Decodes a MethodDescriptorProto message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns MethodDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.MethodDescriptorProto; - - /** - * Verifies a MethodDescriptorProto message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ -static verify(message: { [k: string]: any }): (string|null); - - /** - * Creates a MethodDescriptorProto message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns MethodDescriptorProto - */ -static fromObject(object: { [k: string]: any }): google.protobuf.MethodDescriptorProto; - - /** - * Creates a plain object from a MethodDescriptorProto message. Also converts values to other types if specified. - * @param message MethodDescriptorProto - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.MethodDescriptorProto, options?: $protobuf.IConversionOptions): { [k: string]: any }; - - /** - * Converts this MethodDescriptorProto to JSON. - * @returns JSON object - */ -toJSON(): { [k: string]: any }; - - /** - * Gets the default type url for MethodDescriptorProto - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ -static getTypeUrl(typeUrlPrefix?: string): string; - } - - /** Properties of a FileOptions. */ - interface IFileOptions { - - /** FileOptions javaPackage */ - javaPackage?: (string|null); - - /** FileOptions javaOuterClassname */ - javaOuterClassname?: (string|null); - - /** FileOptions javaMultipleFiles */ - javaMultipleFiles?: (boolean|null); - - /** FileOptions javaGenerateEqualsAndHash */ - javaGenerateEqualsAndHash?: (boolean|null); - - /** FileOptions javaStringCheckUtf8 */ - javaStringCheckUtf8?: (boolean|null); - - /** FileOptions optimizeFor */ - optimizeFor?: (google.protobuf.FileOptions.OptimizeMode|null); - - /** FileOptions goPackage */ - goPackage?: (string|null); - - /** FileOptions ccGenericServices */ - ccGenericServices?: (boolean|null); - - /** FileOptions javaGenericServices */ - javaGenericServices?: (boolean|null); - - /** FileOptions pyGenericServices */ - pyGenericServices?: (boolean|null); - - /** FileOptions deprecated */ - deprecated?: (boolean|null); - - /** FileOptions ccEnableArenas */ - ccEnableArenas?: (boolean|null); - - /** FileOptions objcClassPrefix */ - objcClassPrefix?: (string|null); - - /** FileOptions csharpNamespace */ - csharpNamespace?: (string|null); - - /** FileOptions swiftPrefix */ - swiftPrefix?: (string|null); - - /** FileOptions phpClassPrefix */ - phpClassPrefix?: (string|null); - - /** FileOptions phpNamespace */ - phpNamespace?: (string|null); - - /** FileOptions phpMetadataNamespace */ - phpMetadataNamespace?: (string|null); - - /** FileOptions rubyPackage */ - rubyPackage?: (string|null); - - /** FileOptions features */ - features?: (google.protobuf.IFeatureSet|null); - - /** FileOptions uninterpretedOption */ - uninterpretedOption?: (google.protobuf.IUninterpretedOption[]|null); - } - - /** Represents a FileOptions. */ - class FileOptions implements IFileOptions { - - /** - * Constructs a new FileOptions. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.IFileOptions); - - /** FileOptions javaPackage. */ -javaPackage: string; - - /** FileOptions javaOuterClassname. */ -javaOuterClassname: string; - - /** FileOptions javaMultipleFiles. */ -javaMultipleFiles: boolean; - - /** FileOptions javaGenerateEqualsAndHash. */ -javaGenerateEqualsAndHash: boolean; - - /** FileOptions javaStringCheckUtf8. */ -javaStringCheckUtf8: boolean; - - /** FileOptions optimizeFor. */ -optimizeFor: google.protobuf.FileOptions.OptimizeMode; - - /** FileOptions goPackage. */ -goPackage: string; - - /** FileOptions ccGenericServices. */ -ccGenericServices: boolean; - - /** FileOptions javaGenericServices. */ -javaGenericServices: boolean; - - /** FileOptions pyGenericServices. */ -pyGenericServices: boolean; - - /** FileOptions deprecated. */ -deprecated: boolean; - - /** FileOptions ccEnableArenas. */ -ccEnableArenas: boolean; - - /** FileOptions objcClassPrefix. */ -objcClassPrefix: string; - - /** FileOptions csharpNamespace. */ -csharpNamespace: string; - - /** FileOptions swiftPrefix. */ -swiftPrefix: string; - - /** FileOptions phpClassPrefix. */ -phpClassPrefix: string; - - /** FileOptions phpNamespace. */ -phpNamespace: string; - - /** FileOptions phpMetadataNamespace. */ -phpMetadataNamespace: string; - - /** FileOptions rubyPackage. */ -rubyPackage: string; - - /** FileOptions features. */ -features?: (google.protobuf.IFeatureSet|null); - - /** FileOptions uninterpretedOption. */ -uninterpretedOption: google.protobuf.IUninterpretedOption[]; - - /** - * Creates a new FileOptions instance using the specified properties. - * @param [properties] Properties to set - * @returns FileOptions instance - */ -static create(properties?: google.protobuf.IFileOptions): google.protobuf.FileOptions; - - /** - * Encodes the specified FileOptions message. Does not implicitly {@link google.protobuf.FileOptions.verify|verify} messages. - * @param message FileOptions message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.IFileOptions, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified FileOptions message, length delimited. Does not implicitly {@link google.protobuf.FileOptions.verify|verify} messages. - * @param message FileOptions message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.IFileOptions, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes a FileOptions message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns FileOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.FileOptions; - - /** - * Decodes a FileOptions message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns FileOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.FileOptions; - - /** - * Verifies a FileOptions message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ -static verify(message: { [k: string]: any }): (string|null); - - /** - * Creates a FileOptions message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns FileOptions - */ -static fromObject(object: { [k: string]: any }): google.protobuf.FileOptions; - - /** - * Creates a plain object from a FileOptions message. Also converts values to other types if specified. - * @param message FileOptions - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.FileOptions, options?: $protobuf.IConversionOptions): { [k: string]: any }; - - /** - * Converts this FileOptions to JSON. - * @returns JSON object - */ -toJSON(): { [k: string]: any }; - - /** - * Gets the default type url for FileOptions - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ -static getTypeUrl(typeUrlPrefix?: string): string; - } - - namespace FileOptions { - - /** OptimizeMode enum. */ - enum OptimizeMode { - SPEED = 1, - CODE_SIZE = 2, - LITE_RUNTIME = 3 - } - } - - /** Properties of a MessageOptions. */ - interface IMessageOptions { - - /** MessageOptions messageSetWireFormat */ - messageSetWireFormat?: (boolean|null); - - /** MessageOptions noStandardDescriptorAccessor */ - noStandardDescriptorAccessor?: (boolean|null); - - /** MessageOptions deprecated */ - deprecated?: (boolean|null); - - /** MessageOptions mapEntry */ - mapEntry?: (boolean|null); - - /** MessageOptions deprecatedLegacyJsonFieldConflicts */ - deprecatedLegacyJsonFieldConflicts?: (boolean|null); - - /** MessageOptions features */ - features?: (google.protobuf.IFeatureSet|null); - - /** MessageOptions uninterpretedOption */ - uninterpretedOption?: (google.protobuf.IUninterpretedOption[]|null); - } - - /** Represents a MessageOptions. */ - class MessageOptions implements IMessageOptions { - - /** - * Constructs a new MessageOptions. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.IMessageOptions); - - /** MessageOptions messageSetWireFormat. */ -messageSetWireFormat: boolean; - - /** MessageOptions noStandardDescriptorAccessor. */ -noStandardDescriptorAccessor: boolean; - - /** MessageOptions deprecated. */ -deprecated: boolean; - - /** MessageOptions mapEntry. */ -mapEntry: boolean; - - /** MessageOptions deprecatedLegacyJsonFieldConflicts. */ -deprecatedLegacyJsonFieldConflicts: boolean; - - /** MessageOptions features. */ -features?: (google.protobuf.IFeatureSet|null); - - /** MessageOptions uninterpretedOption. */ -uninterpretedOption: google.protobuf.IUninterpretedOption[]; - - /** - * Creates a new MessageOptions instance using the specified properties. - * @param [properties] Properties to set - * @returns MessageOptions instance - */ -static create(properties?: google.protobuf.IMessageOptions): google.protobuf.MessageOptions; - - /** - * Encodes the specified MessageOptions message. Does not implicitly {@link google.protobuf.MessageOptions.verify|verify} messages. - * @param message MessageOptions message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.IMessageOptions, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified MessageOptions message, length delimited. Does not implicitly {@link google.protobuf.MessageOptions.verify|verify} messages. - * @param message MessageOptions message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.IMessageOptions, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes a MessageOptions message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns MessageOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.MessageOptions; - - /** - * Decodes a MessageOptions message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns MessageOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.MessageOptions; - - /** - * Verifies a MessageOptions message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ -static verify(message: { [k: string]: any }): (string|null); - - /** - * Creates a MessageOptions message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns MessageOptions - */ -static fromObject(object: { [k: string]: any }): google.protobuf.MessageOptions; - - /** - * Creates a plain object from a MessageOptions message. Also converts values to other types if specified. - * @param message MessageOptions - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.MessageOptions, options?: $protobuf.IConversionOptions): { [k: string]: any }; - - /** - * Converts this MessageOptions to JSON. - * @returns JSON object - */ -toJSON(): { [k: string]: any }; - - /** - * Gets the default type url for MessageOptions - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ -static getTypeUrl(typeUrlPrefix?: string): string; - } - - /** Properties of a FieldOptions. */ - interface IFieldOptions { - - /** FieldOptions ctype */ - ctype?: (google.protobuf.FieldOptions.CType|null); - - /** FieldOptions packed */ - packed?: (boolean|null); - - /** FieldOptions jstype */ - jstype?: (google.protobuf.FieldOptions.JSType|null); - - /** FieldOptions lazy */ - lazy?: (boolean|null); - - /** FieldOptions unverifiedLazy */ - unverifiedLazy?: (boolean|null); - - /** FieldOptions deprecated */ - deprecated?: (boolean|null); - - /** FieldOptions weak */ - weak?: (boolean|null); - - /** FieldOptions debugRedact */ - debugRedact?: (boolean|null); - - /** FieldOptions retention */ - retention?: (google.protobuf.FieldOptions.OptionRetention|null); - - /** FieldOptions targets */ - targets?: (google.protobuf.FieldOptions.OptionTargetType[]|null); - - /** FieldOptions editionDefaults */ - editionDefaults?: (google.protobuf.FieldOptions.IEditionDefault[]|null); - - /** FieldOptions features */ - features?: (google.protobuf.IFeatureSet|null); - - /** FieldOptions featureSupport */ - featureSupport?: (google.protobuf.FieldOptions.IFeatureSupport|null); - - /** FieldOptions uninterpretedOption */ - uninterpretedOption?: (google.protobuf.IUninterpretedOption[]|null); - } - - /** Represents a FieldOptions. */ - class FieldOptions implements IFieldOptions { - - /** - * Constructs a new FieldOptions. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.IFieldOptions); - - /** FieldOptions ctype. */ -ctype: google.protobuf.FieldOptions.CType; - - /** FieldOptions packed. */ -packed: boolean; - - /** FieldOptions jstype. */ -jstype: google.protobuf.FieldOptions.JSType; - - /** FieldOptions lazy. */ -lazy: boolean; - - /** FieldOptions unverifiedLazy. */ -unverifiedLazy: boolean; - - /** FieldOptions deprecated. */ -deprecated: boolean; - - /** FieldOptions weak. */ -weak: boolean; - - /** FieldOptions debugRedact. */ -debugRedact: boolean; - - /** FieldOptions retention. */ -retention: google.protobuf.FieldOptions.OptionRetention; - - /** FieldOptions targets. */ -targets: google.protobuf.FieldOptions.OptionTargetType[]; - - /** FieldOptions editionDefaults. */ -editionDefaults: google.protobuf.FieldOptions.IEditionDefault[]; - - /** FieldOptions features. */ -features?: (google.protobuf.IFeatureSet|null); - - /** FieldOptions featureSupport. */ -featureSupport?: (google.protobuf.FieldOptions.IFeatureSupport|null); - - /** FieldOptions uninterpretedOption. */ -uninterpretedOption: google.protobuf.IUninterpretedOption[]; - - /** - * Creates a new FieldOptions instance using the specified properties. - * @param [properties] Properties to set - * @returns FieldOptions instance - */ -static create(properties?: google.protobuf.IFieldOptions): google.protobuf.FieldOptions; - - /** - * Encodes the specified FieldOptions message. Does not implicitly {@link google.protobuf.FieldOptions.verify|verify} messages. - * @param message FieldOptions message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.IFieldOptions, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified FieldOptions message, length delimited. Does not implicitly {@link google.protobuf.FieldOptions.verify|verify} messages. - * @param message FieldOptions message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.IFieldOptions, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes a FieldOptions message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns FieldOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.FieldOptions; - - /** - * Decodes a FieldOptions message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns FieldOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.FieldOptions; - - /** - * Verifies a FieldOptions message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ -static verify(message: { [k: string]: any }): (string|null); - - /** - * Creates a FieldOptions message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns FieldOptions - */ -static fromObject(object: { [k: string]: any }): google.protobuf.FieldOptions; - - /** - * Creates a plain object from a FieldOptions message. Also converts values to other types if specified. - * @param message FieldOptions - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.FieldOptions, options?: $protobuf.IConversionOptions): { [k: string]: any }; - - /** - * Converts this FieldOptions to JSON. - * @returns JSON object - */ -toJSON(): { [k: string]: any }; - - /** - * Gets the default type url for FieldOptions - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ -static getTypeUrl(typeUrlPrefix?: string): string; - } - - namespace FieldOptions { - - /** CType enum. */ - enum CType { - STRING = 0, - CORD = 1, - STRING_PIECE = 2 - } - - /** JSType enum. */ - enum JSType { - JS_NORMAL = 0, - JS_STRING = 1, - JS_NUMBER = 2 - } - - /** OptionRetention enum. */ - enum OptionRetention { - RETENTION_UNKNOWN = 0, - RETENTION_RUNTIME = 1, - RETENTION_SOURCE = 2 - } - - /** OptionTargetType enum. */ - enum OptionTargetType { - TARGET_TYPE_UNKNOWN = 0, - TARGET_TYPE_FILE = 1, - TARGET_TYPE_EXTENSION_RANGE = 2, - TARGET_TYPE_MESSAGE = 3, - TARGET_TYPE_FIELD = 4, - TARGET_TYPE_ONEOF = 5, - TARGET_TYPE_ENUM = 6, - TARGET_TYPE_ENUM_ENTRY = 7, - TARGET_TYPE_SERVICE = 8, - TARGET_TYPE_METHOD = 9 - } - - /** Properties of an EditionDefault. */ - interface IEditionDefault { - - /** EditionDefault edition */ - edition?: (google.protobuf.Edition|null); - - /** EditionDefault value */ - value?: (string|null); - } - - /** Represents an EditionDefault. */ - class EditionDefault implements IEditionDefault { - - /** - * Constructs a new EditionDefault. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.FieldOptions.IEditionDefault); - - /** EditionDefault edition. */ -edition: google.protobuf.Edition; - - /** EditionDefault value. */ -value: string; - - /** - * Creates a new EditionDefault instance using the specified properties. - * @param [properties] Properties to set - * @returns EditionDefault instance - */ -static create(properties?: google.protobuf.FieldOptions.IEditionDefault): google.protobuf.FieldOptions.EditionDefault; - - /** - * Encodes the specified EditionDefault message. Does not implicitly {@link google.protobuf.FieldOptions.EditionDefault.verify|verify} messages. - * @param message EditionDefault message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.FieldOptions.IEditionDefault, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified EditionDefault message, length delimited. Does not implicitly {@link google.protobuf.FieldOptions.EditionDefault.verify|verify} messages. - * @param message EditionDefault message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.FieldOptions.IEditionDefault, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes an EditionDefault message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns EditionDefault - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.FieldOptions.EditionDefault; - - /** - * Decodes an EditionDefault message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns EditionDefault - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.FieldOptions.EditionDefault; - - /** - * Verifies an EditionDefault message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ -static verify(message: { [k: string]: any }): (string|null); - - /** - * Creates an EditionDefault message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns EditionDefault - */ -static fromObject(object: { [k: string]: any }): google.protobuf.FieldOptions.EditionDefault; - - /** - * Creates a plain object from an EditionDefault message. Also converts values to other types if specified. - * @param message EditionDefault - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.FieldOptions.EditionDefault, options?: $protobuf.IConversionOptions): { [k: string]: any }; - - /** - * Converts this EditionDefault to JSON. - * @returns JSON object - */ -toJSON(): { [k: string]: any }; - - /** - * Gets the default type url for EditionDefault - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ -static getTypeUrl(typeUrlPrefix?: string): string; - } - - /** Properties of a FeatureSupport. */ - interface IFeatureSupport { - - /** FeatureSupport editionIntroduced */ - editionIntroduced?: (google.protobuf.Edition|null); - - /** FeatureSupport editionDeprecated */ - editionDeprecated?: (google.protobuf.Edition|null); - - /** FeatureSupport deprecationWarning */ - deprecationWarning?: (string|null); - - /** FeatureSupport editionRemoved */ - editionRemoved?: (google.protobuf.Edition|null); - } - - /** Represents a FeatureSupport. */ - class FeatureSupport implements IFeatureSupport { - - /** - * Constructs a new FeatureSupport. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.FieldOptions.IFeatureSupport); - - /** FeatureSupport editionIntroduced. */ -editionIntroduced: google.protobuf.Edition; - - /** FeatureSupport editionDeprecated. */ -editionDeprecated: google.protobuf.Edition; - - /** FeatureSupport deprecationWarning. */ -deprecationWarning: string; - - /** FeatureSupport editionRemoved. */ -editionRemoved: google.protobuf.Edition; - - /** - * Creates a new FeatureSupport instance using the specified properties. - * @param [properties] Properties to set - * @returns FeatureSupport instance - */ -static create(properties?: google.protobuf.FieldOptions.IFeatureSupport): google.protobuf.FieldOptions.FeatureSupport; - - /** - * Encodes the specified FeatureSupport message. Does not implicitly {@link google.protobuf.FieldOptions.FeatureSupport.verify|verify} messages. - * @param message FeatureSupport message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.FieldOptions.IFeatureSupport, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified FeatureSupport message, length delimited. Does not implicitly {@link google.protobuf.FieldOptions.FeatureSupport.verify|verify} messages. - * @param message FeatureSupport message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.FieldOptions.IFeatureSupport, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes a FeatureSupport message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns FeatureSupport - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.FieldOptions.FeatureSupport; - - /** - * Decodes a FeatureSupport message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns FeatureSupport - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.FieldOptions.FeatureSupport; - - /** - * Verifies a FeatureSupport message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ -static verify(message: { [k: string]: any }): (string|null); - - /** - * Creates a FeatureSupport message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns FeatureSupport - */ -static fromObject(object: { [k: string]: any }): google.protobuf.FieldOptions.FeatureSupport; - - /** - * Creates a plain object from a FeatureSupport message. Also converts values to other types if specified. - * @param message FeatureSupport - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.FieldOptions.FeatureSupport, options?: $protobuf.IConversionOptions): { [k: string]: any }; - - /** - * Converts this FeatureSupport to JSON. - * @returns JSON object - */ -toJSON(): { [k: string]: any }; - - /** - * Gets the default type url for FeatureSupport - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ -static getTypeUrl(typeUrlPrefix?: string): string; - } - } - - /** Properties of an OneofOptions. */ - interface IOneofOptions { - - /** OneofOptions features */ - features?: (google.protobuf.IFeatureSet|null); - - /** OneofOptions uninterpretedOption */ - uninterpretedOption?: (google.protobuf.IUninterpretedOption[]|null); - } - - /** Represents an OneofOptions. */ - class OneofOptions implements IOneofOptions { - - /** - * Constructs a new OneofOptions. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.IOneofOptions); - - /** OneofOptions features. */ -features?: (google.protobuf.IFeatureSet|null); - - /** OneofOptions uninterpretedOption. */ -uninterpretedOption: google.protobuf.IUninterpretedOption[]; - - /** - * Creates a new OneofOptions instance using the specified properties. - * @param [properties] Properties to set - * @returns OneofOptions instance - */ -static create(properties?: google.protobuf.IOneofOptions): google.protobuf.OneofOptions; - - /** - * Encodes the specified OneofOptions message. Does not implicitly {@link google.protobuf.OneofOptions.verify|verify} messages. - * @param message OneofOptions message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.IOneofOptions, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified OneofOptions message, length delimited. Does not implicitly {@link google.protobuf.OneofOptions.verify|verify} messages. - * @param message OneofOptions message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.IOneofOptions, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes an OneofOptions message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns OneofOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.OneofOptions; - - /** - * Decodes an OneofOptions message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns OneofOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.OneofOptions; - - /** - * Verifies an OneofOptions message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ -static verify(message: { [k: string]: any }): (string|null); - - /** - * Creates an OneofOptions message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns OneofOptions - */ -static fromObject(object: { [k: string]: any }): google.protobuf.OneofOptions; - - /** - * Creates a plain object from an OneofOptions message. Also converts values to other types if specified. - * @param message OneofOptions - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.OneofOptions, options?: $protobuf.IConversionOptions): { [k: string]: any }; - - /** - * Converts this OneofOptions to JSON. - * @returns JSON object - */ -toJSON(): { [k: string]: any }; - - /** - * Gets the default type url for OneofOptions - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ -static getTypeUrl(typeUrlPrefix?: string): string; - } - - /** Properties of an EnumOptions. */ - interface IEnumOptions { - - /** EnumOptions allowAlias */ - allowAlias?: (boolean|null); - - /** EnumOptions deprecated */ - deprecated?: (boolean|null); - - /** EnumOptions deprecatedLegacyJsonFieldConflicts */ - deprecatedLegacyJsonFieldConflicts?: (boolean|null); - - /** EnumOptions features */ - features?: (google.protobuf.IFeatureSet|null); - - /** EnumOptions uninterpretedOption */ - uninterpretedOption?: (google.protobuf.IUninterpretedOption[]|null); - } - - /** Represents an EnumOptions. */ - class EnumOptions implements IEnumOptions { - - /** - * Constructs a new EnumOptions. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.IEnumOptions); - - /** EnumOptions allowAlias. */ -allowAlias: boolean; - - /** EnumOptions deprecated. */ -deprecated: boolean; - - /** EnumOptions deprecatedLegacyJsonFieldConflicts. */ -deprecatedLegacyJsonFieldConflicts: boolean; - - /** EnumOptions features. */ -features?: (google.protobuf.IFeatureSet|null); - - /** EnumOptions uninterpretedOption. */ -uninterpretedOption: google.protobuf.IUninterpretedOption[]; - - /** - * Creates a new EnumOptions instance using the specified properties. - * @param [properties] Properties to set - * @returns EnumOptions instance - */ -static create(properties?: google.protobuf.IEnumOptions): google.protobuf.EnumOptions; - - /** - * Encodes the specified EnumOptions message. Does not implicitly {@link google.protobuf.EnumOptions.verify|verify} messages. - * @param message EnumOptions message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.IEnumOptions, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified EnumOptions message, length delimited. Does not implicitly {@link google.protobuf.EnumOptions.verify|verify} messages. - * @param message EnumOptions message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.IEnumOptions, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes an EnumOptions message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns EnumOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.EnumOptions; - - /** - * Decodes an EnumOptions message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns EnumOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.EnumOptions; - - /** - * Verifies an EnumOptions message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ -static verify(message: { [k: string]: any }): (string|null); - - /** - * Creates an EnumOptions message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns EnumOptions - */ -static fromObject(object: { [k: string]: any }): google.protobuf.EnumOptions; - - /** - * Creates a plain object from an EnumOptions message. Also converts values to other types if specified. - * @param message EnumOptions - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.EnumOptions, options?: $protobuf.IConversionOptions): { [k: string]: any }; - - /** - * Converts this EnumOptions to JSON. - * @returns JSON object - */ -toJSON(): { [k: string]: any }; - - /** - * Gets the default type url for EnumOptions - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ -static getTypeUrl(typeUrlPrefix?: string): string; - } - - /** Properties of an EnumValueOptions. */ - interface IEnumValueOptions { - - /** EnumValueOptions deprecated */ - deprecated?: (boolean|null); - - /** EnumValueOptions features */ - features?: (google.protobuf.IFeatureSet|null); - - /** EnumValueOptions debugRedact */ - debugRedact?: (boolean|null); - - /** EnumValueOptions featureSupport */ - featureSupport?: (google.protobuf.FieldOptions.IFeatureSupport|null); - - /** EnumValueOptions uninterpretedOption */ - uninterpretedOption?: (google.protobuf.IUninterpretedOption[]|null); - } - - /** Represents an EnumValueOptions. */ - class EnumValueOptions implements IEnumValueOptions { - - /** - * Constructs a new EnumValueOptions. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.IEnumValueOptions); - - /** EnumValueOptions deprecated. */ -deprecated: boolean; - - /** EnumValueOptions features. */ -features?: (google.protobuf.IFeatureSet|null); - - /** EnumValueOptions debugRedact. */ -debugRedact: boolean; - - /** EnumValueOptions featureSupport. */ -featureSupport?: (google.protobuf.FieldOptions.IFeatureSupport|null); - - /** EnumValueOptions uninterpretedOption. */ -uninterpretedOption: google.protobuf.IUninterpretedOption[]; - - /** - * Creates a new EnumValueOptions instance using the specified properties. - * @param [properties] Properties to set - * @returns EnumValueOptions instance - */ -static create(properties?: google.protobuf.IEnumValueOptions): google.protobuf.EnumValueOptions; - - /** - * Encodes the specified EnumValueOptions message. Does not implicitly {@link google.protobuf.EnumValueOptions.verify|verify} messages. - * @param message EnumValueOptions message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.IEnumValueOptions, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified EnumValueOptions message, length delimited. Does not implicitly {@link google.protobuf.EnumValueOptions.verify|verify} messages. - * @param message EnumValueOptions message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.IEnumValueOptions, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes an EnumValueOptions message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns EnumValueOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.EnumValueOptions; - - /** - * Decodes an EnumValueOptions message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns EnumValueOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.EnumValueOptions; - - /** - * Verifies an EnumValueOptions message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ -static verify(message: { [k: string]: any }): (string|null); - - /** - * Creates an EnumValueOptions message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns EnumValueOptions - */ -static fromObject(object: { [k: string]: any }): google.protobuf.EnumValueOptions; - - /** - * Creates a plain object from an EnumValueOptions message. Also converts values to other types if specified. - * @param message EnumValueOptions - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.EnumValueOptions, options?: $protobuf.IConversionOptions): { [k: string]: any }; - - /** - * Converts this EnumValueOptions to JSON. - * @returns JSON object - */ -toJSON(): { [k: string]: any }; - - /** - * Gets the default type url for EnumValueOptions - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ -static getTypeUrl(typeUrlPrefix?: string): string; - } - - /** Properties of a ServiceOptions. */ - interface IServiceOptions { - - /** ServiceOptions features */ - features?: (google.protobuf.IFeatureSet|null); - - /** ServiceOptions deprecated */ - deprecated?: (boolean|null); - - /** ServiceOptions uninterpretedOption */ - uninterpretedOption?: (google.protobuf.IUninterpretedOption[]|null); - } - - /** Represents a ServiceOptions. */ - class ServiceOptions implements IServiceOptions { - - /** - * Constructs a new ServiceOptions. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.IServiceOptions); - - /** ServiceOptions features. */ -features?: (google.protobuf.IFeatureSet|null); - - /** ServiceOptions deprecated. */ -deprecated: boolean; - - /** ServiceOptions uninterpretedOption. */ -uninterpretedOption: google.protobuf.IUninterpretedOption[]; - - /** - * Creates a new ServiceOptions instance using the specified properties. - * @param [properties] Properties to set - * @returns ServiceOptions instance - */ -static create(properties?: google.protobuf.IServiceOptions): google.protobuf.ServiceOptions; - - /** - * Encodes the specified ServiceOptions message. Does not implicitly {@link google.protobuf.ServiceOptions.verify|verify} messages. - * @param message ServiceOptions message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.IServiceOptions, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified ServiceOptions message, length delimited. Does not implicitly {@link google.protobuf.ServiceOptions.verify|verify} messages. - * @param message ServiceOptions message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.IServiceOptions, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes a ServiceOptions message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns ServiceOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.ServiceOptions; - - /** - * Decodes a ServiceOptions message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns ServiceOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.ServiceOptions; - - /** - * Verifies a ServiceOptions message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ -static verify(message: { [k: string]: any }): (string|null); - - /** - * Creates a ServiceOptions message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns ServiceOptions - */ -static fromObject(object: { [k: string]: any }): google.protobuf.ServiceOptions; - - /** - * Creates a plain object from a ServiceOptions message. Also converts values to other types if specified. - * @param message ServiceOptions - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.ServiceOptions, options?: $protobuf.IConversionOptions): { [k: string]: any }; - - /** - * Converts this ServiceOptions to JSON. - * @returns JSON object - */ -toJSON(): { [k: string]: any }; - - /** - * Gets the default type url for ServiceOptions - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ -static getTypeUrl(typeUrlPrefix?: string): string; - } - - /** Properties of a MethodOptions. */ - interface IMethodOptions { - - /** MethodOptions deprecated */ - deprecated?: (boolean|null); - - /** MethodOptions idempotencyLevel */ - idempotencyLevel?: (google.protobuf.MethodOptions.IdempotencyLevel|null); - - /** MethodOptions features */ - features?: (google.protobuf.IFeatureSet|null); - - /** MethodOptions uninterpretedOption */ - uninterpretedOption?: (google.protobuf.IUninterpretedOption[]|null); - } - - /** Represents a MethodOptions. */ - class MethodOptions implements IMethodOptions { - - /** - * Constructs a new MethodOptions. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.IMethodOptions); - - /** MethodOptions deprecated. */ -deprecated: boolean; - - /** MethodOptions idempotencyLevel. */ -idempotencyLevel: google.protobuf.MethodOptions.IdempotencyLevel; - - /** MethodOptions features. */ -features?: (google.protobuf.IFeatureSet|null); - - /** MethodOptions uninterpretedOption. */ -uninterpretedOption: google.protobuf.IUninterpretedOption[]; - - /** - * Creates a new MethodOptions instance using the specified properties. - * @param [properties] Properties to set - * @returns MethodOptions instance - */ -static create(properties?: google.protobuf.IMethodOptions): google.protobuf.MethodOptions; - - /** - * Encodes the specified MethodOptions message. Does not implicitly {@link google.protobuf.MethodOptions.verify|verify} messages. - * @param message MethodOptions message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.IMethodOptions, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified MethodOptions message, length delimited. Does not implicitly {@link google.protobuf.MethodOptions.verify|verify} messages. - * @param message MethodOptions message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.IMethodOptions, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes a MethodOptions message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns MethodOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.MethodOptions; - - /** - * Decodes a MethodOptions message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns MethodOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.MethodOptions; - - /** - * Verifies a MethodOptions message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ -static verify(message: { [k: string]: any }): (string|null); - - /** - * Creates a MethodOptions message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns MethodOptions - */ -static fromObject(object: { [k: string]: any }): google.protobuf.MethodOptions; - - /** - * Creates a plain object from a MethodOptions message. Also converts values to other types if specified. - * @param message MethodOptions - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.MethodOptions, options?: $protobuf.IConversionOptions): { [k: string]: any }; - - /** - * Converts this MethodOptions to JSON. - * @returns JSON object - */ -toJSON(): { [k: string]: any }; - - /** - * Gets the default type url for MethodOptions - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ -static getTypeUrl(typeUrlPrefix?: string): string; - } - - namespace MethodOptions { - - /** IdempotencyLevel enum. */ - enum IdempotencyLevel { - IDEMPOTENCY_UNKNOWN = 0, - NO_SIDE_EFFECTS = 1, - IDEMPOTENT = 2 - } - } - - /** Properties of an UninterpretedOption. */ - interface IUninterpretedOption { - - /** UninterpretedOption name */ - name?: (google.protobuf.UninterpretedOption.INamePart[]|null); - - /** UninterpretedOption identifierValue */ - identifierValue?: (string|null); - - /** UninterpretedOption positiveIntValue */ - positiveIntValue?: (number|Long|null); - - /** UninterpretedOption negativeIntValue */ - negativeIntValue?: (number|Long|null); - - /** UninterpretedOption doubleValue */ - doubleValue?: (number|null); - - /** UninterpretedOption stringValue */ - stringValue?: (Uint8Array|null); - - /** UninterpretedOption aggregateValue */ - aggregateValue?: (string|null); - } - - /** Represents an UninterpretedOption. */ - class UninterpretedOption implements IUninterpretedOption { - - /** - * Constructs a new UninterpretedOption. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.IUninterpretedOption); - - /** UninterpretedOption name. */ -name: google.protobuf.UninterpretedOption.INamePart[]; - - /** UninterpretedOption identifierValue. */ -identifierValue: string; - - /** UninterpretedOption positiveIntValue. */ -positiveIntValue: (number|Long); - - /** UninterpretedOption negativeIntValue. */ -negativeIntValue: (number|Long); - - /** UninterpretedOption doubleValue. */ -doubleValue: number; - - /** UninterpretedOption stringValue. */ -stringValue: Uint8Array; - - /** UninterpretedOption aggregateValue. */ -aggregateValue: string; - - /** - * Creates a new UninterpretedOption instance using the specified properties. - * @param [properties] Properties to set - * @returns UninterpretedOption instance - */ -static create(properties?: google.protobuf.IUninterpretedOption): google.protobuf.UninterpretedOption; - - /** - * Encodes the specified UninterpretedOption message. Does not implicitly {@link google.protobuf.UninterpretedOption.verify|verify} messages. - * @param message UninterpretedOption message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.IUninterpretedOption, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified UninterpretedOption message, length delimited. Does not implicitly {@link google.protobuf.UninterpretedOption.verify|verify} messages. - * @param message UninterpretedOption message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.IUninterpretedOption, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes an UninterpretedOption message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns UninterpretedOption - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.UninterpretedOption; - - /** - * Decodes an UninterpretedOption message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns UninterpretedOption - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.UninterpretedOption; - - /** - * Verifies an UninterpretedOption message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ -static verify(message: { [k: string]: any }): (string|null); - - /** - * Creates an UninterpretedOption message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns UninterpretedOption - */ -static fromObject(object: { [k: string]: any }): google.protobuf.UninterpretedOption; - - /** - * Creates a plain object from an UninterpretedOption message. Also converts values to other types if specified. - * @param message UninterpretedOption - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.UninterpretedOption, options?: $protobuf.IConversionOptions): { [k: string]: any }; - - /** - * Converts this UninterpretedOption to JSON. - * @returns JSON object - */ -toJSON(): { [k: string]: any }; - - /** - * Gets the default type url for UninterpretedOption - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ -static getTypeUrl(typeUrlPrefix?: string): string; - } - - namespace UninterpretedOption { - - /** Properties of a NamePart. */ - interface INamePart { - - /** NamePart namePart */ - namePart: string; - - /** NamePart isExtension */ - isExtension: boolean; - } - - /** Represents a NamePart. */ - class NamePart implements INamePart { - - /** - * Constructs a new NamePart. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.UninterpretedOption.INamePart); - - /** NamePart namePart. */ -namePart: string; - - /** NamePart isExtension. */ -isExtension: boolean; - - /** - * Creates a new NamePart instance using the specified properties. - * @param [properties] Properties to set - * @returns NamePart instance - */ -static create(properties?: google.protobuf.UninterpretedOption.INamePart): google.protobuf.UninterpretedOption.NamePart; - - /** - * Encodes the specified NamePart message. Does not implicitly {@link google.protobuf.UninterpretedOption.NamePart.verify|verify} messages. - * @param message NamePart message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.UninterpretedOption.INamePart, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified NamePart message, length delimited. Does not implicitly {@link google.protobuf.UninterpretedOption.NamePart.verify|verify} messages. - * @param message NamePart message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.UninterpretedOption.INamePart, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes a NamePart message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns NamePart - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.UninterpretedOption.NamePart; - - /** - * Decodes a NamePart message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns NamePart - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.UninterpretedOption.NamePart; - - /** - * Verifies a NamePart message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ -static verify(message: { [k: string]: any }): (string|null); - - /** - * Creates a NamePart message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns NamePart - */ -static fromObject(object: { [k: string]: any }): google.protobuf.UninterpretedOption.NamePart; - - /** - * Creates a plain object from a NamePart message. Also converts values to other types if specified. - * @param message NamePart - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.UninterpretedOption.NamePart, options?: $protobuf.IConversionOptions): { [k: string]: any }; - - /** - * Converts this NamePart to JSON. - * @returns JSON object - */ -toJSON(): { [k: string]: any }; - - /** - * Gets the default type url for NamePart - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ -static getTypeUrl(typeUrlPrefix?: string): string; - } - } - - /** Properties of a FeatureSet. */ - interface IFeatureSet { - - /** FeatureSet fieldPresence */ - fieldPresence?: (google.protobuf.FeatureSet.FieldPresence|null); - - /** FeatureSet enumType */ - enumType?: (google.protobuf.FeatureSet.EnumType|null); - - /** FeatureSet repeatedFieldEncoding */ - repeatedFieldEncoding?: (google.protobuf.FeatureSet.RepeatedFieldEncoding|null); - - /** FeatureSet utf8Validation */ - utf8Validation?: (google.protobuf.FeatureSet.Utf8Validation|null); - - /** FeatureSet messageEncoding */ - messageEncoding?: (google.protobuf.FeatureSet.MessageEncoding|null); - - /** FeatureSet jsonFormat */ - jsonFormat?: (google.protobuf.FeatureSet.JsonFormat|null); - - /** FeatureSet enforceNamingStyle */ - enforceNamingStyle?: (google.protobuf.FeatureSet.EnforceNamingStyle|null); - - /** FeatureSet defaultSymbolVisibility */ - defaultSymbolVisibility?: (google.protobuf.FeatureSet.VisibilityFeature.DefaultSymbolVisibility|null); - } - - /** Represents a FeatureSet. */ - class FeatureSet implements IFeatureSet { - - /** - * Constructs a new FeatureSet. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.IFeatureSet); - - /** FeatureSet fieldPresence. */ -fieldPresence: google.protobuf.FeatureSet.FieldPresence; - - /** FeatureSet enumType. */ -enumType: google.protobuf.FeatureSet.EnumType; - - /** FeatureSet repeatedFieldEncoding. */ -repeatedFieldEncoding: google.protobuf.FeatureSet.RepeatedFieldEncoding; - - /** FeatureSet utf8Validation. */ -utf8Validation: google.protobuf.FeatureSet.Utf8Validation; - - /** FeatureSet messageEncoding. */ -messageEncoding: google.protobuf.FeatureSet.MessageEncoding; - - /** FeatureSet jsonFormat. */ -jsonFormat: google.protobuf.FeatureSet.JsonFormat; - - /** FeatureSet enforceNamingStyle. */ -enforceNamingStyle: google.protobuf.FeatureSet.EnforceNamingStyle; - - /** FeatureSet defaultSymbolVisibility. */ -defaultSymbolVisibility: google.protobuf.FeatureSet.VisibilityFeature.DefaultSymbolVisibility; - - /** - * Creates a new FeatureSet instance using the specified properties. - * @param [properties] Properties to set - * @returns FeatureSet instance - */ -static create(properties?: google.protobuf.IFeatureSet): google.protobuf.FeatureSet; - - /** - * Encodes the specified FeatureSet message. Does not implicitly {@link google.protobuf.FeatureSet.verify|verify} messages. - * @param message FeatureSet message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.IFeatureSet, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified FeatureSet message, length delimited. Does not implicitly {@link google.protobuf.FeatureSet.verify|verify} messages. - * @param message FeatureSet message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.IFeatureSet, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes a FeatureSet message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns FeatureSet - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.FeatureSet; - - /** - * Decodes a FeatureSet message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns FeatureSet - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.FeatureSet; - - /** - * Verifies a FeatureSet message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ -static verify(message: { [k: string]: any }): (string|null); - - /** - * Creates a FeatureSet message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns FeatureSet - */ -static fromObject(object: { [k: string]: any }): google.protobuf.FeatureSet; - - /** - * Creates a plain object from a FeatureSet message. Also converts values to other types if specified. - * @param message FeatureSet - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.FeatureSet, options?: $protobuf.IConversionOptions): { [k: string]: any }; - - /** - * Converts this FeatureSet to JSON. - * @returns JSON object - */ -toJSON(): { [k: string]: any }; - - /** - * Gets the default type url for FeatureSet - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ -static getTypeUrl(typeUrlPrefix?: string): string; - } - - namespace FeatureSet { - - /** FieldPresence enum. */ - enum FieldPresence { - FIELD_PRESENCE_UNKNOWN = 0, - EXPLICIT = 1, - IMPLICIT = 2, - LEGACY_REQUIRED = 3 - } - - /** EnumType enum. */ - enum EnumType { - ENUM_TYPE_UNKNOWN = 0, - OPEN = 1, - CLOSED = 2 - } - - /** RepeatedFieldEncoding enum. */ - enum RepeatedFieldEncoding { - REPEATED_FIELD_ENCODING_UNKNOWN = 0, - PACKED = 1, - EXPANDED = 2 - } - - /** Utf8Validation enum. */ - enum Utf8Validation { - UTF8_VALIDATION_UNKNOWN = 0, - VERIFY = 2, - NONE = 3 - } - - /** MessageEncoding enum. */ - enum MessageEncoding { - MESSAGE_ENCODING_UNKNOWN = 0, - LENGTH_PREFIXED = 1, - DELIMITED = 2 - } - - /** JsonFormat enum. */ - enum JsonFormat { - JSON_FORMAT_UNKNOWN = 0, - ALLOW = 1, - LEGACY_BEST_EFFORT = 2 - } - - /** EnforceNamingStyle enum. */ - enum EnforceNamingStyle { - ENFORCE_NAMING_STYLE_UNKNOWN = 0, - STYLE2024 = 1, - STYLE_LEGACY = 2 - } - - /** Properties of a VisibilityFeature. */ - interface IVisibilityFeature { - } - - /** Represents a VisibilityFeature. */ - class VisibilityFeature implements IVisibilityFeature { - - /** - * Constructs a new VisibilityFeature. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.FeatureSet.IVisibilityFeature); - - /** - * Creates a new VisibilityFeature instance using the specified properties. - * @param [properties] Properties to set - * @returns VisibilityFeature instance - */ -static create(properties?: google.protobuf.FeatureSet.IVisibilityFeature): google.protobuf.FeatureSet.VisibilityFeature; - - /** - * Encodes the specified VisibilityFeature message. Does not implicitly {@link google.protobuf.FeatureSet.VisibilityFeature.verify|verify} messages. - * @param message VisibilityFeature message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.FeatureSet.IVisibilityFeature, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified VisibilityFeature message, length delimited. Does not implicitly {@link google.protobuf.FeatureSet.VisibilityFeature.verify|verify} messages. - * @param message VisibilityFeature message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.FeatureSet.IVisibilityFeature, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes a VisibilityFeature message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns VisibilityFeature - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.FeatureSet.VisibilityFeature; - - /** - * Decodes a VisibilityFeature message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns VisibilityFeature - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.FeatureSet.VisibilityFeature; - - /** - * Verifies a VisibilityFeature message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ -static verify(message: { [k: string]: any }): (string|null); - - /** - * Creates a VisibilityFeature message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns VisibilityFeature - */ -static fromObject(object: { [k: string]: any }): google.protobuf.FeatureSet.VisibilityFeature; - - /** - * Creates a plain object from a VisibilityFeature message. Also converts values to other types if specified. - * @param message VisibilityFeature - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.FeatureSet.VisibilityFeature, options?: $protobuf.IConversionOptions): { [k: string]: any }; - - /** - * Converts this VisibilityFeature to JSON. - * @returns JSON object - */ -toJSON(): { [k: string]: any }; - - /** - * Gets the default type url for VisibilityFeature - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ -static getTypeUrl(typeUrlPrefix?: string): string; - } - - namespace VisibilityFeature { - - /** DefaultSymbolVisibility enum. */ - enum DefaultSymbolVisibility { - DEFAULT_SYMBOL_VISIBILITY_UNKNOWN = 0, - EXPORT_ALL = 1, - EXPORT_TOP_LEVEL = 2, - LOCAL_ALL = 3, - STRICT = 4 - } - } - } - - /** Properties of a FeatureSetDefaults. */ - interface IFeatureSetDefaults { - - /** FeatureSetDefaults defaults */ - defaults?: (google.protobuf.FeatureSetDefaults.IFeatureSetEditionDefault[]|null); - - /** FeatureSetDefaults minimumEdition */ - minimumEdition?: (google.protobuf.Edition|null); - - /** FeatureSetDefaults maximumEdition */ - maximumEdition?: (google.protobuf.Edition|null); - } - - /** Represents a FeatureSetDefaults. */ - class FeatureSetDefaults implements IFeatureSetDefaults { - - /** - * Constructs a new FeatureSetDefaults. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.IFeatureSetDefaults); - - /** FeatureSetDefaults defaults. */ -defaults: google.protobuf.FeatureSetDefaults.IFeatureSetEditionDefault[]; - - /** FeatureSetDefaults minimumEdition. */ -minimumEdition: google.protobuf.Edition; - - /** FeatureSetDefaults maximumEdition. */ -maximumEdition: google.protobuf.Edition; - - /** - * Creates a new FeatureSetDefaults instance using the specified properties. - * @param [properties] Properties to set - * @returns FeatureSetDefaults instance - */ -static create(properties?: google.protobuf.IFeatureSetDefaults): google.protobuf.FeatureSetDefaults; - - /** - * Encodes the specified FeatureSetDefaults message. Does not implicitly {@link google.protobuf.FeatureSetDefaults.verify|verify} messages. - * @param message FeatureSetDefaults message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.IFeatureSetDefaults, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified FeatureSetDefaults message, length delimited. Does not implicitly {@link google.protobuf.FeatureSetDefaults.verify|verify} messages. - * @param message FeatureSetDefaults message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.IFeatureSetDefaults, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes a FeatureSetDefaults message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns FeatureSetDefaults - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.FeatureSetDefaults; - - /** - * Decodes a FeatureSetDefaults message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns FeatureSetDefaults - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.FeatureSetDefaults; - - /** - * Verifies a FeatureSetDefaults message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ -static verify(message: { [k: string]: any }): (string|null); - - /** - * Creates a FeatureSetDefaults message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns FeatureSetDefaults - */ -static fromObject(object: { [k: string]: any }): google.protobuf.FeatureSetDefaults; - - /** - * Creates a plain object from a FeatureSetDefaults message. Also converts values to other types if specified. - * @param message FeatureSetDefaults - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.FeatureSetDefaults, options?: $protobuf.IConversionOptions): { [k: string]: any }; - - /** - * Converts this FeatureSetDefaults to JSON. - * @returns JSON object - */ -toJSON(): { [k: string]: any }; - - /** - * Gets the default type url for FeatureSetDefaults - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ -static getTypeUrl(typeUrlPrefix?: string): string; - } - - namespace FeatureSetDefaults { - - /** Properties of a FeatureSetEditionDefault. */ - interface IFeatureSetEditionDefault { - - /** FeatureSetEditionDefault edition */ - edition?: (google.protobuf.Edition|null); - - /** FeatureSetEditionDefault overridableFeatures */ - overridableFeatures?: (google.protobuf.IFeatureSet|null); - - /** FeatureSetEditionDefault fixedFeatures */ - fixedFeatures?: (google.protobuf.IFeatureSet|null); - } - - /** Represents a FeatureSetEditionDefault. */ - class FeatureSetEditionDefault implements IFeatureSetEditionDefault { - - /** - * Constructs a new FeatureSetEditionDefault. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.FeatureSetDefaults.IFeatureSetEditionDefault); - - /** FeatureSetEditionDefault edition. */ -edition: google.protobuf.Edition; - - /** FeatureSetEditionDefault overridableFeatures. */ -overridableFeatures?: (google.protobuf.IFeatureSet|null); - - /** FeatureSetEditionDefault fixedFeatures. */ -fixedFeatures?: (google.protobuf.IFeatureSet|null); - - /** - * Creates a new FeatureSetEditionDefault instance using the specified properties. - * @param [properties] Properties to set - * @returns FeatureSetEditionDefault instance - */ -static create(properties?: google.protobuf.FeatureSetDefaults.IFeatureSetEditionDefault): google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault; - - /** - * Encodes the specified FeatureSetEditionDefault message. Does not implicitly {@link google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.verify|verify} messages. - * @param message FeatureSetEditionDefault message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.FeatureSetDefaults.IFeatureSetEditionDefault, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified FeatureSetEditionDefault message, length delimited. Does not implicitly {@link google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.verify|verify} messages. - * @param message FeatureSetEditionDefault message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.FeatureSetDefaults.IFeatureSetEditionDefault, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes a FeatureSetEditionDefault message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns FeatureSetEditionDefault - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault; - - /** - * Decodes a FeatureSetEditionDefault message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns FeatureSetEditionDefault - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault; - - /** - * Verifies a FeatureSetEditionDefault message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ -static verify(message: { [k: string]: any }): (string|null); - - /** - * Creates a FeatureSetEditionDefault message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns FeatureSetEditionDefault - */ -static fromObject(object: { [k: string]: any }): google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault; - - /** - * Creates a plain object from a FeatureSetEditionDefault message. Also converts values to other types if specified. - * @param message FeatureSetEditionDefault - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault, options?: $protobuf.IConversionOptions): { [k: string]: any }; - - /** - * Converts this FeatureSetEditionDefault to JSON. - * @returns JSON object - */ -toJSON(): { [k: string]: any }; - - /** - * Gets the default type url for FeatureSetEditionDefault - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ -static getTypeUrl(typeUrlPrefix?: string): string; - } - } - - /** Properties of a SourceCodeInfo. */ - interface ISourceCodeInfo { - - /** SourceCodeInfo location */ - location?: (google.protobuf.SourceCodeInfo.ILocation[]|null); - } - - /** Represents a SourceCodeInfo. */ - class SourceCodeInfo implements ISourceCodeInfo { - - /** - * Constructs a new SourceCodeInfo. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.ISourceCodeInfo); - - /** SourceCodeInfo location. */ -location: google.protobuf.SourceCodeInfo.ILocation[]; - - /** - * Creates a new SourceCodeInfo instance using the specified properties. - * @param [properties] Properties to set - * @returns SourceCodeInfo instance - */ -static create(properties?: google.protobuf.ISourceCodeInfo): google.protobuf.SourceCodeInfo; - - /** - * Encodes the specified SourceCodeInfo message. Does not implicitly {@link google.protobuf.SourceCodeInfo.verify|verify} messages. - * @param message SourceCodeInfo message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.ISourceCodeInfo, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified SourceCodeInfo message, length delimited. Does not implicitly {@link google.protobuf.SourceCodeInfo.verify|verify} messages. - * @param message SourceCodeInfo message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.ISourceCodeInfo, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes a SourceCodeInfo message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns SourceCodeInfo - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.SourceCodeInfo; - - /** - * Decodes a SourceCodeInfo message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns SourceCodeInfo - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.SourceCodeInfo; - - /** - * Verifies a SourceCodeInfo message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ -static verify(message: { [k: string]: any }): (string|null); - - /** - * Creates a SourceCodeInfo message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns SourceCodeInfo - */ -static fromObject(object: { [k: string]: any }): google.protobuf.SourceCodeInfo; - - /** - * Creates a plain object from a SourceCodeInfo message. Also converts values to other types if specified. - * @param message SourceCodeInfo - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.SourceCodeInfo, options?: $protobuf.IConversionOptions): { [k: string]: any }; - - /** - * Converts this SourceCodeInfo to JSON. - * @returns JSON object - */ -toJSON(): { [k: string]: any }; - - /** - * Gets the default type url for SourceCodeInfo - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ -static getTypeUrl(typeUrlPrefix?: string): string; - } - - namespace SourceCodeInfo { - - /** Properties of a Location. */ - interface ILocation { - - /** Location path */ - path?: (number[]|null); - - /** Location span */ - span?: (number[]|null); - - /** Location leadingComments */ - leadingComments?: (string|null); - - /** Location trailingComments */ - trailingComments?: (string|null); - - /** Location leadingDetachedComments */ - leadingDetachedComments?: (string[]|null); - } - - /** Represents a Location. */ - class Location implements ILocation { - - /** - * Constructs a new Location. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.SourceCodeInfo.ILocation); - - /** Location path. */ -path: number[]; - - /** Location span. */ -span: number[]; - - /** Location leadingComments. */ -leadingComments: string; - - /** Location trailingComments. */ -trailingComments: string; - - /** Location leadingDetachedComments. */ -leadingDetachedComments: string[]; - - /** - * Creates a new Location instance using the specified properties. - * @param [properties] Properties to set - * @returns Location instance - */ -static create(properties?: google.protobuf.SourceCodeInfo.ILocation): google.protobuf.SourceCodeInfo.Location; - - /** - * Encodes the specified Location message. Does not implicitly {@link google.protobuf.SourceCodeInfo.Location.verify|verify} messages. - * @param message Location message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.SourceCodeInfo.ILocation, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified Location message, length delimited. Does not implicitly {@link google.protobuf.SourceCodeInfo.Location.verify|verify} messages. - * @param message Location message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.SourceCodeInfo.ILocation, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes a Location message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns Location - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.SourceCodeInfo.Location; - - /** - * Decodes a Location message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns Location - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.SourceCodeInfo.Location; - - /** - * Verifies a Location message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ -static verify(message: { [k: string]: any }): (string|null); - - /** - * Creates a Location message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns Location - */ -static fromObject(object: { [k: string]: any }): google.protobuf.SourceCodeInfo.Location; - - /** - * Creates a plain object from a Location message. Also converts values to other types if specified. - * @param message Location - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.SourceCodeInfo.Location, options?: $protobuf.IConversionOptions): { [k: string]: any }; - - /** - * Converts this Location to JSON. - * @returns JSON object - */ -toJSON(): { [k: string]: any }; - - /** - * Gets the default type url for Location - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ -static getTypeUrl(typeUrlPrefix?: string): string; - } - } - - /** Properties of a GeneratedCodeInfo. */ - interface IGeneratedCodeInfo { - - /** GeneratedCodeInfo annotation */ - annotation?: (google.protobuf.GeneratedCodeInfo.IAnnotation[]|null); - } - - /** Represents a GeneratedCodeInfo. */ - class GeneratedCodeInfo implements IGeneratedCodeInfo { - - /** - * Constructs a new GeneratedCodeInfo. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.IGeneratedCodeInfo); - - /** GeneratedCodeInfo annotation. */ -annotation: google.protobuf.GeneratedCodeInfo.IAnnotation[]; - - /** - * Creates a new GeneratedCodeInfo instance using the specified properties. - * @param [properties] Properties to set - * @returns GeneratedCodeInfo instance - */ -static create(properties?: google.protobuf.IGeneratedCodeInfo): google.protobuf.GeneratedCodeInfo; - - /** - * Encodes the specified GeneratedCodeInfo message. Does not implicitly {@link google.protobuf.GeneratedCodeInfo.verify|verify} messages. - * @param message GeneratedCodeInfo message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.IGeneratedCodeInfo, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified GeneratedCodeInfo message, length delimited. Does not implicitly {@link google.protobuf.GeneratedCodeInfo.verify|verify} messages. - * @param message GeneratedCodeInfo message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.IGeneratedCodeInfo, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes a GeneratedCodeInfo message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns GeneratedCodeInfo - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.GeneratedCodeInfo; - - /** - * Decodes a GeneratedCodeInfo message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns GeneratedCodeInfo - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.GeneratedCodeInfo; - - /** - * Verifies a GeneratedCodeInfo message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ -static verify(message: { [k: string]: any }): (string|null); - - /** - * Creates a GeneratedCodeInfo message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns GeneratedCodeInfo - */ -static fromObject(object: { [k: string]: any }): google.protobuf.GeneratedCodeInfo; - - /** - * Creates a plain object from a GeneratedCodeInfo message. Also converts values to other types if specified. - * @param message GeneratedCodeInfo - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.GeneratedCodeInfo, options?: $protobuf.IConversionOptions): { [k: string]: any }; - - /** - * Converts this GeneratedCodeInfo to JSON. - * @returns JSON object - */ -toJSON(): { [k: string]: any }; - - /** - * Gets the default type url for GeneratedCodeInfo - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ -static getTypeUrl(typeUrlPrefix?: string): string; - } - - namespace GeneratedCodeInfo { - - /** Properties of an Annotation. */ - interface IAnnotation { - - /** Annotation path */ - path?: (number[]|null); - - /** Annotation sourceFile */ - sourceFile?: (string|null); - - /** Annotation begin */ - begin?: (number|null); - - /** Annotation end */ - end?: (number|null); - - /** Annotation semantic */ - semantic?: (google.protobuf.GeneratedCodeInfo.Annotation.Semantic|null); - } - - /** Represents an Annotation. */ - class Annotation implements IAnnotation { - - /** - * Constructs a new Annotation. - * @param [properties] Properties to set - */ - constructor(properties?: google.protobuf.GeneratedCodeInfo.IAnnotation); - - /** Annotation path. */ -path: number[]; - - /** Annotation sourceFile. */ -sourceFile: string; - - /** Annotation begin. */ -begin: number; - - /** Annotation end. */ -end: number; - - /** Annotation semantic. */ -semantic: google.protobuf.GeneratedCodeInfo.Annotation.Semantic; - - /** - * Creates a new Annotation instance using the specified properties. - * @param [properties] Properties to set - * @returns Annotation instance - */ -static create(properties?: google.protobuf.GeneratedCodeInfo.IAnnotation): google.protobuf.GeneratedCodeInfo.Annotation; - - /** - * Encodes the specified Annotation message. Does not implicitly {@link google.protobuf.GeneratedCodeInfo.Annotation.verify|verify} messages. - * @param message Annotation message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encode(message: google.protobuf.GeneratedCodeInfo.IAnnotation, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Encodes the specified Annotation message, length delimited. Does not implicitly {@link google.protobuf.GeneratedCodeInfo.Annotation.verify|verify} messages. - * @param message Annotation message or plain object to encode - * @param [writer] Writer to encode to - * @returns Writer - */ -static encodeDelimited(message: google.protobuf.GeneratedCodeInfo.IAnnotation, writer?: $protobuf.Writer): $protobuf.Writer; - - /** - * Decodes an Annotation message from the specified reader or buffer. - * @param reader Reader or buffer to decode from - * @param [length] Message length if known beforehand - * @returns Annotation - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.GeneratedCodeInfo.Annotation; - - /** - * Decodes an Annotation message from the specified reader or buffer, length delimited. - * @param reader Reader or buffer to decode from - * @returns Annotation - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ -static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.GeneratedCodeInfo.Annotation; - - /** - * Verifies an Annotation message. - * @param message Plain object to verify - * @returns `null` if valid, otherwise the reason why it is not - */ -static verify(message: { [k: string]: any }): (string|null); - - /** - * Creates an Annotation message from a plain object. Also converts values to their respective internal types. - * @param object Plain object - * @returns Annotation - */ -static fromObject(object: { [k: string]: any }): google.protobuf.GeneratedCodeInfo.Annotation; - - /** - * Creates a plain object from an Annotation message. Also converts values to other types if specified. - * @param message Annotation - * @param [options] Conversion options - * @returns Plain object - */ -static toObject(message: google.protobuf.GeneratedCodeInfo.Annotation, options?: $protobuf.IConversionOptions): { [k: string]: any }; - - /** - * Converts this Annotation to JSON. - * @returns JSON object - */ -toJSON(): { [k: string]: any }; - - /** - * Gets the default type url for Annotation - * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns The default type url - */ -static getTypeUrl(typeUrlPrefix?: string): string; - } - - namespace Annotation { - - /** Semantic enum. */ - enum Semantic { - NONE = 0, - SET = 1, - ALIAS = 2 - } - } - } - - /** SymbolVisibility enum. */ - enum SymbolVisibility { - VISIBILITY_UNSET = 0, - VISIBILITY_LOCAL = 1, - VISIBILITY_EXPORT = 2 - } + } + + /** EnmRetCode enum. */ + enum EnmRetCode { + SUCCESS = 0, + GenJWTFailed = 5010, + InvalidArg = 5013, + MySQL = 5027, + TokenExpire = 5046, + TokenInvalid = 5047 } } diff --git a/assets/Scripts/proto/proto.pb.js b/assets/Scripts/proto/proto.pb.js index 03f19b69..45e60cab 100644 --- a/assets/Scripts/proto/proto.pb.js +++ b/assets/Scripts/proto/proto.pb.js @@ -4,17943 +4,5532 @@ var $protobuf = require("protobufjs/minimal.js"); // Common aliases -var $Reader = $protobuf.Reader, - $Writer = $protobuf.Writer, - $util = $protobuf.util; +var $Reader = $protobuf.Reader, $Writer = $protobuf.Writer, $util = $protobuf.util; // Exported root namespace var $root = $protobuf.roots["default"] || ($protobuf.roots["default"] = {}); -$root.ProtoMsg = (function () { - /** - * Namespace ProtoMsg. - * @exports ProtoMsg - * @namespace - */ - var ProtoMsg = {}; +$root.cs = (function() { - ProtoMsg.CommonRsp = (function () { /** - * Properties of a CommonRsp. - * @memberof ProtoMsg - * @interface ICommonRsp - * @property {ProtoMsg.ErrorCode|null} [RetCode] CommonRsp RetCode - * @property {string|null} [ErrMsg] CommonRsp ErrMsg - * @property {number|null} [MsgId] CommonRsp MsgId - * @property {number|null} [SubMsgId] CommonRsp SubMsgId - * @property {number|null} [DataType] CommonRsp DataType - * @property {string|null} [Data] CommonRsp Data - */ - - /** - * Constructs a new CommonRsp. - * @memberof ProtoMsg - * @classdesc Represents a CommonRsp. - * @implements ICommonRsp - * @constructor - * @param {ProtoMsg.ICommonRsp=} [properties] Properties to set - */ - function CommonRsp(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]]; - } - - /** - * CommonRsp RetCode. - * @member {ProtoMsg.ErrorCode} RetCode - * @memberof ProtoMsg.CommonRsp - * @instance - */ - CommonRsp.prototype.RetCode = 0; - - /** - * CommonRsp ErrMsg. - * @member {string} ErrMsg - * @memberof ProtoMsg.CommonRsp - * @instance - */ - CommonRsp.prototype.ErrMsg = ""; - - /** - * CommonRsp MsgId. - * @member {number} MsgId - * @memberof ProtoMsg.CommonRsp - * @instance - */ - CommonRsp.prototype.MsgId = 0; - - /** - * CommonRsp SubMsgId. - * @member {number} SubMsgId - * @memberof ProtoMsg.CommonRsp - * @instance - */ - CommonRsp.prototype.SubMsgId = 0; - - /** - * CommonRsp DataType. - * @member {number} DataType - * @memberof ProtoMsg.CommonRsp - * @instance - */ - CommonRsp.prototype.DataType = 0; - - /** - * CommonRsp Data. - * @member {string} Data - * @memberof ProtoMsg.CommonRsp - * @instance - */ - CommonRsp.prototype.Data = ""; - - /** - * Creates a new CommonRsp instance using the specified properties. - * @function create - * @memberof ProtoMsg.CommonRsp - * @static - * @param {ProtoMsg.ICommonRsp=} [properties] Properties to set - * @returns {ProtoMsg.CommonRsp} CommonRsp instance - */ - CommonRsp.create = function create(properties) { - return new CommonRsp(properties); - }; - - /** - * Encodes the specified CommonRsp message. Does not implicitly {@link ProtoMsg.CommonRsp.verify|verify} messages. - * @function encode - * @memberof ProtoMsg.CommonRsp - * @static - * @param {ProtoMsg.ICommonRsp} message CommonRsp message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - CommonRsp.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if ( - message.RetCode != null && - Object.hasOwnProperty.call(message, "RetCode") - ) - writer.uint32(/* id 1, wireType 0 =*/ 8).int32(message.RetCode); - if ( - message.ErrMsg != null && - Object.hasOwnProperty.call(message, "ErrMsg") - ) - writer.uint32(/* id 2, wireType 2 =*/ 18).string(message.ErrMsg); - if (message.MsgId != null && Object.hasOwnProperty.call(message, "MsgId")) - writer.uint32(/* id 3, wireType 0 =*/ 24).int32(message.MsgId); - if ( - message.SubMsgId != null && - Object.hasOwnProperty.call(message, "SubMsgId") - ) - writer.uint32(/* id 4, wireType 0 =*/ 32).int32(message.SubMsgId); - if ( - message.DataType != null && - Object.hasOwnProperty.call(message, "DataType") - ) - writer.uint32(/* id 5, wireType 0 =*/ 40).int32(message.DataType); - if (message.Data != null && Object.hasOwnProperty.call(message, "Data")) - writer.uint32(/* id 6, wireType 2 =*/ 50).string(message.Data); - return writer; - }; - - /** - * Encodes the specified CommonRsp message, length delimited. Does not implicitly {@link ProtoMsg.CommonRsp.verify|verify} messages. - * @function encodeDelimited - * @memberof ProtoMsg.CommonRsp - * @static - * @param {ProtoMsg.ICommonRsp} message CommonRsp message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - CommonRsp.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a CommonRsp message from the specified reader or buffer. - * @function decode - * @memberof ProtoMsg.CommonRsp - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {ProtoMsg.CommonRsp} CommonRsp - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - CommonRsp.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.ProtoMsg.CommonRsp(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - message.RetCode = reader.int32(); - break; - } - case 2: { - message.ErrMsg = reader.string(); - break; - } - case 3: { - message.MsgId = reader.int32(); - break; - } - case 4: { - message.SubMsgId = reader.int32(); - break; - } - case 5: { - message.DataType = reader.int32(); - break; - } - case 6: { - message.Data = reader.string(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a CommonRsp message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof ProtoMsg.CommonRsp - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {ProtoMsg.CommonRsp} CommonRsp - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - CommonRsp.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a CommonRsp message. - * @function verify - * @memberof ProtoMsg.CommonRsp - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - CommonRsp.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.RetCode != null && message.hasOwnProperty("RetCode")) - switch (message.RetCode) { - default: - return "RetCode: enum value expected"; - case 0: - case 1: - case 2: - case 3: - case 4: - case 5: - case 6: - case 7: - case 10: - case 100: - case 101: - case 102: - case 103: - case 104: - case 105: - case 106: - case 107: - break; - } - if (message.ErrMsg != null && message.hasOwnProperty("ErrMsg")) - if (!$util.isString(message.ErrMsg)) return "ErrMsg: string expected"; - if (message.MsgId != null && message.hasOwnProperty("MsgId")) - if (!$util.isInteger(message.MsgId)) return "MsgId: integer expected"; - if (message.SubMsgId != null && message.hasOwnProperty("SubMsgId")) - if (!$util.isInteger(message.SubMsgId)) - return "SubMsgId: integer expected"; - if (message.DataType != null && message.hasOwnProperty("DataType")) - if (!$util.isInteger(message.DataType)) - return "DataType: integer expected"; - if (message.Data != null && message.hasOwnProperty("Data")) - if (!$util.isString(message.Data)) return "Data: string expected"; - return null; - }; - - /** - * Creates a CommonRsp message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof ProtoMsg.CommonRsp - * @static - * @param {Object.} object Plain object - * @returns {ProtoMsg.CommonRsp} CommonRsp - */ - CommonRsp.fromObject = function fromObject(object) { - if (object instanceof $root.ProtoMsg.CommonRsp) return object; - var message = new $root.ProtoMsg.CommonRsp(); - switch (object.RetCode) { - default: - if (typeof object.RetCode === "number") { - message.RetCode = object.RetCode; - break; - } - break; - case "Succeed": - case 0: - message.RetCode = 0; - break; - case "TokenWrong": - case 1: - message.RetCode = 1; - break; - case "TokenExpire": - case 2: - message.RetCode = 2; - break; - case "SystemFail": - case 3: - message.RetCode = 3; - break; - case "RequestParamWrong": - case 4: - message.RetCode = 4; - break; - case "HeaderParamWrong": - case 5: - message.RetCode = 5; - break; - case "ConfigError": - case 6: - message.RetCode = 6; - break; - case "MachineIdentifierNotMathch": - case 7: - message.RetCode = 7; - break; - case "ModuleNotOpen": - case 10: - message.RetCode = 10; - break; - case "SystemError": - case 100: - message.RetCode = 100; - break; - case "RewardClaimed": - case 101: - message.RetCode = 101; - break; - case "ItemNotEnough": - case 102: - message.RetCode = 102; - break; - case "ItemConfigNotExist": - case 103: - message.RetCode = 103; - break; - case "PlayerNotExist": - case 104: - message.RetCode = 104; - break; - case "PlayerLevelNotEnough": - case 105: - message.RetCode = 105; - break; - case "PlayerNameAlreadyExist": - case 106: - message.RetCode = 106; - break; - case "RewardNotAchieve": - case 107: - message.RetCode = 107; - break; - } - if (object.ErrMsg != null) message.ErrMsg = String(object.ErrMsg); - if (object.MsgId != null) message.MsgId = object.MsgId | 0; - if (object.SubMsgId != null) message.SubMsgId = object.SubMsgId | 0; - if (object.DataType != null) message.DataType = object.DataType | 0; - if (object.Data != null) message.Data = String(object.Data); - return message; - }; - - /** - * Creates a plain object from a CommonRsp message. Also converts values to other types if specified. - * @function toObject - * @memberof ProtoMsg.CommonRsp - * @static - * @param {ProtoMsg.CommonRsp} message CommonRsp - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - CommonRsp.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.defaults) { - object.RetCode = options.enums === String ? "Succeed" : 0; - object.ErrMsg = ""; - object.MsgId = 0; - object.SubMsgId = 0; - object.DataType = 0; - object.Data = ""; - } - if (message.RetCode != null && message.hasOwnProperty("RetCode")) - object.RetCode = - options.enums === String - ? $root.ProtoMsg.ErrorCode[message.RetCode] === undefined - ? message.RetCode - : $root.ProtoMsg.ErrorCode[message.RetCode] - : message.RetCode; - if (message.ErrMsg != null && message.hasOwnProperty("ErrMsg")) - object.ErrMsg = message.ErrMsg; - if (message.MsgId != null && message.hasOwnProperty("MsgId")) - object.MsgId = message.MsgId; - if (message.SubMsgId != null && message.hasOwnProperty("SubMsgId")) - object.SubMsgId = message.SubMsgId; - if (message.DataType != null && message.hasOwnProperty("DataType")) - object.DataType = message.DataType; - if (message.Data != null && message.hasOwnProperty("Data")) - object.Data = message.Data; - return object; - }; - - /** - * Converts this CommonRsp to JSON. - * @function toJSON - * @memberof ProtoMsg.CommonRsp - * @instance - * @returns {Object.} JSON object - */ - CommonRsp.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for CommonRsp - * @function getTypeUrl - * @memberof ProtoMsg.CommonRsp - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - CommonRsp.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/ProtoMsg.CommonRsp"; - }; - - return CommonRsp; - })(); - - /** - * MsgId enum. - * @name ProtoMsg.MsgId - * @enum {number} - * @property {number} None=0 None value - * @property {number} Account=1 Account value - * @property {number} PlayerData=2 PlayerData value - * @property {number} Admin=99 Admin value - */ - ProtoMsg.MsgId = (function () { - var valuesById = {}, - values = Object.create(valuesById); - values[(valuesById[0] = "None")] = 0; - values[(valuesById[1] = "Account")] = 1; - values[(valuesById[2] = "PlayerData")] = 2; - values[(valuesById[99] = "Admin")] = 99; - return values; - })(); - - /** - * SubMsgId_Account enum. - * @name ProtoMsg.SubMsgId_Account - * @enum {number} - * @property {number} Account_None=0 Account_None value - * @property {number} Login=1 Login value - */ - ProtoMsg.SubMsgId_Account = (function () { - var valuesById = {}, - values = Object.create(valuesById); - values[(valuesById[0] = "Account_None")] = 0; - values[(valuesById[1] = "Login")] = 1; - return values; - })(); - - /** - * SubMsgId_PlayerData enum. - * @name ProtoMsg.SubMsgId_PlayerData - * @enum {number} - * @property {number} PlayerData_None=0 PlayerData_None value - * @property {number} QueryPlayerData=1 QueryPlayerData value - * @property {number} SavePlayerData=2 SavePlayerData value - */ - ProtoMsg.SubMsgId_PlayerData = (function () { - var valuesById = {}, - values = Object.create(valuesById); - values[(valuesById[0] = "PlayerData_None")] = 0; - values[(valuesById[1] = "QueryPlayerData")] = 1; - values[(valuesById[2] = "SavePlayerData")] = 2; - return values; - })(); - - /** - * ErrorCode enum. - * @name ProtoMsg.ErrorCode - * @enum {number} - * @property {number} Succeed=0 Succeed value - * @property {number} TokenWrong=1 TokenWrong value - * @property {number} TokenExpire=2 TokenExpire value - * @property {number} SystemFail=3 SystemFail value - * @property {number} RequestParamWrong=4 RequestParamWrong value - * @property {number} HeaderParamWrong=5 HeaderParamWrong value - * @property {number} ConfigError=6 ConfigError value - * @property {number} MachineIdentifierNotMathch=7 MachineIdentifierNotMathch value - * @property {number} ModuleNotOpen=10 ModuleNotOpen value - * @property {number} SystemError=100 SystemError value - * @property {number} RewardClaimed=101 RewardClaimed value - * @property {number} ItemNotEnough=102 ItemNotEnough value - * @property {number} ItemConfigNotExist=103 ItemConfigNotExist value - * @property {number} PlayerNotExist=104 PlayerNotExist value - * @property {number} PlayerLevelNotEnough=105 PlayerLevelNotEnough value - * @property {number} PlayerNameAlreadyExist=106 PlayerNameAlreadyExist value - * @property {number} RewardNotAchieve=107 RewardNotAchieve value - */ - ProtoMsg.ErrorCode = (function () { - var valuesById = {}, - values = Object.create(valuesById); - values[(valuesById[0] = "Succeed")] = 0; - values[(valuesById[1] = "TokenWrong")] = 1; - values[(valuesById[2] = "TokenExpire")] = 2; - values[(valuesById[3] = "SystemFail")] = 3; - values[(valuesById[4] = "RequestParamWrong")] = 4; - values[(valuesById[5] = "HeaderParamWrong")] = 5; - values[(valuesById[6] = "ConfigError")] = 6; - values[(valuesById[7] = "MachineIdentifierNotMathch")] = 7; - values[(valuesById[10] = "ModuleNotOpen")] = 10; - values[(valuesById[100] = "SystemError")] = 100; - values[(valuesById[101] = "RewardClaimed")] = 101; - values[(valuesById[102] = "ItemNotEnough")] = 102; - values[(valuesById[103] = "ItemConfigNotExist")] = 103; - values[(valuesById[104] = "PlayerNotExist")] = 104; - values[(valuesById[105] = "PlayerLevelNotEnough")] = 105; - values[(valuesById[106] = "PlayerNameAlreadyExist")] = 106; - values[(valuesById[107] = "RewardNotAchieve")] = 107; - return values; - })(); - - ProtoMsg.LoginReq = (function () { - /** - * Properties of a LoginReq. - * @memberof ProtoMsg - * @interface ILoginReq - * @property {string|null} [GameName] LoginReq GameName - * @property {string|null} [Identifier] LoginReq Identifier - * @property {number|null} [IdentityType] LoginReq IdentityType - * @property {number|null} [OperateType] LoginReq OperateType - * @property {string|null} [ShareDeposit] LoginReq ShareDeposit - * @property {string|null} [MachineIdentifier] LoginReq MachineIdentifier - * @property {string|null} [SdkUid] LoginReq SdkUid - */ - - /** - * Constructs a new LoginReq. - * @memberof ProtoMsg - * @classdesc Represents a LoginReq. - * @implements ILoginReq - * @constructor - * @param {ProtoMsg.ILoginReq=} [properties] Properties to set - */ - function LoginReq(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]]; - } - - /** - * LoginReq GameName. - * @member {string} GameName - * @memberof ProtoMsg.LoginReq - * @instance - */ - LoginReq.prototype.GameName = ""; - - /** - * LoginReq Identifier. - * @member {string} Identifier - * @memberof ProtoMsg.LoginReq - * @instance - */ - LoginReq.prototype.Identifier = ""; - - /** - * LoginReq IdentityType. - * @member {number} IdentityType - * @memberof ProtoMsg.LoginReq - * @instance - */ - LoginReq.prototype.IdentityType = 0; - - /** - * LoginReq OperateType. - * @member {number} OperateType - * @memberof ProtoMsg.LoginReq - * @instance - */ - LoginReq.prototype.OperateType = 0; - - /** - * LoginReq ShareDeposit. - * @member {string} ShareDeposit - * @memberof ProtoMsg.LoginReq - * @instance - */ - LoginReq.prototype.ShareDeposit = ""; - - /** - * LoginReq MachineIdentifier. - * @member {string|null|undefined} MachineIdentifier - * @memberof ProtoMsg.LoginReq - * @instance - */ - LoginReq.prototype.MachineIdentifier = null; - - /** - * LoginReq SdkUid. - * @member {string|null|undefined} SdkUid - * @memberof ProtoMsg.LoginReq - * @instance - */ - LoginReq.prototype.SdkUid = null; - - // OneOf field names bound to virtual getters and setters - var $oneOfFields; - - /** - * LoginReq _MachineIdentifier. - * @member {"MachineIdentifier"|undefined} _MachineIdentifier - * @memberof ProtoMsg.LoginReq - * @instance - */ - Object.defineProperty(LoginReq.prototype, "_MachineIdentifier", { - get: $util.oneOfGetter(($oneOfFields = ["MachineIdentifier"])), - set: $util.oneOfSetter($oneOfFields), - }); - - /** - * LoginReq _SdkUid. - * @member {"SdkUid"|undefined} _SdkUid - * @memberof ProtoMsg.LoginReq - * @instance - */ - Object.defineProperty(LoginReq.prototype, "_SdkUid", { - get: $util.oneOfGetter(($oneOfFields = ["SdkUid"])), - set: $util.oneOfSetter($oneOfFields), - }); - - /** - * Creates a new LoginReq instance using the specified properties. - * @function create - * @memberof ProtoMsg.LoginReq - * @static - * @param {ProtoMsg.ILoginReq=} [properties] Properties to set - * @returns {ProtoMsg.LoginReq} LoginReq instance - */ - LoginReq.create = function create(properties) { - return new LoginReq(properties); - }; - - /** - * Encodes the specified LoginReq message. Does not implicitly {@link ProtoMsg.LoginReq.verify|verify} messages. - * @function encode - * @memberof ProtoMsg.LoginReq - * @static - * @param {ProtoMsg.ILoginReq} message LoginReq message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - LoginReq.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if ( - message.GameName != null && - Object.hasOwnProperty.call(message, "GameName") - ) - writer.uint32(/* id 1, wireType 2 =*/ 10).string(message.GameName); - if ( - message.Identifier != null && - Object.hasOwnProperty.call(message, "Identifier") - ) - writer.uint32(/* id 2, wireType 2 =*/ 18).string(message.Identifier); - if ( - message.IdentityType != null && - Object.hasOwnProperty.call(message, "IdentityType") - ) - writer.uint32(/* id 3, wireType 0 =*/ 24).int32(message.IdentityType); - if ( - message.OperateType != null && - Object.hasOwnProperty.call(message, "OperateType") - ) - writer.uint32(/* id 4, wireType 0 =*/ 32).int32(message.OperateType); - if ( - message.ShareDeposit != null && - Object.hasOwnProperty.call(message, "ShareDeposit") - ) - writer.uint32(/* id 5, wireType 2 =*/ 42).string(message.ShareDeposit); - if ( - message.MachineIdentifier != null && - Object.hasOwnProperty.call(message, "MachineIdentifier") - ) - writer - .uint32(/* id 6, wireType 2 =*/ 50) - .string(message.MachineIdentifier); - if ( - message.SdkUid != null && - Object.hasOwnProperty.call(message, "SdkUid") - ) - writer.uint32(/* id 7, wireType 2 =*/ 58).string(message.SdkUid); - return writer; - }; - - /** - * Encodes the specified LoginReq message, length delimited. Does not implicitly {@link ProtoMsg.LoginReq.verify|verify} messages. - * @function encodeDelimited - * @memberof ProtoMsg.LoginReq - * @static - * @param {ProtoMsg.ILoginReq} message LoginReq message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - LoginReq.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a LoginReq message from the specified reader or buffer. - * @function decode - * @memberof ProtoMsg.LoginReq - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {ProtoMsg.LoginReq} LoginReq - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - LoginReq.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.ProtoMsg.LoginReq(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - message.GameName = reader.string(); - break; - } - case 2: { - message.Identifier = reader.string(); - break; - } - case 3: { - message.IdentityType = reader.int32(); - break; - } - case 4: { - message.OperateType = reader.int32(); - break; - } - case 5: { - message.ShareDeposit = reader.string(); - break; - } - case 6: { - message.MachineIdentifier = reader.string(); - break; - } - case 7: { - message.SdkUid = reader.string(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a LoginReq message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof ProtoMsg.LoginReq - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {ProtoMsg.LoginReq} LoginReq - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - LoginReq.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a LoginReq message. - * @function verify - * @memberof ProtoMsg.LoginReq - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - LoginReq.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - var properties = {}; - if (message.GameName != null && message.hasOwnProperty("GameName")) - if (!$util.isString(message.GameName)) - return "GameName: string expected"; - if (message.Identifier != null && message.hasOwnProperty("Identifier")) - if (!$util.isString(message.Identifier)) - return "Identifier: string expected"; - if ( - message.IdentityType != null && - message.hasOwnProperty("IdentityType") - ) - if (!$util.isInteger(message.IdentityType)) - return "IdentityType: integer expected"; - if (message.OperateType != null && message.hasOwnProperty("OperateType")) - if (!$util.isInteger(message.OperateType)) - return "OperateType: integer expected"; - if ( - message.ShareDeposit != null && - message.hasOwnProperty("ShareDeposit") - ) - if (!$util.isString(message.ShareDeposit)) - return "ShareDeposit: string expected"; - if ( - message.MachineIdentifier != null && - message.hasOwnProperty("MachineIdentifier") - ) { - properties._MachineIdentifier = 1; - if (!$util.isString(message.MachineIdentifier)) - return "MachineIdentifier: string expected"; - } - if (message.SdkUid != null && message.hasOwnProperty("SdkUid")) { - properties._SdkUid = 1; - if (!$util.isString(message.SdkUid)) return "SdkUid: string expected"; - } - return null; - }; - - /** - * Creates a LoginReq message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof ProtoMsg.LoginReq - * @static - * @param {Object.} object Plain object - * @returns {ProtoMsg.LoginReq} LoginReq - */ - LoginReq.fromObject = function fromObject(object) { - if (object instanceof $root.ProtoMsg.LoginReq) return object; - var message = new $root.ProtoMsg.LoginReq(); - if (object.GameName != null) message.GameName = String(object.GameName); - if (object.Identifier != null) - message.Identifier = String(object.Identifier); - if (object.IdentityType != null) - message.IdentityType = object.IdentityType | 0; - if (object.OperateType != null) - message.OperateType = object.OperateType | 0; - if (object.ShareDeposit != null) - message.ShareDeposit = String(object.ShareDeposit); - if (object.MachineIdentifier != null) - message.MachineIdentifier = String(object.MachineIdentifier); - if (object.SdkUid != null) message.SdkUid = String(object.SdkUid); - return message; - }; - - /** - * Creates a plain object from a LoginReq message. Also converts values to other types if specified. - * @function toObject - * @memberof ProtoMsg.LoginReq - * @static - * @param {ProtoMsg.LoginReq} message LoginReq - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - LoginReq.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.defaults) { - object.GameName = ""; - object.Identifier = ""; - object.IdentityType = 0; - object.OperateType = 0; - object.ShareDeposit = ""; - } - if (message.GameName != null && message.hasOwnProperty("GameName")) - object.GameName = message.GameName; - if (message.Identifier != null && message.hasOwnProperty("Identifier")) - object.Identifier = message.Identifier; - if ( - message.IdentityType != null && - message.hasOwnProperty("IdentityType") - ) - object.IdentityType = message.IdentityType; - if (message.OperateType != null && message.hasOwnProperty("OperateType")) - object.OperateType = message.OperateType; - if ( - message.ShareDeposit != null && - message.hasOwnProperty("ShareDeposit") - ) - object.ShareDeposit = message.ShareDeposit; - if ( - message.MachineIdentifier != null && - message.hasOwnProperty("MachineIdentifier") - ) { - object.MachineIdentifier = message.MachineIdentifier; - if (options.oneofs) object._MachineIdentifier = "MachineIdentifier"; - } - if (message.SdkUid != null && message.hasOwnProperty("SdkUid")) { - object.SdkUid = message.SdkUid; - if (options.oneofs) object._SdkUid = "SdkUid"; - } - return object; - }; - - /** - * Converts this LoginReq to JSON. - * @function toJSON - * @memberof ProtoMsg.LoginReq - * @instance - * @returns {Object.} JSON object - */ - LoginReq.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for LoginReq - * @function getTypeUrl - * @memberof ProtoMsg.LoginReq - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - LoginReq.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/ProtoMsg.LoginReq"; - }; - - return LoginReq; - })(); - - ProtoMsg.LoginRsp = (function () { - /** - * Properties of a LoginRsp. - * @memberof ProtoMsg - * @interface ILoginRsp - * @property {string|null} [GameName] LoginRsp GameName - * @property {string|null} [Identifier] LoginRsp Identifier - * @property {number|null} [IdentityType] LoginRsp IdentityType - * @property {number|null} [OperateType] LoginRsp OperateType - * @property {number|Long|null} [Uid] LoginRsp Uid - * @property {string|null} [Token] LoginRsp Token - * @property {number|Long|null} [ServerTime] LoginRsp ServerTime - * @property {number|null} [TimezoneOffset] LoginRsp TimezoneOffset - * @property {string|null} [Ip] LoginRsp Ip - * @property {string|null} [MachineIdentifier] LoginRsp MachineIdentifier - * @property {string|null} [SdkUid] LoginRsp SdkUid - * @property {boolean|null} [IsNewGuide] LoginRsp IsNewGuide - * @property {boolean|null} [IsNewRegist] LoginRsp IsNewRegist - * @property {number|Long|null} [LastLoginTime] LoginRsp LastLoginTime - */ - - /** - * Constructs a new LoginRsp. - * @memberof ProtoMsg - * @classdesc Represents a LoginRsp. - * @implements ILoginRsp - * @constructor - * @param {ProtoMsg.ILoginRsp=} [properties] Properties to set - */ - function LoginRsp(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]]; - } - - /** - * LoginRsp GameName. - * @member {string} GameName - * @memberof ProtoMsg.LoginRsp - * @instance - */ - LoginRsp.prototype.GameName = ""; - - /** - * LoginRsp Identifier. - * @member {string} Identifier - * @memberof ProtoMsg.LoginRsp - * @instance - */ - LoginRsp.prototype.Identifier = ""; - - /** - * LoginRsp IdentityType. - * @member {number} IdentityType - * @memberof ProtoMsg.LoginRsp - * @instance - */ - LoginRsp.prototype.IdentityType = 0; - - /** - * LoginRsp OperateType. - * @member {number} OperateType - * @memberof ProtoMsg.LoginRsp - * @instance - */ - LoginRsp.prototype.OperateType = 0; - - /** - * LoginRsp Uid. - * @member {number|Long} Uid - * @memberof ProtoMsg.LoginRsp - * @instance - */ - LoginRsp.prototype.Uid = $util.Long ? $util.Long.fromBits(0, 0, false) : 0; - - /** - * LoginRsp Token. - * @member {string} Token - * @memberof ProtoMsg.LoginRsp - * @instance - */ - LoginRsp.prototype.Token = ""; - - /** - * LoginRsp ServerTime. - * @member {number|Long} ServerTime - * @memberof ProtoMsg.LoginRsp - * @instance - */ - LoginRsp.prototype.ServerTime = $util.Long - ? $util.Long.fromBits(0, 0, false) - : 0; - - /** - * LoginRsp TimezoneOffset. - * @member {number} TimezoneOffset - * @memberof ProtoMsg.LoginRsp - * @instance - */ - LoginRsp.prototype.TimezoneOffset = 0; - - /** - * LoginRsp Ip. - * @member {string} Ip - * @memberof ProtoMsg.LoginRsp - * @instance - */ - LoginRsp.prototype.Ip = ""; - - /** - * LoginRsp MachineIdentifier. - * @member {string|null|undefined} MachineIdentifier - * @memberof ProtoMsg.LoginRsp - * @instance - */ - LoginRsp.prototype.MachineIdentifier = null; - - /** - * LoginRsp SdkUid. - * @member {string|null|undefined} SdkUid - * @memberof ProtoMsg.LoginRsp - * @instance - */ - LoginRsp.prototype.SdkUid = null; - - /** - * LoginRsp IsNewGuide. - * @member {boolean|null|undefined} IsNewGuide - * @memberof ProtoMsg.LoginRsp - * @instance - */ - LoginRsp.prototype.IsNewGuide = null; - - /** - * LoginRsp IsNewRegist. - * @member {boolean|null|undefined} IsNewRegist - * @memberof ProtoMsg.LoginRsp - * @instance - */ - LoginRsp.prototype.IsNewRegist = null; - - /** - * LoginRsp LastLoginTime. - * @member {number|Long|null|undefined} LastLoginTime - * @memberof ProtoMsg.LoginRsp - * @instance - */ - LoginRsp.prototype.LastLoginTime = null; - - // OneOf field names bound to virtual getters and setters - var $oneOfFields; - - /** - * LoginRsp _MachineIdentifier. - * @member {"MachineIdentifier"|undefined} _MachineIdentifier - * @memberof ProtoMsg.LoginRsp - * @instance - */ - Object.defineProperty(LoginRsp.prototype, "_MachineIdentifier", { - get: $util.oneOfGetter(($oneOfFields = ["MachineIdentifier"])), - set: $util.oneOfSetter($oneOfFields), - }); - - /** - * LoginRsp _SdkUid. - * @member {"SdkUid"|undefined} _SdkUid - * @memberof ProtoMsg.LoginRsp - * @instance - */ - Object.defineProperty(LoginRsp.prototype, "_SdkUid", { - get: $util.oneOfGetter(($oneOfFields = ["SdkUid"])), - set: $util.oneOfSetter($oneOfFields), - }); - - /** - * LoginRsp _IsNewGuide. - * @member {"IsNewGuide"|undefined} _IsNewGuide - * @memberof ProtoMsg.LoginRsp - * @instance - */ - Object.defineProperty(LoginRsp.prototype, "_IsNewGuide", { - get: $util.oneOfGetter(($oneOfFields = ["IsNewGuide"])), - set: $util.oneOfSetter($oneOfFields), - }); - - /** - * LoginRsp _IsNewRegist. - * @member {"IsNewRegist"|undefined} _IsNewRegist - * @memberof ProtoMsg.LoginRsp - * @instance - */ - Object.defineProperty(LoginRsp.prototype, "_IsNewRegist", { - get: $util.oneOfGetter(($oneOfFields = ["IsNewRegist"])), - set: $util.oneOfSetter($oneOfFields), - }); - - /** - * LoginRsp _LastLoginTime. - * @member {"LastLoginTime"|undefined} _LastLoginTime - * @memberof ProtoMsg.LoginRsp - * @instance - */ - Object.defineProperty(LoginRsp.prototype, "_LastLoginTime", { - get: $util.oneOfGetter(($oneOfFields = ["LastLoginTime"])), - set: $util.oneOfSetter($oneOfFields), - }); - - /** - * Creates a new LoginRsp instance using the specified properties. - * @function create - * @memberof ProtoMsg.LoginRsp - * @static - * @param {ProtoMsg.ILoginRsp=} [properties] Properties to set - * @returns {ProtoMsg.LoginRsp} LoginRsp instance - */ - LoginRsp.create = function create(properties) { - return new LoginRsp(properties); - }; - - /** - * Encodes the specified LoginRsp message. Does not implicitly {@link ProtoMsg.LoginRsp.verify|verify} messages. - * @function encode - * @memberof ProtoMsg.LoginRsp - * @static - * @param {ProtoMsg.ILoginRsp} message LoginRsp message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - LoginRsp.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if ( - message.GameName != null && - Object.hasOwnProperty.call(message, "GameName") - ) - writer.uint32(/* id 1, wireType 2 =*/ 10).string(message.GameName); - if ( - message.Identifier != null && - Object.hasOwnProperty.call(message, "Identifier") - ) - writer.uint32(/* id 2, wireType 2 =*/ 18).string(message.Identifier); - if ( - message.IdentityType != null && - Object.hasOwnProperty.call(message, "IdentityType") - ) - writer.uint32(/* id 3, wireType 0 =*/ 24).int32(message.IdentityType); - if ( - message.OperateType != null && - Object.hasOwnProperty.call(message, "OperateType") - ) - writer.uint32(/* id 4, wireType 0 =*/ 32).int32(message.OperateType); - if (message.Uid != null && Object.hasOwnProperty.call(message, "Uid")) - writer.uint32(/* id 5, wireType 0 =*/ 40).int64(message.Uid); - if (message.Token != null && Object.hasOwnProperty.call(message, "Token")) - writer.uint32(/* id 6, wireType 2 =*/ 50).string(message.Token); - if ( - message.ServerTime != null && - Object.hasOwnProperty.call(message, "ServerTime") - ) - writer.uint32(/* id 7, wireType 0 =*/ 56).int64(message.ServerTime); - if ( - message.TimezoneOffset != null && - Object.hasOwnProperty.call(message, "TimezoneOffset") - ) - writer.uint32(/* id 8, wireType 0 =*/ 64).int32(message.TimezoneOffset); - if (message.Ip != null && Object.hasOwnProperty.call(message, "Ip")) - writer.uint32(/* id 10, wireType 2 =*/ 82).string(message.Ip); - if ( - message.MachineIdentifier != null && - Object.hasOwnProperty.call(message, "MachineIdentifier") - ) - writer - .uint32(/* id 11, wireType 2 =*/ 90) - .string(message.MachineIdentifier); - if ( - message.SdkUid != null && - Object.hasOwnProperty.call(message, "SdkUid") - ) - writer.uint32(/* id 12, wireType 2 =*/ 98).string(message.SdkUid); - if ( - message.IsNewGuide != null && - Object.hasOwnProperty.call(message, "IsNewGuide") - ) - writer.uint32(/* id 13, wireType 0 =*/ 104).bool(message.IsNewGuide); - if ( - message.IsNewRegist != null && - Object.hasOwnProperty.call(message, "IsNewRegist") - ) - writer.uint32(/* id 14, wireType 0 =*/ 112).bool(message.IsNewRegist); - if ( - message.LastLoginTime != null && - Object.hasOwnProperty.call(message, "LastLoginTime") - ) - writer - .uint32(/* id 15, wireType 0 =*/ 120) - .int64(message.LastLoginTime); - return writer; - }; - - /** - * Encodes the specified LoginRsp message, length delimited. Does not implicitly {@link ProtoMsg.LoginRsp.verify|verify} messages. - * @function encodeDelimited - * @memberof ProtoMsg.LoginRsp - * @static - * @param {ProtoMsg.ILoginRsp} message LoginRsp message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - LoginRsp.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a LoginRsp message from the specified reader or buffer. - * @function decode - * @memberof ProtoMsg.LoginRsp - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {ProtoMsg.LoginRsp} LoginRsp - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - LoginRsp.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.ProtoMsg.LoginRsp(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - message.GameName = reader.string(); - break; - } - case 2: { - message.Identifier = reader.string(); - break; - } - case 3: { - message.IdentityType = reader.int32(); - break; - } - case 4: { - message.OperateType = reader.int32(); - break; - } - case 5: { - message.Uid = reader.int64(); - break; - } - case 6: { - message.Token = reader.string(); - break; - } - case 7: { - message.ServerTime = reader.int64(); - break; - } - case 8: { - message.TimezoneOffset = reader.int32(); - break; - } - case 10: { - message.Ip = reader.string(); - break; - } - case 11: { - message.MachineIdentifier = reader.string(); - break; - } - case 12: { - message.SdkUid = reader.string(); - break; - } - case 13: { - message.IsNewGuide = reader.bool(); - break; - } - case 14: { - message.IsNewRegist = reader.bool(); - break; - } - case 15: { - message.LastLoginTime = reader.int64(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a LoginRsp message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof ProtoMsg.LoginRsp - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {ProtoMsg.LoginRsp} LoginRsp - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - LoginRsp.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a LoginRsp message. - * @function verify - * @memberof ProtoMsg.LoginRsp - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - LoginRsp.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - var properties = {}; - if (message.GameName != null && message.hasOwnProperty("GameName")) - if (!$util.isString(message.GameName)) - return "GameName: string expected"; - if (message.Identifier != null && message.hasOwnProperty("Identifier")) - if (!$util.isString(message.Identifier)) - return "Identifier: string expected"; - if ( - message.IdentityType != null && - message.hasOwnProperty("IdentityType") - ) - if (!$util.isInteger(message.IdentityType)) - return "IdentityType: integer expected"; - if (message.OperateType != null && message.hasOwnProperty("OperateType")) - if (!$util.isInteger(message.OperateType)) - return "OperateType: integer expected"; - if (message.Uid != null && message.hasOwnProperty("Uid")) - if ( - !$util.isInteger(message.Uid) && - !( - message.Uid && - $util.isInteger(message.Uid.low) && - $util.isInteger(message.Uid.high) - ) - ) - return "Uid: integer|Long expected"; - if (message.Token != null && message.hasOwnProperty("Token")) - if (!$util.isString(message.Token)) return "Token: string expected"; - if (message.ServerTime != null && message.hasOwnProperty("ServerTime")) - if ( - !$util.isInteger(message.ServerTime) && - !( - message.ServerTime && - $util.isInteger(message.ServerTime.low) && - $util.isInteger(message.ServerTime.high) - ) - ) - return "ServerTime: integer|Long expected"; - if ( - message.TimezoneOffset != null && - message.hasOwnProperty("TimezoneOffset") - ) - if (!$util.isInteger(message.TimezoneOffset)) - return "TimezoneOffset: integer expected"; - if (message.Ip != null && message.hasOwnProperty("Ip")) - if (!$util.isString(message.Ip)) return "Ip: string expected"; - if ( - message.MachineIdentifier != null && - message.hasOwnProperty("MachineIdentifier") - ) { - properties._MachineIdentifier = 1; - if (!$util.isString(message.MachineIdentifier)) - return "MachineIdentifier: string expected"; - } - if (message.SdkUid != null && message.hasOwnProperty("SdkUid")) { - properties._SdkUid = 1; - if (!$util.isString(message.SdkUid)) return "SdkUid: string expected"; - } - if (message.IsNewGuide != null && message.hasOwnProperty("IsNewGuide")) { - properties._IsNewGuide = 1; - if (typeof message.IsNewGuide !== "boolean") - return "IsNewGuide: boolean expected"; - } - if ( - message.IsNewRegist != null && - message.hasOwnProperty("IsNewRegist") - ) { - properties._IsNewRegist = 1; - if (typeof message.IsNewRegist !== "boolean") - return "IsNewRegist: boolean expected"; - } - if ( - message.LastLoginTime != null && - message.hasOwnProperty("LastLoginTime") - ) { - properties._LastLoginTime = 1; - if ( - !$util.isInteger(message.LastLoginTime) && - !( - message.LastLoginTime && - $util.isInteger(message.LastLoginTime.low) && - $util.isInteger(message.LastLoginTime.high) - ) - ) - return "LastLoginTime: integer|Long expected"; - } - return null; - }; - - /** - * Creates a LoginRsp message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof ProtoMsg.LoginRsp - * @static - * @param {Object.} object Plain object - * @returns {ProtoMsg.LoginRsp} LoginRsp - */ - LoginRsp.fromObject = function fromObject(object) { - if (object instanceof $root.ProtoMsg.LoginRsp) return object; - var message = new $root.ProtoMsg.LoginRsp(); - if (object.GameName != null) message.GameName = String(object.GameName); - if (object.Identifier != null) - message.Identifier = String(object.Identifier); - if (object.IdentityType != null) - message.IdentityType = object.IdentityType | 0; - if (object.OperateType != null) - message.OperateType = object.OperateType | 0; - if (object.Uid != null) - if ($util.Long) - (message.Uid = $util.Long.fromValue(object.Uid)).unsigned = false; - else if (typeof object.Uid === "string") - message.Uid = parseInt(object.Uid, 10); - else if (typeof object.Uid === "number") message.Uid = object.Uid; - else if (typeof object.Uid === "object") - message.Uid = new $util.LongBits( - object.Uid.low >>> 0, - object.Uid.high >>> 0 - ).toNumber(); - if (object.Token != null) message.Token = String(object.Token); - if (object.ServerTime != null) - if ($util.Long) - (message.ServerTime = $util.Long.fromValue( - object.ServerTime - )).unsigned = false; - else if (typeof object.ServerTime === "string") - message.ServerTime = parseInt(object.ServerTime, 10); - else if (typeof object.ServerTime === "number") - message.ServerTime = object.ServerTime; - else if (typeof object.ServerTime === "object") - message.ServerTime = new $util.LongBits( - object.ServerTime.low >>> 0, - object.ServerTime.high >>> 0 - ).toNumber(); - if (object.TimezoneOffset != null) - message.TimezoneOffset = object.TimezoneOffset | 0; - if (object.Ip != null) message.Ip = String(object.Ip); - if (object.MachineIdentifier != null) - message.MachineIdentifier = String(object.MachineIdentifier); - if (object.SdkUid != null) message.SdkUid = String(object.SdkUid); - if (object.IsNewGuide != null) - message.IsNewGuide = Boolean(object.IsNewGuide); - if (object.IsNewRegist != null) - message.IsNewRegist = Boolean(object.IsNewRegist); - if (object.LastLoginTime != null) - if ($util.Long) - (message.LastLoginTime = $util.Long.fromValue( - object.LastLoginTime - )).unsigned = false; - else if (typeof object.LastLoginTime === "string") - message.LastLoginTime = parseInt(object.LastLoginTime, 10); - else if (typeof object.LastLoginTime === "number") - message.LastLoginTime = object.LastLoginTime; - else if (typeof object.LastLoginTime === "object") - message.LastLoginTime = new $util.LongBits( - object.LastLoginTime.low >>> 0, - object.LastLoginTime.high >>> 0 - ).toNumber(); - return message; - }; - - /** - * Creates a plain object from a LoginRsp message. Also converts values to other types if specified. - * @function toObject - * @memberof ProtoMsg.LoginRsp - * @static - * @param {ProtoMsg.LoginRsp} message LoginRsp - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - LoginRsp.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.defaults) { - object.GameName = ""; - object.Identifier = ""; - object.IdentityType = 0; - object.OperateType = 0; - if ($util.Long) { - var long = new $util.Long(0, 0, false); - object.Uid = - options.longs === String - ? long.toString() - : options.longs === Number - ? long.toNumber() - : long; - } else object.Uid = options.longs === String ? "0" : 0; - object.Token = ""; - if ($util.Long) { - var long = new $util.Long(0, 0, false); - object.ServerTime = - options.longs === String - ? long.toString() - : options.longs === Number - ? long.toNumber() - : long; - } else object.ServerTime = options.longs === String ? "0" : 0; - object.TimezoneOffset = 0; - object.Ip = ""; - } - if (message.GameName != null && message.hasOwnProperty("GameName")) - object.GameName = message.GameName; - if (message.Identifier != null && message.hasOwnProperty("Identifier")) - object.Identifier = message.Identifier; - if ( - message.IdentityType != null && - message.hasOwnProperty("IdentityType") - ) - object.IdentityType = message.IdentityType; - if (message.OperateType != null && message.hasOwnProperty("OperateType")) - object.OperateType = message.OperateType; - if (message.Uid != null && message.hasOwnProperty("Uid")) - if (typeof message.Uid === "number") - object.Uid = - options.longs === String ? String(message.Uid) : message.Uid; - else - object.Uid = - options.longs === String - ? $util.Long.prototype.toString.call(message.Uid) - : options.longs === Number - ? new $util.LongBits( - message.Uid.low >>> 0, - message.Uid.high >>> 0 - ).toNumber() - : message.Uid; - if (message.Token != null && message.hasOwnProperty("Token")) - object.Token = message.Token; - if (message.ServerTime != null && message.hasOwnProperty("ServerTime")) - if (typeof message.ServerTime === "number") - object.ServerTime = - options.longs === String - ? String(message.ServerTime) - : message.ServerTime; - else - object.ServerTime = - options.longs === String - ? $util.Long.prototype.toString.call(message.ServerTime) - : options.longs === Number - ? new $util.LongBits( - message.ServerTime.low >>> 0, - message.ServerTime.high >>> 0 - ).toNumber() - : message.ServerTime; - if ( - message.TimezoneOffset != null && - message.hasOwnProperty("TimezoneOffset") - ) - object.TimezoneOffset = message.TimezoneOffset; - if (message.Ip != null && message.hasOwnProperty("Ip")) - object.Ip = message.Ip; - if ( - message.MachineIdentifier != null && - message.hasOwnProperty("MachineIdentifier") - ) { - object.MachineIdentifier = message.MachineIdentifier; - if (options.oneofs) object._MachineIdentifier = "MachineIdentifier"; - } - if (message.SdkUid != null && message.hasOwnProperty("SdkUid")) { - object.SdkUid = message.SdkUid; - if (options.oneofs) object._SdkUid = "SdkUid"; - } - if (message.IsNewGuide != null && message.hasOwnProperty("IsNewGuide")) { - object.IsNewGuide = message.IsNewGuide; - if (options.oneofs) object._IsNewGuide = "IsNewGuide"; - } - if ( - message.IsNewRegist != null && - message.hasOwnProperty("IsNewRegist") - ) { - object.IsNewRegist = message.IsNewRegist; - if (options.oneofs) object._IsNewRegist = "IsNewRegist"; - } - if ( - message.LastLoginTime != null && - message.hasOwnProperty("LastLoginTime") - ) { - if (typeof message.LastLoginTime === "number") - object.LastLoginTime = - options.longs === String - ? String(message.LastLoginTime) - : message.LastLoginTime; - else - object.LastLoginTime = - options.longs === String - ? $util.Long.prototype.toString.call(message.LastLoginTime) - : options.longs === Number - ? new $util.LongBits( - message.LastLoginTime.low >>> 0, - message.LastLoginTime.high >>> 0 - ).toNumber() - : message.LastLoginTime; - if (options.oneofs) object._LastLoginTime = "LastLoginTime"; - } - return object; - }; - - /** - * Converts this LoginRsp to JSON. - * @function toJSON - * @memberof ProtoMsg.LoginRsp - * @instance - * @returns {Object.} JSON object - */ - LoginRsp.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for LoginRsp - * @function getTypeUrl - * @memberof ProtoMsg.LoginRsp - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - LoginRsp.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/ProtoMsg.LoginRsp"; - }; - - return LoginRsp; - })(); - - ProtoMsg.QueryPlayerDataReq = (function () { - /** - * Properties of a QueryPlayerDataReq. - * @memberof ProtoMsg - * @interface IQueryPlayerDataReq - * @property {boolean|null} [IsAll] QueryPlayerDataReq IsAll - * @property {string|null} [GameName] QueryPlayerDataReq GameName - * @property {Array.|null} [DataFlagList] QueryPlayerDataReq DataFlagList - */ - - /** - * Constructs a new QueryPlayerDataReq. - * @memberof ProtoMsg - * @classdesc Represents a QueryPlayerDataReq. - * @implements IQueryPlayerDataReq - * @constructor - * @param {ProtoMsg.IQueryPlayerDataReq=} [properties] Properties to set - */ - function QueryPlayerDataReq(properties) { - this.DataFlagList = []; - 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]]; - } - - /** - * QueryPlayerDataReq IsAll. - * @member {boolean} IsAll - * @memberof ProtoMsg.QueryPlayerDataReq - * @instance - */ - QueryPlayerDataReq.prototype.IsAll = false; - - /** - * QueryPlayerDataReq GameName. - * @member {string} GameName - * @memberof ProtoMsg.QueryPlayerDataReq - * @instance - */ - QueryPlayerDataReq.prototype.GameName = ""; - - /** - * QueryPlayerDataReq DataFlagList. - * @member {Array.} DataFlagList - * @memberof ProtoMsg.QueryPlayerDataReq - * @instance - */ - QueryPlayerDataReq.prototype.DataFlagList = $util.emptyArray; - - /** - * Creates a new QueryPlayerDataReq instance using the specified properties. - * @function create - * @memberof ProtoMsg.QueryPlayerDataReq - * @static - * @param {ProtoMsg.IQueryPlayerDataReq=} [properties] Properties to set - * @returns {ProtoMsg.QueryPlayerDataReq} QueryPlayerDataReq instance - */ - QueryPlayerDataReq.create = function create(properties) { - return new QueryPlayerDataReq(properties); - }; - - /** - * Encodes the specified QueryPlayerDataReq message. Does not implicitly {@link ProtoMsg.QueryPlayerDataReq.verify|verify} messages. - * @function encode - * @memberof ProtoMsg.QueryPlayerDataReq - * @static - * @param {ProtoMsg.IQueryPlayerDataReq} message QueryPlayerDataReq message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - QueryPlayerDataReq.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if (message.IsAll != null && Object.hasOwnProperty.call(message, "IsAll")) - writer.uint32(/* id 1, wireType 0 =*/ 8).bool(message.IsAll); - if ( - message.GameName != null && - Object.hasOwnProperty.call(message, "GameName") - ) - writer.uint32(/* id 2, wireType 2 =*/ 18).string(message.GameName); - if (message.DataFlagList != null && message.DataFlagList.length) - for (var i = 0; i < message.DataFlagList.length; ++i) - writer - .uint32(/* id 3, wireType 2 =*/ 26) - .string(message.DataFlagList[i]); - return writer; - }; - - /** - * Encodes the specified QueryPlayerDataReq message, length delimited. Does not implicitly {@link ProtoMsg.QueryPlayerDataReq.verify|verify} messages. - * @function encodeDelimited - * @memberof ProtoMsg.QueryPlayerDataReq - * @static - * @param {ProtoMsg.IQueryPlayerDataReq} message QueryPlayerDataReq message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - QueryPlayerDataReq.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a QueryPlayerDataReq message from the specified reader or buffer. - * @function decode - * @memberof ProtoMsg.QueryPlayerDataReq - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {ProtoMsg.QueryPlayerDataReq} QueryPlayerDataReq - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - QueryPlayerDataReq.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.ProtoMsg.QueryPlayerDataReq(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - message.IsAll = reader.bool(); - break; - } - case 2: { - message.GameName = reader.string(); - break; - } - case 3: { - if (!(message.DataFlagList && message.DataFlagList.length)) - message.DataFlagList = []; - message.DataFlagList.push(reader.string()); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a QueryPlayerDataReq message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof ProtoMsg.QueryPlayerDataReq - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {ProtoMsg.QueryPlayerDataReq} QueryPlayerDataReq - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - QueryPlayerDataReq.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a QueryPlayerDataReq message. - * @function verify - * @memberof ProtoMsg.QueryPlayerDataReq - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - QueryPlayerDataReq.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.IsAll != null && message.hasOwnProperty("IsAll")) - if (typeof message.IsAll !== "boolean") - return "IsAll: boolean expected"; - if (message.GameName != null && message.hasOwnProperty("GameName")) - if (!$util.isString(message.GameName)) - return "GameName: string expected"; - if ( - message.DataFlagList != null && - message.hasOwnProperty("DataFlagList") - ) { - if (!Array.isArray(message.DataFlagList)) - return "DataFlagList: array expected"; - for (var i = 0; i < message.DataFlagList.length; ++i) - if (!$util.isString(message.DataFlagList[i])) - return "DataFlagList: string[] expected"; - } - return null; - }; - - /** - * Creates a QueryPlayerDataReq message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof ProtoMsg.QueryPlayerDataReq - * @static - * @param {Object.} object Plain object - * @returns {ProtoMsg.QueryPlayerDataReq} QueryPlayerDataReq - */ - QueryPlayerDataReq.fromObject = function fromObject(object) { - if (object instanceof $root.ProtoMsg.QueryPlayerDataReq) return object; - var message = new $root.ProtoMsg.QueryPlayerDataReq(); - if (object.IsAll != null) message.IsAll = Boolean(object.IsAll); - if (object.GameName != null) message.GameName = String(object.GameName); - if (object.DataFlagList) { - if (!Array.isArray(object.DataFlagList)) - throw TypeError( - ".ProtoMsg.QueryPlayerDataReq.DataFlagList: array expected" - ); - message.DataFlagList = []; - for (var i = 0; i < object.DataFlagList.length; ++i) - message.DataFlagList[i] = String(object.DataFlagList[i]); - } - return message; - }; - - /** - * Creates a plain object from a QueryPlayerDataReq message. Also converts values to other types if specified. - * @function toObject - * @memberof ProtoMsg.QueryPlayerDataReq - * @static - * @param {ProtoMsg.QueryPlayerDataReq} message QueryPlayerDataReq - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - QueryPlayerDataReq.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.arrays || options.defaults) object.DataFlagList = []; - if (options.defaults) { - object.IsAll = false; - object.GameName = ""; - } - if (message.IsAll != null && message.hasOwnProperty("IsAll")) - object.IsAll = message.IsAll; - if (message.GameName != null && message.hasOwnProperty("GameName")) - object.GameName = message.GameName; - if (message.DataFlagList && message.DataFlagList.length) { - object.DataFlagList = []; - for (var j = 0; j < message.DataFlagList.length; ++j) - object.DataFlagList[j] = message.DataFlagList[j]; - } - return object; - }; - - /** - * Converts this QueryPlayerDataReq to JSON. - * @function toJSON - * @memberof ProtoMsg.QueryPlayerDataReq - * @instance - * @returns {Object.} JSON object - */ - QueryPlayerDataReq.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for QueryPlayerDataReq - * @function getTypeUrl - * @memberof ProtoMsg.QueryPlayerDataReq - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - QueryPlayerDataReq.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/ProtoMsg.QueryPlayerDataReq"; - }; - - return QueryPlayerDataReq; - })(); - - ProtoMsg.QueryPlayerDataRsp = (function () { - /** - * Properties of a QueryPlayerDataRsp. - * @memberof ProtoMsg - * @interface IQueryPlayerDataRsp - * @property {boolean|null} [IsAll] QueryPlayerDataRsp IsAll - * @property {string|null} [GameName] QueryPlayerDataRsp GameName - * @property {Array.|null} [PlayerDataList] QueryPlayerDataRsp PlayerDataList - */ - - /** - * Constructs a new QueryPlayerDataRsp. - * @memberof ProtoMsg - * @classdesc Represents a QueryPlayerDataRsp. - * @implements IQueryPlayerDataRsp - * @constructor - * @param {ProtoMsg.IQueryPlayerDataRsp=} [properties] Properties to set - */ - function QueryPlayerDataRsp(properties) { - this.PlayerDataList = []; - 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]]; - } - - /** - * QueryPlayerDataRsp IsAll. - * @member {boolean} IsAll - * @memberof ProtoMsg.QueryPlayerDataRsp - * @instance - */ - QueryPlayerDataRsp.prototype.IsAll = false; - - /** - * QueryPlayerDataRsp GameName. - * @member {string} GameName - * @memberof ProtoMsg.QueryPlayerDataRsp - * @instance - */ - QueryPlayerDataRsp.prototype.GameName = ""; - - /** - * QueryPlayerDataRsp PlayerDataList. - * @member {Array.} PlayerDataList - * @memberof ProtoMsg.QueryPlayerDataRsp - * @instance - */ - QueryPlayerDataRsp.prototype.PlayerDataList = $util.emptyArray; - - /** - * Creates a new QueryPlayerDataRsp instance using the specified properties. - * @function create - * @memberof ProtoMsg.QueryPlayerDataRsp - * @static - * @param {ProtoMsg.IQueryPlayerDataRsp=} [properties] Properties to set - * @returns {ProtoMsg.QueryPlayerDataRsp} QueryPlayerDataRsp instance - */ - QueryPlayerDataRsp.create = function create(properties) { - return new QueryPlayerDataRsp(properties); - }; - - /** - * Encodes the specified QueryPlayerDataRsp message. Does not implicitly {@link ProtoMsg.QueryPlayerDataRsp.verify|verify} messages. - * @function encode - * @memberof ProtoMsg.QueryPlayerDataRsp - * @static - * @param {ProtoMsg.IQueryPlayerDataRsp} message QueryPlayerDataRsp message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - QueryPlayerDataRsp.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if (message.IsAll != null && Object.hasOwnProperty.call(message, "IsAll")) - writer.uint32(/* id 1, wireType 0 =*/ 8).bool(message.IsAll); - if ( - message.GameName != null && - Object.hasOwnProperty.call(message, "GameName") - ) - writer.uint32(/* id 2, wireType 2 =*/ 18).string(message.GameName); - if (message.PlayerDataList != null && message.PlayerDataList.length) - for (var i = 0; i < message.PlayerDataList.length; ++i) - $root.ProtoMsg.PlayerDataPair.encode( - message.PlayerDataList[i], - writer.uint32(/* id 3, wireType 2 =*/ 26).fork() - ).ldelim(); - return writer; - }; - - /** - * Encodes the specified QueryPlayerDataRsp message, length delimited. Does not implicitly {@link ProtoMsg.QueryPlayerDataRsp.verify|verify} messages. - * @function encodeDelimited - * @memberof ProtoMsg.QueryPlayerDataRsp - * @static - * @param {ProtoMsg.IQueryPlayerDataRsp} message QueryPlayerDataRsp message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - QueryPlayerDataRsp.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a QueryPlayerDataRsp message from the specified reader or buffer. - * @function decode - * @memberof ProtoMsg.QueryPlayerDataRsp - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {ProtoMsg.QueryPlayerDataRsp} QueryPlayerDataRsp - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - QueryPlayerDataRsp.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.ProtoMsg.QueryPlayerDataRsp(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - message.IsAll = reader.bool(); - break; - } - case 2: { - message.GameName = reader.string(); - break; - } - case 3: { - if (!(message.PlayerDataList && message.PlayerDataList.length)) - message.PlayerDataList = []; - message.PlayerDataList.push( - $root.ProtoMsg.PlayerDataPair.decode(reader, reader.uint32()) - ); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a QueryPlayerDataRsp message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof ProtoMsg.QueryPlayerDataRsp - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {ProtoMsg.QueryPlayerDataRsp} QueryPlayerDataRsp - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - QueryPlayerDataRsp.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a QueryPlayerDataRsp message. - * @function verify - * @memberof ProtoMsg.QueryPlayerDataRsp - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - QueryPlayerDataRsp.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.IsAll != null && message.hasOwnProperty("IsAll")) - if (typeof message.IsAll !== "boolean") - return "IsAll: boolean expected"; - if (message.GameName != null && message.hasOwnProperty("GameName")) - if (!$util.isString(message.GameName)) - return "GameName: string expected"; - if ( - message.PlayerDataList != null && - message.hasOwnProperty("PlayerDataList") - ) { - if (!Array.isArray(message.PlayerDataList)) - return "PlayerDataList: array expected"; - for (var i = 0; i < message.PlayerDataList.length; ++i) { - var error = $root.ProtoMsg.PlayerDataPair.verify( - message.PlayerDataList[i] - ); - if (error) return "PlayerDataList." + error; - } - } - return null; - }; - - /** - * Creates a QueryPlayerDataRsp message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof ProtoMsg.QueryPlayerDataRsp - * @static - * @param {Object.} object Plain object - * @returns {ProtoMsg.QueryPlayerDataRsp} QueryPlayerDataRsp - */ - QueryPlayerDataRsp.fromObject = function fromObject(object) { - if (object instanceof $root.ProtoMsg.QueryPlayerDataRsp) return object; - var message = new $root.ProtoMsg.QueryPlayerDataRsp(); - if (object.IsAll != null) message.IsAll = Boolean(object.IsAll); - if (object.GameName != null) message.GameName = String(object.GameName); - if (object.PlayerDataList) { - if (!Array.isArray(object.PlayerDataList)) - throw TypeError( - ".ProtoMsg.QueryPlayerDataRsp.PlayerDataList: array expected" - ); - message.PlayerDataList = []; - for (var i = 0; i < object.PlayerDataList.length; ++i) { - if (typeof object.PlayerDataList[i] !== "object") - throw TypeError( - ".ProtoMsg.QueryPlayerDataRsp.PlayerDataList: object expected" - ); - message.PlayerDataList[i] = $root.ProtoMsg.PlayerDataPair.fromObject( - object.PlayerDataList[i] - ); - } - } - return message; - }; - - /** - * Creates a plain object from a QueryPlayerDataRsp message. Also converts values to other types if specified. - * @function toObject - * @memberof ProtoMsg.QueryPlayerDataRsp - * @static - * @param {ProtoMsg.QueryPlayerDataRsp} message QueryPlayerDataRsp - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - QueryPlayerDataRsp.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.arrays || options.defaults) object.PlayerDataList = []; - if (options.defaults) { - object.IsAll = false; - object.GameName = ""; - } - if (message.IsAll != null && message.hasOwnProperty("IsAll")) - object.IsAll = message.IsAll; - if (message.GameName != null && message.hasOwnProperty("GameName")) - object.GameName = message.GameName; - if (message.PlayerDataList && message.PlayerDataList.length) { - object.PlayerDataList = []; - for (var j = 0; j < message.PlayerDataList.length; ++j) - object.PlayerDataList[j] = $root.ProtoMsg.PlayerDataPair.toObject( - message.PlayerDataList[j], - options - ); - } - return object; - }; - - /** - * Converts this QueryPlayerDataRsp to JSON. - * @function toJSON - * @memberof ProtoMsg.QueryPlayerDataRsp - * @instance - * @returns {Object.} JSON object - */ - QueryPlayerDataRsp.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for QueryPlayerDataRsp - * @function getTypeUrl - * @memberof ProtoMsg.QueryPlayerDataRsp - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - QueryPlayerDataRsp.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/ProtoMsg.QueryPlayerDataRsp"; - }; - - return QueryPlayerDataRsp; - })(); - - ProtoMsg.PlayerDataPair = (function () { - /** - * Properties of a PlayerDataPair. - * @memberof ProtoMsg - * @interface IPlayerDataPair - * @property {string|null} [DataFlag] PlayerDataPair DataFlag - * @property {string|null} [Content] PlayerDataPair Content - */ - - /** - * Constructs a new PlayerDataPair. - * @memberof ProtoMsg - * @classdesc Represents a PlayerDataPair. - * @implements IPlayerDataPair - * @constructor - * @param {ProtoMsg.IPlayerDataPair=} [properties] Properties to set - */ - function PlayerDataPair(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]]; - } - - /** - * PlayerDataPair DataFlag. - * @member {string} DataFlag - * @memberof ProtoMsg.PlayerDataPair - * @instance - */ - PlayerDataPair.prototype.DataFlag = ""; - - /** - * PlayerDataPair Content. - * @member {string} Content - * @memberof ProtoMsg.PlayerDataPair - * @instance - */ - PlayerDataPair.prototype.Content = ""; - - /** - * Creates a new PlayerDataPair instance using the specified properties. - * @function create - * @memberof ProtoMsg.PlayerDataPair - * @static - * @param {ProtoMsg.IPlayerDataPair=} [properties] Properties to set - * @returns {ProtoMsg.PlayerDataPair} PlayerDataPair instance - */ - PlayerDataPair.create = function create(properties) { - return new PlayerDataPair(properties); - }; - - /** - * Encodes the specified PlayerDataPair message. Does not implicitly {@link ProtoMsg.PlayerDataPair.verify|verify} messages. - * @function encode - * @memberof ProtoMsg.PlayerDataPair - * @static - * @param {ProtoMsg.IPlayerDataPair} message PlayerDataPair message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - PlayerDataPair.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if ( - message.DataFlag != null && - Object.hasOwnProperty.call(message, "DataFlag") - ) - writer.uint32(/* id 1, wireType 2 =*/ 10).string(message.DataFlag); - if ( - message.Content != null && - Object.hasOwnProperty.call(message, "Content") - ) - writer.uint32(/* id 2, wireType 2 =*/ 18).string(message.Content); - return writer; - }; - - /** - * Encodes the specified PlayerDataPair message, length delimited. Does not implicitly {@link ProtoMsg.PlayerDataPair.verify|verify} messages. - * @function encodeDelimited - * @memberof ProtoMsg.PlayerDataPair - * @static - * @param {ProtoMsg.IPlayerDataPair} message PlayerDataPair message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - PlayerDataPair.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a PlayerDataPair message from the specified reader or buffer. - * @function decode - * @memberof ProtoMsg.PlayerDataPair - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {ProtoMsg.PlayerDataPair} PlayerDataPair - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - PlayerDataPair.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.ProtoMsg.PlayerDataPair(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - message.DataFlag = reader.string(); - break; - } - case 2: { - message.Content = reader.string(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a PlayerDataPair message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof ProtoMsg.PlayerDataPair - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {ProtoMsg.PlayerDataPair} PlayerDataPair - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - PlayerDataPair.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a PlayerDataPair message. - * @function verify - * @memberof ProtoMsg.PlayerDataPair - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - PlayerDataPair.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.DataFlag != null && message.hasOwnProperty("DataFlag")) - if (!$util.isString(message.DataFlag)) - return "DataFlag: string expected"; - if (message.Content != null && message.hasOwnProperty("Content")) - if (!$util.isString(message.Content)) return "Content: string expected"; - return null; - }; - - /** - * Creates a PlayerDataPair message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof ProtoMsg.PlayerDataPair - * @static - * @param {Object.} object Plain object - * @returns {ProtoMsg.PlayerDataPair} PlayerDataPair - */ - PlayerDataPair.fromObject = function fromObject(object) { - if (object instanceof $root.ProtoMsg.PlayerDataPair) return object; - var message = new $root.ProtoMsg.PlayerDataPair(); - if (object.DataFlag != null) message.DataFlag = String(object.DataFlag); - if (object.Content != null) message.Content = String(object.Content); - return message; - }; - - /** - * Creates a plain object from a PlayerDataPair message. Also converts values to other types if specified. - * @function toObject - * @memberof ProtoMsg.PlayerDataPair - * @static - * @param {ProtoMsg.PlayerDataPair} message PlayerDataPair - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - PlayerDataPair.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.defaults) { - object.DataFlag = ""; - object.Content = ""; - } - if (message.DataFlag != null && message.hasOwnProperty("DataFlag")) - object.DataFlag = message.DataFlag; - if (message.Content != null && message.hasOwnProperty("Content")) - object.Content = message.Content; - return object; - }; - - /** - * Converts this PlayerDataPair to JSON. - * @function toJSON - * @memberof ProtoMsg.PlayerDataPair - * @instance - * @returns {Object.} JSON object - */ - PlayerDataPair.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for PlayerDataPair - * @function getTypeUrl - * @memberof ProtoMsg.PlayerDataPair - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - PlayerDataPair.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/ProtoMsg.PlayerDataPair"; - }; - - return PlayerDataPair; - })(); - - ProtoMsg.SavePlayerDataReq = (function () { - /** - * Properties of a SavePlayerDataReq. - * @memberof ProtoMsg - * @interface ISavePlayerDataReq - * @property {string|null} [GameName] SavePlayerDataReq GameName - * @property {string|null} [DataFlag] SavePlayerDataReq DataFlag - * @property {string|null} [Content] SavePlayerDataReq Content - */ - - /** - * Constructs a new SavePlayerDataReq. - * @memberof ProtoMsg - * @classdesc Represents a SavePlayerDataReq. - * @implements ISavePlayerDataReq - * @constructor - * @param {ProtoMsg.ISavePlayerDataReq=} [properties] Properties to set - */ - function SavePlayerDataReq(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]]; - } - - /** - * SavePlayerDataReq GameName. - * @member {string} GameName - * @memberof ProtoMsg.SavePlayerDataReq - * @instance - */ - SavePlayerDataReq.prototype.GameName = ""; - - /** - * SavePlayerDataReq DataFlag. - * @member {string} DataFlag - * @memberof ProtoMsg.SavePlayerDataReq - * @instance - */ - SavePlayerDataReq.prototype.DataFlag = ""; - - /** - * SavePlayerDataReq Content. - * @member {string} Content - * @memberof ProtoMsg.SavePlayerDataReq - * @instance - */ - SavePlayerDataReq.prototype.Content = ""; - - /** - * Creates a new SavePlayerDataReq instance using the specified properties. - * @function create - * @memberof ProtoMsg.SavePlayerDataReq - * @static - * @param {ProtoMsg.ISavePlayerDataReq=} [properties] Properties to set - * @returns {ProtoMsg.SavePlayerDataReq} SavePlayerDataReq instance - */ - SavePlayerDataReq.create = function create(properties) { - return new SavePlayerDataReq(properties); - }; - - /** - * Encodes the specified SavePlayerDataReq message. Does not implicitly {@link ProtoMsg.SavePlayerDataReq.verify|verify} messages. - * @function encode - * @memberof ProtoMsg.SavePlayerDataReq - * @static - * @param {ProtoMsg.ISavePlayerDataReq} message SavePlayerDataReq message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - SavePlayerDataReq.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if ( - message.GameName != null && - Object.hasOwnProperty.call(message, "GameName") - ) - writer.uint32(/* id 1, wireType 2 =*/ 10).string(message.GameName); - if ( - message.DataFlag != null && - Object.hasOwnProperty.call(message, "DataFlag") - ) - writer.uint32(/* id 2, wireType 2 =*/ 18).string(message.DataFlag); - if ( - message.Content != null && - Object.hasOwnProperty.call(message, "Content") - ) - writer.uint32(/* id 3, wireType 2 =*/ 26).string(message.Content); - return writer; - }; - - /** - * Encodes the specified SavePlayerDataReq message, length delimited. Does not implicitly {@link ProtoMsg.SavePlayerDataReq.verify|verify} messages. - * @function encodeDelimited - * @memberof ProtoMsg.SavePlayerDataReq - * @static - * @param {ProtoMsg.ISavePlayerDataReq} message SavePlayerDataReq message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - SavePlayerDataReq.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a SavePlayerDataReq message from the specified reader or buffer. - * @function decode - * @memberof ProtoMsg.SavePlayerDataReq - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {ProtoMsg.SavePlayerDataReq} SavePlayerDataReq - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - SavePlayerDataReq.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.ProtoMsg.SavePlayerDataReq(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - message.GameName = reader.string(); - break; - } - case 2: { - message.DataFlag = reader.string(); - break; - } - case 3: { - message.Content = reader.string(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a SavePlayerDataReq message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof ProtoMsg.SavePlayerDataReq - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {ProtoMsg.SavePlayerDataReq} SavePlayerDataReq - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - SavePlayerDataReq.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a SavePlayerDataReq message. - * @function verify - * @memberof ProtoMsg.SavePlayerDataReq - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - SavePlayerDataReq.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.GameName != null && message.hasOwnProperty("GameName")) - if (!$util.isString(message.GameName)) - return "GameName: string expected"; - if (message.DataFlag != null && message.hasOwnProperty("DataFlag")) - if (!$util.isString(message.DataFlag)) - return "DataFlag: string expected"; - if (message.Content != null && message.hasOwnProperty("Content")) - if (!$util.isString(message.Content)) return "Content: string expected"; - return null; - }; - - /** - * Creates a SavePlayerDataReq message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof ProtoMsg.SavePlayerDataReq - * @static - * @param {Object.} object Plain object - * @returns {ProtoMsg.SavePlayerDataReq} SavePlayerDataReq - */ - SavePlayerDataReq.fromObject = function fromObject(object) { - if (object instanceof $root.ProtoMsg.SavePlayerDataReq) return object; - var message = new $root.ProtoMsg.SavePlayerDataReq(); - if (object.GameName != null) message.GameName = String(object.GameName); - if (object.DataFlag != null) message.DataFlag = String(object.DataFlag); - if (object.Content != null) message.Content = String(object.Content); - return message; - }; - - /** - * Creates a plain object from a SavePlayerDataReq message. Also converts values to other types if specified. - * @function toObject - * @memberof ProtoMsg.SavePlayerDataReq - * @static - * @param {ProtoMsg.SavePlayerDataReq} message SavePlayerDataReq - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - SavePlayerDataReq.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.defaults) { - object.GameName = ""; - object.DataFlag = ""; - object.Content = ""; - } - if (message.GameName != null && message.hasOwnProperty("GameName")) - object.GameName = message.GameName; - if (message.DataFlag != null && message.hasOwnProperty("DataFlag")) - object.DataFlag = message.DataFlag; - if (message.Content != null && message.hasOwnProperty("Content")) - object.Content = message.Content; - return object; - }; - - /** - * Converts this SavePlayerDataReq to JSON. - * @function toJSON - * @memberof ProtoMsg.SavePlayerDataReq - * @instance - * @returns {Object.} JSON object - */ - SavePlayerDataReq.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for SavePlayerDataReq - * @function getTypeUrl - * @memberof ProtoMsg.SavePlayerDataReq - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - SavePlayerDataReq.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/ProtoMsg.SavePlayerDataReq"; - }; - - return SavePlayerDataReq; - })(); - - ProtoMsg.SavePlayerDataRsp = (function () { - /** - * Properties of a SavePlayerDataRsp. - * @memberof ProtoMsg - * @interface ISavePlayerDataRsp - * @property {string|null} [GameName] SavePlayerDataRsp GameName - * @property {string|null} [DataFlag] SavePlayerDataRsp DataFlag - */ - - /** - * Constructs a new SavePlayerDataRsp. - * @memberof ProtoMsg - * @classdesc Represents a SavePlayerDataRsp. - * @implements ISavePlayerDataRsp - * @constructor - * @param {ProtoMsg.ISavePlayerDataRsp=} [properties] Properties to set - */ - function SavePlayerDataRsp(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]]; - } - - /** - * SavePlayerDataRsp GameName. - * @member {string} GameName - * @memberof ProtoMsg.SavePlayerDataRsp - * @instance - */ - SavePlayerDataRsp.prototype.GameName = ""; - - /** - * SavePlayerDataRsp DataFlag. - * @member {string} DataFlag - * @memberof ProtoMsg.SavePlayerDataRsp - * @instance - */ - SavePlayerDataRsp.prototype.DataFlag = ""; - - /** - * Creates a new SavePlayerDataRsp instance using the specified properties. - * @function create - * @memberof ProtoMsg.SavePlayerDataRsp - * @static - * @param {ProtoMsg.ISavePlayerDataRsp=} [properties] Properties to set - * @returns {ProtoMsg.SavePlayerDataRsp} SavePlayerDataRsp instance - */ - SavePlayerDataRsp.create = function create(properties) { - return new SavePlayerDataRsp(properties); - }; - - /** - * Encodes the specified SavePlayerDataRsp message. Does not implicitly {@link ProtoMsg.SavePlayerDataRsp.verify|verify} messages. - * @function encode - * @memberof ProtoMsg.SavePlayerDataRsp - * @static - * @param {ProtoMsg.ISavePlayerDataRsp} message SavePlayerDataRsp message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - SavePlayerDataRsp.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if ( - message.GameName != null && - Object.hasOwnProperty.call(message, "GameName") - ) - writer.uint32(/* id 1, wireType 2 =*/ 10).string(message.GameName); - if ( - message.DataFlag != null && - Object.hasOwnProperty.call(message, "DataFlag") - ) - writer.uint32(/* id 2, wireType 2 =*/ 18).string(message.DataFlag); - return writer; - }; - - /** - * Encodes the specified SavePlayerDataRsp message, length delimited. Does not implicitly {@link ProtoMsg.SavePlayerDataRsp.verify|verify} messages. - * @function encodeDelimited - * @memberof ProtoMsg.SavePlayerDataRsp - * @static - * @param {ProtoMsg.ISavePlayerDataRsp} message SavePlayerDataRsp message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - SavePlayerDataRsp.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a SavePlayerDataRsp message from the specified reader or buffer. - * @function decode - * @memberof ProtoMsg.SavePlayerDataRsp - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {ProtoMsg.SavePlayerDataRsp} SavePlayerDataRsp - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - SavePlayerDataRsp.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.ProtoMsg.SavePlayerDataRsp(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - message.GameName = reader.string(); - break; - } - case 2: { - message.DataFlag = reader.string(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a SavePlayerDataRsp message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof ProtoMsg.SavePlayerDataRsp - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {ProtoMsg.SavePlayerDataRsp} SavePlayerDataRsp - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - SavePlayerDataRsp.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a SavePlayerDataRsp message. - * @function verify - * @memberof ProtoMsg.SavePlayerDataRsp - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - SavePlayerDataRsp.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.GameName != null && message.hasOwnProperty("GameName")) - if (!$util.isString(message.GameName)) - return "GameName: string expected"; - if (message.DataFlag != null && message.hasOwnProperty("DataFlag")) - if (!$util.isString(message.DataFlag)) - return "DataFlag: string expected"; - return null; - }; - - /** - * Creates a SavePlayerDataRsp message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof ProtoMsg.SavePlayerDataRsp - * @static - * @param {Object.} object Plain object - * @returns {ProtoMsg.SavePlayerDataRsp} SavePlayerDataRsp - */ - SavePlayerDataRsp.fromObject = function fromObject(object) { - if (object instanceof $root.ProtoMsg.SavePlayerDataRsp) return object; - var message = new $root.ProtoMsg.SavePlayerDataRsp(); - if (object.GameName != null) message.GameName = String(object.GameName); - if (object.DataFlag != null) message.DataFlag = String(object.DataFlag); - return message; - }; - - /** - * Creates a plain object from a SavePlayerDataRsp message. Also converts values to other types if specified. - * @function toObject - * @memberof ProtoMsg.SavePlayerDataRsp - * @static - * @param {ProtoMsg.SavePlayerDataRsp} message SavePlayerDataRsp - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - SavePlayerDataRsp.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.defaults) { - object.GameName = ""; - object.DataFlag = ""; - } - if (message.GameName != null && message.hasOwnProperty("GameName")) - object.GameName = message.GameName; - if (message.DataFlag != null && message.hasOwnProperty("DataFlag")) - object.DataFlag = message.DataFlag; - return object; - }; - - /** - * Converts this SavePlayerDataRsp to JSON. - * @function toJSON - * @memberof ProtoMsg.SavePlayerDataRsp - * @instance - * @returns {Object.} JSON object - */ - SavePlayerDataRsp.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for SavePlayerDataRsp - * @function getTypeUrl - * @memberof ProtoMsg.SavePlayerDataRsp - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - SavePlayerDataRsp.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/ProtoMsg.SavePlayerDataRsp"; - }; - - return SavePlayerDataRsp; - })(); - - return ProtoMsg; -})(); - -$root.google = (function () { - /** - * Namespace google. - * @exports google - * @namespace - */ - var google = {}; - - google.protobuf = (function () { - /** - * Namespace protobuf. - * @memberof google + * Namespace cs. + * @exports cs * @namespace */ - var protobuf = {}; + var cs = {}; - protobuf.FileDescriptorSet = (function () { - /** - * Properties of a FileDescriptorSet. - * @memberof google.protobuf - * @interface IFileDescriptorSet - * @property {Array.|null} [file] FileDescriptorSet file - */ + cs.GirlBrief = (function() { - /** - * Constructs a new FileDescriptorSet. - * @memberof google.protobuf - * @classdesc Represents a FileDescriptorSet. - * @implements IFileDescriptorSet - * @constructor - * @param {google.protobuf.IFileDescriptorSet=} [properties] Properties to set - */ - function FileDescriptorSet(properties) { - this.file = []; - 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]]; - } - - /** - * FileDescriptorSet file. - * @member {Array.} file - * @memberof google.protobuf.FileDescriptorSet - * @instance - */ - FileDescriptorSet.prototype.file = $util.emptyArray; - - /** - * Creates a new FileDescriptorSet instance using the specified properties. - * @function create - * @memberof google.protobuf.FileDescriptorSet - * @static - * @param {google.protobuf.IFileDescriptorSet=} [properties] Properties to set - * @returns {google.protobuf.FileDescriptorSet} FileDescriptorSet instance - */ - FileDescriptorSet.create = function create(properties) { - return new FileDescriptorSet(properties); - }; - - /** - * Encodes the specified FileDescriptorSet message. Does not implicitly {@link google.protobuf.FileDescriptorSet.verify|verify} messages. - * @function encode - * @memberof google.protobuf.FileDescriptorSet - * @static - * @param {google.protobuf.IFileDescriptorSet} message FileDescriptorSet message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - FileDescriptorSet.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if (message.file != null && message.file.length) - for (var i = 0; i < message.file.length; ++i) - $root.google.protobuf.FileDescriptorProto.encode( - message.file[i], - writer.uint32(/* id 1, wireType 2 =*/ 10).fork() - ).ldelim(); - return writer; - }; - - /** - * Encodes the specified FileDescriptorSet message, length delimited. Does not implicitly {@link google.protobuf.FileDescriptorSet.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.FileDescriptorSet - * @static - * @param {google.protobuf.IFileDescriptorSet} message FileDescriptorSet message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - FileDescriptorSet.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a FileDescriptorSet message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.FileDescriptorSet - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.FileDescriptorSet} FileDescriptorSet - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - FileDescriptorSet.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.google.protobuf.FileDescriptorSet(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - if (!(message.file && message.file.length)) message.file = []; - message.file.push( - $root.google.protobuf.FileDescriptorProto.decode( - reader, - reader.uint32() - ) - ); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a FileDescriptorSet message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.FileDescriptorSet - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.FileDescriptorSet} FileDescriptorSet - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - FileDescriptorSet.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a FileDescriptorSet message. - * @function verify - * @memberof google.protobuf.FileDescriptorSet - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - FileDescriptorSet.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.file != null && message.hasOwnProperty("file")) { - if (!Array.isArray(message.file)) return "file: array expected"; - for (var i = 0; i < message.file.length; ++i) { - var error = $root.google.protobuf.FileDescriptorProto.verify( - message.file[i] - ); - if (error) return "file." + error; - } - } - return null; - }; - - /** - * Creates a FileDescriptorSet message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.FileDescriptorSet - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.FileDescriptorSet} FileDescriptorSet - */ - FileDescriptorSet.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.FileDescriptorSet) - return object; - var message = new $root.google.protobuf.FileDescriptorSet(); - if (object.file) { - if (!Array.isArray(object.file)) - throw TypeError( - ".google.protobuf.FileDescriptorSet.file: array expected" - ); - message.file = []; - for (var i = 0; i < object.file.length; ++i) { - if (typeof object.file[i] !== "object") - throw TypeError( - ".google.protobuf.FileDescriptorSet.file: object expected" - ); - message.file[i] = - $root.google.protobuf.FileDescriptorProto.fromObject( - object.file[i] - ); - } - } - return message; - }; - - /** - * Creates a plain object from a FileDescriptorSet message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.FileDescriptorSet - * @static - * @param {google.protobuf.FileDescriptorSet} message FileDescriptorSet - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - FileDescriptorSet.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.arrays || options.defaults) object.file = []; - if (message.file && message.file.length) { - object.file = []; - for (var j = 0; j < message.file.length; ++j) - object.file[j] = $root.google.protobuf.FileDescriptorProto.toObject( - message.file[j], - options - ); - } - return object; - }; - - /** - * Converts this FileDescriptorSet to JSON. - * @function toJSON - * @memberof google.protobuf.FileDescriptorSet - * @instance - * @returns {Object.} JSON object - */ - FileDescriptorSet.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for FileDescriptorSet - * @function getTypeUrl - * @memberof google.protobuf.FileDescriptorSet - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - FileDescriptorSet.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.FileDescriptorSet"; - }; - - return FileDescriptorSet; - })(); - - /** - * Edition enum. - * @name google.protobuf.Edition - * @enum {number} - * @property {number} EDITION_UNKNOWN=0 EDITION_UNKNOWN value - * @property {number} EDITION_LEGACY=900 EDITION_LEGACY value - * @property {number} EDITION_PROTO2=998 EDITION_PROTO2 value - * @property {number} EDITION_PROTO3=999 EDITION_PROTO3 value - * @property {number} EDITION_2023=1000 EDITION_2023 value - * @property {number} EDITION_2024=1001 EDITION_2024 value - * @property {number} EDITION_1_TEST_ONLY=1 EDITION_1_TEST_ONLY value - * @property {number} EDITION_2_TEST_ONLY=2 EDITION_2_TEST_ONLY value - * @property {number} EDITION_99997_TEST_ONLY=99997 EDITION_99997_TEST_ONLY value - * @property {number} EDITION_99998_TEST_ONLY=99998 EDITION_99998_TEST_ONLY value - * @property {number} EDITION_99999_TEST_ONLY=99999 EDITION_99999_TEST_ONLY value - * @property {number} EDITION_MAX=2147483647 EDITION_MAX value - */ - protobuf.Edition = (function () { - var valuesById = {}, - values = Object.create(valuesById); - values[(valuesById[0] = "EDITION_UNKNOWN")] = 0; - values[(valuesById[900] = "EDITION_LEGACY")] = 900; - values[(valuesById[998] = "EDITION_PROTO2")] = 998; - values[(valuesById[999] = "EDITION_PROTO3")] = 999; - values[(valuesById[1000] = "EDITION_2023")] = 1000; - values[(valuesById[1001] = "EDITION_2024")] = 1001; - values[(valuesById[1] = "EDITION_1_TEST_ONLY")] = 1; - values[(valuesById[2] = "EDITION_2_TEST_ONLY")] = 2; - values[(valuesById[99997] = "EDITION_99997_TEST_ONLY")] = 99997; - values[(valuesById[99998] = "EDITION_99998_TEST_ONLY")] = 99998; - values[(valuesById[99999] = "EDITION_99999_TEST_ONLY")] = 99999; - values[(valuesById[2147483647] = "EDITION_MAX")] = 2147483647; - return values; - })(); - - protobuf.FileDescriptorProto = (function () { - /** - * Properties of a FileDescriptorProto. - * @memberof google.protobuf - * @interface IFileDescriptorProto - * @property {string|null} [name] FileDescriptorProto name - * @property {string|null} ["package"] FileDescriptorProto package - * @property {Array.|null} [dependency] FileDescriptorProto dependency - * @property {Array.|null} [publicDependency] FileDescriptorProto publicDependency - * @property {Array.|null} [weakDependency] FileDescriptorProto weakDependency - * @property {Array.|null} [optionDependency] FileDescriptorProto optionDependency - * @property {Array.|null} [messageType] FileDescriptorProto messageType - * @property {Array.|null} [enumType] FileDescriptorProto enumType - * @property {Array.|null} [service] FileDescriptorProto service - * @property {Array.|null} [extension] FileDescriptorProto extension - * @property {google.protobuf.IFileOptions|null} [options] FileDescriptorProto options - * @property {google.protobuf.ISourceCodeInfo|null} [sourceCodeInfo] FileDescriptorProto sourceCodeInfo - * @property {string|null} [syntax] FileDescriptorProto syntax - * @property {google.protobuf.Edition|null} [edition] FileDescriptorProto edition - */ - - /** - * Constructs a new FileDescriptorProto. - * @memberof google.protobuf - * @classdesc Represents a FileDescriptorProto. - * @implements IFileDescriptorProto - * @constructor - * @param {google.protobuf.IFileDescriptorProto=} [properties] Properties to set - */ - function FileDescriptorProto(properties) { - this.dependency = []; - this.publicDependency = []; - this.weakDependency = []; - this.optionDependency = []; - this.messageType = []; - this.enumType = []; - this.service = []; - this.extension = []; - 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]]; - } - - /** - * FileDescriptorProto name. - * @member {string} name - * @memberof google.protobuf.FileDescriptorProto - * @instance - */ - FileDescriptorProto.prototype.name = ""; - - /** - * FileDescriptorProto package. - * @member {string} package - * @memberof google.protobuf.FileDescriptorProto - * @instance - */ - FileDescriptorProto.prototype["package"] = ""; - - /** - * FileDescriptorProto dependency. - * @member {Array.} dependency - * @memberof google.protobuf.FileDescriptorProto - * @instance - */ - FileDescriptorProto.prototype.dependency = $util.emptyArray; - - /** - * FileDescriptorProto publicDependency. - * @member {Array.} publicDependency - * @memberof google.protobuf.FileDescriptorProto - * @instance - */ - FileDescriptorProto.prototype.publicDependency = $util.emptyArray; - - /** - * FileDescriptorProto weakDependency. - * @member {Array.} weakDependency - * @memberof google.protobuf.FileDescriptorProto - * @instance - */ - FileDescriptorProto.prototype.weakDependency = $util.emptyArray; - - /** - * FileDescriptorProto optionDependency. - * @member {Array.} optionDependency - * @memberof google.protobuf.FileDescriptorProto - * @instance - */ - FileDescriptorProto.prototype.optionDependency = $util.emptyArray; - - /** - * FileDescriptorProto messageType. - * @member {Array.} messageType - * @memberof google.protobuf.FileDescriptorProto - * @instance - */ - FileDescriptorProto.prototype.messageType = $util.emptyArray; - - /** - * FileDescriptorProto enumType. - * @member {Array.} enumType - * @memberof google.protobuf.FileDescriptorProto - * @instance - */ - FileDescriptorProto.prototype.enumType = $util.emptyArray; - - /** - * FileDescriptorProto service. - * @member {Array.} service - * @memberof google.protobuf.FileDescriptorProto - * @instance - */ - FileDescriptorProto.prototype.service = $util.emptyArray; - - /** - * FileDescriptorProto extension. - * @member {Array.} extension - * @memberof google.protobuf.FileDescriptorProto - * @instance - */ - FileDescriptorProto.prototype.extension = $util.emptyArray; - - /** - * FileDescriptorProto options. - * @member {google.protobuf.IFileOptions|null|undefined} options - * @memberof google.protobuf.FileDescriptorProto - * @instance - */ - FileDescriptorProto.prototype.options = null; - - /** - * FileDescriptorProto sourceCodeInfo. - * @member {google.protobuf.ISourceCodeInfo|null|undefined} sourceCodeInfo - * @memberof google.protobuf.FileDescriptorProto - * @instance - */ - FileDescriptorProto.prototype.sourceCodeInfo = null; - - /** - * FileDescriptorProto syntax. - * @member {string} syntax - * @memberof google.protobuf.FileDescriptorProto - * @instance - */ - FileDescriptorProto.prototype.syntax = ""; - - /** - * FileDescriptorProto edition. - * @member {google.protobuf.Edition} edition - * @memberof google.protobuf.FileDescriptorProto - * @instance - */ - FileDescriptorProto.prototype.edition = 0; - - /** - * Creates a new FileDescriptorProto instance using the specified properties. - * @function create - * @memberof google.protobuf.FileDescriptorProto - * @static - * @param {google.protobuf.IFileDescriptorProto=} [properties] Properties to set - * @returns {google.protobuf.FileDescriptorProto} FileDescriptorProto instance - */ - FileDescriptorProto.create = function create(properties) { - return new FileDescriptorProto(properties); - }; - - /** - * Encodes the specified FileDescriptorProto message. Does not implicitly {@link google.protobuf.FileDescriptorProto.verify|verify} messages. - * @function encode - * @memberof google.protobuf.FileDescriptorProto - * @static - * @param {google.protobuf.IFileDescriptorProto} message FileDescriptorProto message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - FileDescriptorProto.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["package"] != null && - Object.hasOwnProperty.call(message, "package") - ) - writer.uint32(/* id 2, wireType 2 =*/ 18).string(message["package"]); - if (message.dependency != null && message.dependency.length) - for (var i = 0; i < message.dependency.length; ++i) - writer - .uint32(/* id 3, wireType 2 =*/ 26) - .string(message.dependency[i]); - if (message.messageType != null && message.messageType.length) - for (var i = 0; i < message.messageType.length; ++i) - $root.google.protobuf.DescriptorProto.encode( - message.messageType[i], - writer.uint32(/* id 4, wireType 2 =*/ 34).fork() - ).ldelim(); - if (message.enumType != null && message.enumType.length) - for (var i = 0; i < message.enumType.length; ++i) - $root.google.protobuf.EnumDescriptorProto.encode( - message.enumType[i], - writer.uint32(/* id 5, wireType 2 =*/ 42).fork() - ).ldelim(); - if (message.service != null && message.service.length) - for (var i = 0; i < message.service.length; ++i) - $root.google.protobuf.ServiceDescriptorProto.encode( - message.service[i], - writer.uint32(/* id 6, wireType 2 =*/ 50).fork() - ).ldelim(); - if (message.extension != null && message.extension.length) - for (var i = 0; i < message.extension.length; ++i) - $root.google.protobuf.FieldDescriptorProto.encode( - message.extension[i], - writer.uint32(/* id 7, wireType 2 =*/ 58).fork() - ).ldelim(); - if ( - message.options != null && - Object.hasOwnProperty.call(message, "options") - ) - $root.google.protobuf.FileOptions.encode( - message.options, - writer.uint32(/* id 8, wireType 2 =*/ 66).fork() - ).ldelim(); - if ( - message.sourceCodeInfo != null && - Object.hasOwnProperty.call(message, "sourceCodeInfo") - ) - $root.google.protobuf.SourceCodeInfo.encode( - message.sourceCodeInfo, - writer.uint32(/* id 9, wireType 2 =*/ 74).fork() - ).ldelim(); - if (message.publicDependency != null && message.publicDependency.length) - for (var i = 0; i < message.publicDependency.length; ++i) - writer - .uint32(/* id 10, wireType 0 =*/ 80) - .int32(message.publicDependency[i]); - if (message.weakDependency != null && message.weakDependency.length) - for (var i = 0; i < message.weakDependency.length; ++i) - writer - .uint32(/* id 11, wireType 0 =*/ 88) - .int32(message.weakDependency[i]); - if ( - message.syntax != null && - Object.hasOwnProperty.call(message, "syntax") - ) - writer.uint32(/* id 12, wireType 2 =*/ 98).string(message.syntax); - if ( - message.edition != null && - Object.hasOwnProperty.call(message, "edition") - ) - writer.uint32(/* id 14, wireType 0 =*/ 112).int32(message.edition); - if (message.optionDependency != null && message.optionDependency.length) - for (var i = 0; i < message.optionDependency.length; ++i) - writer - .uint32(/* id 15, wireType 2 =*/ 122) - .string(message.optionDependency[i]); - return writer; - }; - - /** - * Encodes the specified FileDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.FileDescriptorProto.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.FileDescriptorProto - * @static - * @param {google.protobuf.IFileDescriptorProto} message FileDescriptorProto message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - FileDescriptorProto.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a FileDescriptorProto message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.FileDescriptorProto - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.FileDescriptorProto} FileDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - FileDescriptorProto.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.google.protobuf.FileDescriptorProto(); - 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["package"] = reader.string(); - break; - } - case 3: { - if (!(message.dependency && message.dependency.length)) - message.dependency = []; - message.dependency.push(reader.string()); - break; - } - case 10: { - if ( - !(message.publicDependency && message.publicDependency.length) - ) - message.publicDependency = []; - if ((tag & 7) === 2) { - var end2 = reader.uint32() + reader.pos; - while (reader.pos < end2) - message.publicDependency.push(reader.int32()); - } else message.publicDependency.push(reader.int32()); - break; - } - case 11: { - if (!(message.weakDependency && message.weakDependency.length)) - message.weakDependency = []; - if ((tag & 7) === 2) { - var end2 = reader.uint32() + reader.pos; - while (reader.pos < end2) - message.weakDependency.push(reader.int32()); - } else message.weakDependency.push(reader.int32()); - break; - } - case 15: { - if ( - !(message.optionDependency && message.optionDependency.length) - ) - message.optionDependency = []; - message.optionDependency.push(reader.string()); - break; - } - case 4: { - if (!(message.messageType && message.messageType.length)) - message.messageType = []; - message.messageType.push( - $root.google.protobuf.DescriptorProto.decode( - reader, - reader.uint32() - ) - ); - break; - } - case 5: { - if (!(message.enumType && message.enumType.length)) - message.enumType = []; - message.enumType.push( - $root.google.protobuf.EnumDescriptorProto.decode( - reader, - reader.uint32() - ) - ); - break; - } - case 6: { - if (!(message.service && message.service.length)) - message.service = []; - message.service.push( - $root.google.protobuf.ServiceDescriptorProto.decode( - reader, - reader.uint32() - ) - ); - break; - } - case 7: { - if (!(message.extension && message.extension.length)) - message.extension = []; - message.extension.push( - $root.google.protobuf.FieldDescriptorProto.decode( - reader, - reader.uint32() - ) - ); - break; - } - case 8: { - message.options = $root.google.protobuf.FileOptions.decode( - reader, - reader.uint32() - ); - break; - } - case 9: { - message.sourceCodeInfo = - $root.google.protobuf.SourceCodeInfo.decode( - reader, - reader.uint32() - ); - break; - } - case 12: { - message.syntax = reader.string(); - break; - } - case 14: { - message.edition = reader.int32(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a FileDescriptorProto message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.FileDescriptorProto - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.FileDescriptorProto} FileDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - FileDescriptorProto.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a FileDescriptorProto message. - * @function verify - * @memberof google.protobuf.FileDescriptorProto - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - FileDescriptorProto.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["package"] != null && message.hasOwnProperty("package")) - if (!$util.isString(message["package"])) - return "package: string expected"; - if ( - message.dependency != null && - message.hasOwnProperty("dependency") - ) { - if (!Array.isArray(message.dependency)) - return "dependency: array expected"; - for (var i = 0; i < message.dependency.length; ++i) - if (!$util.isString(message.dependency[i])) - return "dependency: string[] expected"; - } - if ( - message.publicDependency != null && - message.hasOwnProperty("publicDependency") - ) { - if (!Array.isArray(message.publicDependency)) - return "publicDependency: array expected"; - for (var i = 0; i < message.publicDependency.length; ++i) - if (!$util.isInteger(message.publicDependency[i])) - return "publicDependency: integer[] expected"; - } - if ( - message.weakDependency != null && - message.hasOwnProperty("weakDependency") - ) { - if (!Array.isArray(message.weakDependency)) - return "weakDependency: array expected"; - for (var i = 0; i < message.weakDependency.length; ++i) - if (!$util.isInteger(message.weakDependency[i])) - return "weakDependency: integer[] expected"; - } - if ( - message.optionDependency != null && - message.hasOwnProperty("optionDependency") - ) { - if (!Array.isArray(message.optionDependency)) - return "optionDependency: array expected"; - for (var i = 0; i < message.optionDependency.length; ++i) - if (!$util.isString(message.optionDependency[i])) - return "optionDependency: string[] expected"; - } - if ( - message.messageType != null && - message.hasOwnProperty("messageType") - ) { - if (!Array.isArray(message.messageType)) - return "messageType: array expected"; - for (var i = 0; i < message.messageType.length; ++i) { - var error = $root.google.protobuf.DescriptorProto.verify( - message.messageType[i] - ); - if (error) return "messageType." + error; - } - } - if (message.enumType != null && message.hasOwnProperty("enumType")) { - if (!Array.isArray(message.enumType)) - return "enumType: array expected"; - for (var i = 0; i < message.enumType.length; ++i) { - var error = $root.google.protobuf.EnumDescriptorProto.verify( - message.enumType[i] - ); - if (error) return "enumType." + error; - } - } - if (message.service != null && message.hasOwnProperty("service")) { - if (!Array.isArray(message.service)) return "service: array expected"; - for (var i = 0; i < message.service.length; ++i) { - var error = $root.google.protobuf.ServiceDescriptorProto.verify( - message.service[i] - ); - if (error) return "service." + error; - } - } - if (message.extension != null && message.hasOwnProperty("extension")) { - if (!Array.isArray(message.extension)) - return "extension: array expected"; - for (var i = 0; i < message.extension.length; ++i) { - var error = $root.google.protobuf.FieldDescriptorProto.verify( - message.extension[i] - ); - if (error) return "extension." + error; - } - } - if (message.options != null && message.hasOwnProperty("options")) { - var error = $root.google.protobuf.FileOptions.verify(message.options); - if (error) return "options." + error; - } - if ( - message.sourceCodeInfo != null && - message.hasOwnProperty("sourceCodeInfo") - ) { - var error = $root.google.protobuf.SourceCodeInfo.verify( - message.sourceCodeInfo - ); - if (error) return "sourceCodeInfo." + error; - } - if (message.syntax != null && message.hasOwnProperty("syntax")) - if (!$util.isString(message.syntax)) return "syntax: string expected"; - if (message.edition != null && message.hasOwnProperty("edition")) - switch (message.edition) { - default: - return "edition: enum value expected"; - case 0: - case 900: - case 998: - case 999: - case 1000: - case 1001: - case 1: - case 2: - case 99997: - case 99998: - case 99999: - case 2147483647: - break; - } - return null; - }; - - /** - * Creates a FileDescriptorProto message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.FileDescriptorProto - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.FileDescriptorProto} FileDescriptorProto - */ - FileDescriptorProto.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.FileDescriptorProto) - return object; - var message = new $root.google.protobuf.FileDescriptorProto(); - if (object.name != null) message.name = String(object.name); - if (object["package"] != null) - message["package"] = String(object["package"]); - if (object.dependency) { - if (!Array.isArray(object.dependency)) - throw TypeError( - ".google.protobuf.FileDescriptorProto.dependency: array expected" - ); - message.dependency = []; - for (var i = 0; i < object.dependency.length; ++i) - message.dependency[i] = String(object.dependency[i]); - } - if (object.publicDependency) { - if (!Array.isArray(object.publicDependency)) - throw TypeError( - ".google.protobuf.FileDescriptorProto.publicDependency: array expected" - ); - message.publicDependency = []; - for (var i = 0; i < object.publicDependency.length; ++i) - message.publicDependency[i] = object.publicDependency[i] | 0; - } - if (object.weakDependency) { - if (!Array.isArray(object.weakDependency)) - throw TypeError( - ".google.protobuf.FileDescriptorProto.weakDependency: array expected" - ); - message.weakDependency = []; - for (var i = 0; i < object.weakDependency.length; ++i) - message.weakDependency[i] = object.weakDependency[i] | 0; - } - if (object.optionDependency) { - if (!Array.isArray(object.optionDependency)) - throw TypeError( - ".google.protobuf.FileDescriptorProto.optionDependency: array expected" - ); - message.optionDependency = []; - for (var i = 0; i < object.optionDependency.length; ++i) - message.optionDependency[i] = String(object.optionDependency[i]); - } - if (object.messageType) { - if (!Array.isArray(object.messageType)) - throw TypeError( - ".google.protobuf.FileDescriptorProto.messageType: array expected" - ); - message.messageType = []; - for (var i = 0; i < object.messageType.length; ++i) { - if (typeof object.messageType[i] !== "object") - throw TypeError( - ".google.protobuf.FileDescriptorProto.messageType: object expected" - ); - message.messageType[i] = - $root.google.protobuf.DescriptorProto.fromObject( - object.messageType[i] - ); - } - } - if (object.enumType) { - if (!Array.isArray(object.enumType)) - throw TypeError( - ".google.protobuf.FileDescriptorProto.enumType: array expected" - ); - message.enumType = []; - for (var i = 0; i < object.enumType.length; ++i) { - if (typeof object.enumType[i] !== "object") - throw TypeError( - ".google.protobuf.FileDescriptorProto.enumType: object expected" - ); - message.enumType[i] = - $root.google.protobuf.EnumDescriptorProto.fromObject( - object.enumType[i] - ); - } - } - if (object.service) { - if (!Array.isArray(object.service)) - throw TypeError( - ".google.protobuf.FileDescriptorProto.service: array expected" - ); - message.service = []; - for (var i = 0; i < object.service.length; ++i) { - if (typeof object.service[i] !== "object") - throw TypeError( - ".google.protobuf.FileDescriptorProto.service: object expected" - ); - message.service[i] = - $root.google.protobuf.ServiceDescriptorProto.fromObject( - object.service[i] - ); - } - } - if (object.extension) { - if (!Array.isArray(object.extension)) - throw TypeError( - ".google.protobuf.FileDescriptorProto.extension: array expected" - ); - message.extension = []; - for (var i = 0; i < object.extension.length; ++i) { - if (typeof object.extension[i] !== "object") - throw TypeError( - ".google.protobuf.FileDescriptorProto.extension: object expected" - ); - message.extension[i] = - $root.google.protobuf.FieldDescriptorProto.fromObject( - object.extension[i] - ); - } - } - if (object.options != null) { - if (typeof object.options !== "object") - throw TypeError( - ".google.protobuf.FileDescriptorProto.options: object expected" - ); - message.options = $root.google.protobuf.FileOptions.fromObject( - object.options - ); - } - if (object.sourceCodeInfo != null) { - if (typeof object.sourceCodeInfo !== "object") - throw TypeError( - ".google.protobuf.FileDescriptorProto.sourceCodeInfo: object expected" - ); - message.sourceCodeInfo = - $root.google.protobuf.SourceCodeInfo.fromObject( - object.sourceCodeInfo - ); - } - if (object.syntax != null) message.syntax = String(object.syntax); - switch (object.edition) { - default: - if (typeof object.edition === "number") { - message.edition = object.edition; - break; - } - break; - case "EDITION_UNKNOWN": - case 0: - message.edition = 0; - break; - case "EDITION_LEGACY": - case 900: - message.edition = 900; - break; - case "EDITION_PROTO2": - case 998: - message.edition = 998; - break; - case "EDITION_PROTO3": - case 999: - message.edition = 999; - break; - case "EDITION_2023": - case 1000: - message.edition = 1000; - break; - case "EDITION_2024": - case 1001: - message.edition = 1001; - break; - case "EDITION_1_TEST_ONLY": - case 1: - message.edition = 1; - break; - case "EDITION_2_TEST_ONLY": - case 2: - message.edition = 2; - break; - case "EDITION_99997_TEST_ONLY": - case 99997: - message.edition = 99997; - break; - case "EDITION_99998_TEST_ONLY": - case 99998: - message.edition = 99998; - break; - case "EDITION_99999_TEST_ONLY": - case 99999: - message.edition = 99999; - break; - case "EDITION_MAX": - case 2147483647: - message.edition = 2147483647; - break; - } - return message; - }; - - /** - * Creates a plain object from a FileDescriptorProto message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.FileDescriptorProto - * @static - * @param {google.protobuf.FileDescriptorProto} message FileDescriptorProto - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - FileDescriptorProto.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.arrays || options.defaults) { - object.dependency = []; - object.messageType = []; - object.enumType = []; - object.service = []; - object.extension = []; - object.publicDependency = []; - object.weakDependency = []; - object.optionDependency = []; - } - if (options.defaults) { - object.name = ""; - object["package"] = ""; - object.options = null; - object.sourceCodeInfo = null; - object.syntax = ""; - object.edition = options.enums === String ? "EDITION_UNKNOWN" : 0; - } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message["package"] != null && message.hasOwnProperty("package")) - object["package"] = message["package"]; - if (message.dependency && message.dependency.length) { - object.dependency = []; - for (var j = 0; j < message.dependency.length; ++j) - object.dependency[j] = message.dependency[j]; - } - if (message.messageType && message.messageType.length) { - object.messageType = []; - for (var j = 0; j < message.messageType.length; ++j) - object.messageType[j] = - $root.google.protobuf.DescriptorProto.toObject( - message.messageType[j], - options - ); - } - if (message.enumType && message.enumType.length) { - object.enumType = []; - for (var j = 0; j < message.enumType.length; ++j) - object.enumType[j] = - $root.google.protobuf.EnumDescriptorProto.toObject( - message.enumType[j], - options - ); - } - if (message.service && message.service.length) { - object.service = []; - for (var j = 0; j < message.service.length; ++j) - object.service[j] = - $root.google.protobuf.ServiceDescriptorProto.toObject( - message.service[j], - options - ); - } - if (message.extension && message.extension.length) { - object.extension = []; - for (var j = 0; j < message.extension.length; ++j) - object.extension[j] = - $root.google.protobuf.FieldDescriptorProto.toObject( - message.extension[j], - options - ); - } - if (message.options != null && message.hasOwnProperty("options")) - object.options = $root.google.protobuf.FileOptions.toObject( - message.options, - options - ); - if ( - message.sourceCodeInfo != null && - message.hasOwnProperty("sourceCodeInfo") - ) - object.sourceCodeInfo = $root.google.protobuf.SourceCodeInfo.toObject( - message.sourceCodeInfo, - options - ); - if (message.publicDependency && message.publicDependency.length) { - object.publicDependency = []; - for (var j = 0; j < message.publicDependency.length; ++j) - object.publicDependency[j] = message.publicDependency[j]; - } - if (message.weakDependency && message.weakDependency.length) { - object.weakDependency = []; - for (var j = 0; j < message.weakDependency.length; ++j) - object.weakDependency[j] = message.weakDependency[j]; - } - if (message.syntax != null && message.hasOwnProperty("syntax")) - object.syntax = message.syntax; - if (message.edition != null && message.hasOwnProperty("edition")) - object.edition = - options.enums === String - ? $root.google.protobuf.Edition[message.edition] === undefined - ? message.edition - : $root.google.protobuf.Edition[message.edition] - : message.edition; - if (message.optionDependency && message.optionDependency.length) { - object.optionDependency = []; - for (var j = 0; j < message.optionDependency.length; ++j) - object.optionDependency[j] = message.optionDependency[j]; - } - return object; - }; - - /** - * Converts this FileDescriptorProto to JSON. - * @function toJSON - * @memberof google.protobuf.FileDescriptorProto - * @instance - * @returns {Object.} JSON object - */ - FileDescriptorProto.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for FileDescriptorProto - * @function getTypeUrl - * @memberof google.protobuf.FileDescriptorProto - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - FileDescriptorProto.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.FileDescriptorProto"; - }; - - return FileDescriptorProto; - })(); - - protobuf.DescriptorProto = (function () { - /** - * Properties of a DescriptorProto. - * @memberof google.protobuf - * @interface IDescriptorProto - * @property {string|null} [name] DescriptorProto name - * @property {Array.|null} [field] DescriptorProto field - * @property {Array.|null} [extension] DescriptorProto extension - * @property {Array.|null} [nestedType] DescriptorProto nestedType - * @property {Array.|null} [enumType] DescriptorProto enumType - * @property {Array.|null} [extensionRange] DescriptorProto extensionRange - * @property {Array.|null} [oneofDecl] DescriptorProto oneofDecl - * @property {google.protobuf.IMessageOptions|null} [options] DescriptorProto options - * @property {Array.|null} [reservedRange] DescriptorProto reservedRange - * @property {Array.|null} [reservedName] DescriptorProto reservedName - * @property {google.protobuf.SymbolVisibility|null} [visibility] DescriptorProto visibility - */ - - /** - * Constructs a new DescriptorProto. - * @memberof google.protobuf - * @classdesc Represents a DescriptorProto. - * @implements IDescriptorProto - * @constructor - * @param {google.protobuf.IDescriptorProto=} [properties] Properties to set - */ - function DescriptorProto(properties) { - this.field = []; - this.extension = []; - this.nestedType = []; - this.enumType = []; - this.extensionRange = []; - this.oneofDecl = []; - this.reservedRange = []; - this.reservedName = []; - 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]]; - } - - /** - * DescriptorProto name. - * @member {string} name - * @memberof google.protobuf.DescriptorProto - * @instance - */ - DescriptorProto.prototype.name = ""; - - /** - * DescriptorProto field. - * @member {Array.} field - * @memberof google.protobuf.DescriptorProto - * @instance - */ - DescriptorProto.prototype.field = $util.emptyArray; - - /** - * DescriptorProto extension. - * @member {Array.} extension - * @memberof google.protobuf.DescriptorProto - * @instance - */ - DescriptorProto.prototype.extension = $util.emptyArray; - - /** - * DescriptorProto nestedType. - * @member {Array.} nestedType - * @memberof google.protobuf.DescriptorProto - * @instance - */ - DescriptorProto.prototype.nestedType = $util.emptyArray; - - /** - * DescriptorProto enumType. - * @member {Array.} enumType - * @memberof google.protobuf.DescriptorProto - * @instance - */ - DescriptorProto.prototype.enumType = $util.emptyArray; - - /** - * DescriptorProto extensionRange. - * @member {Array.} extensionRange - * @memberof google.protobuf.DescriptorProto - * @instance - */ - DescriptorProto.prototype.extensionRange = $util.emptyArray; - - /** - * DescriptorProto oneofDecl. - * @member {Array.} oneofDecl - * @memberof google.protobuf.DescriptorProto - * @instance - */ - DescriptorProto.prototype.oneofDecl = $util.emptyArray; - - /** - * DescriptorProto options. - * @member {google.protobuf.IMessageOptions|null|undefined} options - * @memberof google.protobuf.DescriptorProto - * @instance - */ - DescriptorProto.prototype.options = null; - - /** - * DescriptorProto reservedRange. - * @member {Array.} reservedRange - * @memberof google.protobuf.DescriptorProto - * @instance - */ - DescriptorProto.prototype.reservedRange = $util.emptyArray; - - /** - * DescriptorProto reservedName. - * @member {Array.} reservedName - * @memberof google.protobuf.DescriptorProto - * @instance - */ - DescriptorProto.prototype.reservedName = $util.emptyArray; - - /** - * DescriptorProto visibility. - * @member {google.protobuf.SymbolVisibility} visibility - * @memberof google.protobuf.DescriptorProto - * @instance - */ - DescriptorProto.prototype.visibility = 0; - - /** - * Creates a new DescriptorProto instance using the specified properties. - * @function create - * @memberof google.protobuf.DescriptorProto - * @static - * @param {google.protobuf.IDescriptorProto=} [properties] Properties to set - * @returns {google.protobuf.DescriptorProto} DescriptorProto instance - */ - DescriptorProto.create = function create(properties) { - return new DescriptorProto(properties); - }; - - /** - * Encodes the specified DescriptorProto message. Does not implicitly {@link google.protobuf.DescriptorProto.verify|verify} messages. - * @function encode - * @memberof google.protobuf.DescriptorProto - * @static - * @param {google.protobuf.IDescriptorProto} message DescriptorProto message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - DescriptorProto.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.field != null && message.field.length) - for (var i = 0; i < message.field.length; ++i) - $root.google.protobuf.FieldDescriptorProto.encode( - message.field[i], - writer.uint32(/* id 2, wireType 2 =*/ 18).fork() - ).ldelim(); - if (message.nestedType != null && message.nestedType.length) - for (var i = 0; i < message.nestedType.length; ++i) - $root.google.protobuf.DescriptorProto.encode( - message.nestedType[i], - writer.uint32(/* id 3, wireType 2 =*/ 26).fork() - ).ldelim(); - if (message.enumType != null && message.enumType.length) - for (var i = 0; i < message.enumType.length; ++i) - $root.google.protobuf.EnumDescriptorProto.encode( - message.enumType[i], - writer.uint32(/* id 4, wireType 2 =*/ 34).fork() - ).ldelim(); - if (message.extensionRange != null && message.extensionRange.length) - for (var i = 0; i < message.extensionRange.length; ++i) - $root.google.protobuf.DescriptorProto.ExtensionRange.encode( - message.extensionRange[i], - writer.uint32(/* id 5, wireType 2 =*/ 42).fork() - ).ldelim(); - if (message.extension != null && message.extension.length) - for (var i = 0; i < message.extension.length; ++i) - $root.google.protobuf.FieldDescriptorProto.encode( - message.extension[i], - writer.uint32(/* id 6, wireType 2 =*/ 50).fork() - ).ldelim(); - if ( - message.options != null && - Object.hasOwnProperty.call(message, "options") - ) - $root.google.protobuf.MessageOptions.encode( - message.options, - writer.uint32(/* id 7, wireType 2 =*/ 58).fork() - ).ldelim(); - if (message.oneofDecl != null && message.oneofDecl.length) - for (var i = 0; i < message.oneofDecl.length; ++i) - $root.google.protobuf.OneofDescriptorProto.encode( - message.oneofDecl[i], - writer.uint32(/* id 8, wireType 2 =*/ 66).fork() - ).ldelim(); - if (message.reservedRange != null && message.reservedRange.length) - for (var i = 0; i < message.reservedRange.length; ++i) - $root.google.protobuf.DescriptorProto.ReservedRange.encode( - message.reservedRange[i], - writer.uint32(/* id 9, wireType 2 =*/ 74).fork() - ).ldelim(); - if (message.reservedName != null && message.reservedName.length) - for (var i = 0; i < message.reservedName.length; ++i) - writer - .uint32(/* id 10, wireType 2 =*/ 82) - .string(message.reservedName[i]); - if ( - message.visibility != null && - Object.hasOwnProperty.call(message, "visibility") - ) - writer.uint32(/* id 11, wireType 0 =*/ 88).int32(message.visibility); - return writer; - }; - - /** - * Encodes the specified DescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.DescriptorProto.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.DescriptorProto - * @static - * @param {google.protobuf.IDescriptorProto} message DescriptorProto message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - DescriptorProto.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a DescriptorProto message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.DescriptorProto - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.DescriptorProto} DescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - DescriptorProto.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.google.protobuf.DescriptorProto(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - message.name = reader.string(); - break; - } - case 2: { - if (!(message.field && message.field.length)) message.field = []; - message.field.push( - $root.google.protobuf.FieldDescriptorProto.decode( - reader, - reader.uint32() - ) - ); - break; - } - case 6: { - if (!(message.extension && message.extension.length)) - message.extension = []; - message.extension.push( - $root.google.protobuf.FieldDescriptorProto.decode( - reader, - reader.uint32() - ) - ); - break; - } - case 3: { - if (!(message.nestedType && message.nestedType.length)) - message.nestedType = []; - message.nestedType.push( - $root.google.protobuf.DescriptorProto.decode( - reader, - reader.uint32() - ) - ); - break; - } - case 4: { - if (!(message.enumType && message.enumType.length)) - message.enumType = []; - message.enumType.push( - $root.google.protobuf.EnumDescriptorProto.decode( - reader, - reader.uint32() - ) - ); - break; - } - case 5: { - if (!(message.extensionRange && message.extensionRange.length)) - message.extensionRange = []; - message.extensionRange.push( - $root.google.protobuf.DescriptorProto.ExtensionRange.decode( - reader, - reader.uint32() - ) - ); - break; - } - case 8: { - if (!(message.oneofDecl && message.oneofDecl.length)) - message.oneofDecl = []; - message.oneofDecl.push( - $root.google.protobuf.OneofDescriptorProto.decode( - reader, - reader.uint32() - ) - ); - break; - } - case 7: { - message.options = $root.google.protobuf.MessageOptions.decode( - reader, - reader.uint32() - ); - break; - } - case 9: { - if (!(message.reservedRange && message.reservedRange.length)) - message.reservedRange = []; - message.reservedRange.push( - $root.google.protobuf.DescriptorProto.ReservedRange.decode( - reader, - reader.uint32() - ) - ); - break; - } - case 10: { - if (!(message.reservedName && message.reservedName.length)) - message.reservedName = []; - message.reservedName.push(reader.string()); - break; - } - case 11: { - message.visibility = reader.int32(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a DescriptorProto message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.DescriptorProto - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.DescriptorProto} DescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - DescriptorProto.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a DescriptorProto message. - * @function verify - * @memberof google.protobuf.DescriptorProto - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - DescriptorProto.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.field != null && message.hasOwnProperty("field")) { - if (!Array.isArray(message.field)) return "field: array expected"; - for (var i = 0; i < message.field.length; ++i) { - var error = $root.google.protobuf.FieldDescriptorProto.verify( - message.field[i] - ); - if (error) return "field." + error; - } - } - if (message.extension != null && message.hasOwnProperty("extension")) { - if (!Array.isArray(message.extension)) - return "extension: array expected"; - for (var i = 0; i < message.extension.length; ++i) { - var error = $root.google.protobuf.FieldDescriptorProto.verify( - message.extension[i] - ); - if (error) return "extension." + error; - } - } - if ( - message.nestedType != null && - message.hasOwnProperty("nestedType") - ) { - if (!Array.isArray(message.nestedType)) - return "nestedType: array expected"; - for (var i = 0; i < message.nestedType.length; ++i) { - var error = $root.google.protobuf.DescriptorProto.verify( - message.nestedType[i] - ); - if (error) return "nestedType." + error; - } - } - if (message.enumType != null && message.hasOwnProperty("enumType")) { - if (!Array.isArray(message.enumType)) - return "enumType: array expected"; - for (var i = 0; i < message.enumType.length; ++i) { - var error = $root.google.protobuf.EnumDescriptorProto.verify( - message.enumType[i] - ); - if (error) return "enumType." + error; - } - } - if ( - message.extensionRange != null && - message.hasOwnProperty("extensionRange") - ) { - if (!Array.isArray(message.extensionRange)) - return "extensionRange: array expected"; - for (var i = 0; i < message.extensionRange.length; ++i) { - var error = - $root.google.protobuf.DescriptorProto.ExtensionRange.verify( - message.extensionRange[i] - ); - if (error) return "extensionRange." + error; - } - } - if (message.oneofDecl != null && message.hasOwnProperty("oneofDecl")) { - if (!Array.isArray(message.oneofDecl)) - return "oneofDecl: array expected"; - for (var i = 0; i < message.oneofDecl.length; ++i) { - var error = $root.google.protobuf.OneofDescriptorProto.verify( - message.oneofDecl[i] - ); - if (error) return "oneofDecl." + error; - } - } - if (message.options != null && message.hasOwnProperty("options")) { - var error = $root.google.protobuf.MessageOptions.verify( - message.options - ); - if (error) return "options." + error; - } - if ( - message.reservedRange != null && - message.hasOwnProperty("reservedRange") - ) { - if (!Array.isArray(message.reservedRange)) - return "reservedRange: array expected"; - for (var i = 0; i < message.reservedRange.length; ++i) { - var error = - $root.google.protobuf.DescriptorProto.ReservedRange.verify( - message.reservedRange[i] - ); - if (error) return "reservedRange." + error; - } - } - if ( - message.reservedName != null && - message.hasOwnProperty("reservedName") - ) { - if (!Array.isArray(message.reservedName)) - return "reservedName: array expected"; - for (var i = 0; i < message.reservedName.length; ++i) - if (!$util.isString(message.reservedName[i])) - return "reservedName: string[] expected"; - } - if (message.visibility != null && message.hasOwnProperty("visibility")) - switch (message.visibility) { - default: - return "visibility: enum value expected"; - case 0: - case 1: - case 2: - break; - } - return null; - }; - - /** - * Creates a DescriptorProto message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.DescriptorProto - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.DescriptorProto} DescriptorProto - */ - DescriptorProto.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.DescriptorProto) - return object; - var message = new $root.google.protobuf.DescriptorProto(); - if (object.name != null) message.name = String(object.name); - if (object.field) { - if (!Array.isArray(object.field)) - throw TypeError( - ".google.protobuf.DescriptorProto.field: array expected" - ); - message.field = []; - for (var i = 0; i < object.field.length; ++i) { - if (typeof object.field[i] !== "object") - throw TypeError( - ".google.protobuf.DescriptorProto.field: object expected" - ); - message.field[i] = - $root.google.protobuf.FieldDescriptorProto.fromObject( - object.field[i] - ); - } - } - if (object.extension) { - if (!Array.isArray(object.extension)) - throw TypeError( - ".google.protobuf.DescriptorProto.extension: array expected" - ); - message.extension = []; - for (var i = 0; i < object.extension.length; ++i) { - if (typeof object.extension[i] !== "object") - throw TypeError( - ".google.protobuf.DescriptorProto.extension: object expected" - ); - message.extension[i] = - $root.google.protobuf.FieldDescriptorProto.fromObject( - object.extension[i] - ); - } - } - if (object.nestedType) { - if (!Array.isArray(object.nestedType)) - throw TypeError( - ".google.protobuf.DescriptorProto.nestedType: array expected" - ); - message.nestedType = []; - for (var i = 0; i < object.nestedType.length; ++i) { - if (typeof object.nestedType[i] !== "object") - throw TypeError( - ".google.protobuf.DescriptorProto.nestedType: object expected" - ); - message.nestedType[i] = - $root.google.protobuf.DescriptorProto.fromObject( - object.nestedType[i] - ); - } - } - if (object.enumType) { - if (!Array.isArray(object.enumType)) - throw TypeError( - ".google.protobuf.DescriptorProto.enumType: array expected" - ); - message.enumType = []; - for (var i = 0; i < object.enumType.length; ++i) { - if (typeof object.enumType[i] !== "object") - throw TypeError( - ".google.protobuf.DescriptorProto.enumType: object expected" - ); - message.enumType[i] = - $root.google.protobuf.EnumDescriptorProto.fromObject( - object.enumType[i] - ); - } - } - if (object.extensionRange) { - if (!Array.isArray(object.extensionRange)) - throw TypeError( - ".google.protobuf.DescriptorProto.extensionRange: array expected" - ); - message.extensionRange = []; - for (var i = 0; i < object.extensionRange.length; ++i) { - if (typeof object.extensionRange[i] !== "object") - throw TypeError( - ".google.protobuf.DescriptorProto.extensionRange: object expected" - ); - message.extensionRange[i] = - $root.google.protobuf.DescriptorProto.ExtensionRange.fromObject( - object.extensionRange[i] - ); - } - } - if (object.oneofDecl) { - if (!Array.isArray(object.oneofDecl)) - throw TypeError( - ".google.protobuf.DescriptorProto.oneofDecl: array expected" - ); - message.oneofDecl = []; - for (var i = 0; i < object.oneofDecl.length; ++i) { - if (typeof object.oneofDecl[i] !== "object") - throw TypeError( - ".google.protobuf.DescriptorProto.oneofDecl: object expected" - ); - message.oneofDecl[i] = - $root.google.protobuf.OneofDescriptorProto.fromObject( - object.oneofDecl[i] - ); - } - } - if (object.options != null) { - if (typeof object.options !== "object") - throw TypeError( - ".google.protobuf.DescriptorProto.options: object expected" - ); - message.options = $root.google.protobuf.MessageOptions.fromObject( - object.options - ); - } - if (object.reservedRange) { - if (!Array.isArray(object.reservedRange)) - throw TypeError( - ".google.protobuf.DescriptorProto.reservedRange: array expected" - ); - message.reservedRange = []; - for (var i = 0; i < object.reservedRange.length; ++i) { - if (typeof object.reservedRange[i] !== "object") - throw TypeError( - ".google.protobuf.DescriptorProto.reservedRange: object expected" - ); - message.reservedRange[i] = - $root.google.protobuf.DescriptorProto.ReservedRange.fromObject( - object.reservedRange[i] - ); - } - } - if (object.reservedName) { - if (!Array.isArray(object.reservedName)) - throw TypeError( - ".google.protobuf.DescriptorProto.reservedName: array expected" - ); - message.reservedName = []; - for (var i = 0; i < object.reservedName.length; ++i) - message.reservedName[i] = String(object.reservedName[i]); - } - switch (object.visibility) { - default: - if (typeof object.visibility === "number") { - message.visibility = object.visibility; - break; - } - break; - case "VISIBILITY_UNSET": - case 0: - message.visibility = 0; - break; - case "VISIBILITY_LOCAL": - case 1: - message.visibility = 1; - break; - case "VISIBILITY_EXPORT": - case 2: - message.visibility = 2; - break; - } - return message; - }; - - /** - * Creates a plain object from a DescriptorProto message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.DescriptorProto - * @static - * @param {google.protobuf.DescriptorProto} message DescriptorProto - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - DescriptorProto.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.arrays || options.defaults) { - object.field = []; - object.nestedType = []; - object.enumType = []; - object.extensionRange = []; - object.extension = []; - object.oneofDecl = []; - object.reservedRange = []; - object.reservedName = []; - } - if (options.defaults) { - object.name = ""; - object.options = null; - object.visibility = options.enums === String ? "VISIBILITY_UNSET" : 0; - } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message.field && message.field.length) { - object.field = []; - for (var j = 0; j < message.field.length; ++j) - object.field[j] = - $root.google.protobuf.FieldDescriptorProto.toObject( - message.field[j], - options - ); - } - if (message.nestedType && message.nestedType.length) { - object.nestedType = []; - for (var j = 0; j < message.nestedType.length; ++j) - object.nestedType[j] = - $root.google.protobuf.DescriptorProto.toObject( - message.nestedType[j], - options - ); - } - if (message.enumType && message.enumType.length) { - object.enumType = []; - for (var j = 0; j < message.enumType.length; ++j) - object.enumType[j] = - $root.google.protobuf.EnumDescriptorProto.toObject( - message.enumType[j], - options - ); - } - if (message.extensionRange && message.extensionRange.length) { - object.extensionRange = []; - for (var j = 0; j < message.extensionRange.length; ++j) - object.extensionRange[j] = - $root.google.protobuf.DescriptorProto.ExtensionRange.toObject( - message.extensionRange[j], - options - ); - } - if (message.extension && message.extension.length) { - object.extension = []; - for (var j = 0; j < message.extension.length; ++j) - object.extension[j] = - $root.google.protobuf.FieldDescriptorProto.toObject( - message.extension[j], - options - ); - } - if (message.options != null && message.hasOwnProperty("options")) - object.options = $root.google.protobuf.MessageOptions.toObject( - message.options, - options - ); - if (message.oneofDecl && message.oneofDecl.length) { - object.oneofDecl = []; - for (var j = 0; j < message.oneofDecl.length; ++j) - object.oneofDecl[j] = - $root.google.protobuf.OneofDescriptorProto.toObject( - message.oneofDecl[j], - options - ); - } - if (message.reservedRange && message.reservedRange.length) { - object.reservedRange = []; - for (var j = 0; j < message.reservedRange.length; ++j) - object.reservedRange[j] = - $root.google.protobuf.DescriptorProto.ReservedRange.toObject( - message.reservedRange[j], - options - ); - } - if (message.reservedName && message.reservedName.length) { - object.reservedName = []; - for (var j = 0; j < message.reservedName.length; ++j) - object.reservedName[j] = message.reservedName[j]; - } - if (message.visibility != null && message.hasOwnProperty("visibility")) - object.visibility = - options.enums === String - ? $root.google.protobuf.SymbolVisibility[message.visibility] === - undefined - ? message.visibility - : $root.google.protobuf.SymbolVisibility[message.visibility] - : message.visibility; - return object; - }; - - /** - * Converts this DescriptorProto to JSON. - * @function toJSON - * @memberof google.protobuf.DescriptorProto - * @instance - * @returns {Object.} JSON object - */ - DescriptorProto.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for DescriptorProto - * @function getTypeUrl - * @memberof google.protobuf.DescriptorProto - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - DescriptorProto.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.DescriptorProto"; - }; - - DescriptorProto.ExtensionRange = (function () { /** - * Properties of an ExtensionRange. - * @memberof google.protobuf.DescriptorProto - * @interface IExtensionRange - * @property {number|null} [start] ExtensionRange start - * @property {number|null} [end] ExtensionRange end - * @property {google.protobuf.IExtensionRangeOptions|null} [options] ExtensionRange options + * 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 */ /** - * Constructs a new ExtensionRange. - * @memberof google.protobuf.DescriptorProto - * @classdesc Represents an ExtensionRange. - * @implements IExtensionRange + * Constructs a new GirlBrief. + * @memberof cs + * @classdesc Represents a GirlBrief. + * @implements IGirlBrief * @constructor - * @param {google.protobuf.DescriptorProto.IExtensionRange=} [properties] Properties to set + * @param {cs.IGirlBrief=} [properties] Properties to set */ - function ExtensionRange(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]]; + 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]]; } /** - * ExtensionRange start. - * @member {number} start - * @memberof google.protobuf.DescriptorProto.ExtensionRange + * GirlBrief id. + * @member {number} id + * @memberof cs.GirlBrief * @instance */ - ExtensionRange.prototype.start = 0; + GirlBrief.prototype.id = 0; /** - * ExtensionRange end. - * @member {number} end - * @memberof google.protobuf.DescriptorProto.ExtensionRange + * GirlBrief name. + * @member {string} name + * @memberof cs.GirlBrief * @instance */ - ExtensionRange.prototype.end = 0; + GirlBrief.prototype.name = ""; /** - * ExtensionRange options. - * @member {google.protobuf.IExtensionRangeOptions|null|undefined} options - * @memberof google.protobuf.DescriptorProto.ExtensionRange + * GirlBrief age. + * @member {number} age + * @memberof cs.GirlBrief * @instance */ - ExtensionRange.prototype.options = null; + GirlBrief.prototype.age = 0; /** - * Creates a new ExtensionRange instance using the specified properties. + * 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; + + /** + * Creates a new GirlBrief instance using the specified properties. * @function create - * @memberof google.protobuf.DescriptorProto.ExtensionRange + * @memberof cs.GirlBrief * @static - * @param {google.protobuf.DescriptorProto.IExtensionRange=} [properties] Properties to set - * @returns {google.protobuf.DescriptorProto.ExtensionRange} ExtensionRange instance + * @param {cs.IGirlBrief=} [properties] Properties to set + * @returns {cs.GirlBrief} GirlBrief instance */ - ExtensionRange.create = function create(properties) { - return new ExtensionRange(properties); + GirlBrief.create = function create(properties) { + return new GirlBrief(properties); }; /** - * Encodes the specified ExtensionRange message. Does not implicitly {@link google.protobuf.DescriptorProto.ExtensionRange.verify|verify} messages. + * Encodes the specified GirlBrief message. Does not implicitly {@link cs.GirlBrief.verify|verify} messages. * @function encode - * @memberof google.protobuf.DescriptorProto.ExtensionRange + * @memberof cs.GirlBrief * @static - * @param {google.protobuf.DescriptorProto.IExtensionRange} message ExtensionRange message or plain object to encode + * @param {cs.IGirlBrief} message GirlBrief message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ExtensionRange.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if ( - message.start != null && - Object.hasOwnProperty.call(message, "start") - ) - writer.uint32(/* id 1, wireType 0 =*/ 8).int32(message.start); - if (message.end != null && Object.hasOwnProperty.call(message, "end")) - writer.uint32(/* id 2, wireType 0 =*/ 16).int32(message.end); - if ( - message.options != null && - Object.hasOwnProperty.call(message, "options") - ) - $root.google.protobuf.ExtensionRangeOptions.encode( - message.options, - writer.uint32(/* id 3, wireType 2 =*/ 26).fork() - ).ldelim(); - return writer; + 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); + return writer; }; /** - * Encodes the specified ExtensionRange message, length delimited. Does not implicitly {@link google.protobuf.DescriptorProto.ExtensionRange.verify|verify} messages. + * Encodes the specified GirlBrief message, length delimited. Does not implicitly {@link cs.GirlBrief.verify|verify} messages. * @function encodeDelimited - * @memberof google.protobuf.DescriptorProto.ExtensionRange + * @memberof cs.GirlBrief * @static - * @param {google.protobuf.DescriptorProto.IExtensionRange} message ExtensionRange message or plain object to encode + * @param {cs.IGirlBrief} message GirlBrief message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ExtensionRange.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); + GirlBrief.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); }; /** - * Decodes an ExtensionRange message from the specified reader or buffer. + * Decodes a GirlBrief message from the specified reader or buffer. * @function decode - * @memberof google.protobuf.DescriptorProto.ExtensionRange + * @memberof cs.GirlBrief * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.DescriptorProto.ExtensionRange} ExtensionRange + * @returns {cs.GirlBrief} GirlBrief * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ExtensionRange.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.google.protobuf.DescriptorProto.ExtensionRange(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - message.start = reader.int32(); - break; - } - case 2: { - message.end = reader.int32(); - break; - } - case 3: { - message.options = - $root.google.protobuf.ExtensionRangeOptions.decode( - reader, - reader.uint32() - ); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes an ExtensionRange message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.DescriptorProto.ExtensionRange - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.DescriptorProto.ExtensionRange} ExtensionRange - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - ExtensionRange.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies an ExtensionRange message. - * @function verify - * @memberof google.protobuf.DescriptorProto.ExtensionRange - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - ExtensionRange.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.start != null && message.hasOwnProperty("start")) - if (!$util.isInteger(message.start)) - return "start: integer expected"; - if (message.end != null && message.hasOwnProperty("end")) - if (!$util.isInteger(message.end)) return "end: integer expected"; - if (message.options != null && message.hasOwnProperty("options")) { - var error = $root.google.protobuf.ExtensionRangeOptions.verify( - message.options - ); - if (error) return "options." + error; - } - return null; - }; - - /** - * Creates an ExtensionRange message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.DescriptorProto.ExtensionRange - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.DescriptorProto.ExtensionRange} ExtensionRange - */ - ExtensionRange.fromObject = function fromObject(object) { - if ( - object instanceof - $root.google.protobuf.DescriptorProto.ExtensionRange - ) - return object; - var message = - new $root.google.protobuf.DescriptorProto.ExtensionRange(); - if (object.start != null) message.start = object.start | 0; - if (object.end != null) message.end = object.end | 0; - if (object.options != null) { - if (typeof object.options !== "object") - throw TypeError( - ".google.protobuf.DescriptorProto.ExtensionRange.options: object expected" - ); - message.options = - $root.google.protobuf.ExtensionRangeOptions.fromObject( - object.options - ); - } - return message; - }; - - /** - * Creates a plain object from an ExtensionRange message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.DescriptorProto.ExtensionRange - * @static - * @param {google.protobuf.DescriptorProto.ExtensionRange} message ExtensionRange - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - ExtensionRange.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.defaults) { - object.start = 0; - object.end = 0; - object.options = null; - } - if (message.start != null && message.hasOwnProperty("start")) - object.start = message.start; - if (message.end != null && message.hasOwnProperty("end")) - object.end = message.end; - if (message.options != null && message.hasOwnProperty("options")) - object.options = - $root.google.protobuf.ExtensionRangeOptions.toObject( - message.options, - options - ); - return object; - }; - - /** - * Converts this ExtensionRange to JSON. - * @function toJSON - * @memberof google.protobuf.DescriptorProto.ExtensionRange - * @instance - * @returns {Object.} JSON object - */ - ExtensionRange.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for ExtensionRange - * @function getTypeUrl - * @memberof google.protobuf.DescriptorProto.ExtensionRange - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - ExtensionRange.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return ( - typeUrlPrefix + "/google.protobuf.DescriptorProto.ExtensionRange" - ); - }; - - return ExtensionRange; - })(); - - DescriptorProto.ReservedRange = (function () { - /** - * Properties of a ReservedRange. - * @memberof google.protobuf.DescriptorProto - * @interface IReservedRange - * @property {number|null} [start] ReservedRange start - * @property {number|null} [end] ReservedRange end - */ - - /** - * Constructs a new ReservedRange. - * @memberof google.protobuf.DescriptorProto - * @classdesc Represents a ReservedRange. - * @implements IReservedRange - * @constructor - * @param {google.protobuf.DescriptorProto.IReservedRange=} [properties] Properties to set - */ - function ReservedRange(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]]; - } - - /** - * ReservedRange start. - * @member {number} start - * @memberof google.protobuf.DescriptorProto.ReservedRange - * @instance - */ - ReservedRange.prototype.start = 0; - - /** - * ReservedRange end. - * @member {number} end - * @memberof google.protobuf.DescriptorProto.ReservedRange - * @instance - */ - ReservedRange.prototype.end = 0; - - /** - * Creates a new ReservedRange instance using the specified properties. - * @function create - * @memberof google.protobuf.DescriptorProto.ReservedRange - * @static - * @param {google.protobuf.DescriptorProto.IReservedRange=} [properties] Properties to set - * @returns {google.protobuf.DescriptorProto.ReservedRange} ReservedRange instance - */ - ReservedRange.create = function create(properties) { - return new ReservedRange(properties); - }; - - /** - * Encodes the specified ReservedRange message. Does not implicitly {@link google.protobuf.DescriptorProto.ReservedRange.verify|verify} messages. - * @function encode - * @memberof google.protobuf.DescriptorProto.ReservedRange - * @static - * @param {google.protobuf.DescriptorProto.IReservedRange} message ReservedRange message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - ReservedRange.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if ( - message.start != null && - Object.hasOwnProperty.call(message, "start") - ) - writer.uint32(/* id 1, wireType 0 =*/ 8).int32(message.start); - if (message.end != null && Object.hasOwnProperty.call(message, "end")) - writer.uint32(/* id 2, wireType 0 =*/ 16).int32(message.end); - return writer; - }; - - /** - * Encodes the specified ReservedRange message, length delimited. Does not implicitly {@link google.protobuf.DescriptorProto.ReservedRange.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.DescriptorProto.ReservedRange - * @static - * @param {google.protobuf.DescriptorProto.IReservedRange} message ReservedRange message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - ReservedRange.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a ReservedRange message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.DescriptorProto.ReservedRange - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.DescriptorProto.ReservedRange} ReservedRange - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - ReservedRange.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.google.protobuf.DescriptorProto.ReservedRange(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - message.start = reader.int32(); - break; - } - case 2: { - message.end = reader.int32(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a ReservedRange message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.DescriptorProto.ReservedRange - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.DescriptorProto.ReservedRange} ReservedRange - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - ReservedRange.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a ReservedRange message. - * @function verify - * @memberof google.protobuf.DescriptorProto.ReservedRange - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - ReservedRange.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.start != null && message.hasOwnProperty("start")) - if (!$util.isInteger(message.start)) - return "start: integer expected"; - if (message.end != null && message.hasOwnProperty("end")) - if (!$util.isInteger(message.end)) return "end: integer expected"; - return null; - }; - - /** - * Creates a ReservedRange message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.DescriptorProto.ReservedRange - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.DescriptorProto.ReservedRange} ReservedRange - */ - ReservedRange.fromObject = function fromObject(object) { - if ( - object instanceof - $root.google.protobuf.DescriptorProto.ReservedRange - ) - return object; - var message = - new $root.google.protobuf.DescriptorProto.ReservedRange(); - if (object.start != null) message.start = object.start | 0; - if (object.end != null) message.end = object.end | 0; - return message; - }; - - /** - * Creates a plain object from a ReservedRange message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.DescriptorProto.ReservedRange - * @static - * @param {google.protobuf.DescriptorProto.ReservedRange} message ReservedRange - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - ReservedRange.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.defaults) { - object.start = 0; - object.end = 0; - } - if (message.start != null && message.hasOwnProperty("start")) - object.start = message.start; - if (message.end != null && message.hasOwnProperty("end")) - object.end = message.end; - return object; - }; - - /** - * Converts this ReservedRange to JSON. - * @function toJSON - * @memberof google.protobuf.DescriptorProto.ReservedRange - * @instance - * @returns {Object.} JSON object - */ - ReservedRange.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for ReservedRange - * @function getTypeUrl - * @memberof google.protobuf.DescriptorProto.ReservedRange - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - ReservedRange.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return ( - typeUrlPrefix + "/google.protobuf.DescriptorProto.ReservedRange" - ); - }; - - return ReservedRange; - })(); - - return DescriptorProto; - })(); - - protobuf.ExtensionRangeOptions = (function () { - /** - * Properties of an ExtensionRangeOptions. - * @memberof google.protobuf - * @interface IExtensionRangeOptions - * @property {Array.|null} [uninterpretedOption] ExtensionRangeOptions uninterpretedOption - * @property {Array.|null} [declaration] ExtensionRangeOptions declaration - * @property {google.protobuf.IFeatureSet|null} [features] ExtensionRangeOptions features - * @property {google.protobuf.ExtensionRangeOptions.VerificationState|null} [verification] ExtensionRangeOptions verification - */ - - /** - * Constructs a new ExtensionRangeOptions. - * @memberof google.protobuf - * @classdesc Represents an ExtensionRangeOptions. - * @implements IExtensionRangeOptions - * @constructor - * @param {google.protobuf.IExtensionRangeOptions=} [properties] Properties to set - */ - function ExtensionRangeOptions(properties) { - this.uninterpretedOption = []; - this.declaration = []; - 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]]; - } - - /** - * ExtensionRangeOptions uninterpretedOption. - * @member {Array.} uninterpretedOption - * @memberof google.protobuf.ExtensionRangeOptions - * @instance - */ - ExtensionRangeOptions.prototype.uninterpretedOption = $util.emptyArray; - - /** - * ExtensionRangeOptions declaration. - * @member {Array.} declaration - * @memberof google.protobuf.ExtensionRangeOptions - * @instance - */ - ExtensionRangeOptions.prototype.declaration = $util.emptyArray; - - /** - * ExtensionRangeOptions features. - * @member {google.protobuf.IFeatureSet|null|undefined} features - * @memberof google.protobuf.ExtensionRangeOptions - * @instance - */ - ExtensionRangeOptions.prototype.features = null; - - /** - * ExtensionRangeOptions verification. - * @member {google.protobuf.ExtensionRangeOptions.VerificationState} verification - * @memberof google.protobuf.ExtensionRangeOptions - * @instance - */ - ExtensionRangeOptions.prototype.verification = 1; - - /** - * Creates a new ExtensionRangeOptions instance using the specified properties. - * @function create - * @memberof google.protobuf.ExtensionRangeOptions - * @static - * @param {google.protobuf.IExtensionRangeOptions=} [properties] Properties to set - * @returns {google.protobuf.ExtensionRangeOptions} ExtensionRangeOptions instance - */ - ExtensionRangeOptions.create = function create(properties) { - return new ExtensionRangeOptions(properties); - }; - - /** - * Encodes the specified ExtensionRangeOptions message. Does not implicitly {@link google.protobuf.ExtensionRangeOptions.verify|verify} messages. - * @function encode - * @memberof google.protobuf.ExtensionRangeOptions - * @static - * @param {google.protobuf.IExtensionRangeOptions} message ExtensionRangeOptions message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - ExtensionRangeOptions.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if (message.declaration != null && message.declaration.length) - for (var i = 0; i < message.declaration.length; ++i) - $root.google.protobuf.ExtensionRangeOptions.Declaration.encode( - message.declaration[i], - writer.uint32(/* id 2, wireType 2 =*/ 18).fork() - ).ldelim(); - if ( - message.verification != null && - Object.hasOwnProperty.call(message, "verification") - ) - writer.uint32(/* id 3, wireType 0 =*/ 24).int32(message.verification); - if ( - message.features != null && - Object.hasOwnProperty.call(message, "features") - ) - $root.google.protobuf.FeatureSet.encode( - message.features, - writer.uint32(/* id 50, wireType 2 =*/ 402).fork() - ).ldelim(); - if ( - message.uninterpretedOption != null && - message.uninterpretedOption.length - ) - for (var i = 0; i < message.uninterpretedOption.length; ++i) - $root.google.protobuf.UninterpretedOption.encode( - message.uninterpretedOption[i], - writer.uint32(/* id 999, wireType 2 =*/ 7994).fork() - ).ldelim(); - return writer; - }; - - /** - * Encodes the specified ExtensionRangeOptions message, length delimited. Does not implicitly {@link google.protobuf.ExtensionRangeOptions.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.ExtensionRangeOptions - * @static - * @param {google.protobuf.IExtensionRangeOptions} message ExtensionRangeOptions message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - ExtensionRangeOptions.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes an ExtensionRangeOptions message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.ExtensionRangeOptions - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.ExtensionRangeOptions} ExtensionRangeOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - ExtensionRangeOptions.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.google.protobuf.ExtensionRangeOptions(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 999: { - if ( - !( - message.uninterpretedOption && - message.uninterpretedOption.length - ) - ) - message.uninterpretedOption = []; - message.uninterpretedOption.push( - $root.google.protobuf.UninterpretedOption.decode( - reader, - reader.uint32() - ) - ); - break; - } - case 2: { - if (!(message.declaration && message.declaration.length)) - message.declaration = []; - message.declaration.push( - $root.google.protobuf.ExtensionRangeOptions.Declaration.decode( - reader, - reader.uint32() - ) - ); - break; - } - case 50: { - message.features = $root.google.protobuf.FeatureSet.decode( - reader, - reader.uint32() - ); - break; - } - case 3: { - message.verification = reader.int32(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes an ExtensionRangeOptions message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.ExtensionRangeOptions - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.ExtensionRangeOptions} ExtensionRangeOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - ExtensionRangeOptions.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies an ExtensionRangeOptions message. - * @function verify - * @memberof google.protobuf.ExtensionRangeOptions - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - ExtensionRangeOptions.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if ( - message.uninterpretedOption != null && - message.hasOwnProperty("uninterpretedOption") - ) { - if (!Array.isArray(message.uninterpretedOption)) - return "uninterpretedOption: array expected"; - for (var i = 0; i < message.uninterpretedOption.length; ++i) { - var error = $root.google.protobuf.UninterpretedOption.verify( - message.uninterpretedOption[i] - ); - if (error) return "uninterpretedOption." + error; - } - } - if ( - message.declaration != null && - message.hasOwnProperty("declaration") - ) { - if (!Array.isArray(message.declaration)) - return "declaration: array expected"; - for (var i = 0; i < message.declaration.length; ++i) { - var error = - $root.google.protobuf.ExtensionRangeOptions.Declaration.verify( - message.declaration[i] - ); - if (error) return "declaration." + error; - } - } - if (message.features != null && message.hasOwnProperty("features")) { - var error = $root.google.protobuf.FeatureSet.verify(message.features); - if (error) return "features." + error; - } - if ( - message.verification != null && - message.hasOwnProperty("verification") - ) - switch (message.verification) { - default: - return "verification: enum value expected"; - case 0: - case 1: - break; - } - return null; - }; - - /** - * Creates an ExtensionRangeOptions message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.ExtensionRangeOptions - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.ExtensionRangeOptions} ExtensionRangeOptions - */ - ExtensionRangeOptions.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.ExtensionRangeOptions) - return object; - var message = new $root.google.protobuf.ExtensionRangeOptions(); - if (object.uninterpretedOption) { - if (!Array.isArray(object.uninterpretedOption)) - throw TypeError( - ".google.protobuf.ExtensionRangeOptions.uninterpretedOption: array expected" - ); - message.uninterpretedOption = []; - for (var i = 0; i < object.uninterpretedOption.length; ++i) { - if (typeof object.uninterpretedOption[i] !== "object") - throw TypeError( - ".google.protobuf.ExtensionRangeOptions.uninterpretedOption: object expected" - ); - message.uninterpretedOption[i] = - $root.google.protobuf.UninterpretedOption.fromObject( - object.uninterpretedOption[i] - ); - } - } - if (object.declaration) { - if (!Array.isArray(object.declaration)) - throw TypeError( - ".google.protobuf.ExtensionRangeOptions.declaration: array expected" - ); - message.declaration = []; - for (var i = 0; i < object.declaration.length; ++i) { - if (typeof object.declaration[i] !== "object") - throw TypeError( - ".google.protobuf.ExtensionRangeOptions.declaration: object expected" - ); - message.declaration[i] = - $root.google.protobuf.ExtensionRangeOptions.Declaration.fromObject( - object.declaration[i] - ); - } - } - if (object.features != null) { - if (typeof object.features !== "object") - throw TypeError( - ".google.protobuf.ExtensionRangeOptions.features: object expected" - ); - message.features = $root.google.protobuf.FeatureSet.fromObject( - object.features - ); - } - switch (object.verification) { - case "DECLARATION": - case 0: - message.verification = 0; - break; - default: - if (typeof object.verification === "number") { - message.verification = object.verification; - break; - } - break; - case "UNVERIFIED": - case 1: - message.verification = 1; - break; - } - return message; - }; - - /** - * Creates a plain object from an ExtensionRangeOptions message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.ExtensionRangeOptions - * @static - * @param {google.protobuf.ExtensionRangeOptions} message ExtensionRangeOptions - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - ExtensionRangeOptions.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.arrays || options.defaults) { - object.declaration = []; - object.uninterpretedOption = []; - } - if (options.defaults) { - object.verification = options.enums === String ? "UNVERIFIED" : 1; - object.features = null; - } - if (message.declaration && message.declaration.length) { - object.declaration = []; - for (var j = 0; j < message.declaration.length; ++j) - object.declaration[j] = - $root.google.protobuf.ExtensionRangeOptions.Declaration.toObject( - message.declaration[j], - options - ); - } - if ( - message.verification != null && - message.hasOwnProperty("verification") - ) - object.verification = - options.enums === String - ? $root.google.protobuf.ExtensionRangeOptions.VerificationState[ - message.verification - ] === undefined - ? message.verification - : $root.google.protobuf.ExtensionRangeOptions.VerificationState[ - message.verification - ] - : message.verification; - if (message.features != null && message.hasOwnProperty("features")) - object.features = $root.google.protobuf.FeatureSet.toObject( - message.features, - options - ); - if (message.uninterpretedOption && message.uninterpretedOption.length) { - object.uninterpretedOption = []; - for (var j = 0; j < message.uninterpretedOption.length; ++j) - object.uninterpretedOption[j] = - $root.google.protobuf.UninterpretedOption.toObject( - message.uninterpretedOption[j], - options - ); - } - return object; - }; - - /** - * Converts this ExtensionRangeOptions to JSON. - * @function toJSON - * @memberof google.protobuf.ExtensionRangeOptions - * @instance - * @returns {Object.} JSON object - */ - ExtensionRangeOptions.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for ExtensionRangeOptions - * @function getTypeUrl - * @memberof google.protobuf.ExtensionRangeOptions - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - ExtensionRangeOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.ExtensionRangeOptions"; - }; - - ExtensionRangeOptions.Declaration = (function () { - /** - * Properties of a Declaration. - * @memberof google.protobuf.ExtensionRangeOptions - * @interface IDeclaration - * @property {number|null} [number] Declaration number - * @property {string|null} [fullName] Declaration fullName - * @property {string|null} [type] Declaration type - * @property {boolean|null} [reserved] Declaration reserved - * @property {boolean|null} [repeated] Declaration repeated - */ - - /** - * Constructs a new Declaration. - * @memberof google.protobuf.ExtensionRangeOptions - * @classdesc Represents a Declaration. - * @implements IDeclaration - * @constructor - * @param {google.protobuf.ExtensionRangeOptions.IDeclaration=} [properties] Properties to set - */ - function Declaration(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]]; - } - - /** - * Declaration number. - * @member {number} number - * @memberof google.protobuf.ExtensionRangeOptions.Declaration - * @instance - */ - Declaration.prototype.number = 0; - - /** - * Declaration fullName. - * @member {string} fullName - * @memberof google.protobuf.ExtensionRangeOptions.Declaration - * @instance - */ - Declaration.prototype.fullName = ""; - - /** - * Declaration type. - * @member {string} type - * @memberof google.protobuf.ExtensionRangeOptions.Declaration - * @instance - */ - Declaration.prototype.type = ""; - - /** - * Declaration reserved. - * @member {boolean} reserved - * @memberof google.protobuf.ExtensionRangeOptions.Declaration - * @instance - */ - Declaration.prototype.reserved = false; - - /** - * Declaration repeated. - * @member {boolean} repeated - * @memberof google.protobuf.ExtensionRangeOptions.Declaration - * @instance - */ - Declaration.prototype.repeated = false; - - /** - * Creates a new Declaration instance using the specified properties. - * @function create - * @memberof google.protobuf.ExtensionRangeOptions.Declaration - * @static - * @param {google.protobuf.ExtensionRangeOptions.IDeclaration=} [properties] Properties to set - * @returns {google.protobuf.ExtensionRangeOptions.Declaration} Declaration instance - */ - Declaration.create = function create(properties) { - return new Declaration(properties); - }; - - /** - * Encodes the specified Declaration message. Does not implicitly {@link google.protobuf.ExtensionRangeOptions.Declaration.verify|verify} messages. - * @function encode - * @memberof google.protobuf.ExtensionRangeOptions.Declaration - * @static - * @param {google.protobuf.ExtensionRangeOptions.IDeclaration} message Declaration message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - Declaration.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if ( - message.number != null && - Object.hasOwnProperty.call(message, "number") - ) - writer.uint32(/* id 1, wireType 0 =*/ 8).int32(message.number); - if ( - message.fullName != null && - Object.hasOwnProperty.call(message, "fullName") - ) - writer.uint32(/* id 2, wireType 2 =*/ 18).string(message.fullName); - if ( - message.type != null && - Object.hasOwnProperty.call(message, "type") - ) - writer.uint32(/* id 3, wireType 2 =*/ 26).string(message.type); - if ( - message.reserved != null && - Object.hasOwnProperty.call(message, "reserved") - ) - writer.uint32(/* id 5, wireType 0 =*/ 40).bool(message.reserved); - if ( - message.repeated != null && - Object.hasOwnProperty.call(message, "repeated") - ) - writer.uint32(/* id 6, wireType 0 =*/ 48).bool(message.repeated); - return writer; - }; - - /** - * Encodes the specified Declaration message, length delimited. Does not implicitly {@link google.protobuf.ExtensionRangeOptions.Declaration.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.ExtensionRangeOptions.Declaration - * @static - * @param {google.protobuf.ExtensionRangeOptions.IDeclaration} message Declaration message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - Declaration.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a Declaration message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.ExtensionRangeOptions.Declaration - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.ExtensionRangeOptions.Declaration} Declaration - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - Declaration.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.google.protobuf.ExtensionRangeOptions.Declaration(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - message.number = reader.int32(); - break; - } - case 2: { - message.fullName = reader.string(); - break; - } - case 3: { - message.type = reader.string(); - break; - } - case 5: { - message.reserved = reader.bool(); - break; - } - case 6: { - message.repeated = reader.bool(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a Declaration message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.ExtensionRangeOptions.Declaration - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.ExtensionRangeOptions.Declaration} Declaration - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - Declaration.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a Declaration message. - * @function verify - * @memberof google.protobuf.ExtensionRangeOptions.Declaration - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - Declaration.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.number != null && message.hasOwnProperty("number")) - if (!$util.isInteger(message.number)) - return "number: integer expected"; - if (message.fullName != null && message.hasOwnProperty("fullName")) - if (!$util.isString(message.fullName)) - return "fullName: string expected"; - if (message.type != null && message.hasOwnProperty("type")) - if (!$util.isString(message.type)) return "type: string expected"; - if (message.reserved != null && message.hasOwnProperty("reserved")) - if (typeof message.reserved !== "boolean") - return "reserved: boolean expected"; - if (message.repeated != null && message.hasOwnProperty("repeated")) - if (typeof message.repeated !== "boolean") - return "repeated: boolean expected"; - return null; - }; - - /** - * Creates a Declaration message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.ExtensionRangeOptions.Declaration - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.ExtensionRangeOptions.Declaration} Declaration - */ - Declaration.fromObject = function fromObject(object) { - if ( - object instanceof - $root.google.protobuf.ExtensionRangeOptions.Declaration - ) - return object; - var message = - new $root.google.protobuf.ExtensionRangeOptions.Declaration(); - if (object.number != null) message.number = object.number | 0; - if (object.fullName != null) - message.fullName = String(object.fullName); - if (object.type != null) message.type = String(object.type); - if (object.reserved != null) - message.reserved = Boolean(object.reserved); - if (object.repeated != null) - message.repeated = Boolean(object.repeated); - return message; - }; - - /** - * Creates a plain object from a Declaration message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.ExtensionRangeOptions.Declaration - * @static - * @param {google.protobuf.ExtensionRangeOptions.Declaration} message Declaration - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - Declaration.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.defaults) { - object.number = 0; - object.fullName = ""; - object.type = ""; - object.reserved = false; - object.repeated = false; - } - if (message.number != null && message.hasOwnProperty("number")) - object.number = message.number; - if (message.fullName != null && message.hasOwnProperty("fullName")) - object.fullName = message.fullName; - if (message.type != null && message.hasOwnProperty("type")) - object.type = message.type; - if (message.reserved != null && message.hasOwnProperty("reserved")) - object.reserved = message.reserved; - if (message.repeated != null && message.hasOwnProperty("repeated")) - object.repeated = message.repeated; - return object; - }; - - /** - * Converts this Declaration to JSON. - * @function toJSON - * @memberof google.protobuf.ExtensionRangeOptions.Declaration - * @instance - * @returns {Object.} JSON object - */ - Declaration.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for Declaration - * @function getTypeUrl - * @memberof google.protobuf.ExtensionRangeOptions.Declaration - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - Declaration.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return ( - typeUrlPrefix + "/google.protobuf.ExtensionRangeOptions.Declaration" - ); - }; - - return Declaration; - })(); - - /** - * VerificationState enum. - * @name google.protobuf.ExtensionRangeOptions.VerificationState - * @enum {number} - * @property {number} DECLARATION=0 DECLARATION value - * @property {number} UNVERIFIED=1 UNVERIFIED value - */ - ExtensionRangeOptions.VerificationState = (function () { - var valuesById = {}, - values = Object.create(valuesById); - values[(valuesById[0] = "DECLARATION")] = 0; - values[(valuesById[1] = "UNVERIFIED")] = 1; - return values; - })(); - - return ExtensionRangeOptions; - })(); - - protobuf.FieldDescriptorProto = (function () { - /** - * Properties of a FieldDescriptorProto. - * @memberof google.protobuf - * @interface IFieldDescriptorProto - * @property {string|null} [name] FieldDescriptorProto name - * @property {number|null} [number] FieldDescriptorProto number - * @property {google.protobuf.FieldDescriptorProto.Label|null} [label] FieldDescriptorProto label - * @property {google.protobuf.FieldDescriptorProto.Type|null} [type] FieldDescriptorProto type - * @property {string|null} [typeName] FieldDescriptorProto typeName - * @property {string|null} [extendee] FieldDescriptorProto extendee - * @property {string|null} [defaultValue] FieldDescriptorProto defaultValue - * @property {number|null} [oneofIndex] FieldDescriptorProto oneofIndex - * @property {string|null} [jsonName] FieldDescriptorProto jsonName - * @property {google.protobuf.IFieldOptions|null} [options] FieldDescriptorProto options - * @property {boolean|null} [proto3Optional] FieldDescriptorProto proto3Optional - */ - - /** - * Constructs a new FieldDescriptorProto. - * @memberof google.protobuf - * @classdesc Represents a FieldDescriptorProto. - * @implements IFieldDescriptorProto - * @constructor - * @param {google.protobuf.IFieldDescriptorProto=} [properties] Properties to set - */ - function FieldDescriptorProto(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]]; - } - - /** - * FieldDescriptorProto name. - * @member {string} name - * @memberof google.protobuf.FieldDescriptorProto - * @instance - */ - FieldDescriptorProto.prototype.name = ""; - - /** - * FieldDescriptorProto number. - * @member {number} number - * @memberof google.protobuf.FieldDescriptorProto - * @instance - */ - FieldDescriptorProto.prototype.number = 0; - - /** - * FieldDescriptorProto label. - * @member {google.protobuf.FieldDescriptorProto.Label} label - * @memberof google.protobuf.FieldDescriptorProto - * @instance - */ - FieldDescriptorProto.prototype.label = 1; - - /** - * FieldDescriptorProto type. - * @member {google.protobuf.FieldDescriptorProto.Type} type - * @memberof google.protobuf.FieldDescriptorProto - * @instance - */ - FieldDescriptorProto.prototype.type = 1; - - /** - * FieldDescriptorProto typeName. - * @member {string} typeName - * @memberof google.protobuf.FieldDescriptorProto - * @instance - */ - FieldDescriptorProto.prototype.typeName = ""; - - /** - * FieldDescriptorProto extendee. - * @member {string} extendee - * @memberof google.protobuf.FieldDescriptorProto - * @instance - */ - FieldDescriptorProto.prototype.extendee = ""; - - /** - * FieldDescriptorProto defaultValue. - * @member {string} defaultValue - * @memberof google.protobuf.FieldDescriptorProto - * @instance - */ - FieldDescriptorProto.prototype.defaultValue = ""; - - /** - * FieldDescriptorProto oneofIndex. - * @member {number} oneofIndex - * @memberof google.protobuf.FieldDescriptorProto - * @instance - */ - FieldDescriptorProto.prototype.oneofIndex = 0; - - /** - * FieldDescriptorProto jsonName. - * @member {string} jsonName - * @memberof google.protobuf.FieldDescriptorProto - * @instance - */ - FieldDescriptorProto.prototype.jsonName = ""; - - /** - * FieldDescriptorProto options. - * @member {google.protobuf.IFieldOptions|null|undefined} options - * @memberof google.protobuf.FieldDescriptorProto - * @instance - */ - FieldDescriptorProto.prototype.options = null; - - /** - * FieldDescriptorProto proto3Optional. - * @member {boolean} proto3Optional - * @memberof google.protobuf.FieldDescriptorProto - * @instance - */ - FieldDescriptorProto.prototype.proto3Optional = false; - - /** - * Creates a new FieldDescriptorProto instance using the specified properties. - * @function create - * @memberof google.protobuf.FieldDescriptorProto - * @static - * @param {google.protobuf.IFieldDescriptorProto=} [properties] Properties to set - * @returns {google.protobuf.FieldDescriptorProto} FieldDescriptorProto instance - */ - FieldDescriptorProto.create = function create(properties) { - return new FieldDescriptorProto(properties); - }; - - /** - * Encodes the specified FieldDescriptorProto message. Does not implicitly {@link google.protobuf.FieldDescriptorProto.verify|verify} messages. - * @function encode - * @memberof google.protobuf.FieldDescriptorProto - * @static - * @param {google.protobuf.IFieldDescriptorProto} message FieldDescriptorProto message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - FieldDescriptorProto.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.extendee != null && - Object.hasOwnProperty.call(message, "extendee") - ) - writer.uint32(/* id 2, wireType 2 =*/ 18).string(message.extendee); - if ( - message.number != null && - Object.hasOwnProperty.call(message, "number") - ) - writer.uint32(/* id 3, wireType 0 =*/ 24).int32(message.number); - if ( - message.label != null && - Object.hasOwnProperty.call(message, "label") - ) - writer.uint32(/* id 4, wireType 0 =*/ 32).int32(message.label); - if (message.type != null && Object.hasOwnProperty.call(message, "type")) - writer.uint32(/* id 5, wireType 0 =*/ 40).int32(message.type); - if ( - message.typeName != null && - Object.hasOwnProperty.call(message, "typeName") - ) - writer.uint32(/* id 6, wireType 2 =*/ 50).string(message.typeName); - if ( - message.defaultValue != null && - Object.hasOwnProperty.call(message, "defaultValue") - ) - writer - .uint32(/* id 7, wireType 2 =*/ 58) - .string(message.defaultValue); - if ( - message.options != null && - Object.hasOwnProperty.call(message, "options") - ) - $root.google.protobuf.FieldOptions.encode( - message.options, - writer.uint32(/* id 8, wireType 2 =*/ 66).fork() - ).ldelim(); - if ( - message.oneofIndex != null && - Object.hasOwnProperty.call(message, "oneofIndex") - ) - writer.uint32(/* id 9, wireType 0 =*/ 72).int32(message.oneofIndex); - if ( - message.jsonName != null && - Object.hasOwnProperty.call(message, "jsonName") - ) - writer.uint32(/* id 10, wireType 2 =*/ 82).string(message.jsonName); - if ( - message.proto3Optional != null && - Object.hasOwnProperty.call(message, "proto3Optional") - ) - writer - .uint32(/* id 17, wireType 0 =*/ 136) - .bool(message.proto3Optional); - return writer; - }; - - /** - * Encodes the specified FieldDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.FieldDescriptorProto.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.FieldDescriptorProto - * @static - * @param {google.protobuf.IFieldDescriptorProto} message FieldDescriptorProto message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - FieldDescriptorProto.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a FieldDescriptorProto message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.FieldDescriptorProto - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.FieldDescriptorProto} FieldDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - FieldDescriptorProto.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.google.protobuf.FieldDescriptorProto(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - message.name = reader.string(); - break; - } - case 3: { - message.number = reader.int32(); - break; - } - case 4: { - message.label = reader.int32(); - break; - } - case 5: { - message.type = reader.int32(); - break; - } - case 6: { - message.typeName = reader.string(); - break; - } - case 2: { - message.extendee = reader.string(); - break; - } - case 7: { - message.defaultValue = reader.string(); - break; - } - case 9: { - message.oneofIndex = reader.int32(); - break; - } - case 10: { - message.jsonName = reader.string(); - break; - } - case 8: { - message.options = $root.google.protobuf.FieldOptions.decode( - reader, - reader.uint32() - ); - break; - } - case 17: { - message.proto3Optional = reader.bool(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a FieldDescriptorProto message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.FieldDescriptorProto - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.FieldDescriptorProto} FieldDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - FieldDescriptorProto.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a FieldDescriptorProto message. - * @function verify - * @memberof google.protobuf.FieldDescriptorProto - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - FieldDescriptorProto.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.number != null && message.hasOwnProperty("number")) - if (!$util.isInteger(message.number)) - return "number: integer expected"; - if (message.label != null && message.hasOwnProperty("label")) - switch (message.label) { - default: - return "label: enum value expected"; - case 1: - case 3: - case 2: - break; - } - if (message.type != null && message.hasOwnProperty("type")) - switch (message.type) { - default: - return "type: enum value expected"; - case 1: - case 2: - case 3: - case 4: - case 5: - case 6: - case 7: - case 8: - case 9: - case 10: - case 11: - case 12: - case 13: - case 14: - case 15: - case 16: - case 17: - case 18: - break; - } - if (message.typeName != null && message.hasOwnProperty("typeName")) - if (!$util.isString(message.typeName)) - return "typeName: string expected"; - if (message.extendee != null && message.hasOwnProperty("extendee")) - if (!$util.isString(message.extendee)) - return "extendee: string expected"; - if ( - message.defaultValue != null && - message.hasOwnProperty("defaultValue") - ) - if (!$util.isString(message.defaultValue)) - return "defaultValue: string expected"; - if (message.oneofIndex != null && message.hasOwnProperty("oneofIndex")) - if (!$util.isInteger(message.oneofIndex)) - return "oneofIndex: integer expected"; - if (message.jsonName != null && message.hasOwnProperty("jsonName")) - if (!$util.isString(message.jsonName)) - return "jsonName: string expected"; - if (message.options != null && message.hasOwnProperty("options")) { - var error = $root.google.protobuf.FieldOptions.verify( - message.options - ); - if (error) return "options." + error; - } - if ( - message.proto3Optional != null && - message.hasOwnProperty("proto3Optional") - ) - if (typeof message.proto3Optional !== "boolean") - return "proto3Optional: boolean expected"; - return null; - }; - - /** - * Creates a FieldDescriptorProto message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.FieldDescriptorProto - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.FieldDescriptorProto} FieldDescriptorProto - */ - FieldDescriptorProto.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.FieldDescriptorProto) - return object; - var message = new $root.google.protobuf.FieldDescriptorProto(); - if (object.name != null) message.name = String(object.name); - if (object.number != null) message.number = object.number | 0; - switch (object.label) { - default: - if (typeof object.label === "number") { - message.label = object.label; - break; - } - break; - case "LABEL_OPTIONAL": - case 1: - message.label = 1; - break; - case "LABEL_REPEATED": - case 3: - message.label = 3; - break; - case "LABEL_REQUIRED": - case 2: - message.label = 2; - break; - } - switch (object.type) { - default: - if (typeof object.type === "number") { - message.type = object.type; - break; - } - break; - case "TYPE_DOUBLE": - case 1: - message.type = 1; - break; - case "TYPE_FLOAT": - case 2: - message.type = 2; - break; - case "TYPE_INT64": - case 3: - message.type = 3; - break; - case "TYPE_UINT64": - case 4: - message.type = 4; - break; - case "TYPE_INT32": - case 5: - message.type = 5; - break; - case "TYPE_FIXED64": - case 6: - message.type = 6; - break; - case "TYPE_FIXED32": - case 7: - message.type = 7; - break; - case "TYPE_BOOL": - case 8: - message.type = 8; - break; - case "TYPE_STRING": - case 9: - message.type = 9; - break; - case "TYPE_GROUP": - case 10: - message.type = 10; - break; - case "TYPE_MESSAGE": - case 11: - message.type = 11; - break; - case "TYPE_BYTES": - case 12: - message.type = 12; - break; - case "TYPE_UINT32": - case 13: - message.type = 13; - break; - case "TYPE_ENUM": - case 14: - message.type = 14; - break; - case "TYPE_SFIXED32": - case 15: - message.type = 15; - break; - case "TYPE_SFIXED64": - case 16: - message.type = 16; - break; - case "TYPE_SINT32": - case 17: - message.type = 17; - break; - case "TYPE_SINT64": - case 18: - message.type = 18; - break; - } - if (object.typeName != null) message.typeName = String(object.typeName); - if (object.extendee != null) message.extendee = String(object.extendee); - if (object.defaultValue != null) - message.defaultValue = String(object.defaultValue); - if (object.oneofIndex != null) - message.oneofIndex = object.oneofIndex | 0; - if (object.jsonName != null) message.jsonName = String(object.jsonName); - if (object.options != null) { - if (typeof object.options !== "object") - throw TypeError( - ".google.protobuf.FieldDescriptorProto.options: object expected" - ); - message.options = $root.google.protobuf.FieldOptions.fromObject( - object.options - ); - } - if (object.proto3Optional != null) - message.proto3Optional = Boolean(object.proto3Optional); - return message; - }; - - /** - * Creates a plain object from a FieldDescriptorProto message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.FieldDescriptorProto - * @static - * @param {google.protobuf.FieldDescriptorProto} message FieldDescriptorProto - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - FieldDescriptorProto.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.defaults) { - object.name = ""; - object.extendee = ""; - object.number = 0; - object.label = options.enums === String ? "LABEL_OPTIONAL" : 1; - object.type = options.enums === String ? "TYPE_DOUBLE" : 1; - object.typeName = ""; - object.defaultValue = ""; - object.options = null; - object.oneofIndex = 0; - object.jsonName = ""; - object.proto3Optional = false; - } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message.extendee != null && message.hasOwnProperty("extendee")) - object.extendee = message.extendee; - if (message.number != null && message.hasOwnProperty("number")) - object.number = message.number; - if (message.label != null && message.hasOwnProperty("label")) - object.label = - options.enums === String - ? $root.google.protobuf.FieldDescriptorProto.Label[ - message.label - ] === undefined - ? message.label - : $root.google.protobuf.FieldDescriptorProto.Label[ - message.label - ] - : message.label; - if (message.type != null && message.hasOwnProperty("type")) - object.type = - options.enums === String - ? $root.google.protobuf.FieldDescriptorProto.Type[ - message.type - ] === undefined - ? message.type - : $root.google.protobuf.FieldDescriptorProto.Type[message.type] - : message.type; - if (message.typeName != null && message.hasOwnProperty("typeName")) - object.typeName = message.typeName; - if ( - message.defaultValue != null && - message.hasOwnProperty("defaultValue") - ) - object.defaultValue = message.defaultValue; - if (message.options != null && message.hasOwnProperty("options")) - object.options = $root.google.protobuf.FieldOptions.toObject( - message.options, - options - ); - if (message.oneofIndex != null && message.hasOwnProperty("oneofIndex")) - object.oneofIndex = message.oneofIndex; - if (message.jsonName != null && message.hasOwnProperty("jsonName")) - object.jsonName = message.jsonName; - if ( - message.proto3Optional != null && - message.hasOwnProperty("proto3Optional") - ) - object.proto3Optional = message.proto3Optional; - return object; - }; - - /** - * Converts this FieldDescriptorProto to JSON. - * @function toJSON - * @memberof google.protobuf.FieldDescriptorProto - * @instance - * @returns {Object.} JSON object - */ - FieldDescriptorProto.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for FieldDescriptorProto - * @function getTypeUrl - * @memberof google.protobuf.FieldDescriptorProto - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - FieldDescriptorProto.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.FieldDescriptorProto"; - }; - - /** - * Type enum. - * @name google.protobuf.FieldDescriptorProto.Type - * @enum {number} - * @property {number} TYPE_DOUBLE=1 TYPE_DOUBLE value - * @property {number} TYPE_FLOAT=2 TYPE_FLOAT value - * @property {number} TYPE_INT64=3 TYPE_INT64 value - * @property {number} TYPE_UINT64=4 TYPE_UINT64 value - * @property {number} TYPE_INT32=5 TYPE_INT32 value - * @property {number} TYPE_FIXED64=6 TYPE_FIXED64 value - * @property {number} TYPE_FIXED32=7 TYPE_FIXED32 value - * @property {number} TYPE_BOOL=8 TYPE_BOOL value - * @property {number} TYPE_STRING=9 TYPE_STRING value - * @property {number} TYPE_GROUP=10 TYPE_GROUP value - * @property {number} TYPE_MESSAGE=11 TYPE_MESSAGE value - * @property {number} TYPE_BYTES=12 TYPE_BYTES value - * @property {number} TYPE_UINT32=13 TYPE_UINT32 value - * @property {number} TYPE_ENUM=14 TYPE_ENUM value - * @property {number} TYPE_SFIXED32=15 TYPE_SFIXED32 value - * @property {number} TYPE_SFIXED64=16 TYPE_SFIXED64 value - * @property {number} TYPE_SINT32=17 TYPE_SINT32 value - * @property {number} TYPE_SINT64=18 TYPE_SINT64 value - */ - FieldDescriptorProto.Type = (function () { - var valuesById = {}, - values = Object.create(valuesById); - values[(valuesById[1] = "TYPE_DOUBLE")] = 1; - values[(valuesById[2] = "TYPE_FLOAT")] = 2; - values[(valuesById[3] = "TYPE_INT64")] = 3; - values[(valuesById[4] = "TYPE_UINT64")] = 4; - values[(valuesById[5] = "TYPE_INT32")] = 5; - values[(valuesById[6] = "TYPE_FIXED64")] = 6; - values[(valuesById[7] = "TYPE_FIXED32")] = 7; - values[(valuesById[8] = "TYPE_BOOL")] = 8; - values[(valuesById[9] = "TYPE_STRING")] = 9; - values[(valuesById[10] = "TYPE_GROUP")] = 10; - values[(valuesById[11] = "TYPE_MESSAGE")] = 11; - values[(valuesById[12] = "TYPE_BYTES")] = 12; - values[(valuesById[13] = "TYPE_UINT32")] = 13; - values[(valuesById[14] = "TYPE_ENUM")] = 14; - values[(valuesById[15] = "TYPE_SFIXED32")] = 15; - values[(valuesById[16] = "TYPE_SFIXED64")] = 16; - values[(valuesById[17] = "TYPE_SINT32")] = 17; - values[(valuesById[18] = "TYPE_SINT64")] = 18; - return values; - })(); - - /** - * Label enum. - * @name google.protobuf.FieldDescriptorProto.Label - * @enum {number} - * @property {number} LABEL_OPTIONAL=1 LABEL_OPTIONAL value - * @property {number} LABEL_REPEATED=3 LABEL_REPEATED value - * @property {number} LABEL_REQUIRED=2 LABEL_REQUIRED value - */ - FieldDescriptorProto.Label = (function () { - var valuesById = {}, - values = Object.create(valuesById); - values[(valuesById[1] = "LABEL_OPTIONAL")] = 1; - values[(valuesById[3] = "LABEL_REPEATED")] = 3; - values[(valuesById[2] = "LABEL_REQUIRED")] = 2; - return values; - })(); - - return FieldDescriptorProto; - })(); - - protobuf.OneofDescriptorProto = (function () { - /** - * Properties of an OneofDescriptorProto. - * @memberof google.protobuf - * @interface IOneofDescriptorProto - * @property {string|null} [name] OneofDescriptorProto name - * @property {google.protobuf.IOneofOptions|null} [options] OneofDescriptorProto options - */ - - /** - * Constructs a new OneofDescriptorProto. - * @memberof google.protobuf - * @classdesc Represents an OneofDescriptorProto. - * @implements IOneofDescriptorProto - * @constructor - * @param {google.protobuf.IOneofDescriptorProto=} [properties] Properties to set - */ - function OneofDescriptorProto(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]]; - } - - /** - * OneofDescriptorProto name. - * @member {string} name - * @memberof google.protobuf.OneofDescriptorProto - * @instance - */ - OneofDescriptorProto.prototype.name = ""; - - /** - * OneofDescriptorProto options. - * @member {google.protobuf.IOneofOptions|null|undefined} options - * @memberof google.protobuf.OneofDescriptorProto - * @instance - */ - OneofDescriptorProto.prototype.options = null; - - /** - * Creates a new OneofDescriptorProto instance using the specified properties. - * @function create - * @memberof google.protobuf.OneofDescriptorProto - * @static - * @param {google.protobuf.IOneofDescriptorProto=} [properties] Properties to set - * @returns {google.protobuf.OneofDescriptorProto} OneofDescriptorProto instance - */ - OneofDescriptorProto.create = function create(properties) { - return new OneofDescriptorProto(properties); - }; - - /** - * Encodes the specified OneofDescriptorProto message. Does not implicitly {@link google.protobuf.OneofDescriptorProto.verify|verify} messages. - * @function encode - * @memberof google.protobuf.OneofDescriptorProto - * @static - * @param {google.protobuf.IOneofDescriptorProto} message OneofDescriptorProto message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - OneofDescriptorProto.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.options != null && - Object.hasOwnProperty.call(message, "options") - ) - $root.google.protobuf.OneofOptions.encode( - message.options, - writer.uint32(/* id 2, wireType 2 =*/ 18).fork() - ).ldelim(); - return writer; - }; - - /** - * Encodes the specified OneofDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.OneofDescriptorProto.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.OneofDescriptorProto - * @static - * @param {google.protobuf.IOneofDescriptorProto} message OneofDescriptorProto message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - OneofDescriptorProto.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes an OneofDescriptorProto message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.OneofDescriptorProto - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.OneofDescriptorProto} OneofDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - OneofDescriptorProto.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.google.protobuf.OneofDescriptorProto(); - 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.options = $root.google.protobuf.OneofOptions.decode( - reader, - reader.uint32() - ); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes an OneofDescriptorProto message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.OneofDescriptorProto - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.OneofDescriptorProto} OneofDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - OneofDescriptorProto.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies an OneofDescriptorProto message. - * @function verify - * @memberof google.protobuf.OneofDescriptorProto - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - OneofDescriptorProto.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.options != null && message.hasOwnProperty("options")) { - var error = $root.google.protobuf.OneofOptions.verify( - message.options - ); - if (error) return "options." + error; - } - return null; - }; - - /** - * Creates an OneofDescriptorProto message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.OneofDescriptorProto - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.OneofDescriptorProto} OneofDescriptorProto - */ - OneofDescriptorProto.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.OneofDescriptorProto) - return object; - var message = new $root.google.protobuf.OneofDescriptorProto(); - if (object.name != null) message.name = String(object.name); - if (object.options != null) { - if (typeof object.options !== "object") - throw TypeError( - ".google.protobuf.OneofDescriptorProto.options: object expected" - ); - message.options = $root.google.protobuf.OneofOptions.fromObject( - object.options - ); - } - return message; - }; - - /** - * Creates a plain object from an OneofDescriptorProto message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.OneofDescriptorProto - * @static - * @param {google.protobuf.OneofDescriptorProto} message OneofDescriptorProto - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - OneofDescriptorProto.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.defaults) { - object.name = ""; - object.options = null; - } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message.options != null && message.hasOwnProperty("options")) - object.options = $root.google.protobuf.OneofOptions.toObject( - message.options, - options - ); - return object; - }; - - /** - * Converts this OneofDescriptorProto to JSON. - * @function toJSON - * @memberof google.protobuf.OneofDescriptorProto - * @instance - * @returns {Object.} JSON object - */ - OneofDescriptorProto.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for OneofDescriptorProto - * @function getTypeUrl - * @memberof google.protobuf.OneofDescriptorProto - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - OneofDescriptorProto.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.OneofDescriptorProto"; - }; - - return OneofDescriptorProto; - })(); - - protobuf.EnumDescriptorProto = (function () { - /** - * Properties of an EnumDescriptorProto. - * @memberof google.protobuf - * @interface IEnumDescriptorProto - * @property {string|null} [name] EnumDescriptorProto name - * @property {Array.|null} [value] EnumDescriptorProto value - * @property {google.protobuf.IEnumOptions|null} [options] EnumDescriptorProto options - * @property {Array.|null} [reservedRange] EnumDescriptorProto reservedRange - * @property {Array.|null} [reservedName] EnumDescriptorProto reservedName - * @property {google.protobuf.SymbolVisibility|null} [visibility] EnumDescriptorProto visibility - */ - - /** - * Constructs a new EnumDescriptorProto. - * @memberof google.protobuf - * @classdesc Represents an EnumDescriptorProto. - * @implements IEnumDescriptorProto - * @constructor - * @param {google.protobuf.IEnumDescriptorProto=} [properties] Properties to set - */ - function EnumDescriptorProto(properties) { - this.value = []; - this.reservedRange = []; - this.reservedName = []; - 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]]; - } - - /** - * EnumDescriptorProto name. - * @member {string} name - * @memberof google.protobuf.EnumDescriptorProto - * @instance - */ - EnumDescriptorProto.prototype.name = ""; - - /** - * EnumDescriptorProto value. - * @member {Array.} value - * @memberof google.protobuf.EnumDescriptorProto - * @instance - */ - EnumDescriptorProto.prototype.value = $util.emptyArray; - - /** - * EnumDescriptorProto options. - * @member {google.protobuf.IEnumOptions|null|undefined} options - * @memberof google.protobuf.EnumDescriptorProto - * @instance - */ - EnumDescriptorProto.prototype.options = null; - - /** - * EnumDescriptorProto reservedRange. - * @member {Array.} reservedRange - * @memberof google.protobuf.EnumDescriptorProto - * @instance - */ - EnumDescriptorProto.prototype.reservedRange = $util.emptyArray; - - /** - * EnumDescriptorProto reservedName. - * @member {Array.} reservedName - * @memberof google.protobuf.EnumDescriptorProto - * @instance - */ - EnumDescriptorProto.prototype.reservedName = $util.emptyArray; - - /** - * EnumDescriptorProto visibility. - * @member {google.protobuf.SymbolVisibility} visibility - * @memberof google.protobuf.EnumDescriptorProto - * @instance - */ - EnumDescriptorProto.prototype.visibility = 0; - - /** - * Creates a new EnumDescriptorProto instance using the specified properties. - * @function create - * @memberof google.protobuf.EnumDescriptorProto - * @static - * @param {google.protobuf.IEnumDescriptorProto=} [properties] Properties to set - * @returns {google.protobuf.EnumDescriptorProto} EnumDescriptorProto instance - */ - EnumDescriptorProto.create = function create(properties) { - return new EnumDescriptorProto(properties); - }; - - /** - * Encodes the specified EnumDescriptorProto message. Does not implicitly {@link google.protobuf.EnumDescriptorProto.verify|verify} messages. - * @function encode - * @memberof google.protobuf.EnumDescriptorProto - * @static - * @param {google.protobuf.IEnumDescriptorProto} message EnumDescriptorProto message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EnumDescriptorProto.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.value != null && message.value.length) - for (var i = 0; i < message.value.length; ++i) - $root.google.protobuf.EnumValueDescriptorProto.encode( - message.value[i], - writer.uint32(/* id 2, wireType 2 =*/ 18).fork() - ).ldelim(); - if ( - message.options != null && - Object.hasOwnProperty.call(message, "options") - ) - $root.google.protobuf.EnumOptions.encode( - message.options, - writer.uint32(/* id 3, wireType 2 =*/ 26).fork() - ).ldelim(); - if (message.reservedRange != null && message.reservedRange.length) - for (var i = 0; i < message.reservedRange.length; ++i) - $root.google.protobuf.EnumDescriptorProto.EnumReservedRange.encode( - message.reservedRange[i], - writer.uint32(/* id 4, wireType 2 =*/ 34).fork() - ).ldelim(); - if (message.reservedName != null && message.reservedName.length) - for (var i = 0; i < message.reservedName.length; ++i) - writer - .uint32(/* id 5, wireType 2 =*/ 42) - .string(message.reservedName[i]); - if ( - message.visibility != null && - Object.hasOwnProperty.call(message, "visibility") - ) - writer.uint32(/* id 6, wireType 0 =*/ 48).int32(message.visibility); - return writer; - }; - - /** - * Encodes the specified EnumDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.EnumDescriptorProto.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.EnumDescriptorProto - * @static - * @param {google.protobuf.IEnumDescriptorProto} message EnumDescriptorProto message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EnumDescriptorProto.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes an EnumDescriptorProto message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.EnumDescriptorProto - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.EnumDescriptorProto} EnumDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - EnumDescriptorProto.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.google.protobuf.EnumDescriptorProto(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - message.name = reader.string(); - break; - } - case 2: { - if (!(message.value && message.value.length)) message.value = []; - message.value.push( - $root.google.protobuf.EnumValueDescriptorProto.decode( - reader, - reader.uint32() - ) - ); - break; - } - case 3: { - message.options = $root.google.protobuf.EnumOptions.decode( - reader, - reader.uint32() - ); - break; - } - case 4: { - if (!(message.reservedRange && message.reservedRange.length)) - message.reservedRange = []; - message.reservedRange.push( - $root.google.protobuf.EnumDescriptorProto.EnumReservedRange.decode( - reader, - reader.uint32() - ) - ); - break; - } - case 5: { - if (!(message.reservedName && message.reservedName.length)) - message.reservedName = []; - message.reservedName.push(reader.string()); - break; - } - case 6: { - message.visibility = reader.int32(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes an EnumDescriptorProto message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.EnumDescriptorProto - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.EnumDescriptorProto} EnumDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - EnumDescriptorProto.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies an EnumDescriptorProto message. - * @function verify - * @memberof google.protobuf.EnumDescriptorProto - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - EnumDescriptorProto.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.value != null && message.hasOwnProperty("value")) { - if (!Array.isArray(message.value)) return "value: array expected"; - for (var i = 0; i < message.value.length; ++i) { - var error = $root.google.protobuf.EnumValueDescriptorProto.verify( - message.value[i] - ); - if (error) return "value." + error; - } - } - if (message.options != null && message.hasOwnProperty("options")) { - var error = $root.google.protobuf.EnumOptions.verify(message.options); - if (error) return "options." + error; - } - if ( - message.reservedRange != null && - message.hasOwnProperty("reservedRange") - ) { - if (!Array.isArray(message.reservedRange)) - return "reservedRange: array expected"; - for (var i = 0; i < message.reservedRange.length; ++i) { - var error = - $root.google.protobuf.EnumDescriptorProto.EnumReservedRange.verify( - message.reservedRange[i] - ); - if (error) return "reservedRange." + error; - } - } - if ( - message.reservedName != null && - message.hasOwnProperty("reservedName") - ) { - if (!Array.isArray(message.reservedName)) - return "reservedName: array expected"; - for (var i = 0; i < message.reservedName.length; ++i) - if (!$util.isString(message.reservedName[i])) - return "reservedName: string[] expected"; - } - if (message.visibility != null && message.hasOwnProperty("visibility")) - switch (message.visibility) { - default: - return "visibility: enum value expected"; - case 0: - case 1: - case 2: - break; - } - return null; - }; - - /** - * Creates an EnumDescriptorProto message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.EnumDescriptorProto - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.EnumDescriptorProto} EnumDescriptorProto - */ - EnumDescriptorProto.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.EnumDescriptorProto) - return object; - var message = new $root.google.protobuf.EnumDescriptorProto(); - if (object.name != null) message.name = String(object.name); - if (object.value) { - if (!Array.isArray(object.value)) - throw TypeError( - ".google.protobuf.EnumDescriptorProto.value: array expected" - ); - message.value = []; - for (var i = 0; i < object.value.length; ++i) { - if (typeof object.value[i] !== "object") - throw TypeError( - ".google.protobuf.EnumDescriptorProto.value: object expected" - ); - message.value[i] = - $root.google.protobuf.EnumValueDescriptorProto.fromObject( - object.value[i] - ); - } - } - if (object.options != null) { - if (typeof object.options !== "object") - throw TypeError( - ".google.protobuf.EnumDescriptorProto.options: object expected" - ); - message.options = $root.google.protobuf.EnumOptions.fromObject( - object.options - ); - } - if (object.reservedRange) { - if (!Array.isArray(object.reservedRange)) - throw TypeError( - ".google.protobuf.EnumDescriptorProto.reservedRange: array expected" - ); - message.reservedRange = []; - for (var i = 0; i < object.reservedRange.length; ++i) { - if (typeof object.reservedRange[i] !== "object") - throw TypeError( - ".google.protobuf.EnumDescriptorProto.reservedRange: object expected" - ); - message.reservedRange[i] = - $root.google.protobuf.EnumDescriptorProto.EnumReservedRange.fromObject( - object.reservedRange[i] - ); - } - } - if (object.reservedName) { - if (!Array.isArray(object.reservedName)) - throw TypeError( - ".google.protobuf.EnumDescriptorProto.reservedName: array expected" - ); - message.reservedName = []; - for (var i = 0; i < object.reservedName.length; ++i) - message.reservedName[i] = String(object.reservedName[i]); - } - switch (object.visibility) { - default: - if (typeof object.visibility === "number") { - message.visibility = object.visibility; - break; - } - break; - case "VISIBILITY_UNSET": - case 0: - message.visibility = 0; - break; - case "VISIBILITY_LOCAL": - case 1: - message.visibility = 1; - break; - case "VISIBILITY_EXPORT": - case 2: - message.visibility = 2; - break; - } - return message; - }; - - /** - * Creates a plain object from an EnumDescriptorProto message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.EnumDescriptorProto - * @static - * @param {google.protobuf.EnumDescriptorProto} message EnumDescriptorProto - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - EnumDescriptorProto.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.arrays || options.defaults) { - object.value = []; - object.reservedRange = []; - object.reservedName = []; - } - if (options.defaults) { - object.name = ""; - object.options = null; - object.visibility = options.enums === String ? "VISIBILITY_UNSET" : 0; - } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message.value && message.value.length) { - object.value = []; - for (var j = 0; j < message.value.length; ++j) - object.value[j] = - $root.google.protobuf.EnumValueDescriptorProto.toObject( - message.value[j], - options - ); - } - if (message.options != null && message.hasOwnProperty("options")) - object.options = $root.google.protobuf.EnumOptions.toObject( - message.options, - options - ); - if (message.reservedRange && message.reservedRange.length) { - object.reservedRange = []; - for (var j = 0; j < message.reservedRange.length; ++j) - object.reservedRange[j] = - $root.google.protobuf.EnumDescriptorProto.EnumReservedRange.toObject( - message.reservedRange[j], - options - ); - } - if (message.reservedName && message.reservedName.length) { - object.reservedName = []; - for (var j = 0; j < message.reservedName.length; ++j) - object.reservedName[j] = message.reservedName[j]; - } - if (message.visibility != null && message.hasOwnProperty("visibility")) - object.visibility = - options.enums === String - ? $root.google.protobuf.SymbolVisibility[message.visibility] === - undefined - ? message.visibility - : $root.google.protobuf.SymbolVisibility[message.visibility] - : message.visibility; - return object; - }; - - /** - * Converts this EnumDescriptorProto to JSON. - * @function toJSON - * @memberof google.protobuf.EnumDescriptorProto - * @instance - * @returns {Object.} JSON object - */ - EnumDescriptorProto.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for EnumDescriptorProto - * @function getTypeUrl - * @memberof google.protobuf.EnumDescriptorProto - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - EnumDescriptorProto.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.EnumDescriptorProto"; - }; - - EnumDescriptorProto.EnumReservedRange = (function () { - /** - * Properties of an EnumReservedRange. - * @memberof google.protobuf.EnumDescriptorProto - * @interface IEnumReservedRange - * @property {number|null} [start] EnumReservedRange start - * @property {number|null} [end] EnumReservedRange end - */ - - /** - * Constructs a new EnumReservedRange. - * @memberof google.protobuf.EnumDescriptorProto - * @classdesc Represents an EnumReservedRange. - * @implements IEnumReservedRange - * @constructor - * @param {google.protobuf.EnumDescriptorProto.IEnumReservedRange=} [properties] Properties to set - */ - function EnumReservedRange(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]]; - } - - /** - * EnumReservedRange start. - * @member {number} start - * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange - * @instance - */ - EnumReservedRange.prototype.start = 0; - - /** - * EnumReservedRange end. - * @member {number} end - * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange - * @instance - */ - EnumReservedRange.prototype.end = 0; - - /** - * Creates a new EnumReservedRange instance using the specified properties. - * @function create - * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange - * @static - * @param {google.protobuf.EnumDescriptorProto.IEnumReservedRange=} [properties] Properties to set - * @returns {google.protobuf.EnumDescriptorProto.EnumReservedRange} EnumReservedRange instance - */ - EnumReservedRange.create = function create(properties) { - return new EnumReservedRange(properties); - }; - - /** - * Encodes the specified EnumReservedRange message. Does not implicitly {@link google.protobuf.EnumDescriptorProto.EnumReservedRange.verify|verify} messages. - * @function encode - * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange - * @static - * @param {google.protobuf.EnumDescriptorProto.IEnumReservedRange} message EnumReservedRange message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EnumReservedRange.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if ( - message.start != null && - Object.hasOwnProperty.call(message, "start") - ) - writer.uint32(/* id 1, wireType 0 =*/ 8).int32(message.start); - if (message.end != null && Object.hasOwnProperty.call(message, "end")) - writer.uint32(/* id 2, wireType 0 =*/ 16).int32(message.end); - return writer; - }; - - /** - * Encodes the specified EnumReservedRange message, length delimited. Does not implicitly {@link google.protobuf.EnumDescriptorProto.EnumReservedRange.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange - * @static - * @param {google.protobuf.EnumDescriptorProto.IEnumReservedRange} message EnumReservedRange message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EnumReservedRange.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes an EnumReservedRange message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.EnumDescriptorProto.EnumReservedRange} EnumReservedRange - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - EnumReservedRange.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.google.protobuf.EnumDescriptorProto.EnumReservedRange(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - message.start = reader.int32(); - break; - } - case 2: { - message.end = reader.int32(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes an EnumReservedRange message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.EnumDescriptorProto.EnumReservedRange} EnumReservedRange - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - EnumReservedRange.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies an EnumReservedRange message. - * @function verify - * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - EnumReservedRange.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.start != null && message.hasOwnProperty("start")) - if (!$util.isInteger(message.start)) - return "start: integer expected"; - if (message.end != null && message.hasOwnProperty("end")) - if (!$util.isInteger(message.end)) return "end: integer expected"; - return null; - }; - - /** - * Creates an EnumReservedRange message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.EnumDescriptorProto.EnumReservedRange} EnumReservedRange - */ - EnumReservedRange.fromObject = function fromObject(object) { - if ( - object instanceof - $root.google.protobuf.EnumDescriptorProto.EnumReservedRange - ) - return object; - var message = - new $root.google.protobuf.EnumDescriptorProto.EnumReservedRange(); - if (object.start != null) message.start = object.start | 0; - if (object.end != null) message.end = object.end | 0; - return message; - }; - - /** - * Creates a plain object from an EnumReservedRange message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange - * @static - * @param {google.protobuf.EnumDescriptorProto.EnumReservedRange} message EnumReservedRange - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - EnumReservedRange.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.defaults) { - object.start = 0; - object.end = 0; - } - if (message.start != null && message.hasOwnProperty("start")) - object.start = message.start; - if (message.end != null && message.hasOwnProperty("end")) - object.end = message.end; - return object; - }; - - /** - * Converts this EnumReservedRange to JSON. - * @function toJSON - * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange - * @instance - * @returns {Object.} JSON object - */ - EnumReservedRange.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for EnumReservedRange - * @function getTypeUrl - * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - EnumReservedRange.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return ( - typeUrlPrefix + - "/google.protobuf.EnumDescriptorProto.EnumReservedRange" - ); - }; - - return EnumReservedRange; - })(); - - return EnumDescriptorProto; - })(); - - protobuf.EnumValueDescriptorProto = (function () { - /** - * Properties of an EnumValueDescriptorProto. - * @memberof google.protobuf - * @interface IEnumValueDescriptorProto - * @property {string|null} [name] EnumValueDescriptorProto name - * @property {number|null} [number] EnumValueDescriptorProto number - * @property {google.protobuf.IEnumValueOptions|null} [options] EnumValueDescriptorProto options - */ - - /** - * Constructs a new EnumValueDescriptorProto. - * @memberof google.protobuf - * @classdesc Represents an EnumValueDescriptorProto. - * @implements IEnumValueDescriptorProto - * @constructor - * @param {google.protobuf.IEnumValueDescriptorProto=} [properties] Properties to set - */ - function EnumValueDescriptorProto(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]]; - } - - /** - * EnumValueDescriptorProto name. - * @member {string} name - * @memberof google.protobuf.EnumValueDescriptorProto - * @instance - */ - EnumValueDescriptorProto.prototype.name = ""; - - /** - * EnumValueDescriptorProto number. - * @member {number} number - * @memberof google.protobuf.EnumValueDescriptorProto - * @instance - */ - EnumValueDescriptorProto.prototype.number = 0; - - /** - * EnumValueDescriptorProto options. - * @member {google.protobuf.IEnumValueOptions|null|undefined} options - * @memberof google.protobuf.EnumValueDescriptorProto - * @instance - */ - EnumValueDescriptorProto.prototype.options = null; - - /** - * Creates a new EnumValueDescriptorProto instance using the specified properties. - * @function create - * @memberof google.protobuf.EnumValueDescriptorProto - * @static - * @param {google.protobuf.IEnumValueDescriptorProto=} [properties] Properties to set - * @returns {google.protobuf.EnumValueDescriptorProto} EnumValueDescriptorProto instance - */ - EnumValueDescriptorProto.create = function create(properties) { - return new EnumValueDescriptorProto(properties); - }; - - /** - * Encodes the specified EnumValueDescriptorProto message. Does not implicitly {@link google.protobuf.EnumValueDescriptorProto.verify|verify} messages. - * @function encode - * @memberof google.protobuf.EnumValueDescriptorProto - * @static - * @param {google.protobuf.IEnumValueDescriptorProto} message EnumValueDescriptorProto message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EnumValueDescriptorProto.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.number != null && - Object.hasOwnProperty.call(message, "number") - ) - writer.uint32(/* id 2, wireType 0 =*/ 16).int32(message.number); - if ( - message.options != null && - Object.hasOwnProperty.call(message, "options") - ) - $root.google.protobuf.EnumValueOptions.encode( - message.options, - writer.uint32(/* id 3, wireType 2 =*/ 26).fork() - ).ldelim(); - return writer; - }; - - /** - * Encodes the specified EnumValueDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.EnumValueDescriptorProto.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.EnumValueDescriptorProto - * @static - * @param {google.protobuf.IEnumValueDescriptorProto} message EnumValueDescriptorProto message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EnumValueDescriptorProto.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes an EnumValueDescriptorProto message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.EnumValueDescriptorProto - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.EnumValueDescriptorProto} EnumValueDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - EnumValueDescriptorProto.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.google.protobuf.EnumValueDescriptorProto(); - 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.number = reader.int32(); - break; - } - case 3: { - message.options = $root.google.protobuf.EnumValueOptions.decode( - reader, - reader.uint32() - ); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes an EnumValueDescriptorProto message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.EnumValueDescriptorProto - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.EnumValueDescriptorProto} EnumValueDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - EnumValueDescriptorProto.decodeDelimited = function decodeDelimited( - reader - ) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies an EnumValueDescriptorProto message. - * @function verify - * @memberof google.protobuf.EnumValueDescriptorProto - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - EnumValueDescriptorProto.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.number != null && message.hasOwnProperty("number")) - if (!$util.isInteger(message.number)) - return "number: integer expected"; - if (message.options != null && message.hasOwnProperty("options")) { - var error = $root.google.protobuf.EnumValueOptions.verify( - message.options - ); - if (error) return "options." + error; - } - return null; - }; - - /** - * Creates an EnumValueDescriptorProto message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.EnumValueDescriptorProto - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.EnumValueDescriptorProto} EnumValueDescriptorProto - */ - EnumValueDescriptorProto.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.EnumValueDescriptorProto) - return object; - var message = new $root.google.protobuf.EnumValueDescriptorProto(); - if (object.name != null) message.name = String(object.name); - if (object.number != null) message.number = object.number | 0; - if (object.options != null) { - if (typeof object.options !== "object") - throw TypeError( - ".google.protobuf.EnumValueDescriptorProto.options: object expected" - ); - message.options = $root.google.protobuf.EnumValueOptions.fromObject( - object.options - ); - } - return message; - }; - - /** - * Creates a plain object from an EnumValueDescriptorProto message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.EnumValueDescriptorProto - * @static - * @param {google.protobuf.EnumValueDescriptorProto} message EnumValueDescriptorProto - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - EnumValueDescriptorProto.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.defaults) { - object.name = ""; - object.number = 0; - object.options = null; - } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message.number != null && message.hasOwnProperty("number")) - object.number = message.number; - if (message.options != null && message.hasOwnProperty("options")) - object.options = $root.google.protobuf.EnumValueOptions.toObject( - message.options, - options - ); - return object; - }; - - /** - * Converts this EnumValueDescriptorProto to JSON. - * @function toJSON - * @memberof google.protobuf.EnumValueDescriptorProto - * @instance - * @returns {Object.} JSON object - */ - EnumValueDescriptorProto.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for EnumValueDescriptorProto - * @function getTypeUrl - * @memberof google.protobuf.EnumValueDescriptorProto - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - EnumValueDescriptorProto.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.EnumValueDescriptorProto"; - }; - - return EnumValueDescriptorProto; - })(); - - protobuf.ServiceDescriptorProto = (function () { - /** - * Properties of a ServiceDescriptorProto. - * @memberof google.protobuf - * @interface IServiceDescriptorProto - * @property {string|null} [name] ServiceDescriptorProto name - * @property {Array.|null} [method] ServiceDescriptorProto method - * @property {google.protobuf.IServiceOptions|null} [options] ServiceDescriptorProto options - */ - - /** - * Constructs a new ServiceDescriptorProto. - * @memberof google.protobuf - * @classdesc Represents a ServiceDescriptorProto. - * @implements IServiceDescriptorProto - * @constructor - * @param {google.protobuf.IServiceDescriptorProto=} [properties] Properties to set - */ - function ServiceDescriptorProto(properties) { - this.method = []; - 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]]; - } - - /** - * ServiceDescriptorProto name. - * @member {string} name - * @memberof google.protobuf.ServiceDescriptorProto - * @instance - */ - ServiceDescriptorProto.prototype.name = ""; - - /** - * ServiceDescriptorProto method. - * @member {Array.} method - * @memberof google.protobuf.ServiceDescriptorProto - * @instance - */ - ServiceDescriptorProto.prototype.method = $util.emptyArray; - - /** - * ServiceDescriptorProto options. - * @member {google.protobuf.IServiceOptions|null|undefined} options - * @memberof google.protobuf.ServiceDescriptorProto - * @instance - */ - ServiceDescriptorProto.prototype.options = null; - - /** - * Creates a new ServiceDescriptorProto instance using the specified properties. - * @function create - * @memberof google.protobuf.ServiceDescriptorProto - * @static - * @param {google.protobuf.IServiceDescriptorProto=} [properties] Properties to set - * @returns {google.protobuf.ServiceDescriptorProto} ServiceDescriptorProto instance - */ - ServiceDescriptorProto.create = function create(properties) { - return new ServiceDescriptorProto(properties); - }; - - /** - * Encodes the specified ServiceDescriptorProto message. Does not implicitly {@link google.protobuf.ServiceDescriptorProto.verify|verify} messages. - * @function encode - * @memberof google.protobuf.ServiceDescriptorProto - * @static - * @param {google.protobuf.IServiceDescriptorProto} message ServiceDescriptorProto message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - ServiceDescriptorProto.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.method != null && message.method.length) - for (var i = 0; i < message.method.length; ++i) - $root.google.protobuf.MethodDescriptorProto.encode( - message.method[i], - writer.uint32(/* id 2, wireType 2 =*/ 18).fork() - ).ldelim(); - if ( - message.options != null && - Object.hasOwnProperty.call(message, "options") - ) - $root.google.protobuf.ServiceOptions.encode( - message.options, - writer.uint32(/* id 3, wireType 2 =*/ 26).fork() - ).ldelim(); - return writer; - }; - - /** - * Encodes the specified ServiceDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.ServiceDescriptorProto.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.ServiceDescriptorProto - * @static - * @param {google.protobuf.IServiceDescriptorProto} message ServiceDescriptorProto message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - ServiceDescriptorProto.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a ServiceDescriptorProto message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.ServiceDescriptorProto - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.ServiceDescriptorProto} ServiceDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - ServiceDescriptorProto.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.google.protobuf.ServiceDescriptorProto(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - message.name = reader.string(); - break; - } - case 2: { - if (!(message.method && message.method.length)) - message.method = []; - message.method.push( - $root.google.protobuf.MethodDescriptorProto.decode( - reader, - reader.uint32() - ) - ); - break; - } - case 3: { - message.options = $root.google.protobuf.ServiceOptions.decode( - reader, - reader.uint32() - ); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a ServiceDescriptorProto message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.ServiceDescriptorProto - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.ServiceDescriptorProto} ServiceDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - ServiceDescriptorProto.decodeDelimited = function decodeDelimited( - reader - ) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a ServiceDescriptorProto message. - * @function verify - * @memberof google.protobuf.ServiceDescriptorProto - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - ServiceDescriptorProto.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.method != null && message.hasOwnProperty("method")) { - if (!Array.isArray(message.method)) return "method: array expected"; - for (var i = 0; i < message.method.length; ++i) { - var error = $root.google.protobuf.MethodDescriptorProto.verify( - message.method[i] - ); - if (error) return "method." + error; - } - } - if (message.options != null && message.hasOwnProperty("options")) { - var error = $root.google.protobuf.ServiceOptions.verify( - message.options - ); - if (error) return "options." + error; - } - return null; - }; - - /** - * Creates a ServiceDescriptorProto message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.ServiceDescriptorProto - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.ServiceDescriptorProto} ServiceDescriptorProto - */ - ServiceDescriptorProto.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.ServiceDescriptorProto) - return object; - var message = new $root.google.protobuf.ServiceDescriptorProto(); - if (object.name != null) message.name = String(object.name); - if (object.method) { - if (!Array.isArray(object.method)) - throw TypeError( - ".google.protobuf.ServiceDescriptorProto.method: array expected" - ); - message.method = []; - for (var i = 0; i < object.method.length; ++i) { - if (typeof object.method[i] !== "object") - throw TypeError( - ".google.protobuf.ServiceDescriptorProto.method: object expected" - ); - message.method[i] = - $root.google.protobuf.MethodDescriptorProto.fromObject( - object.method[i] - ); - } - } - if (object.options != null) { - if (typeof object.options !== "object") - throw TypeError( - ".google.protobuf.ServiceDescriptorProto.options: object expected" - ); - message.options = $root.google.protobuf.ServiceOptions.fromObject( - object.options - ); - } - return message; - }; - - /** - * Creates a plain object from a ServiceDescriptorProto message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.ServiceDescriptorProto - * @static - * @param {google.protobuf.ServiceDescriptorProto} message ServiceDescriptorProto - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - ServiceDescriptorProto.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.arrays || options.defaults) object.method = []; - if (options.defaults) { - object.name = ""; - object.options = null; - } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message.method && message.method.length) { - object.method = []; - for (var j = 0; j < message.method.length; ++j) - object.method[j] = - $root.google.protobuf.MethodDescriptorProto.toObject( - message.method[j], - options - ); - } - if (message.options != null && message.hasOwnProperty("options")) - object.options = $root.google.protobuf.ServiceOptions.toObject( - message.options, - options - ); - return object; - }; - - /** - * Converts this ServiceDescriptorProto to JSON. - * @function toJSON - * @memberof google.protobuf.ServiceDescriptorProto - * @instance - * @returns {Object.} JSON object - */ - ServiceDescriptorProto.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for ServiceDescriptorProto - * @function getTypeUrl - * @memberof google.protobuf.ServiceDescriptorProto - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - ServiceDescriptorProto.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.ServiceDescriptorProto"; - }; - - return ServiceDescriptorProto; - })(); - - protobuf.MethodDescriptorProto = (function () { - /** - * Properties of a MethodDescriptorProto. - * @memberof google.protobuf - * @interface IMethodDescriptorProto - * @property {string|null} [name] MethodDescriptorProto name - * @property {string|null} [inputType] MethodDescriptorProto inputType - * @property {string|null} [outputType] MethodDescriptorProto outputType - * @property {google.protobuf.IMethodOptions|null} [options] MethodDescriptorProto options - * @property {boolean|null} [clientStreaming] MethodDescriptorProto clientStreaming - * @property {boolean|null} [serverStreaming] MethodDescriptorProto serverStreaming - */ - - /** - * Constructs a new MethodDescriptorProto. - * @memberof google.protobuf - * @classdesc Represents a MethodDescriptorProto. - * @implements IMethodDescriptorProto - * @constructor - * @param {google.protobuf.IMethodDescriptorProto=} [properties] Properties to set - */ - function MethodDescriptorProto(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]]; - } - - /** - * MethodDescriptorProto name. - * @member {string} name - * @memberof google.protobuf.MethodDescriptorProto - * @instance - */ - MethodDescriptorProto.prototype.name = ""; - - /** - * MethodDescriptorProto inputType. - * @member {string} inputType - * @memberof google.protobuf.MethodDescriptorProto - * @instance - */ - MethodDescriptorProto.prototype.inputType = ""; - - /** - * MethodDescriptorProto outputType. - * @member {string} outputType - * @memberof google.protobuf.MethodDescriptorProto - * @instance - */ - MethodDescriptorProto.prototype.outputType = ""; - - /** - * MethodDescriptorProto options. - * @member {google.protobuf.IMethodOptions|null|undefined} options - * @memberof google.protobuf.MethodDescriptorProto - * @instance - */ - MethodDescriptorProto.prototype.options = null; - - /** - * MethodDescriptorProto clientStreaming. - * @member {boolean} clientStreaming - * @memberof google.protobuf.MethodDescriptorProto - * @instance - */ - MethodDescriptorProto.prototype.clientStreaming = false; - - /** - * MethodDescriptorProto serverStreaming. - * @member {boolean} serverStreaming - * @memberof google.protobuf.MethodDescriptorProto - * @instance - */ - MethodDescriptorProto.prototype.serverStreaming = false; - - /** - * Creates a new MethodDescriptorProto instance using the specified properties. - * @function create - * @memberof google.protobuf.MethodDescriptorProto - * @static - * @param {google.protobuf.IMethodDescriptorProto=} [properties] Properties to set - * @returns {google.protobuf.MethodDescriptorProto} MethodDescriptorProto instance - */ - MethodDescriptorProto.create = function create(properties) { - return new MethodDescriptorProto(properties); - }; - - /** - * Encodes the specified MethodDescriptorProto message. Does not implicitly {@link google.protobuf.MethodDescriptorProto.verify|verify} messages. - * @function encode - * @memberof google.protobuf.MethodDescriptorProto - * @static - * @param {google.protobuf.IMethodDescriptorProto} message MethodDescriptorProto message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - MethodDescriptorProto.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.inputType != null && - Object.hasOwnProperty.call(message, "inputType") - ) - writer.uint32(/* id 2, wireType 2 =*/ 18).string(message.inputType); - if ( - message.outputType != null && - Object.hasOwnProperty.call(message, "outputType") - ) - writer.uint32(/* id 3, wireType 2 =*/ 26).string(message.outputType); - if ( - message.options != null && - Object.hasOwnProperty.call(message, "options") - ) - $root.google.protobuf.MethodOptions.encode( - message.options, - writer.uint32(/* id 4, wireType 2 =*/ 34).fork() - ).ldelim(); - if ( - message.clientStreaming != null && - Object.hasOwnProperty.call(message, "clientStreaming") - ) - writer - .uint32(/* id 5, wireType 0 =*/ 40) - .bool(message.clientStreaming); - if ( - message.serverStreaming != null && - Object.hasOwnProperty.call(message, "serverStreaming") - ) - writer - .uint32(/* id 6, wireType 0 =*/ 48) - .bool(message.serverStreaming); - return writer; - }; - - /** - * Encodes the specified MethodDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.MethodDescriptorProto.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.MethodDescriptorProto - * @static - * @param {google.protobuf.IMethodDescriptorProto} message MethodDescriptorProto message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - MethodDescriptorProto.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a MethodDescriptorProto message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.MethodDescriptorProto - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.MethodDescriptorProto} MethodDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - MethodDescriptorProto.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.google.protobuf.MethodDescriptorProto(); - 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.inputType = reader.string(); - break; - } - case 3: { - message.outputType = reader.string(); - break; - } - case 4: { - message.options = $root.google.protobuf.MethodOptions.decode( - reader, - reader.uint32() - ); - break; - } - case 5: { - message.clientStreaming = reader.bool(); - break; - } - case 6: { - message.serverStreaming = reader.bool(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a MethodDescriptorProto message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.MethodDescriptorProto - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.MethodDescriptorProto} MethodDescriptorProto - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - MethodDescriptorProto.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a MethodDescriptorProto message. - * @function verify - * @memberof google.protobuf.MethodDescriptorProto - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - MethodDescriptorProto.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.inputType != null && message.hasOwnProperty("inputType")) - if (!$util.isString(message.inputType)) - return "inputType: string expected"; - if (message.outputType != null && message.hasOwnProperty("outputType")) - if (!$util.isString(message.outputType)) - return "outputType: string expected"; - if (message.options != null && message.hasOwnProperty("options")) { - var error = $root.google.protobuf.MethodOptions.verify( - message.options - ); - if (error) return "options." + error; - } - if ( - message.clientStreaming != null && - message.hasOwnProperty("clientStreaming") - ) - if (typeof message.clientStreaming !== "boolean") - return "clientStreaming: boolean expected"; - if ( - message.serverStreaming != null && - message.hasOwnProperty("serverStreaming") - ) - if (typeof message.serverStreaming !== "boolean") - return "serverStreaming: boolean expected"; - return null; - }; - - /** - * Creates a MethodDescriptorProto message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.MethodDescriptorProto - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.MethodDescriptorProto} MethodDescriptorProto - */ - MethodDescriptorProto.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.MethodDescriptorProto) - return object; - var message = new $root.google.protobuf.MethodDescriptorProto(); - if (object.name != null) message.name = String(object.name); - if (object.inputType != null) - message.inputType = String(object.inputType); - if (object.outputType != null) - message.outputType = String(object.outputType); - if (object.options != null) { - if (typeof object.options !== "object") - throw TypeError( - ".google.protobuf.MethodDescriptorProto.options: object expected" - ); - message.options = $root.google.protobuf.MethodOptions.fromObject( - object.options - ); - } - if (object.clientStreaming != null) - message.clientStreaming = Boolean(object.clientStreaming); - if (object.serverStreaming != null) - message.serverStreaming = Boolean(object.serverStreaming); - return message; - }; - - /** - * Creates a plain object from a MethodDescriptorProto message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.MethodDescriptorProto - * @static - * @param {google.protobuf.MethodDescriptorProto} message MethodDescriptorProto - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - MethodDescriptorProto.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.defaults) { - object.name = ""; - object.inputType = ""; - object.outputType = ""; - object.options = null; - object.clientStreaming = false; - object.serverStreaming = false; - } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message.inputType != null && message.hasOwnProperty("inputType")) - object.inputType = message.inputType; - if (message.outputType != null && message.hasOwnProperty("outputType")) - object.outputType = message.outputType; - if (message.options != null && message.hasOwnProperty("options")) - object.options = $root.google.protobuf.MethodOptions.toObject( - message.options, - options - ); - if ( - message.clientStreaming != null && - message.hasOwnProperty("clientStreaming") - ) - object.clientStreaming = message.clientStreaming; - if ( - message.serverStreaming != null && - message.hasOwnProperty("serverStreaming") - ) - object.serverStreaming = message.serverStreaming; - return object; - }; - - /** - * Converts this MethodDescriptorProto to JSON. - * @function toJSON - * @memberof google.protobuf.MethodDescriptorProto - * @instance - * @returns {Object.} JSON object - */ - MethodDescriptorProto.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for MethodDescriptorProto - * @function getTypeUrl - * @memberof google.protobuf.MethodDescriptorProto - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - MethodDescriptorProto.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.MethodDescriptorProto"; - }; - - return MethodDescriptorProto; - })(); - - protobuf.FileOptions = (function () { - /** - * Properties of a FileOptions. - * @memberof google.protobuf - * @interface IFileOptions - * @property {string|null} [javaPackage] FileOptions javaPackage - * @property {string|null} [javaOuterClassname] FileOptions javaOuterClassname - * @property {boolean|null} [javaMultipleFiles] FileOptions javaMultipleFiles - * @property {boolean|null} [javaGenerateEqualsAndHash] FileOptions javaGenerateEqualsAndHash - * @property {boolean|null} [javaStringCheckUtf8] FileOptions javaStringCheckUtf8 - * @property {google.protobuf.FileOptions.OptimizeMode|null} [optimizeFor] FileOptions optimizeFor - * @property {string|null} [goPackage] FileOptions goPackage - * @property {boolean|null} [ccGenericServices] FileOptions ccGenericServices - * @property {boolean|null} [javaGenericServices] FileOptions javaGenericServices - * @property {boolean|null} [pyGenericServices] FileOptions pyGenericServices - * @property {boolean|null} [deprecated] FileOptions deprecated - * @property {boolean|null} [ccEnableArenas] FileOptions ccEnableArenas - * @property {string|null} [objcClassPrefix] FileOptions objcClassPrefix - * @property {string|null} [csharpNamespace] FileOptions csharpNamespace - * @property {string|null} [swiftPrefix] FileOptions swiftPrefix - * @property {string|null} [phpClassPrefix] FileOptions phpClassPrefix - * @property {string|null} [phpNamespace] FileOptions phpNamespace - * @property {string|null} [phpMetadataNamespace] FileOptions phpMetadataNamespace - * @property {string|null} [rubyPackage] FileOptions rubyPackage - * @property {google.protobuf.IFeatureSet|null} [features] FileOptions features - * @property {Array.|null} [uninterpretedOption] FileOptions uninterpretedOption - */ - - /** - * Constructs a new FileOptions. - * @memberof google.protobuf - * @classdesc Represents a FileOptions. - * @implements IFileOptions - * @constructor - * @param {google.protobuf.IFileOptions=} [properties] Properties to set - */ - function FileOptions(properties) { - this.uninterpretedOption = []; - 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]]; - } - - /** - * FileOptions javaPackage. - * @member {string} javaPackage - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.javaPackage = ""; - - /** - * FileOptions javaOuterClassname. - * @member {string} javaOuterClassname - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.javaOuterClassname = ""; - - /** - * FileOptions javaMultipleFiles. - * @member {boolean} javaMultipleFiles - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.javaMultipleFiles = false; - - /** - * FileOptions javaGenerateEqualsAndHash. - * @member {boolean} javaGenerateEqualsAndHash - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.javaGenerateEqualsAndHash = false; - - /** - * FileOptions javaStringCheckUtf8. - * @member {boolean} javaStringCheckUtf8 - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.javaStringCheckUtf8 = false; - - /** - * FileOptions optimizeFor. - * @member {google.protobuf.FileOptions.OptimizeMode} optimizeFor - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.optimizeFor = 1; - - /** - * FileOptions goPackage. - * @member {string} goPackage - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.goPackage = ""; - - /** - * FileOptions ccGenericServices. - * @member {boolean} ccGenericServices - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.ccGenericServices = false; - - /** - * FileOptions javaGenericServices. - * @member {boolean} javaGenericServices - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.javaGenericServices = false; - - /** - * FileOptions pyGenericServices. - * @member {boolean} pyGenericServices - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.pyGenericServices = false; - - /** - * FileOptions deprecated. - * @member {boolean} deprecated - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.deprecated = false; - - /** - * FileOptions ccEnableArenas. - * @member {boolean} ccEnableArenas - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.ccEnableArenas = true; - - /** - * FileOptions objcClassPrefix. - * @member {string} objcClassPrefix - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.objcClassPrefix = ""; - - /** - * FileOptions csharpNamespace. - * @member {string} csharpNamespace - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.csharpNamespace = ""; - - /** - * FileOptions swiftPrefix. - * @member {string} swiftPrefix - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.swiftPrefix = ""; - - /** - * FileOptions phpClassPrefix. - * @member {string} phpClassPrefix - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.phpClassPrefix = ""; - - /** - * FileOptions phpNamespace. - * @member {string} phpNamespace - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.phpNamespace = ""; - - /** - * FileOptions phpMetadataNamespace. - * @member {string} phpMetadataNamespace - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.phpMetadataNamespace = ""; - - /** - * FileOptions rubyPackage. - * @member {string} rubyPackage - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.rubyPackage = ""; - - /** - * FileOptions features. - * @member {google.protobuf.IFeatureSet|null|undefined} features - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.features = null; - - /** - * FileOptions uninterpretedOption. - * @member {Array.} uninterpretedOption - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.uninterpretedOption = $util.emptyArray; - - /** - * Creates a new FileOptions instance using the specified properties. - * @function create - * @memberof google.protobuf.FileOptions - * @static - * @param {google.protobuf.IFileOptions=} [properties] Properties to set - * @returns {google.protobuf.FileOptions} FileOptions instance - */ - FileOptions.create = function create(properties) { - return new FileOptions(properties); - }; - - /** - * Encodes the specified FileOptions message. Does not implicitly {@link google.protobuf.FileOptions.verify|verify} messages. - * @function encode - * @memberof google.protobuf.FileOptions - * @static - * @param {google.protobuf.IFileOptions} message FileOptions message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - FileOptions.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if ( - message.javaPackage != null && - Object.hasOwnProperty.call(message, "javaPackage") - ) - writer.uint32(/* id 1, wireType 2 =*/ 10).string(message.javaPackage); - if ( - message.javaOuterClassname != null && - Object.hasOwnProperty.call(message, "javaOuterClassname") - ) - writer - .uint32(/* id 8, wireType 2 =*/ 66) - .string(message.javaOuterClassname); - if ( - message.optimizeFor != null && - Object.hasOwnProperty.call(message, "optimizeFor") - ) - writer.uint32(/* id 9, wireType 0 =*/ 72).int32(message.optimizeFor); - if ( - message.javaMultipleFiles != null && - Object.hasOwnProperty.call(message, "javaMultipleFiles") - ) - writer - .uint32(/* id 10, wireType 0 =*/ 80) - .bool(message.javaMultipleFiles); - if ( - message.goPackage != null && - Object.hasOwnProperty.call(message, "goPackage") - ) - writer.uint32(/* id 11, wireType 2 =*/ 90).string(message.goPackage); - if ( - message.ccGenericServices != null && - Object.hasOwnProperty.call(message, "ccGenericServices") - ) - writer - .uint32(/* id 16, wireType 0 =*/ 128) - .bool(message.ccGenericServices); - if ( - message.javaGenericServices != null && - Object.hasOwnProperty.call(message, "javaGenericServices") - ) - writer - .uint32(/* id 17, wireType 0 =*/ 136) - .bool(message.javaGenericServices); - if ( - message.pyGenericServices != null && - Object.hasOwnProperty.call(message, "pyGenericServices") - ) - writer - .uint32(/* id 18, wireType 0 =*/ 144) - .bool(message.pyGenericServices); - if ( - message.javaGenerateEqualsAndHash != null && - Object.hasOwnProperty.call(message, "javaGenerateEqualsAndHash") - ) - writer - .uint32(/* id 20, wireType 0 =*/ 160) - .bool(message.javaGenerateEqualsAndHash); - if ( - message.deprecated != null && - Object.hasOwnProperty.call(message, "deprecated") - ) - writer.uint32(/* id 23, wireType 0 =*/ 184).bool(message.deprecated); - if ( - message.javaStringCheckUtf8 != null && - Object.hasOwnProperty.call(message, "javaStringCheckUtf8") - ) - writer - .uint32(/* id 27, wireType 0 =*/ 216) - .bool(message.javaStringCheckUtf8); - if ( - message.ccEnableArenas != null && - Object.hasOwnProperty.call(message, "ccEnableArenas") - ) - writer - .uint32(/* id 31, wireType 0 =*/ 248) - .bool(message.ccEnableArenas); - if ( - message.objcClassPrefix != null && - Object.hasOwnProperty.call(message, "objcClassPrefix") - ) - writer - .uint32(/* id 36, wireType 2 =*/ 290) - .string(message.objcClassPrefix); - if ( - message.csharpNamespace != null && - Object.hasOwnProperty.call(message, "csharpNamespace") - ) - writer - .uint32(/* id 37, wireType 2 =*/ 298) - .string(message.csharpNamespace); - if ( - message.swiftPrefix != null && - Object.hasOwnProperty.call(message, "swiftPrefix") - ) - writer - .uint32(/* id 39, wireType 2 =*/ 314) - .string(message.swiftPrefix); - if ( - message.phpClassPrefix != null && - Object.hasOwnProperty.call(message, "phpClassPrefix") - ) - writer - .uint32(/* id 40, wireType 2 =*/ 322) - .string(message.phpClassPrefix); - if ( - message.phpNamespace != null && - Object.hasOwnProperty.call(message, "phpNamespace") - ) - writer - .uint32(/* id 41, wireType 2 =*/ 330) - .string(message.phpNamespace); - if ( - message.phpMetadataNamespace != null && - Object.hasOwnProperty.call(message, "phpMetadataNamespace") - ) - writer - .uint32(/* id 44, wireType 2 =*/ 354) - .string(message.phpMetadataNamespace); - if ( - message.rubyPackage != null && - Object.hasOwnProperty.call(message, "rubyPackage") - ) - writer - .uint32(/* id 45, wireType 2 =*/ 362) - .string(message.rubyPackage); - if ( - message.features != null && - Object.hasOwnProperty.call(message, "features") - ) - $root.google.protobuf.FeatureSet.encode( - message.features, - writer.uint32(/* id 50, wireType 2 =*/ 402).fork() - ).ldelim(); - if ( - message.uninterpretedOption != null && - message.uninterpretedOption.length - ) - for (var i = 0; i < message.uninterpretedOption.length; ++i) - $root.google.protobuf.UninterpretedOption.encode( - message.uninterpretedOption[i], - writer.uint32(/* id 999, wireType 2 =*/ 7994).fork() - ).ldelim(); - return writer; - }; - - /** - * Encodes the specified FileOptions message, length delimited. Does not implicitly {@link google.protobuf.FileOptions.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.FileOptions - * @static - * @param {google.protobuf.IFileOptions} message FileOptions message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - FileOptions.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a FileOptions message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.FileOptions - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.FileOptions} FileOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - FileOptions.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.google.protobuf.FileOptions(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - message.javaPackage = reader.string(); - break; - } - case 8: { - message.javaOuterClassname = reader.string(); - break; - } - case 10: { - message.javaMultipleFiles = reader.bool(); - break; - } - case 20: { - message.javaGenerateEqualsAndHash = reader.bool(); - break; - } - case 27: { - message.javaStringCheckUtf8 = reader.bool(); - break; - } - case 9: { - message.optimizeFor = reader.int32(); - break; - } - case 11: { - message.goPackage = reader.string(); - break; - } - case 16: { - message.ccGenericServices = reader.bool(); - break; - } - case 17: { - message.javaGenericServices = reader.bool(); - break; - } - case 18: { - message.pyGenericServices = reader.bool(); - break; - } - case 23: { - message.deprecated = reader.bool(); - break; - } - case 31: { - message.ccEnableArenas = reader.bool(); - break; - } - case 36: { - message.objcClassPrefix = reader.string(); - break; - } - case 37: { - message.csharpNamespace = reader.string(); - break; - } - case 39: { - message.swiftPrefix = reader.string(); - break; - } - case 40: { - message.phpClassPrefix = reader.string(); - break; - } - case 41: { - message.phpNamespace = reader.string(); - break; - } - case 44: { - message.phpMetadataNamespace = reader.string(); - break; - } - case 45: { - message.rubyPackage = reader.string(); - break; - } - case 50: { - message.features = $root.google.protobuf.FeatureSet.decode( - reader, - reader.uint32() - ); - break; - } - case 999: { - if ( - !( - message.uninterpretedOption && - message.uninterpretedOption.length - ) - ) - message.uninterpretedOption = []; - message.uninterpretedOption.push( - $root.google.protobuf.UninterpretedOption.decode( - reader, - reader.uint32() - ) - ); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a FileOptions message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.FileOptions - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.FileOptions} FileOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - FileOptions.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a FileOptions message. - * @function verify - * @memberof google.protobuf.FileOptions - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - FileOptions.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if ( - message.javaPackage != null && - message.hasOwnProperty("javaPackage") - ) - if (!$util.isString(message.javaPackage)) - return "javaPackage: string expected"; - if ( - message.javaOuterClassname != null && - message.hasOwnProperty("javaOuterClassname") - ) - if (!$util.isString(message.javaOuterClassname)) - return "javaOuterClassname: string expected"; - if ( - message.javaMultipleFiles != null && - message.hasOwnProperty("javaMultipleFiles") - ) - if (typeof message.javaMultipleFiles !== "boolean") - return "javaMultipleFiles: boolean expected"; - if ( - message.javaGenerateEqualsAndHash != null && - message.hasOwnProperty("javaGenerateEqualsAndHash") - ) - if (typeof message.javaGenerateEqualsAndHash !== "boolean") - return "javaGenerateEqualsAndHash: boolean expected"; - if ( - message.javaStringCheckUtf8 != null && - message.hasOwnProperty("javaStringCheckUtf8") - ) - if (typeof message.javaStringCheckUtf8 !== "boolean") - return "javaStringCheckUtf8: boolean expected"; - if ( - message.optimizeFor != null && - message.hasOwnProperty("optimizeFor") - ) - switch (message.optimizeFor) { - default: - return "optimizeFor: enum value expected"; - case 1: - case 2: - case 3: - break; - } - if (message.goPackage != null && message.hasOwnProperty("goPackage")) - if (!$util.isString(message.goPackage)) - return "goPackage: string expected"; - if ( - message.ccGenericServices != null && - message.hasOwnProperty("ccGenericServices") - ) - if (typeof message.ccGenericServices !== "boolean") - return "ccGenericServices: boolean expected"; - if ( - message.javaGenericServices != null && - message.hasOwnProperty("javaGenericServices") - ) - if (typeof message.javaGenericServices !== "boolean") - return "javaGenericServices: boolean expected"; - if ( - message.pyGenericServices != null && - message.hasOwnProperty("pyGenericServices") - ) - if (typeof message.pyGenericServices !== "boolean") - return "pyGenericServices: boolean expected"; - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - if (typeof message.deprecated !== "boolean") - return "deprecated: boolean expected"; - if ( - message.ccEnableArenas != null && - message.hasOwnProperty("ccEnableArenas") - ) - if (typeof message.ccEnableArenas !== "boolean") - return "ccEnableArenas: boolean expected"; - if ( - message.objcClassPrefix != null && - message.hasOwnProperty("objcClassPrefix") - ) - if (!$util.isString(message.objcClassPrefix)) - return "objcClassPrefix: string expected"; - if ( - message.csharpNamespace != null && - message.hasOwnProperty("csharpNamespace") - ) - if (!$util.isString(message.csharpNamespace)) - return "csharpNamespace: string expected"; - if ( - message.swiftPrefix != null && - message.hasOwnProperty("swiftPrefix") - ) - if (!$util.isString(message.swiftPrefix)) - return "swiftPrefix: string expected"; - if ( - message.phpClassPrefix != null && - message.hasOwnProperty("phpClassPrefix") - ) - if (!$util.isString(message.phpClassPrefix)) - return "phpClassPrefix: string expected"; - if ( - message.phpNamespace != null && - message.hasOwnProperty("phpNamespace") - ) - if (!$util.isString(message.phpNamespace)) - return "phpNamespace: string expected"; - if ( - message.phpMetadataNamespace != null && - message.hasOwnProperty("phpMetadataNamespace") - ) - if (!$util.isString(message.phpMetadataNamespace)) - return "phpMetadataNamespace: string expected"; - if ( - message.rubyPackage != null && - message.hasOwnProperty("rubyPackage") - ) - if (!$util.isString(message.rubyPackage)) - return "rubyPackage: string expected"; - if (message.features != null && message.hasOwnProperty("features")) { - var error = $root.google.protobuf.FeatureSet.verify(message.features); - if (error) return "features." + error; - } - if ( - message.uninterpretedOption != null && - message.hasOwnProperty("uninterpretedOption") - ) { - if (!Array.isArray(message.uninterpretedOption)) - return "uninterpretedOption: array expected"; - for (var i = 0; i < message.uninterpretedOption.length; ++i) { - var error = $root.google.protobuf.UninterpretedOption.verify( - message.uninterpretedOption[i] - ); - if (error) return "uninterpretedOption." + error; - } - } - return null; - }; - - /** - * Creates a FileOptions message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.FileOptions - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.FileOptions} FileOptions - */ - FileOptions.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.FileOptions) return object; - var message = new $root.google.protobuf.FileOptions(); - if (object.javaPackage != null) - message.javaPackage = String(object.javaPackage); - if (object.javaOuterClassname != null) - message.javaOuterClassname = String(object.javaOuterClassname); - if (object.javaMultipleFiles != null) - message.javaMultipleFiles = Boolean(object.javaMultipleFiles); - if (object.javaGenerateEqualsAndHash != null) - message.javaGenerateEqualsAndHash = Boolean( - object.javaGenerateEqualsAndHash - ); - if (object.javaStringCheckUtf8 != null) - message.javaStringCheckUtf8 = Boolean(object.javaStringCheckUtf8); - switch (object.optimizeFor) { - default: - if (typeof object.optimizeFor === "number") { - message.optimizeFor = object.optimizeFor; - break; - } - break; - case "SPEED": - case 1: - message.optimizeFor = 1; - break; - case "CODE_SIZE": - case 2: - message.optimizeFor = 2; - break; - case "LITE_RUNTIME": - case 3: - message.optimizeFor = 3; - break; - } - if (object.goPackage != null) - message.goPackage = String(object.goPackage); - if (object.ccGenericServices != null) - message.ccGenericServices = Boolean(object.ccGenericServices); - if (object.javaGenericServices != null) - message.javaGenericServices = Boolean(object.javaGenericServices); - if (object.pyGenericServices != null) - message.pyGenericServices = Boolean(object.pyGenericServices); - if (object.deprecated != null) - message.deprecated = Boolean(object.deprecated); - if (object.ccEnableArenas != null) - message.ccEnableArenas = Boolean(object.ccEnableArenas); - if (object.objcClassPrefix != null) - message.objcClassPrefix = String(object.objcClassPrefix); - if (object.csharpNamespace != null) - message.csharpNamespace = String(object.csharpNamespace); - if (object.swiftPrefix != null) - message.swiftPrefix = String(object.swiftPrefix); - if (object.phpClassPrefix != null) - message.phpClassPrefix = String(object.phpClassPrefix); - if (object.phpNamespace != null) - message.phpNamespace = String(object.phpNamespace); - if (object.phpMetadataNamespace != null) - message.phpMetadataNamespace = String(object.phpMetadataNamespace); - if (object.rubyPackage != null) - message.rubyPackage = String(object.rubyPackage); - if (object.features != null) { - if (typeof object.features !== "object") - throw TypeError( - ".google.protobuf.FileOptions.features: object expected" - ); - message.features = $root.google.protobuf.FeatureSet.fromObject( - object.features - ); - } - if (object.uninterpretedOption) { - if (!Array.isArray(object.uninterpretedOption)) - throw TypeError( - ".google.protobuf.FileOptions.uninterpretedOption: array expected" - ); - message.uninterpretedOption = []; - for (var i = 0; i < object.uninterpretedOption.length; ++i) { - if (typeof object.uninterpretedOption[i] !== "object") - throw TypeError( - ".google.protobuf.FileOptions.uninterpretedOption: object expected" - ); - message.uninterpretedOption[i] = - $root.google.protobuf.UninterpretedOption.fromObject( - object.uninterpretedOption[i] - ); - } - } - return message; - }; - - /** - * Creates a plain object from a FileOptions message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.FileOptions - * @static - * @param {google.protobuf.FileOptions} message FileOptions - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - FileOptions.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.arrays || options.defaults) object.uninterpretedOption = []; - if (options.defaults) { - object.javaPackage = ""; - object.javaOuterClassname = ""; - object.optimizeFor = options.enums === String ? "SPEED" : 1; - object.javaMultipleFiles = false; - object.goPackage = ""; - object.ccGenericServices = false; - object.javaGenericServices = false; - object.pyGenericServices = false; - object.javaGenerateEqualsAndHash = false; - object.deprecated = false; - object.javaStringCheckUtf8 = false; - object.ccEnableArenas = true; - object.objcClassPrefix = ""; - object.csharpNamespace = ""; - object.swiftPrefix = ""; - object.phpClassPrefix = ""; - object.phpNamespace = ""; - object.phpMetadataNamespace = ""; - object.rubyPackage = ""; - object.features = null; - } - if ( - message.javaPackage != null && - message.hasOwnProperty("javaPackage") - ) - object.javaPackage = message.javaPackage; - if ( - message.javaOuterClassname != null && - message.hasOwnProperty("javaOuterClassname") - ) - object.javaOuterClassname = message.javaOuterClassname; - if ( - message.optimizeFor != null && - message.hasOwnProperty("optimizeFor") - ) - object.optimizeFor = - options.enums === String - ? $root.google.protobuf.FileOptions.OptimizeMode[ - message.optimizeFor - ] === undefined - ? message.optimizeFor - : $root.google.protobuf.FileOptions.OptimizeMode[ - message.optimizeFor - ] - : message.optimizeFor; - if ( - message.javaMultipleFiles != null && - message.hasOwnProperty("javaMultipleFiles") - ) - object.javaMultipleFiles = message.javaMultipleFiles; - if (message.goPackage != null && message.hasOwnProperty("goPackage")) - object.goPackage = message.goPackage; - if ( - message.ccGenericServices != null && - message.hasOwnProperty("ccGenericServices") - ) - object.ccGenericServices = message.ccGenericServices; - if ( - message.javaGenericServices != null && - message.hasOwnProperty("javaGenericServices") - ) - object.javaGenericServices = message.javaGenericServices; - if ( - message.pyGenericServices != null && - message.hasOwnProperty("pyGenericServices") - ) - object.pyGenericServices = message.pyGenericServices; - if ( - message.javaGenerateEqualsAndHash != null && - message.hasOwnProperty("javaGenerateEqualsAndHash") - ) - object.javaGenerateEqualsAndHash = message.javaGenerateEqualsAndHash; - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - object.deprecated = message.deprecated; - if ( - message.javaStringCheckUtf8 != null && - message.hasOwnProperty("javaStringCheckUtf8") - ) - object.javaStringCheckUtf8 = message.javaStringCheckUtf8; - if ( - message.ccEnableArenas != null && - message.hasOwnProperty("ccEnableArenas") - ) - object.ccEnableArenas = message.ccEnableArenas; - if ( - message.objcClassPrefix != null && - message.hasOwnProperty("objcClassPrefix") - ) - object.objcClassPrefix = message.objcClassPrefix; - if ( - message.csharpNamespace != null && - message.hasOwnProperty("csharpNamespace") - ) - object.csharpNamespace = message.csharpNamespace; - if ( - message.swiftPrefix != null && - message.hasOwnProperty("swiftPrefix") - ) - object.swiftPrefix = message.swiftPrefix; - if ( - message.phpClassPrefix != null && - message.hasOwnProperty("phpClassPrefix") - ) - object.phpClassPrefix = message.phpClassPrefix; - if ( - message.phpNamespace != null && - message.hasOwnProperty("phpNamespace") - ) - object.phpNamespace = message.phpNamespace; - if ( - message.phpMetadataNamespace != null && - message.hasOwnProperty("phpMetadataNamespace") - ) - object.phpMetadataNamespace = message.phpMetadataNamespace; - if ( - message.rubyPackage != null && - message.hasOwnProperty("rubyPackage") - ) - object.rubyPackage = message.rubyPackage; - if (message.features != null && message.hasOwnProperty("features")) - object.features = $root.google.protobuf.FeatureSet.toObject( - message.features, - options - ); - if (message.uninterpretedOption && message.uninterpretedOption.length) { - object.uninterpretedOption = []; - for (var j = 0; j < message.uninterpretedOption.length; ++j) - object.uninterpretedOption[j] = - $root.google.protobuf.UninterpretedOption.toObject( - message.uninterpretedOption[j], - options - ); - } - return object; - }; - - /** - * Converts this FileOptions to JSON. - * @function toJSON - * @memberof google.protobuf.FileOptions - * @instance - * @returns {Object.} JSON object - */ - FileOptions.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for FileOptions - * @function getTypeUrl - * @memberof google.protobuf.FileOptions - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - FileOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.FileOptions"; - }; - - /** - * OptimizeMode enum. - * @name google.protobuf.FileOptions.OptimizeMode - * @enum {number} - * @property {number} SPEED=1 SPEED value - * @property {number} CODE_SIZE=2 CODE_SIZE value - * @property {number} LITE_RUNTIME=3 LITE_RUNTIME value - */ - FileOptions.OptimizeMode = (function () { - var valuesById = {}, - values = Object.create(valuesById); - values[(valuesById[1] = "SPEED")] = 1; - values[(valuesById[2] = "CODE_SIZE")] = 2; - values[(valuesById[3] = "LITE_RUNTIME")] = 3; - return values; - })(); - - return FileOptions; - })(); - - protobuf.MessageOptions = (function () { - /** - * Properties of a MessageOptions. - * @memberof google.protobuf - * @interface IMessageOptions - * @property {boolean|null} [messageSetWireFormat] MessageOptions messageSetWireFormat - * @property {boolean|null} [noStandardDescriptorAccessor] MessageOptions noStandardDescriptorAccessor - * @property {boolean|null} [deprecated] MessageOptions deprecated - * @property {boolean|null} [mapEntry] MessageOptions mapEntry - * @property {boolean|null} [deprecatedLegacyJsonFieldConflicts] MessageOptions deprecatedLegacyJsonFieldConflicts - * @property {google.protobuf.IFeatureSet|null} [features] MessageOptions features - * @property {Array.|null} [uninterpretedOption] MessageOptions uninterpretedOption - */ - - /** - * Constructs a new MessageOptions. - * @memberof google.protobuf - * @classdesc Represents a MessageOptions. - * @implements IMessageOptions - * @constructor - * @param {google.protobuf.IMessageOptions=} [properties] Properties to set - */ - function MessageOptions(properties) { - this.uninterpretedOption = []; - 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]]; - } - - /** - * MessageOptions messageSetWireFormat. - * @member {boolean} messageSetWireFormat - * @memberof google.protobuf.MessageOptions - * @instance - */ - MessageOptions.prototype.messageSetWireFormat = false; - - /** - * MessageOptions noStandardDescriptorAccessor. - * @member {boolean} noStandardDescriptorAccessor - * @memberof google.protobuf.MessageOptions - * @instance - */ - MessageOptions.prototype.noStandardDescriptorAccessor = false; - - /** - * MessageOptions deprecated. - * @member {boolean} deprecated - * @memberof google.protobuf.MessageOptions - * @instance - */ - MessageOptions.prototype.deprecated = false; - - /** - * MessageOptions mapEntry. - * @member {boolean} mapEntry - * @memberof google.protobuf.MessageOptions - * @instance - */ - MessageOptions.prototype.mapEntry = false; - - /** - * MessageOptions deprecatedLegacyJsonFieldConflicts. - * @member {boolean} deprecatedLegacyJsonFieldConflicts - * @memberof google.protobuf.MessageOptions - * @instance - */ - MessageOptions.prototype.deprecatedLegacyJsonFieldConflicts = false; - - /** - * MessageOptions features. - * @member {google.protobuf.IFeatureSet|null|undefined} features - * @memberof google.protobuf.MessageOptions - * @instance - */ - MessageOptions.prototype.features = null; - - /** - * MessageOptions uninterpretedOption. - * @member {Array.} uninterpretedOption - * @memberof google.protobuf.MessageOptions - * @instance - */ - MessageOptions.prototype.uninterpretedOption = $util.emptyArray; - - /** - * Creates a new MessageOptions instance using the specified properties. - * @function create - * @memberof google.protobuf.MessageOptions - * @static - * @param {google.protobuf.IMessageOptions=} [properties] Properties to set - * @returns {google.protobuf.MessageOptions} MessageOptions instance - */ - MessageOptions.create = function create(properties) { - return new MessageOptions(properties); - }; - - /** - * Encodes the specified MessageOptions message. Does not implicitly {@link google.protobuf.MessageOptions.verify|verify} messages. - * @function encode - * @memberof google.protobuf.MessageOptions - * @static - * @param {google.protobuf.IMessageOptions} message MessageOptions message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - MessageOptions.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if ( - message.messageSetWireFormat != null && - Object.hasOwnProperty.call(message, "messageSetWireFormat") - ) - writer - .uint32(/* id 1, wireType 0 =*/ 8) - .bool(message.messageSetWireFormat); - if ( - message.noStandardDescriptorAccessor != null && - Object.hasOwnProperty.call(message, "noStandardDescriptorAccessor") - ) - writer - .uint32(/* id 2, wireType 0 =*/ 16) - .bool(message.noStandardDescriptorAccessor); - if ( - message.deprecated != null && - Object.hasOwnProperty.call(message, "deprecated") - ) - writer.uint32(/* id 3, wireType 0 =*/ 24).bool(message.deprecated); - if ( - message.mapEntry != null && - Object.hasOwnProperty.call(message, "mapEntry") - ) - writer.uint32(/* id 7, wireType 0 =*/ 56).bool(message.mapEntry); - if ( - message.deprecatedLegacyJsonFieldConflicts != null && - Object.hasOwnProperty.call( - message, - "deprecatedLegacyJsonFieldConflicts" - ) - ) - writer - .uint32(/* id 11, wireType 0 =*/ 88) - .bool(message.deprecatedLegacyJsonFieldConflicts); - if ( - message.features != null && - Object.hasOwnProperty.call(message, "features") - ) - $root.google.protobuf.FeatureSet.encode( - message.features, - writer.uint32(/* id 12, wireType 2 =*/ 98).fork() - ).ldelim(); - if ( - message.uninterpretedOption != null && - message.uninterpretedOption.length - ) - for (var i = 0; i < message.uninterpretedOption.length; ++i) - $root.google.protobuf.UninterpretedOption.encode( - message.uninterpretedOption[i], - writer.uint32(/* id 999, wireType 2 =*/ 7994).fork() - ).ldelim(); - return writer; - }; - - /** - * Encodes the specified MessageOptions message, length delimited. Does not implicitly {@link google.protobuf.MessageOptions.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.MessageOptions - * @static - * @param {google.protobuf.IMessageOptions} message MessageOptions message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - MessageOptions.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a MessageOptions message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.MessageOptions - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.MessageOptions} MessageOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - MessageOptions.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.google.protobuf.MessageOptions(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - message.messageSetWireFormat = reader.bool(); - break; - } - case 2: { - message.noStandardDescriptorAccessor = reader.bool(); - break; - } - case 3: { - message.deprecated = reader.bool(); - break; - } - case 7: { - message.mapEntry = reader.bool(); - break; - } - case 11: { - message.deprecatedLegacyJsonFieldConflicts = reader.bool(); - break; - } - case 12: { - message.features = $root.google.protobuf.FeatureSet.decode( - reader, - reader.uint32() - ); - break; - } - case 999: { - if ( - !( - message.uninterpretedOption && - message.uninterpretedOption.length - ) - ) - message.uninterpretedOption = []; - message.uninterpretedOption.push( - $root.google.protobuf.UninterpretedOption.decode( - reader, - reader.uint32() - ) - ); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a MessageOptions message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.MessageOptions - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.MessageOptions} MessageOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - MessageOptions.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a MessageOptions message. - * @function verify - * @memberof google.protobuf.MessageOptions - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - MessageOptions.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if ( - message.messageSetWireFormat != null && - message.hasOwnProperty("messageSetWireFormat") - ) - if (typeof message.messageSetWireFormat !== "boolean") - return "messageSetWireFormat: boolean expected"; - if ( - message.noStandardDescriptorAccessor != null && - message.hasOwnProperty("noStandardDescriptorAccessor") - ) - if (typeof message.noStandardDescriptorAccessor !== "boolean") - return "noStandardDescriptorAccessor: boolean expected"; - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - if (typeof message.deprecated !== "boolean") - return "deprecated: boolean expected"; - if (message.mapEntry != null && message.hasOwnProperty("mapEntry")) - if (typeof message.mapEntry !== "boolean") - return "mapEntry: boolean expected"; - if ( - message.deprecatedLegacyJsonFieldConflicts != null && - message.hasOwnProperty("deprecatedLegacyJsonFieldConflicts") - ) - if (typeof message.deprecatedLegacyJsonFieldConflicts !== "boolean") - return "deprecatedLegacyJsonFieldConflicts: boolean expected"; - if (message.features != null && message.hasOwnProperty("features")) { - var error = $root.google.protobuf.FeatureSet.verify(message.features); - if (error) return "features." + error; - } - if ( - message.uninterpretedOption != null && - message.hasOwnProperty("uninterpretedOption") - ) { - if (!Array.isArray(message.uninterpretedOption)) - return "uninterpretedOption: array expected"; - for (var i = 0; i < message.uninterpretedOption.length; ++i) { - var error = $root.google.protobuf.UninterpretedOption.verify( - message.uninterpretedOption[i] - ); - if (error) return "uninterpretedOption." + error; - } - } - return null; - }; - - /** - * Creates a MessageOptions message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.MessageOptions - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.MessageOptions} MessageOptions - */ - MessageOptions.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.MessageOptions) - return object; - var message = new $root.google.protobuf.MessageOptions(); - if (object.messageSetWireFormat != null) - message.messageSetWireFormat = Boolean(object.messageSetWireFormat); - if (object.noStandardDescriptorAccessor != null) - message.noStandardDescriptorAccessor = Boolean( - object.noStandardDescriptorAccessor - ); - if (object.deprecated != null) - message.deprecated = Boolean(object.deprecated); - if (object.mapEntry != null) - message.mapEntry = Boolean(object.mapEntry); - if (object.deprecatedLegacyJsonFieldConflicts != null) - message.deprecatedLegacyJsonFieldConflicts = Boolean( - object.deprecatedLegacyJsonFieldConflicts - ); - if (object.features != null) { - if (typeof object.features !== "object") - throw TypeError( - ".google.protobuf.MessageOptions.features: object expected" - ); - message.features = $root.google.protobuf.FeatureSet.fromObject( - object.features - ); - } - if (object.uninterpretedOption) { - if (!Array.isArray(object.uninterpretedOption)) - throw TypeError( - ".google.protobuf.MessageOptions.uninterpretedOption: array expected" - ); - message.uninterpretedOption = []; - for (var i = 0; i < object.uninterpretedOption.length; ++i) { - if (typeof object.uninterpretedOption[i] !== "object") - throw TypeError( - ".google.protobuf.MessageOptions.uninterpretedOption: object expected" - ); - message.uninterpretedOption[i] = - $root.google.protobuf.UninterpretedOption.fromObject( - object.uninterpretedOption[i] - ); - } - } - return message; - }; - - /** - * Creates a plain object from a MessageOptions message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.MessageOptions - * @static - * @param {google.protobuf.MessageOptions} message MessageOptions - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - MessageOptions.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.arrays || options.defaults) object.uninterpretedOption = []; - if (options.defaults) { - object.messageSetWireFormat = false; - object.noStandardDescriptorAccessor = false; - object.deprecated = false; - object.mapEntry = false; - object.deprecatedLegacyJsonFieldConflicts = false; - object.features = null; - } - if ( - message.messageSetWireFormat != null && - message.hasOwnProperty("messageSetWireFormat") - ) - object.messageSetWireFormat = message.messageSetWireFormat; - if ( - message.noStandardDescriptorAccessor != null && - message.hasOwnProperty("noStandardDescriptorAccessor") - ) - object.noStandardDescriptorAccessor = - message.noStandardDescriptorAccessor; - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - object.deprecated = message.deprecated; - if (message.mapEntry != null && message.hasOwnProperty("mapEntry")) - object.mapEntry = message.mapEntry; - if ( - message.deprecatedLegacyJsonFieldConflicts != null && - message.hasOwnProperty("deprecatedLegacyJsonFieldConflicts") - ) - object.deprecatedLegacyJsonFieldConflicts = - message.deprecatedLegacyJsonFieldConflicts; - if (message.features != null && message.hasOwnProperty("features")) - object.features = $root.google.protobuf.FeatureSet.toObject( - message.features, - options - ); - if (message.uninterpretedOption && message.uninterpretedOption.length) { - object.uninterpretedOption = []; - for (var j = 0; j < message.uninterpretedOption.length; ++j) - object.uninterpretedOption[j] = - $root.google.protobuf.UninterpretedOption.toObject( - message.uninterpretedOption[j], - options - ); - } - return object; - }; - - /** - * Converts this MessageOptions to JSON. - * @function toJSON - * @memberof google.protobuf.MessageOptions - * @instance - * @returns {Object.} JSON object - */ - MessageOptions.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for MessageOptions - * @function getTypeUrl - * @memberof google.protobuf.MessageOptions - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - MessageOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.MessageOptions"; - }; - - return MessageOptions; - })(); - - protobuf.FieldOptions = (function () { - /** - * Properties of a FieldOptions. - * @memberof google.protobuf - * @interface IFieldOptions - * @property {google.protobuf.FieldOptions.CType|null} [ctype] FieldOptions ctype - * @property {boolean|null} [packed] FieldOptions packed - * @property {google.protobuf.FieldOptions.JSType|null} [jstype] FieldOptions jstype - * @property {boolean|null} [lazy] FieldOptions lazy - * @property {boolean|null} [unverifiedLazy] FieldOptions unverifiedLazy - * @property {boolean|null} [deprecated] FieldOptions deprecated - * @property {boolean|null} [weak] FieldOptions weak - * @property {boolean|null} [debugRedact] FieldOptions debugRedact - * @property {google.protobuf.FieldOptions.OptionRetention|null} [retention] FieldOptions retention - * @property {Array.|null} [targets] FieldOptions targets - * @property {Array.|null} [editionDefaults] FieldOptions editionDefaults - * @property {google.protobuf.IFeatureSet|null} [features] FieldOptions features - * @property {google.protobuf.FieldOptions.IFeatureSupport|null} [featureSupport] FieldOptions featureSupport - * @property {Array.|null} [uninterpretedOption] FieldOptions uninterpretedOption - */ - - /** - * Constructs a new FieldOptions. - * @memberof google.protobuf - * @classdesc Represents a FieldOptions. - * @implements IFieldOptions - * @constructor - * @param {google.protobuf.IFieldOptions=} [properties] Properties to set - */ - function FieldOptions(properties) { - this.targets = []; - this.editionDefaults = []; - this.uninterpretedOption = []; - 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]]; - } - - /** - * FieldOptions ctype. - * @member {google.protobuf.FieldOptions.CType} ctype - * @memberof google.protobuf.FieldOptions - * @instance - */ - FieldOptions.prototype.ctype = 0; - - /** - * FieldOptions packed. - * @member {boolean} packed - * @memberof google.protobuf.FieldOptions - * @instance - */ - FieldOptions.prototype.packed = false; - - /** - * FieldOptions jstype. - * @member {google.protobuf.FieldOptions.JSType} jstype - * @memberof google.protobuf.FieldOptions - * @instance - */ - FieldOptions.prototype.jstype = 0; - - /** - * FieldOptions lazy. - * @member {boolean} lazy - * @memberof google.protobuf.FieldOptions - * @instance - */ - FieldOptions.prototype.lazy = false; - - /** - * FieldOptions unverifiedLazy. - * @member {boolean} unverifiedLazy - * @memberof google.protobuf.FieldOptions - * @instance - */ - FieldOptions.prototype.unverifiedLazy = false; - - /** - * FieldOptions deprecated. - * @member {boolean} deprecated - * @memberof google.protobuf.FieldOptions - * @instance - */ - FieldOptions.prototype.deprecated = false; - - /** - * FieldOptions weak. - * @member {boolean} weak - * @memberof google.protobuf.FieldOptions - * @instance - */ - FieldOptions.prototype.weak = false; - - /** - * FieldOptions debugRedact. - * @member {boolean} debugRedact - * @memberof google.protobuf.FieldOptions - * @instance - */ - FieldOptions.prototype.debugRedact = false; - - /** - * FieldOptions retention. - * @member {google.protobuf.FieldOptions.OptionRetention} retention - * @memberof google.protobuf.FieldOptions - * @instance - */ - FieldOptions.prototype.retention = 0; - - /** - * FieldOptions targets. - * @member {Array.} targets - * @memberof google.protobuf.FieldOptions - * @instance - */ - FieldOptions.prototype.targets = $util.emptyArray; - - /** - * FieldOptions editionDefaults. - * @member {Array.} editionDefaults - * @memberof google.protobuf.FieldOptions - * @instance - */ - FieldOptions.prototype.editionDefaults = $util.emptyArray; - - /** - * FieldOptions features. - * @member {google.protobuf.IFeatureSet|null|undefined} features - * @memberof google.protobuf.FieldOptions - * @instance - */ - FieldOptions.prototype.features = null; - - /** - * FieldOptions featureSupport. - * @member {google.protobuf.FieldOptions.IFeatureSupport|null|undefined} featureSupport - * @memberof google.protobuf.FieldOptions - * @instance - */ - FieldOptions.prototype.featureSupport = null; - - /** - * FieldOptions uninterpretedOption. - * @member {Array.} uninterpretedOption - * @memberof google.protobuf.FieldOptions - * @instance - */ - FieldOptions.prototype.uninterpretedOption = $util.emptyArray; - - /** - * Creates a new FieldOptions instance using the specified properties. - * @function create - * @memberof google.protobuf.FieldOptions - * @static - * @param {google.protobuf.IFieldOptions=} [properties] Properties to set - * @returns {google.protobuf.FieldOptions} FieldOptions instance - */ - FieldOptions.create = function create(properties) { - return new FieldOptions(properties); - }; - - /** - * Encodes the specified FieldOptions message. Does not implicitly {@link google.protobuf.FieldOptions.verify|verify} messages. - * @function encode - * @memberof google.protobuf.FieldOptions - * @static - * @param {google.protobuf.IFieldOptions} message FieldOptions message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - FieldOptions.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if ( - message.ctype != null && - Object.hasOwnProperty.call(message, "ctype") - ) - writer.uint32(/* id 1, wireType 0 =*/ 8).int32(message.ctype); - if ( - message.packed != null && - Object.hasOwnProperty.call(message, "packed") - ) - writer.uint32(/* id 2, wireType 0 =*/ 16).bool(message.packed); - if ( - message.deprecated != null && - Object.hasOwnProperty.call(message, "deprecated") - ) - writer.uint32(/* id 3, wireType 0 =*/ 24).bool(message.deprecated); - if (message.lazy != null && Object.hasOwnProperty.call(message, "lazy")) - writer.uint32(/* id 5, wireType 0 =*/ 40).bool(message.lazy); - if ( - message.jstype != null && - Object.hasOwnProperty.call(message, "jstype") - ) - writer.uint32(/* id 6, wireType 0 =*/ 48).int32(message.jstype); - if (message.weak != null && Object.hasOwnProperty.call(message, "weak")) - writer.uint32(/* id 10, wireType 0 =*/ 80).bool(message.weak); - if ( - message.unverifiedLazy != null && - Object.hasOwnProperty.call(message, "unverifiedLazy") - ) - writer - .uint32(/* id 15, wireType 0 =*/ 120) - .bool(message.unverifiedLazy); - if ( - message.debugRedact != null && - Object.hasOwnProperty.call(message, "debugRedact") - ) - writer.uint32(/* id 16, wireType 0 =*/ 128).bool(message.debugRedact); - if ( - message.retention != null && - Object.hasOwnProperty.call(message, "retention") - ) - writer.uint32(/* id 17, wireType 0 =*/ 136).int32(message.retention); - if (message.targets != null && message.targets.length) - for (var i = 0; i < message.targets.length; ++i) - writer - .uint32(/* id 19, wireType 0 =*/ 152) - .int32(message.targets[i]); - if (message.editionDefaults != null && message.editionDefaults.length) - for (var i = 0; i < message.editionDefaults.length; ++i) - $root.google.protobuf.FieldOptions.EditionDefault.encode( - message.editionDefaults[i], - writer.uint32(/* id 20, wireType 2 =*/ 162).fork() - ).ldelim(); - if ( - message.features != null && - Object.hasOwnProperty.call(message, "features") - ) - $root.google.protobuf.FeatureSet.encode( - message.features, - writer.uint32(/* id 21, wireType 2 =*/ 170).fork() - ).ldelim(); - if ( - message.featureSupport != null && - Object.hasOwnProperty.call(message, "featureSupport") - ) - $root.google.protobuf.FieldOptions.FeatureSupport.encode( - message.featureSupport, - writer.uint32(/* id 22, wireType 2 =*/ 178).fork() - ).ldelim(); - if ( - message.uninterpretedOption != null && - message.uninterpretedOption.length - ) - for (var i = 0; i < message.uninterpretedOption.length; ++i) - $root.google.protobuf.UninterpretedOption.encode( - message.uninterpretedOption[i], - writer.uint32(/* id 999, wireType 2 =*/ 7994).fork() - ).ldelim(); - return writer; - }; - - /** - * Encodes the specified FieldOptions message, length delimited. Does not implicitly {@link google.protobuf.FieldOptions.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.FieldOptions - * @static - * @param {google.protobuf.IFieldOptions} message FieldOptions message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - FieldOptions.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a FieldOptions message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.FieldOptions - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.FieldOptions} FieldOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - FieldOptions.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.google.protobuf.FieldOptions(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - message.ctype = reader.int32(); - break; - } - case 2: { - message.packed = reader.bool(); - break; - } - case 6: { - message.jstype = reader.int32(); - break; - } - case 5: { - message.lazy = reader.bool(); - break; - } - case 15: { - message.unverifiedLazy = reader.bool(); - break; - } - case 3: { - message.deprecated = reader.bool(); - break; - } - case 10: { - message.weak = reader.bool(); - break; - } - case 16: { - message.debugRedact = reader.bool(); - break; - } - case 17: { - message.retention = reader.int32(); - break; - } - case 19: { - if (!(message.targets && message.targets.length)) - message.targets = []; - if ((tag & 7) === 2) { - var end2 = reader.uint32() + reader.pos; - while (reader.pos < end2) message.targets.push(reader.int32()); - } else message.targets.push(reader.int32()); - break; - } - case 20: { - if (!(message.editionDefaults && message.editionDefaults.length)) - message.editionDefaults = []; - message.editionDefaults.push( - $root.google.protobuf.FieldOptions.EditionDefault.decode( - reader, - reader.uint32() - ) - ); - break; - } - case 21: { - message.features = $root.google.protobuf.FeatureSet.decode( - reader, - reader.uint32() - ); - break; - } - case 22: { - message.featureSupport = - $root.google.protobuf.FieldOptions.FeatureSupport.decode( - reader, - reader.uint32() - ); - break; - } - case 999: { - if ( - !( - message.uninterpretedOption && - message.uninterpretedOption.length - ) - ) - message.uninterpretedOption = []; - message.uninterpretedOption.push( - $root.google.protobuf.UninterpretedOption.decode( - reader, - reader.uint32() - ) - ); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a FieldOptions message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.FieldOptions - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.FieldOptions} FieldOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - FieldOptions.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a FieldOptions message. - * @function verify - * @memberof google.protobuf.FieldOptions - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - FieldOptions.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.ctype != null && message.hasOwnProperty("ctype")) - switch (message.ctype) { - default: - return "ctype: enum value expected"; - case 0: - case 1: - case 2: - break; - } - if (message.packed != null && message.hasOwnProperty("packed")) - if (typeof message.packed !== "boolean") - return "packed: boolean expected"; - if (message.jstype != null && message.hasOwnProperty("jstype")) - switch (message.jstype) { - default: - return "jstype: enum value expected"; - case 0: - case 1: - case 2: - break; - } - if (message.lazy != null && message.hasOwnProperty("lazy")) - if (typeof message.lazy !== "boolean") - return "lazy: boolean expected"; - if ( - message.unverifiedLazy != null && - message.hasOwnProperty("unverifiedLazy") - ) - if (typeof message.unverifiedLazy !== "boolean") - return "unverifiedLazy: boolean expected"; - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - if (typeof message.deprecated !== "boolean") - return "deprecated: boolean expected"; - if (message.weak != null && message.hasOwnProperty("weak")) - if (typeof message.weak !== "boolean") - return "weak: boolean expected"; - if ( - message.debugRedact != null && - message.hasOwnProperty("debugRedact") - ) - if (typeof message.debugRedact !== "boolean") - return "debugRedact: boolean expected"; - if (message.retention != null && message.hasOwnProperty("retention")) - switch (message.retention) { - default: - return "retention: enum value expected"; - case 0: - case 1: - case 2: - break; - } - if (message.targets != null && message.hasOwnProperty("targets")) { - if (!Array.isArray(message.targets)) return "targets: array expected"; - for (var i = 0; i < message.targets.length; ++i) - switch (message.targets[i]) { - default: - return "targets: enum value[] expected"; - case 0: - case 1: - case 2: - case 3: - case 4: - case 5: - case 6: - case 7: - case 8: - case 9: - break; - } - } - if ( - message.editionDefaults != null && - message.hasOwnProperty("editionDefaults") - ) { - if (!Array.isArray(message.editionDefaults)) - return "editionDefaults: array expected"; - for (var i = 0; i < message.editionDefaults.length; ++i) { - var error = - $root.google.protobuf.FieldOptions.EditionDefault.verify( - message.editionDefaults[i] - ); - if (error) return "editionDefaults." + error; - } - } - if (message.features != null && message.hasOwnProperty("features")) { - var error = $root.google.protobuf.FeatureSet.verify(message.features); - if (error) return "features." + error; - } - if ( - message.featureSupport != null && - message.hasOwnProperty("featureSupport") - ) { - var error = $root.google.protobuf.FieldOptions.FeatureSupport.verify( - message.featureSupport - ); - if (error) return "featureSupport." + error; - } - if ( - message.uninterpretedOption != null && - message.hasOwnProperty("uninterpretedOption") - ) { - if (!Array.isArray(message.uninterpretedOption)) - return "uninterpretedOption: array expected"; - for (var i = 0; i < message.uninterpretedOption.length; ++i) { - var error = $root.google.protobuf.UninterpretedOption.verify( - message.uninterpretedOption[i] - ); - if (error) return "uninterpretedOption." + error; - } - } - return null; - }; - - /** - * Creates a FieldOptions message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.FieldOptions - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.FieldOptions} FieldOptions - */ - FieldOptions.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.FieldOptions) return object; - var message = new $root.google.protobuf.FieldOptions(); - switch (object.ctype) { - default: - if (typeof object.ctype === "number") { - message.ctype = object.ctype; - break; - } - break; - case "STRING": - case 0: - message.ctype = 0; - break; - case "CORD": - case 1: - message.ctype = 1; - break; - case "STRING_PIECE": - case 2: - message.ctype = 2; - break; - } - if (object.packed != null) message.packed = Boolean(object.packed); - switch (object.jstype) { - default: - if (typeof object.jstype === "number") { - message.jstype = object.jstype; - break; - } - break; - case "JS_NORMAL": - case 0: - message.jstype = 0; - break; - case "JS_STRING": - case 1: - message.jstype = 1; - break; - case "JS_NUMBER": - case 2: - message.jstype = 2; - break; - } - if (object.lazy != null) message.lazy = Boolean(object.lazy); - if (object.unverifiedLazy != null) - message.unverifiedLazy = Boolean(object.unverifiedLazy); - if (object.deprecated != null) - message.deprecated = Boolean(object.deprecated); - if (object.weak != null) message.weak = Boolean(object.weak); - if (object.debugRedact != null) - message.debugRedact = Boolean(object.debugRedact); - switch (object.retention) { - default: - if (typeof object.retention === "number") { - message.retention = object.retention; - break; - } - break; - case "RETENTION_UNKNOWN": - case 0: - message.retention = 0; - break; - case "RETENTION_RUNTIME": - case 1: - message.retention = 1; - break; - case "RETENTION_SOURCE": - case 2: - message.retention = 2; - break; - } - if (object.targets) { - if (!Array.isArray(object.targets)) - throw TypeError( - ".google.protobuf.FieldOptions.targets: array expected" - ); - message.targets = []; - for (var i = 0; i < object.targets.length; ++i) - switch (object.targets[i]) { - default: - if (typeof object.targets[i] === "number") { - message.targets[i] = object.targets[i]; - break; + 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; + } + default: + reader.skipType(tag & 7); + break; } - case "TARGET_TYPE_UNKNOWN": - case 0: - message.targets[i] = 0; - break; - case "TARGET_TYPE_FILE": - case 1: - message.targets[i] = 1; - break; - case "TARGET_TYPE_EXTENSION_RANGE": - case 2: - message.targets[i] = 2; - break; - case "TARGET_TYPE_MESSAGE": - case 3: - message.targets[i] = 3; - break; - case "TARGET_TYPE_FIELD": - case 4: - message.targets[i] = 4; - break; - case "TARGET_TYPE_ONEOF": - case 5: - message.targets[i] = 5; - break; - case "TARGET_TYPE_ENUM": - case 6: - message.targets[i] = 6; - break; - case "TARGET_TYPE_ENUM_ENTRY": - case 7: - message.targets[i] = 7; - break; - case "TARGET_TYPE_SERVICE": - case 8: - message.targets[i] = 8; - break; - case "TARGET_TYPE_METHOD": - case 9: - message.targets[i] = 9; - break; } - } - if (object.editionDefaults) { - if (!Array.isArray(object.editionDefaults)) - throw TypeError( - ".google.protobuf.FieldOptions.editionDefaults: array expected" - ); - message.editionDefaults = []; - for (var i = 0; i < object.editionDefaults.length; ++i) { - if (typeof object.editionDefaults[i] !== "object") - throw TypeError( - ".google.protobuf.FieldOptions.editionDefaults: object expected" - ); - message.editionDefaults[i] = - $root.google.protobuf.FieldOptions.EditionDefault.fromObject( - object.editionDefaults[i] - ); - } - } - if (object.features != null) { - if (typeof object.features !== "object") - throw TypeError( - ".google.protobuf.FieldOptions.features: object expected" - ); - message.features = $root.google.protobuf.FeatureSet.fromObject( - object.features - ); - } - if (object.featureSupport != null) { - if (typeof object.featureSupport !== "object") - throw TypeError( - ".google.protobuf.FieldOptions.featureSupport: object expected" - ); - message.featureSupport = - $root.google.protobuf.FieldOptions.FeatureSupport.fromObject( - object.featureSupport - ); - } - if (object.uninterpretedOption) { - if (!Array.isArray(object.uninterpretedOption)) - throw TypeError( - ".google.protobuf.FieldOptions.uninterpretedOption: array expected" - ); - message.uninterpretedOption = []; - for (var i = 0; i < object.uninterpretedOption.length; ++i) { - if (typeof object.uninterpretedOption[i] !== "object") - throw TypeError( - ".google.protobuf.FieldOptions.uninterpretedOption: object expected" - ); - message.uninterpretedOption[i] = - $root.google.protobuf.UninterpretedOption.fromObject( - object.uninterpretedOption[i] - ); - } - } - return message; - }; - - /** - * Creates a plain object from a FieldOptions message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.FieldOptions - * @static - * @param {google.protobuf.FieldOptions} message FieldOptions - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - FieldOptions.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.arrays || options.defaults) { - object.targets = []; - object.editionDefaults = []; - object.uninterpretedOption = []; - } - if (options.defaults) { - object.ctype = options.enums === String ? "STRING" : 0; - object.packed = false; - object.deprecated = false; - object.lazy = false; - object.jstype = options.enums === String ? "JS_NORMAL" : 0; - object.weak = false; - object.unverifiedLazy = false; - object.debugRedact = false; - object.retention = options.enums === String ? "RETENTION_UNKNOWN" : 0; - object.features = null; - object.featureSupport = null; - } - if (message.ctype != null && message.hasOwnProperty("ctype")) - object.ctype = - options.enums === String - ? $root.google.protobuf.FieldOptions.CType[message.ctype] === - undefined - ? message.ctype - : $root.google.protobuf.FieldOptions.CType[message.ctype] - : message.ctype; - if (message.packed != null && message.hasOwnProperty("packed")) - object.packed = message.packed; - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - object.deprecated = message.deprecated; - if (message.lazy != null && message.hasOwnProperty("lazy")) - object.lazy = message.lazy; - if (message.jstype != null && message.hasOwnProperty("jstype")) - object.jstype = - options.enums === String - ? $root.google.protobuf.FieldOptions.JSType[message.jstype] === - undefined - ? message.jstype - : $root.google.protobuf.FieldOptions.JSType[message.jstype] - : message.jstype; - if (message.weak != null && message.hasOwnProperty("weak")) - object.weak = message.weak; - if ( - message.unverifiedLazy != null && - message.hasOwnProperty("unverifiedLazy") - ) - object.unverifiedLazy = message.unverifiedLazy; - if ( - message.debugRedact != null && - message.hasOwnProperty("debugRedact") - ) - object.debugRedact = message.debugRedact; - if (message.retention != null && message.hasOwnProperty("retention")) - object.retention = - options.enums === String - ? $root.google.protobuf.FieldOptions.OptionRetention[ - message.retention - ] === undefined - ? message.retention - : $root.google.protobuf.FieldOptions.OptionRetention[ - message.retention - ] - : message.retention; - if (message.targets && message.targets.length) { - object.targets = []; - for (var j = 0; j < message.targets.length; ++j) - object.targets[j] = - options.enums === String - ? $root.google.protobuf.FieldOptions.OptionTargetType[ - message.targets[j] - ] === undefined - ? message.targets[j] - : $root.google.protobuf.FieldOptions.OptionTargetType[ - message.targets[j] - ] - : message.targets[j]; - } - if (message.editionDefaults && message.editionDefaults.length) { - object.editionDefaults = []; - for (var j = 0; j < message.editionDefaults.length; ++j) - object.editionDefaults[j] = - $root.google.protobuf.FieldOptions.EditionDefault.toObject( - message.editionDefaults[j], - options - ); - } - if (message.features != null && message.hasOwnProperty("features")) - object.features = $root.google.protobuf.FeatureSet.toObject( - message.features, - options - ); - if ( - message.featureSupport != null && - message.hasOwnProperty("featureSupport") - ) - object.featureSupport = - $root.google.protobuf.FieldOptions.FeatureSupport.toObject( - message.featureSupport, - options - ); - if (message.uninterpretedOption && message.uninterpretedOption.length) { - object.uninterpretedOption = []; - for (var j = 0; j < message.uninterpretedOption.length; ++j) - object.uninterpretedOption[j] = - $root.google.protobuf.UninterpretedOption.toObject( - message.uninterpretedOption[j], - options - ); - } - return object; - }; - - /** - * Converts this FieldOptions to JSON. - * @function toJSON - * @memberof google.protobuf.FieldOptions - * @instance - * @returns {Object.} JSON object - */ - FieldOptions.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for FieldOptions - * @function getTypeUrl - * @memberof google.protobuf.FieldOptions - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - FieldOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.FieldOptions"; - }; - - /** - * CType enum. - * @name google.protobuf.FieldOptions.CType - * @enum {number} - * @property {number} STRING=0 STRING value - * @property {number} CORD=1 CORD value - * @property {number} STRING_PIECE=2 STRING_PIECE value - */ - FieldOptions.CType = (function () { - var valuesById = {}, - values = Object.create(valuesById); - values[(valuesById[0] = "STRING")] = 0; - values[(valuesById[1] = "CORD")] = 1; - values[(valuesById[2] = "STRING_PIECE")] = 2; - return values; - })(); - - /** - * JSType enum. - * @name google.protobuf.FieldOptions.JSType - * @enum {number} - * @property {number} JS_NORMAL=0 JS_NORMAL value - * @property {number} JS_STRING=1 JS_STRING value - * @property {number} JS_NUMBER=2 JS_NUMBER value - */ - FieldOptions.JSType = (function () { - var valuesById = {}, - values = Object.create(valuesById); - values[(valuesById[0] = "JS_NORMAL")] = 0; - values[(valuesById[1] = "JS_STRING")] = 1; - values[(valuesById[2] = "JS_NUMBER")] = 2; - return values; - })(); - - /** - * OptionRetention enum. - * @name google.protobuf.FieldOptions.OptionRetention - * @enum {number} - * @property {number} RETENTION_UNKNOWN=0 RETENTION_UNKNOWN value - * @property {number} RETENTION_RUNTIME=1 RETENTION_RUNTIME value - * @property {number} RETENTION_SOURCE=2 RETENTION_SOURCE value - */ - FieldOptions.OptionRetention = (function () { - var valuesById = {}, - values = Object.create(valuesById); - values[(valuesById[0] = "RETENTION_UNKNOWN")] = 0; - values[(valuesById[1] = "RETENTION_RUNTIME")] = 1; - values[(valuesById[2] = "RETENTION_SOURCE")] = 2; - return values; - })(); - - /** - * OptionTargetType enum. - * @name google.protobuf.FieldOptions.OptionTargetType - * @enum {number} - * @property {number} TARGET_TYPE_UNKNOWN=0 TARGET_TYPE_UNKNOWN value - * @property {number} TARGET_TYPE_FILE=1 TARGET_TYPE_FILE value - * @property {number} TARGET_TYPE_EXTENSION_RANGE=2 TARGET_TYPE_EXTENSION_RANGE value - * @property {number} TARGET_TYPE_MESSAGE=3 TARGET_TYPE_MESSAGE value - * @property {number} TARGET_TYPE_FIELD=4 TARGET_TYPE_FIELD value - * @property {number} TARGET_TYPE_ONEOF=5 TARGET_TYPE_ONEOF value - * @property {number} TARGET_TYPE_ENUM=6 TARGET_TYPE_ENUM value - * @property {number} TARGET_TYPE_ENUM_ENTRY=7 TARGET_TYPE_ENUM_ENTRY value - * @property {number} TARGET_TYPE_SERVICE=8 TARGET_TYPE_SERVICE value - * @property {number} TARGET_TYPE_METHOD=9 TARGET_TYPE_METHOD value - */ - FieldOptions.OptionTargetType = (function () { - var valuesById = {}, - values = Object.create(valuesById); - values[(valuesById[0] = "TARGET_TYPE_UNKNOWN")] = 0; - values[(valuesById[1] = "TARGET_TYPE_FILE")] = 1; - values[(valuesById[2] = "TARGET_TYPE_EXTENSION_RANGE")] = 2; - values[(valuesById[3] = "TARGET_TYPE_MESSAGE")] = 3; - values[(valuesById[4] = "TARGET_TYPE_FIELD")] = 4; - values[(valuesById[5] = "TARGET_TYPE_ONEOF")] = 5; - values[(valuesById[6] = "TARGET_TYPE_ENUM")] = 6; - values[(valuesById[7] = "TARGET_TYPE_ENUM_ENTRY")] = 7; - values[(valuesById[8] = "TARGET_TYPE_SERVICE")] = 8; - values[(valuesById[9] = "TARGET_TYPE_METHOD")] = 9; - return values; - })(); - - FieldOptions.EditionDefault = (function () { - /** - * Properties of an EditionDefault. - * @memberof google.protobuf.FieldOptions - * @interface IEditionDefault - * @property {google.protobuf.Edition|null} [edition] EditionDefault edition - * @property {string|null} [value] EditionDefault value - */ - - /** - * Constructs a new EditionDefault. - * @memberof google.protobuf.FieldOptions - * @classdesc Represents an EditionDefault. - * @implements IEditionDefault - * @constructor - * @param {google.protobuf.FieldOptions.IEditionDefault=} [properties] Properties to set - */ - function EditionDefault(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]]; - } - - /** - * EditionDefault edition. - * @member {google.protobuf.Edition} edition - * @memberof google.protobuf.FieldOptions.EditionDefault - * @instance - */ - EditionDefault.prototype.edition = 0; - - /** - * EditionDefault value. - * @member {string} value - * @memberof google.protobuf.FieldOptions.EditionDefault - * @instance - */ - EditionDefault.prototype.value = ""; - - /** - * Creates a new EditionDefault instance using the specified properties. - * @function create - * @memberof google.protobuf.FieldOptions.EditionDefault - * @static - * @param {google.protobuf.FieldOptions.IEditionDefault=} [properties] Properties to set - * @returns {google.protobuf.FieldOptions.EditionDefault} EditionDefault instance - */ - EditionDefault.create = function create(properties) { - return new EditionDefault(properties); + return message; }; /** - * Encodes the specified EditionDefault message. Does not implicitly {@link google.protobuf.FieldOptions.EditionDefault.verify|verify} messages. - * @function encode - * @memberof google.protobuf.FieldOptions.EditionDefault - * @static - * @param {google.protobuf.FieldOptions.IEditionDefault} message EditionDefault message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EditionDefault.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if ( - message.value != null && - Object.hasOwnProperty.call(message, "value") - ) - writer.uint32(/* id 2, wireType 2 =*/ 18).string(message.value); - if ( - message.edition != null && - Object.hasOwnProperty.call(message, "edition") - ) - writer.uint32(/* id 3, wireType 0 =*/ 24).int32(message.edition); - return writer; - }; - - /** - * Encodes the specified EditionDefault message, length delimited. Does not implicitly {@link google.protobuf.FieldOptions.EditionDefault.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.FieldOptions.EditionDefault - * @static - * @param {google.protobuf.FieldOptions.IEditionDefault} message EditionDefault message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EditionDefault.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes an EditionDefault message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.FieldOptions.EditionDefault - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.FieldOptions.EditionDefault} EditionDefault - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - EditionDefault.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.google.protobuf.FieldOptions.EditionDefault(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 3: { - message.edition = reader.int32(); - break; - } - case 2: { - message.value = reader.string(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes an EditionDefault message from the specified reader or buffer, length delimited. + * Decodes a GirlBrief message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.protobuf.FieldOptions.EditionDefault + * @memberof cs.GirlBrief * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.FieldOptions.EditionDefault} EditionDefault + * @returns {cs.GirlBrief} GirlBrief * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - EditionDefault.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); + GirlBrief.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); }; /** - * Verifies an EditionDefault message. + * Verifies a GirlBrief message. * @function verify - * @memberof google.protobuf.FieldOptions.EditionDefault + * @memberof cs.GirlBrief * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - EditionDefault.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.edition != null && message.hasOwnProperty("edition")) - switch (message.edition) { - default: - return "edition: enum value expected"; - case 0: - case 900: - case 998: - case 999: - case 1000: - case 1001: - case 1: - case 2: - case 99997: - case 99998: - case 99999: - case 2147483647: - break; - } - if (message.value != null && message.hasOwnProperty("value")) - if (!$util.isString(message.value)) return "value: string expected"; - return null; + 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"; + return null; }; /** - * Creates an EditionDefault message from a plain object. Also converts values to their respective internal types. + * Creates a GirlBrief message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.protobuf.FieldOptions.EditionDefault + * @memberof cs.GirlBrief * @static * @param {Object.} object Plain object - * @returns {google.protobuf.FieldOptions.EditionDefault} EditionDefault + * @returns {cs.GirlBrief} GirlBrief */ - EditionDefault.fromObject = function fromObject(object) { - if ( - object instanceof $root.google.protobuf.FieldOptions.EditionDefault - ) - return object; - var message = new $root.google.protobuf.FieldOptions.EditionDefault(); - switch (object.edition) { - default: - if (typeof object.edition === "number") { - message.edition = object.edition; - break; - } - break; - case "EDITION_UNKNOWN": - case 0: - message.edition = 0; - break; - case "EDITION_LEGACY": - case 900: - message.edition = 900; - break; - case "EDITION_PROTO2": - case 998: - message.edition = 998; - break; - case "EDITION_PROTO3": - case 999: - message.edition = 999; - break; - case "EDITION_2023": - case 1000: - message.edition = 1000; - break; - case "EDITION_2024": - case 1001: - message.edition = 1001; - break; - case "EDITION_1_TEST_ONLY": - case 1: - message.edition = 1; - break; - case "EDITION_2_TEST_ONLY": - case 2: - message.edition = 2; - break; - case "EDITION_99997_TEST_ONLY": - case 99997: - message.edition = 99997; - break; - case "EDITION_99998_TEST_ONLY": - case 99998: - message.edition = 99998; - break; - case "EDITION_99999_TEST_ONLY": - case 99999: - message.edition = 99999; - break; - case "EDITION_MAX": - case 2147483647: - message.edition = 2147483647; - break; - } - if (object.value != null) message.value = String(object.value); - return message; + 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; + return message; }; /** - * Creates a plain object from an EditionDefault message. Also converts values to other types if specified. + * Creates a plain object from a GirlBrief message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.FieldOptions.EditionDefault + * @memberof cs.GirlBrief * @static - * @param {google.protobuf.FieldOptions.EditionDefault} message EditionDefault + * @param {cs.GirlBrief} message GirlBrief * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - EditionDefault.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.defaults) { - object.value = ""; - object.edition = options.enums === String ? "EDITION_UNKNOWN" : 0; - } - if (message.value != null && message.hasOwnProperty("value")) - object.value = message.value; - if (message.edition != null && message.hasOwnProperty("edition")) - object.edition = - options.enums === String - ? $root.google.protobuf.Edition[message.edition] === undefined - ? message.edition - : $root.google.protobuf.Edition[message.edition] - : message.edition; - return object; + 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; + } + 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; + return object; }; /** - * Converts this EditionDefault to JSON. + * Converts this GirlBrief to JSON. * @function toJSON - * @memberof google.protobuf.FieldOptions.EditionDefault + * @memberof cs.GirlBrief * @instance * @returns {Object.} JSON object */ - EditionDefault.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + GirlBrief.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for EditionDefault + * Gets the default type url for GirlBrief * @function getTypeUrl - * @memberof google.protobuf.FieldOptions.EditionDefault + * @memberof cs.GirlBrief * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - EditionDefault.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.FieldOptions.EditionDefault"; + GirlBrief.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/cs.GirlBrief"; }; - return EditionDefault; - })(); + return GirlBrief; + })(); + + cs.GirlDetail = (function() { - FieldOptions.FeatureSupport = (function () { /** - * Properties of a FeatureSupport. - * @memberof google.protobuf.FieldOptions - * @interface IFeatureSupport - * @property {google.protobuf.Edition|null} [editionIntroduced] FeatureSupport editionIntroduced - * @property {google.protobuf.Edition|null} [editionDeprecated] FeatureSupport editionDeprecated - * @property {string|null} [deprecationWarning] FeatureSupport deprecationWarning - * @property {google.protobuf.Edition|null} [editionRemoved] FeatureSupport editionRemoved + * Properties of a GirlDetail. + * @memberof cs + * @interface IGirlDetail + * @property {cs.IGirlBrief|null} [brief] GirlDetail brief + * @property {string|null} [desc] GirlDetail desc + * @property {Array.|null} [pics] GirlDetail pics */ /** - * Constructs a new FeatureSupport. - * @memberof google.protobuf.FieldOptions - * @classdesc Represents a FeatureSupport. - * @implements IFeatureSupport + * Constructs a new GirlDetail. + * @memberof cs + * @classdesc Represents a GirlDetail. + * @implements IGirlDetail * @constructor - * @param {google.protobuf.FieldOptions.IFeatureSupport=} [properties] Properties to set + * @param {cs.IGirlDetail=} [properties] Properties to set */ - function FeatureSupport(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]]; + function GirlDetail(properties) { + this.pics = []; + 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]]; } /** - * FeatureSupport editionIntroduced. - * @member {google.protobuf.Edition} editionIntroduced - * @memberof google.protobuf.FieldOptions.FeatureSupport + * GirlDetail brief. + * @member {cs.IGirlBrief|null|undefined} brief + * @memberof cs.GirlDetail * @instance */ - FeatureSupport.prototype.editionIntroduced = 0; + GirlDetail.prototype.brief = null; /** - * FeatureSupport editionDeprecated. - * @member {google.protobuf.Edition} editionDeprecated - * @memberof google.protobuf.FieldOptions.FeatureSupport + * GirlDetail desc. + * @member {string} desc + * @memberof cs.GirlDetail * @instance */ - FeatureSupport.prototype.editionDeprecated = 0; + GirlDetail.prototype.desc = ""; /** - * FeatureSupport deprecationWarning. - * @member {string} deprecationWarning - * @memberof google.protobuf.FieldOptions.FeatureSupport + * GirlDetail pics. + * @member {Array.} pics + * @memberof cs.GirlDetail * @instance */ - FeatureSupport.prototype.deprecationWarning = ""; + GirlDetail.prototype.pics = $util.emptyArray; /** - * FeatureSupport editionRemoved. - * @member {google.protobuf.Edition} editionRemoved - * @memberof google.protobuf.FieldOptions.FeatureSupport - * @instance - */ - FeatureSupport.prototype.editionRemoved = 0; - - /** - * Creates a new FeatureSupport instance using the specified properties. + * Creates a new GirlDetail instance using the specified properties. * @function create - * @memberof google.protobuf.FieldOptions.FeatureSupport + * @memberof cs.GirlDetail * @static - * @param {google.protobuf.FieldOptions.IFeatureSupport=} [properties] Properties to set - * @returns {google.protobuf.FieldOptions.FeatureSupport} FeatureSupport instance + * @param {cs.IGirlDetail=} [properties] Properties to set + * @returns {cs.GirlDetail} GirlDetail instance */ - FeatureSupport.create = function create(properties) { - return new FeatureSupport(properties); + GirlDetail.create = function create(properties) { + return new GirlDetail(properties); }; /** - * Encodes the specified FeatureSupport message. Does not implicitly {@link google.protobuf.FieldOptions.FeatureSupport.verify|verify} messages. + * Encodes the specified GirlDetail message. Does not implicitly {@link cs.GirlDetail.verify|verify} messages. * @function encode - * @memberof google.protobuf.FieldOptions.FeatureSupport + * @memberof cs.GirlDetail * @static - * @param {google.protobuf.FieldOptions.IFeatureSupport} message FeatureSupport message or plain object to encode + * @param {cs.IGirlDetail} message GirlDetail message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - FeatureSupport.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if ( - message.editionIntroduced != null && - Object.hasOwnProperty.call(message, "editionIntroduced") - ) - writer - .uint32(/* id 1, wireType 0 =*/ 8) - .int32(message.editionIntroduced); - if ( - message.editionDeprecated != null && - Object.hasOwnProperty.call(message, "editionDeprecated") - ) - writer - .uint32(/* id 2, wireType 0 =*/ 16) - .int32(message.editionDeprecated); - if ( - message.deprecationWarning != null && - Object.hasOwnProperty.call(message, "deprecationWarning") - ) - writer - .uint32(/* id 3, wireType 2 =*/ 26) - .string(message.deprecationWarning); - if ( - message.editionRemoved != null && - Object.hasOwnProperty.call(message, "editionRemoved") - ) - writer - .uint32(/* id 4, wireType 0 =*/ 32) - .int32(message.editionRemoved); - return writer; + 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); + if (message.pics != null && message.pics.length) + for (var i = 0; i < message.pics.length; ++i) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.pics[i]); + return writer; }; /** - * Encodes the specified FeatureSupport message, length delimited. Does not implicitly {@link google.protobuf.FieldOptions.FeatureSupport.verify|verify} messages. + * Encodes the specified GirlDetail message, length delimited. Does not implicitly {@link cs.GirlDetail.verify|verify} messages. * @function encodeDelimited - * @memberof google.protobuf.FieldOptions.FeatureSupport + * @memberof cs.GirlDetail * @static - * @param {google.protobuf.FieldOptions.IFeatureSupport} message FeatureSupport message or plain object to encode + * @param {cs.IGirlDetail} message GirlDetail message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - FeatureSupport.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); + GirlDetail.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); }; /** - * Decodes a FeatureSupport message from the specified reader or buffer. + * Decodes a GirlDetail message from the specified reader or buffer. * @function decode - * @memberof google.protobuf.FieldOptions.FeatureSupport + * @memberof cs.GirlDetail * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.FieldOptions.FeatureSupport} FeatureSupport + * @returns {cs.GirlDetail} GirlDetail * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - FeatureSupport.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.google.protobuf.FieldOptions.FeatureSupport(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - message.editionIntroduced = reader.int32(); - break; - } - case 2: { - message.editionDeprecated = reader.int32(); - break; - } - case 3: { - message.deprecationWarning = reader.string(); - break; - } - case 4: { - message.editionRemoved = reader.int32(); - break; - } - default: - reader.skipType(tag & 7); - break; + 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; + } + case 3: { + if (!(message.pics && message.pics.length)) + message.pics = []; + message.pics.push(reader.string()); + break; + } + default: + reader.skipType(tag & 7); + break; + } } - } - return message; + return message; }; /** - * Decodes a FeatureSupport message from the specified reader or buffer, length delimited. + * Decodes a GirlDetail message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.protobuf.FieldOptions.FeatureSupport + * @memberof cs.GirlDetail * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.FieldOptions.FeatureSupport} FeatureSupport + * @returns {cs.GirlDetail} GirlDetail * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - FeatureSupport.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); + GirlDetail.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); }; /** - * Verifies a FeatureSupport message. + * Verifies a GirlDetail message. * @function verify - * @memberof google.protobuf.FieldOptions.FeatureSupport + * @memberof cs.GirlDetail * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - FeatureSupport.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if ( - message.editionIntroduced != null && - message.hasOwnProperty("editionIntroduced") - ) - switch (message.editionIntroduced) { - default: - return "editionIntroduced: enum value expected"; - case 0: - case 900: - case 998: - case 999: - case 1000: - case 1001: - case 1: - case 2: - case 99997: - case 99998: - case 99999: - case 2147483647: - break; + 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; } - if ( - message.editionDeprecated != null && - message.hasOwnProperty("editionDeprecated") - ) - switch (message.editionDeprecated) { - default: - return "editionDeprecated: enum value expected"; - case 0: - case 900: - case 998: - case 999: - case 1000: - case 1001: - case 1: - case 2: - case 99997: - case 99998: - case 99999: - case 2147483647: - break; + if (message.desc != null && message.hasOwnProperty("desc")) + if (!$util.isString(message.desc)) + return "desc: string expected"; + if (message.pics != null && message.hasOwnProperty("pics")) { + if (!Array.isArray(message.pics)) + return "pics: array expected"; + for (var i = 0; i < message.pics.length; ++i) + if (!$util.isString(message.pics[i])) + return "pics: string[] expected"; } - if ( - message.deprecationWarning != null && - message.hasOwnProperty("deprecationWarning") - ) - if (!$util.isString(message.deprecationWarning)) - return "deprecationWarning: string expected"; - if ( - message.editionRemoved != null && - message.hasOwnProperty("editionRemoved") - ) - switch (message.editionRemoved) { - default: - return "editionRemoved: enum value expected"; - case 0: - case 900: - case 998: - case 999: - case 1000: - case 1001: - case 1: - case 2: - case 99997: - case 99998: - case 99999: - case 2147483647: - break; - } - return null; + return null; }; /** - * Creates a FeatureSupport message from a plain object. Also converts values to their respective internal types. + * Creates a GirlDetail message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.protobuf.FieldOptions.FeatureSupport + * @memberof cs.GirlDetail * @static * @param {Object.} object Plain object - * @returns {google.protobuf.FieldOptions.FeatureSupport} FeatureSupport + * @returns {cs.GirlDetail} GirlDetail */ - FeatureSupport.fromObject = function fromObject(object) { - if ( - object instanceof $root.google.protobuf.FieldOptions.FeatureSupport - ) - return object; - var message = new $root.google.protobuf.FieldOptions.FeatureSupport(); - switch (object.editionIntroduced) { - default: - if (typeof object.editionIntroduced === "number") { - message.editionIntroduced = object.editionIntroduced; - break; - } - break; - case "EDITION_UNKNOWN": - case 0: - message.editionIntroduced = 0; - break; - case "EDITION_LEGACY": - case 900: - message.editionIntroduced = 900; - break; - case "EDITION_PROTO2": - case 998: - message.editionIntroduced = 998; - break; - case "EDITION_PROTO3": - case 999: - message.editionIntroduced = 999; - break; - case "EDITION_2023": - case 1000: - message.editionIntroduced = 1000; - break; - case "EDITION_2024": - case 1001: - message.editionIntroduced = 1001; - break; - case "EDITION_1_TEST_ONLY": - case 1: - message.editionIntroduced = 1; - break; - case "EDITION_2_TEST_ONLY": - case 2: - message.editionIntroduced = 2; - break; - case "EDITION_99997_TEST_ONLY": - case 99997: - message.editionIntroduced = 99997; - break; - case "EDITION_99998_TEST_ONLY": - case 99998: - message.editionIntroduced = 99998; - break; - case "EDITION_99999_TEST_ONLY": - case 99999: - message.editionIntroduced = 99999; - break; - case "EDITION_MAX": - case 2147483647: - message.editionIntroduced = 2147483647; - break; - } - switch (object.editionDeprecated) { - default: - if (typeof object.editionDeprecated === "number") { - message.editionDeprecated = object.editionDeprecated; - break; - } - break; - case "EDITION_UNKNOWN": - case 0: - message.editionDeprecated = 0; - break; - case "EDITION_LEGACY": - case 900: - message.editionDeprecated = 900; - break; - case "EDITION_PROTO2": - case 998: - message.editionDeprecated = 998; - break; - case "EDITION_PROTO3": - case 999: - message.editionDeprecated = 999; - break; - case "EDITION_2023": - case 1000: - message.editionDeprecated = 1000; - break; - case "EDITION_2024": - case 1001: - message.editionDeprecated = 1001; - break; - case "EDITION_1_TEST_ONLY": - case 1: - message.editionDeprecated = 1; - break; - case "EDITION_2_TEST_ONLY": - case 2: - message.editionDeprecated = 2; - break; - case "EDITION_99997_TEST_ONLY": - case 99997: - message.editionDeprecated = 99997; - break; - case "EDITION_99998_TEST_ONLY": - case 99998: - message.editionDeprecated = 99998; - break; - case "EDITION_99999_TEST_ONLY": - case 99999: - message.editionDeprecated = 99999; - break; - case "EDITION_MAX": - case 2147483647: - message.editionDeprecated = 2147483647; - break; - } - if (object.deprecationWarning != null) - message.deprecationWarning = String(object.deprecationWarning); - switch (object.editionRemoved) { - default: - if (typeof object.editionRemoved === "number") { - message.editionRemoved = object.editionRemoved; - break; - } - break; - case "EDITION_UNKNOWN": - case 0: - message.editionRemoved = 0; - break; - case "EDITION_LEGACY": - case 900: - message.editionRemoved = 900; - break; - case "EDITION_PROTO2": - case 998: - message.editionRemoved = 998; - break; - case "EDITION_PROTO3": - case 999: - message.editionRemoved = 999; - break; - case "EDITION_2023": - case 1000: - message.editionRemoved = 1000; - break; - case "EDITION_2024": - case 1001: - message.editionRemoved = 1001; - break; - case "EDITION_1_TEST_ONLY": - case 1: - message.editionRemoved = 1; - break; - case "EDITION_2_TEST_ONLY": - case 2: - message.editionRemoved = 2; - break; - case "EDITION_99997_TEST_ONLY": - case 99997: - message.editionRemoved = 99997; - break; - case "EDITION_99998_TEST_ONLY": - case 99998: - message.editionRemoved = 99998; - break; - case "EDITION_99999_TEST_ONLY": - case 99999: - message.editionRemoved = 99999; - break; - case "EDITION_MAX": - case 2147483647: - message.editionRemoved = 2147483647; - break; - } - return message; + 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); + if (object.pics) { + if (!Array.isArray(object.pics)) + throw TypeError(".cs.GirlDetail.pics: array expected"); + message.pics = []; + for (var i = 0; i < object.pics.length; ++i) + message.pics[i] = String(object.pics[i]); + } + return message; }; /** - * Creates a plain object from a FeatureSupport message. Also converts values to other types if specified. + * Creates a plain object from a GirlDetail message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.FieldOptions.FeatureSupport + * @memberof cs.GirlDetail * @static - * @param {google.protobuf.FieldOptions.FeatureSupport} message FeatureSupport + * @param {cs.GirlDetail} message GirlDetail * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - FeatureSupport.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.defaults) { - object.editionIntroduced = - options.enums === String ? "EDITION_UNKNOWN" : 0; - object.editionDeprecated = - options.enums === String ? "EDITION_UNKNOWN" : 0; - object.deprecationWarning = ""; - object.editionRemoved = - options.enums === String ? "EDITION_UNKNOWN" : 0; - } - if ( - message.editionIntroduced != null && - message.hasOwnProperty("editionIntroduced") - ) - object.editionIntroduced = - options.enums === String - ? $root.google.protobuf.Edition[message.editionIntroduced] === - undefined - ? message.editionIntroduced - : $root.google.protobuf.Edition[message.editionIntroduced] - : message.editionIntroduced; - if ( - message.editionDeprecated != null && - message.hasOwnProperty("editionDeprecated") - ) - object.editionDeprecated = - options.enums === String - ? $root.google.protobuf.Edition[message.editionDeprecated] === - undefined - ? message.editionDeprecated - : $root.google.protobuf.Edition[message.editionDeprecated] - : message.editionDeprecated; - if ( - message.deprecationWarning != null && - message.hasOwnProperty("deprecationWarning") - ) - object.deprecationWarning = message.deprecationWarning; - if ( - message.editionRemoved != null && - message.hasOwnProperty("editionRemoved") - ) - object.editionRemoved = - options.enums === String - ? $root.google.protobuf.Edition[message.editionRemoved] === - undefined - ? message.editionRemoved - : $root.google.protobuf.Edition[message.editionRemoved] - : message.editionRemoved; - return object; + GirlDetail.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) + object.pics = []; + if (options.defaults) { + object.brief = null; + object.desc = ""; + } + 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; + if (message.pics && message.pics.length) { + object.pics = []; + for (var j = 0; j < message.pics.length; ++j) + object.pics[j] = message.pics[j]; + } + return object; }; /** - * Converts this FeatureSupport to JSON. + * Converts this GirlDetail to JSON. * @function toJSON - * @memberof google.protobuf.FieldOptions.FeatureSupport + * @memberof cs.GirlDetail * @instance * @returns {Object.} JSON object */ - FeatureSupport.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + GirlDetail.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for FeatureSupport + * Gets the default type url for GirlDetail * @function getTypeUrl - * @memberof google.protobuf.FieldOptions.FeatureSupport + * @memberof cs.GirlDetail * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - FeatureSupport.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.FieldOptions.FeatureSupport"; + GirlDetail.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/cs.GirlDetail"; }; - return FeatureSupport; - })(); - - return FieldOptions; + return GirlDetail; })(); - protobuf.OneofOptions = (function () { - /** - * Properties of an OneofOptions. - * @memberof google.protobuf - * @interface IOneofOptions - * @property {google.protobuf.IFeatureSet|null} [features] OneofOptions features - * @property {Array.|null} [uninterpretedOption] OneofOptions uninterpretedOption - */ + cs.CSDailyRecommendReq = (function() { - /** - * Constructs a new OneofOptions. - * @memberof google.protobuf - * @classdesc Represents an OneofOptions. - * @implements IOneofOptions - * @constructor - * @param {google.protobuf.IOneofOptions=} [properties] Properties to set - */ - function OneofOptions(properties) { - this.uninterpretedOption = []; - 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]]; - } - - /** - * OneofOptions features. - * @member {google.protobuf.IFeatureSet|null|undefined} features - * @memberof google.protobuf.OneofOptions - * @instance - */ - OneofOptions.prototype.features = null; - - /** - * OneofOptions uninterpretedOption. - * @member {Array.} uninterpretedOption - * @memberof google.protobuf.OneofOptions - * @instance - */ - OneofOptions.prototype.uninterpretedOption = $util.emptyArray; - - /** - * Creates a new OneofOptions instance using the specified properties. - * @function create - * @memberof google.protobuf.OneofOptions - * @static - * @param {google.protobuf.IOneofOptions=} [properties] Properties to set - * @returns {google.protobuf.OneofOptions} OneofOptions instance - */ - OneofOptions.create = function create(properties) { - return new OneofOptions(properties); - }; - - /** - * Encodes the specified OneofOptions message. Does not implicitly {@link google.protobuf.OneofOptions.verify|verify} messages. - * @function encode - * @memberof google.protobuf.OneofOptions - * @static - * @param {google.protobuf.IOneofOptions} message OneofOptions message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - OneofOptions.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if ( - message.features != null && - Object.hasOwnProperty.call(message, "features") - ) - $root.google.protobuf.FeatureSet.encode( - message.features, - writer.uint32(/* id 1, wireType 2 =*/ 10).fork() - ).ldelim(); - if ( - message.uninterpretedOption != null && - message.uninterpretedOption.length - ) - for (var i = 0; i < message.uninterpretedOption.length; ++i) - $root.google.protobuf.UninterpretedOption.encode( - message.uninterpretedOption[i], - writer.uint32(/* id 999, wireType 2 =*/ 7994).fork() - ).ldelim(); - return writer; - }; - - /** - * Encodes the specified OneofOptions message, length delimited. Does not implicitly {@link google.protobuf.OneofOptions.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.OneofOptions - * @static - * @param {google.protobuf.IOneofOptions} message OneofOptions message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - OneofOptions.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes an OneofOptions message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.OneofOptions - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.OneofOptions} OneofOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - OneofOptions.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.google.protobuf.OneofOptions(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - message.features = $root.google.protobuf.FeatureSet.decode( - reader, - reader.uint32() - ); - break; - } - case 999: { - if ( - !( - message.uninterpretedOption && - message.uninterpretedOption.length - ) - ) - message.uninterpretedOption = []; - message.uninterpretedOption.push( - $root.google.protobuf.UninterpretedOption.decode( - reader, - reader.uint32() - ) - ); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes an OneofOptions message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.OneofOptions - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.OneofOptions} OneofOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - OneofOptions.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies an OneofOptions message. - * @function verify - * @memberof google.protobuf.OneofOptions - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - OneofOptions.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.features != null && message.hasOwnProperty("features")) { - var error = $root.google.protobuf.FeatureSet.verify(message.features); - if (error) return "features." + error; - } - if ( - message.uninterpretedOption != null && - message.hasOwnProperty("uninterpretedOption") - ) { - if (!Array.isArray(message.uninterpretedOption)) - return "uninterpretedOption: array expected"; - for (var i = 0; i < message.uninterpretedOption.length; ++i) { - var error = $root.google.protobuf.UninterpretedOption.verify( - message.uninterpretedOption[i] - ); - if (error) return "uninterpretedOption." + error; - } - } - return null; - }; - - /** - * Creates an OneofOptions message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.OneofOptions - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.OneofOptions} OneofOptions - */ - OneofOptions.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.OneofOptions) return object; - var message = new $root.google.protobuf.OneofOptions(); - if (object.features != null) { - if (typeof object.features !== "object") - throw TypeError( - ".google.protobuf.OneofOptions.features: object expected" - ); - message.features = $root.google.protobuf.FeatureSet.fromObject( - object.features - ); - } - if (object.uninterpretedOption) { - if (!Array.isArray(object.uninterpretedOption)) - throw TypeError( - ".google.protobuf.OneofOptions.uninterpretedOption: array expected" - ); - message.uninterpretedOption = []; - for (var i = 0; i < object.uninterpretedOption.length; ++i) { - if (typeof object.uninterpretedOption[i] !== "object") - throw TypeError( - ".google.protobuf.OneofOptions.uninterpretedOption: object expected" - ); - message.uninterpretedOption[i] = - $root.google.protobuf.UninterpretedOption.fromObject( - object.uninterpretedOption[i] - ); - } - } - return message; - }; - - /** - * Creates a plain object from an OneofOptions message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.OneofOptions - * @static - * @param {google.protobuf.OneofOptions} message OneofOptions - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - OneofOptions.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.arrays || options.defaults) object.uninterpretedOption = []; - if (options.defaults) object.features = null; - if (message.features != null && message.hasOwnProperty("features")) - object.features = $root.google.protobuf.FeatureSet.toObject( - message.features, - options - ); - if (message.uninterpretedOption && message.uninterpretedOption.length) { - object.uninterpretedOption = []; - for (var j = 0; j < message.uninterpretedOption.length; ++j) - object.uninterpretedOption[j] = - $root.google.protobuf.UninterpretedOption.toObject( - message.uninterpretedOption[j], - options - ); - } - return object; - }; - - /** - * Converts this OneofOptions to JSON. - * @function toJSON - * @memberof google.protobuf.OneofOptions - * @instance - * @returns {Object.} JSON object - */ - OneofOptions.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for OneofOptions - * @function getTypeUrl - * @memberof google.protobuf.OneofOptions - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - OneofOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.OneofOptions"; - }; - - return OneofOptions; - })(); - - protobuf.EnumOptions = (function () { - /** - * Properties of an EnumOptions. - * @memberof google.protobuf - * @interface IEnumOptions - * @property {boolean|null} [allowAlias] EnumOptions allowAlias - * @property {boolean|null} [deprecated] EnumOptions deprecated - * @property {boolean|null} [deprecatedLegacyJsonFieldConflicts] EnumOptions deprecatedLegacyJsonFieldConflicts - * @property {google.protobuf.IFeatureSet|null} [features] EnumOptions features - * @property {Array.|null} [uninterpretedOption] EnumOptions uninterpretedOption - */ - - /** - * Constructs a new EnumOptions. - * @memberof google.protobuf - * @classdesc Represents an EnumOptions. - * @implements IEnumOptions - * @constructor - * @param {google.protobuf.IEnumOptions=} [properties] Properties to set - */ - function EnumOptions(properties) { - this.uninterpretedOption = []; - 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]]; - } - - /** - * EnumOptions allowAlias. - * @member {boolean} allowAlias - * @memberof google.protobuf.EnumOptions - * @instance - */ - EnumOptions.prototype.allowAlias = false; - - /** - * EnumOptions deprecated. - * @member {boolean} deprecated - * @memberof google.protobuf.EnumOptions - * @instance - */ - EnumOptions.prototype.deprecated = false; - - /** - * EnumOptions deprecatedLegacyJsonFieldConflicts. - * @member {boolean} deprecatedLegacyJsonFieldConflicts - * @memberof google.protobuf.EnumOptions - * @instance - */ - EnumOptions.prototype.deprecatedLegacyJsonFieldConflicts = false; - - /** - * EnumOptions features. - * @member {google.protobuf.IFeatureSet|null|undefined} features - * @memberof google.protobuf.EnumOptions - * @instance - */ - EnumOptions.prototype.features = null; - - /** - * EnumOptions uninterpretedOption. - * @member {Array.} uninterpretedOption - * @memberof google.protobuf.EnumOptions - * @instance - */ - EnumOptions.prototype.uninterpretedOption = $util.emptyArray; - - /** - * Creates a new EnumOptions instance using the specified properties. - * @function create - * @memberof google.protobuf.EnumOptions - * @static - * @param {google.protobuf.IEnumOptions=} [properties] Properties to set - * @returns {google.protobuf.EnumOptions} EnumOptions instance - */ - EnumOptions.create = function create(properties) { - return new EnumOptions(properties); - }; - - /** - * Encodes the specified EnumOptions message. Does not implicitly {@link google.protobuf.EnumOptions.verify|verify} messages. - * @function encode - * @memberof google.protobuf.EnumOptions - * @static - * @param {google.protobuf.IEnumOptions} message EnumOptions message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EnumOptions.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if ( - message.allowAlias != null && - Object.hasOwnProperty.call(message, "allowAlias") - ) - writer.uint32(/* id 2, wireType 0 =*/ 16).bool(message.allowAlias); - if ( - message.deprecated != null && - Object.hasOwnProperty.call(message, "deprecated") - ) - writer.uint32(/* id 3, wireType 0 =*/ 24).bool(message.deprecated); - if ( - message.deprecatedLegacyJsonFieldConflicts != null && - Object.hasOwnProperty.call( - message, - "deprecatedLegacyJsonFieldConflicts" - ) - ) - writer - .uint32(/* id 6, wireType 0 =*/ 48) - .bool(message.deprecatedLegacyJsonFieldConflicts); - if ( - message.features != null && - Object.hasOwnProperty.call(message, "features") - ) - $root.google.protobuf.FeatureSet.encode( - message.features, - writer.uint32(/* id 7, wireType 2 =*/ 58).fork() - ).ldelim(); - if ( - message.uninterpretedOption != null && - message.uninterpretedOption.length - ) - for (var i = 0; i < message.uninterpretedOption.length; ++i) - $root.google.protobuf.UninterpretedOption.encode( - message.uninterpretedOption[i], - writer.uint32(/* id 999, wireType 2 =*/ 7994).fork() - ).ldelim(); - return writer; - }; - - /** - * Encodes the specified EnumOptions message, length delimited. Does not implicitly {@link google.protobuf.EnumOptions.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.EnumOptions - * @static - * @param {google.protobuf.IEnumOptions} message EnumOptions message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EnumOptions.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes an EnumOptions message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.EnumOptions - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.EnumOptions} EnumOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - EnumOptions.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.google.protobuf.EnumOptions(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 2: { - message.allowAlias = reader.bool(); - break; - } - case 3: { - message.deprecated = reader.bool(); - break; - } - case 6: { - message.deprecatedLegacyJsonFieldConflicts = reader.bool(); - break; - } - case 7: { - message.features = $root.google.protobuf.FeatureSet.decode( - reader, - reader.uint32() - ); - break; - } - case 999: { - if ( - !( - message.uninterpretedOption && - message.uninterpretedOption.length - ) - ) - message.uninterpretedOption = []; - message.uninterpretedOption.push( - $root.google.protobuf.UninterpretedOption.decode( - reader, - reader.uint32() - ) - ); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes an EnumOptions message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.EnumOptions - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.EnumOptions} EnumOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - EnumOptions.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies an EnumOptions message. - * @function verify - * @memberof google.protobuf.EnumOptions - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - EnumOptions.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.allowAlias != null && message.hasOwnProperty("allowAlias")) - if (typeof message.allowAlias !== "boolean") - return "allowAlias: boolean expected"; - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - if (typeof message.deprecated !== "boolean") - return "deprecated: boolean expected"; - if ( - message.deprecatedLegacyJsonFieldConflicts != null && - message.hasOwnProperty("deprecatedLegacyJsonFieldConflicts") - ) - if (typeof message.deprecatedLegacyJsonFieldConflicts !== "boolean") - return "deprecatedLegacyJsonFieldConflicts: boolean expected"; - if (message.features != null && message.hasOwnProperty("features")) { - var error = $root.google.protobuf.FeatureSet.verify(message.features); - if (error) return "features." + error; - } - if ( - message.uninterpretedOption != null && - message.hasOwnProperty("uninterpretedOption") - ) { - if (!Array.isArray(message.uninterpretedOption)) - return "uninterpretedOption: array expected"; - for (var i = 0; i < message.uninterpretedOption.length; ++i) { - var error = $root.google.protobuf.UninterpretedOption.verify( - message.uninterpretedOption[i] - ); - if (error) return "uninterpretedOption." + error; - } - } - return null; - }; - - /** - * Creates an EnumOptions message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.EnumOptions - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.EnumOptions} EnumOptions - */ - EnumOptions.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.EnumOptions) return object; - var message = new $root.google.protobuf.EnumOptions(); - if (object.allowAlias != null) - message.allowAlias = Boolean(object.allowAlias); - if (object.deprecated != null) - message.deprecated = Boolean(object.deprecated); - if (object.deprecatedLegacyJsonFieldConflicts != null) - message.deprecatedLegacyJsonFieldConflicts = Boolean( - object.deprecatedLegacyJsonFieldConflicts - ); - if (object.features != null) { - if (typeof object.features !== "object") - throw TypeError( - ".google.protobuf.EnumOptions.features: object expected" - ); - message.features = $root.google.protobuf.FeatureSet.fromObject( - object.features - ); - } - if (object.uninterpretedOption) { - if (!Array.isArray(object.uninterpretedOption)) - throw TypeError( - ".google.protobuf.EnumOptions.uninterpretedOption: array expected" - ); - message.uninterpretedOption = []; - for (var i = 0; i < object.uninterpretedOption.length; ++i) { - if (typeof object.uninterpretedOption[i] !== "object") - throw TypeError( - ".google.protobuf.EnumOptions.uninterpretedOption: object expected" - ); - message.uninterpretedOption[i] = - $root.google.protobuf.UninterpretedOption.fromObject( - object.uninterpretedOption[i] - ); - } - } - return message; - }; - - /** - * Creates a plain object from an EnumOptions message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.EnumOptions - * @static - * @param {google.protobuf.EnumOptions} message EnumOptions - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - EnumOptions.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.arrays || options.defaults) object.uninterpretedOption = []; - if (options.defaults) { - object.allowAlias = false; - object.deprecated = false; - object.deprecatedLegacyJsonFieldConflicts = false; - object.features = null; - } - if (message.allowAlias != null && message.hasOwnProperty("allowAlias")) - object.allowAlias = message.allowAlias; - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - object.deprecated = message.deprecated; - if ( - message.deprecatedLegacyJsonFieldConflicts != null && - message.hasOwnProperty("deprecatedLegacyJsonFieldConflicts") - ) - object.deprecatedLegacyJsonFieldConflicts = - message.deprecatedLegacyJsonFieldConflicts; - if (message.features != null && message.hasOwnProperty("features")) - object.features = $root.google.protobuf.FeatureSet.toObject( - message.features, - options - ); - if (message.uninterpretedOption && message.uninterpretedOption.length) { - object.uninterpretedOption = []; - for (var j = 0; j < message.uninterpretedOption.length; ++j) - object.uninterpretedOption[j] = - $root.google.protobuf.UninterpretedOption.toObject( - message.uninterpretedOption[j], - options - ); - } - return object; - }; - - /** - * Converts this EnumOptions to JSON. - * @function toJSON - * @memberof google.protobuf.EnumOptions - * @instance - * @returns {Object.} JSON object - */ - EnumOptions.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for EnumOptions - * @function getTypeUrl - * @memberof google.protobuf.EnumOptions - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - EnumOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.EnumOptions"; - }; - - return EnumOptions; - })(); - - protobuf.EnumValueOptions = (function () { - /** - * Properties of an EnumValueOptions. - * @memberof google.protobuf - * @interface IEnumValueOptions - * @property {boolean|null} [deprecated] EnumValueOptions deprecated - * @property {google.protobuf.IFeatureSet|null} [features] EnumValueOptions features - * @property {boolean|null} [debugRedact] EnumValueOptions debugRedact - * @property {google.protobuf.FieldOptions.IFeatureSupport|null} [featureSupport] EnumValueOptions featureSupport - * @property {Array.|null} [uninterpretedOption] EnumValueOptions uninterpretedOption - */ - - /** - * Constructs a new EnumValueOptions. - * @memberof google.protobuf - * @classdesc Represents an EnumValueOptions. - * @implements IEnumValueOptions - * @constructor - * @param {google.protobuf.IEnumValueOptions=} [properties] Properties to set - */ - function EnumValueOptions(properties) { - this.uninterpretedOption = []; - 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]]; - } - - /** - * EnumValueOptions deprecated. - * @member {boolean} deprecated - * @memberof google.protobuf.EnumValueOptions - * @instance - */ - EnumValueOptions.prototype.deprecated = false; - - /** - * EnumValueOptions features. - * @member {google.protobuf.IFeatureSet|null|undefined} features - * @memberof google.protobuf.EnumValueOptions - * @instance - */ - EnumValueOptions.prototype.features = null; - - /** - * EnumValueOptions debugRedact. - * @member {boolean} debugRedact - * @memberof google.protobuf.EnumValueOptions - * @instance - */ - EnumValueOptions.prototype.debugRedact = false; - - /** - * EnumValueOptions featureSupport. - * @member {google.protobuf.FieldOptions.IFeatureSupport|null|undefined} featureSupport - * @memberof google.protobuf.EnumValueOptions - * @instance - */ - EnumValueOptions.prototype.featureSupport = null; - - /** - * EnumValueOptions uninterpretedOption. - * @member {Array.} uninterpretedOption - * @memberof google.protobuf.EnumValueOptions - * @instance - */ - EnumValueOptions.prototype.uninterpretedOption = $util.emptyArray; - - /** - * Creates a new EnumValueOptions instance using the specified properties. - * @function create - * @memberof google.protobuf.EnumValueOptions - * @static - * @param {google.protobuf.IEnumValueOptions=} [properties] Properties to set - * @returns {google.protobuf.EnumValueOptions} EnumValueOptions instance - */ - EnumValueOptions.create = function create(properties) { - return new EnumValueOptions(properties); - }; - - /** - * Encodes the specified EnumValueOptions message. Does not implicitly {@link google.protobuf.EnumValueOptions.verify|verify} messages. - * @function encode - * @memberof google.protobuf.EnumValueOptions - * @static - * @param {google.protobuf.IEnumValueOptions} message EnumValueOptions message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EnumValueOptions.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if ( - message.deprecated != null && - Object.hasOwnProperty.call(message, "deprecated") - ) - writer.uint32(/* id 1, wireType 0 =*/ 8).bool(message.deprecated); - if ( - message.features != null && - Object.hasOwnProperty.call(message, "features") - ) - $root.google.protobuf.FeatureSet.encode( - message.features, - writer.uint32(/* id 2, wireType 2 =*/ 18).fork() - ).ldelim(); - if ( - message.debugRedact != null && - Object.hasOwnProperty.call(message, "debugRedact") - ) - writer.uint32(/* id 3, wireType 0 =*/ 24).bool(message.debugRedact); - if ( - message.featureSupport != null && - Object.hasOwnProperty.call(message, "featureSupport") - ) - $root.google.protobuf.FieldOptions.FeatureSupport.encode( - message.featureSupport, - writer.uint32(/* id 4, wireType 2 =*/ 34).fork() - ).ldelim(); - if ( - message.uninterpretedOption != null && - message.uninterpretedOption.length - ) - for (var i = 0; i < message.uninterpretedOption.length; ++i) - $root.google.protobuf.UninterpretedOption.encode( - message.uninterpretedOption[i], - writer.uint32(/* id 999, wireType 2 =*/ 7994).fork() - ).ldelim(); - return writer; - }; - - /** - * Encodes the specified EnumValueOptions message, length delimited. Does not implicitly {@link google.protobuf.EnumValueOptions.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.EnumValueOptions - * @static - * @param {google.protobuf.IEnumValueOptions} message EnumValueOptions message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EnumValueOptions.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes an EnumValueOptions message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.EnumValueOptions - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.EnumValueOptions} EnumValueOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - EnumValueOptions.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.google.protobuf.EnumValueOptions(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - message.deprecated = reader.bool(); - break; - } - case 2: { - message.features = $root.google.protobuf.FeatureSet.decode( - reader, - reader.uint32() - ); - break; - } - case 3: { - message.debugRedact = reader.bool(); - break; - } - case 4: { - message.featureSupport = - $root.google.protobuf.FieldOptions.FeatureSupport.decode( - reader, - reader.uint32() - ); - break; - } - case 999: { - if ( - !( - message.uninterpretedOption && - message.uninterpretedOption.length - ) - ) - message.uninterpretedOption = []; - message.uninterpretedOption.push( - $root.google.protobuf.UninterpretedOption.decode( - reader, - reader.uint32() - ) - ); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes an EnumValueOptions message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.EnumValueOptions - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.EnumValueOptions} EnumValueOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - EnumValueOptions.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies an EnumValueOptions message. - * @function verify - * @memberof google.protobuf.EnumValueOptions - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - EnumValueOptions.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - if (typeof message.deprecated !== "boolean") - return "deprecated: boolean expected"; - if (message.features != null && message.hasOwnProperty("features")) { - var error = $root.google.protobuf.FeatureSet.verify(message.features); - if (error) return "features." + error; - } - if ( - message.debugRedact != null && - message.hasOwnProperty("debugRedact") - ) - if (typeof message.debugRedact !== "boolean") - return "debugRedact: boolean expected"; - if ( - message.featureSupport != null && - message.hasOwnProperty("featureSupport") - ) { - var error = $root.google.protobuf.FieldOptions.FeatureSupport.verify( - message.featureSupport - ); - if (error) return "featureSupport." + error; - } - if ( - message.uninterpretedOption != null && - message.hasOwnProperty("uninterpretedOption") - ) { - if (!Array.isArray(message.uninterpretedOption)) - return "uninterpretedOption: array expected"; - for (var i = 0; i < message.uninterpretedOption.length; ++i) { - var error = $root.google.protobuf.UninterpretedOption.verify( - message.uninterpretedOption[i] - ); - if (error) return "uninterpretedOption." + error; - } - } - return null; - }; - - /** - * Creates an EnumValueOptions message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.EnumValueOptions - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.EnumValueOptions} EnumValueOptions - */ - EnumValueOptions.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.EnumValueOptions) - return object; - var message = new $root.google.protobuf.EnumValueOptions(); - if (object.deprecated != null) - message.deprecated = Boolean(object.deprecated); - if (object.features != null) { - if (typeof object.features !== "object") - throw TypeError( - ".google.protobuf.EnumValueOptions.features: object expected" - ); - message.features = $root.google.protobuf.FeatureSet.fromObject( - object.features - ); - } - if (object.debugRedact != null) - message.debugRedact = Boolean(object.debugRedact); - if (object.featureSupport != null) { - if (typeof object.featureSupport !== "object") - throw TypeError( - ".google.protobuf.EnumValueOptions.featureSupport: object expected" - ); - message.featureSupport = - $root.google.protobuf.FieldOptions.FeatureSupport.fromObject( - object.featureSupport - ); - } - if (object.uninterpretedOption) { - if (!Array.isArray(object.uninterpretedOption)) - throw TypeError( - ".google.protobuf.EnumValueOptions.uninterpretedOption: array expected" - ); - message.uninterpretedOption = []; - for (var i = 0; i < object.uninterpretedOption.length; ++i) { - if (typeof object.uninterpretedOption[i] !== "object") - throw TypeError( - ".google.protobuf.EnumValueOptions.uninterpretedOption: object expected" - ); - message.uninterpretedOption[i] = - $root.google.protobuf.UninterpretedOption.fromObject( - object.uninterpretedOption[i] - ); - } - } - return message; - }; - - /** - * Creates a plain object from an EnumValueOptions message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.EnumValueOptions - * @static - * @param {google.protobuf.EnumValueOptions} message EnumValueOptions - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - EnumValueOptions.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.arrays || options.defaults) object.uninterpretedOption = []; - if (options.defaults) { - object.deprecated = false; - object.features = null; - object.debugRedact = false; - object.featureSupport = null; - } - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - object.deprecated = message.deprecated; - if (message.features != null && message.hasOwnProperty("features")) - object.features = $root.google.protobuf.FeatureSet.toObject( - message.features, - options - ); - if ( - message.debugRedact != null && - message.hasOwnProperty("debugRedact") - ) - object.debugRedact = message.debugRedact; - if ( - message.featureSupport != null && - message.hasOwnProperty("featureSupport") - ) - object.featureSupport = - $root.google.protobuf.FieldOptions.FeatureSupport.toObject( - message.featureSupport, - options - ); - if (message.uninterpretedOption && message.uninterpretedOption.length) { - object.uninterpretedOption = []; - for (var j = 0; j < message.uninterpretedOption.length; ++j) - object.uninterpretedOption[j] = - $root.google.protobuf.UninterpretedOption.toObject( - message.uninterpretedOption[j], - options - ); - } - return object; - }; - - /** - * Converts this EnumValueOptions to JSON. - * @function toJSON - * @memberof google.protobuf.EnumValueOptions - * @instance - * @returns {Object.} JSON object - */ - EnumValueOptions.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for EnumValueOptions - * @function getTypeUrl - * @memberof google.protobuf.EnumValueOptions - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - EnumValueOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.EnumValueOptions"; - }; - - return EnumValueOptions; - })(); - - protobuf.ServiceOptions = (function () { - /** - * Properties of a ServiceOptions. - * @memberof google.protobuf - * @interface IServiceOptions - * @property {google.protobuf.IFeatureSet|null} [features] ServiceOptions features - * @property {boolean|null} [deprecated] ServiceOptions deprecated - * @property {Array.|null} [uninterpretedOption] ServiceOptions uninterpretedOption - */ - - /** - * Constructs a new ServiceOptions. - * @memberof google.protobuf - * @classdesc Represents a ServiceOptions. - * @implements IServiceOptions - * @constructor - * @param {google.protobuf.IServiceOptions=} [properties] Properties to set - */ - function ServiceOptions(properties) { - this.uninterpretedOption = []; - 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]]; - } - - /** - * ServiceOptions features. - * @member {google.protobuf.IFeatureSet|null|undefined} features - * @memberof google.protobuf.ServiceOptions - * @instance - */ - ServiceOptions.prototype.features = null; - - /** - * ServiceOptions deprecated. - * @member {boolean} deprecated - * @memberof google.protobuf.ServiceOptions - * @instance - */ - ServiceOptions.prototype.deprecated = false; - - /** - * ServiceOptions uninterpretedOption. - * @member {Array.} uninterpretedOption - * @memberof google.protobuf.ServiceOptions - * @instance - */ - ServiceOptions.prototype.uninterpretedOption = $util.emptyArray; - - /** - * Creates a new ServiceOptions instance using the specified properties. - * @function create - * @memberof google.protobuf.ServiceOptions - * @static - * @param {google.protobuf.IServiceOptions=} [properties] Properties to set - * @returns {google.protobuf.ServiceOptions} ServiceOptions instance - */ - ServiceOptions.create = function create(properties) { - return new ServiceOptions(properties); - }; - - /** - * Encodes the specified ServiceOptions message. Does not implicitly {@link google.protobuf.ServiceOptions.verify|verify} messages. - * @function encode - * @memberof google.protobuf.ServiceOptions - * @static - * @param {google.protobuf.IServiceOptions} message ServiceOptions message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - ServiceOptions.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if ( - message.deprecated != null && - Object.hasOwnProperty.call(message, "deprecated") - ) - writer.uint32(/* id 33, wireType 0 =*/ 264).bool(message.deprecated); - if ( - message.features != null && - Object.hasOwnProperty.call(message, "features") - ) - $root.google.protobuf.FeatureSet.encode( - message.features, - writer.uint32(/* id 34, wireType 2 =*/ 274).fork() - ).ldelim(); - if ( - message.uninterpretedOption != null && - message.uninterpretedOption.length - ) - for (var i = 0; i < message.uninterpretedOption.length; ++i) - $root.google.protobuf.UninterpretedOption.encode( - message.uninterpretedOption[i], - writer.uint32(/* id 999, wireType 2 =*/ 7994).fork() - ).ldelim(); - return writer; - }; - - /** - * Encodes the specified ServiceOptions message, length delimited. Does not implicitly {@link google.protobuf.ServiceOptions.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.ServiceOptions - * @static - * @param {google.protobuf.IServiceOptions} message ServiceOptions message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - ServiceOptions.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a ServiceOptions message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.ServiceOptions - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.ServiceOptions} ServiceOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - ServiceOptions.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.google.protobuf.ServiceOptions(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 34: { - message.features = $root.google.protobuf.FeatureSet.decode( - reader, - reader.uint32() - ); - break; - } - case 33: { - message.deprecated = reader.bool(); - break; - } - case 999: { - if ( - !( - message.uninterpretedOption && - message.uninterpretedOption.length - ) - ) - message.uninterpretedOption = []; - message.uninterpretedOption.push( - $root.google.protobuf.UninterpretedOption.decode( - reader, - reader.uint32() - ) - ); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a ServiceOptions message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.ServiceOptions - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.ServiceOptions} ServiceOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - ServiceOptions.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a ServiceOptions message. - * @function verify - * @memberof google.protobuf.ServiceOptions - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - ServiceOptions.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.features != null && message.hasOwnProperty("features")) { - var error = $root.google.protobuf.FeatureSet.verify(message.features); - if (error) return "features." + error; - } - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - if (typeof message.deprecated !== "boolean") - return "deprecated: boolean expected"; - if ( - message.uninterpretedOption != null && - message.hasOwnProperty("uninterpretedOption") - ) { - if (!Array.isArray(message.uninterpretedOption)) - return "uninterpretedOption: array expected"; - for (var i = 0; i < message.uninterpretedOption.length; ++i) { - var error = $root.google.protobuf.UninterpretedOption.verify( - message.uninterpretedOption[i] - ); - if (error) return "uninterpretedOption." + error; - } - } - return null; - }; - - /** - * Creates a ServiceOptions message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.ServiceOptions - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.ServiceOptions} ServiceOptions - */ - ServiceOptions.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.ServiceOptions) - return object; - var message = new $root.google.protobuf.ServiceOptions(); - if (object.features != null) { - if (typeof object.features !== "object") - throw TypeError( - ".google.protobuf.ServiceOptions.features: object expected" - ); - message.features = $root.google.protobuf.FeatureSet.fromObject( - object.features - ); - } - if (object.deprecated != null) - message.deprecated = Boolean(object.deprecated); - if (object.uninterpretedOption) { - if (!Array.isArray(object.uninterpretedOption)) - throw TypeError( - ".google.protobuf.ServiceOptions.uninterpretedOption: array expected" - ); - message.uninterpretedOption = []; - for (var i = 0; i < object.uninterpretedOption.length; ++i) { - if (typeof object.uninterpretedOption[i] !== "object") - throw TypeError( - ".google.protobuf.ServiceOptions.uninterpretedOption: object expected" - ); - message.uninterpretedOption[i] = - $root.google.protobuf.UninterpretedOption.fromObject( - object.uninterpretedOption[i] - ); - } - } - return message; - }; - - /** - * Creates a plain object from a ServiceOptions message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.ServiceOptions - * @static - * @param {google.protobuf.ServiceOptions} message ServiceOptions - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - ServiceOptions.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.arrays || options.defaults) object.uninterpretedOption = []; - if (options.defaults) { - object.deprecated = false; - object.features = null; - } - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - object.deprecated = message.deprecated; - if (message.features != null && message.hasOwnProperty("features")) - object.features = $root.google.protobuf.FeatureSet.toObject( - message.features, - options - ); - if (message.uninterpretedOption && message.uninterpretedOption.length) { - object.uninterpretedOption = []; - for (var j = 0; j < message.uninterpretedOption.length; ++j) - object.uninterpretedOption[j] = - $root.google.protobuf.UninterpretedOption.toObject( - message.uninterpretedOption[j], - options - ); - } - return object; - }; - - /** - * Converts this ServiceOptions to JSON. - * @function toJSON - * @memberof google.protobuf.ServiceOptions - * @instance - * @returns {Object.} JSON object - */ - ServiceOptions.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for ServiceOptions - * @function getTypeUrl - * @memberof google.protobuf.ServiceOptions - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - ServiceOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.ServiceOptions"; - }; - - return ServiceOptions; - })(); - - protobuf.MethodOptions = (function () { - /** - * Properties of a MethodOptions. - * @memberof google.protobuf - * @interface IMethodOptions - * @property {boolean|null} [deprecated] MethodOptions deprecated - * @property {google.protobuf.MethodOptions.IdempotencyLevel|null} [idempotencyLevel] MethodOptions idempotencyLevel - * @property {google.protobuf.IFeatureSet|null} [features] MethodOptions features - * @property {Array.|null} [uninterpretedOption] MethodOptions uninterpretedOption - */ - - /** - * Constructs a new MethodOptions. - * @memberof google.protobuf - * @classdesc Represents a MethodOptions. - * @implements IMethodOptions - * @constructor - * @param {google.protobuf.IMethodOptions=} [properties] Properties to set - */ - function MethodOptions(properties) { - this.uninterpretedOption = []; - 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]]; - } - - /** - * MethodOptions deprecated. - * @member {boolean} deprecated - * @memberof google.protobuf.MethodOptions - * @instance - */ - MethodOptions.prototype.deprecated = false; - - /** - * MethodOptions idempotencyLevel. - * @member {google.protobuf.MethodOptions.IdempotencyLevel} idempotencyLevel - * @memberof google.protobuf.MethodOptions - * @instance - */ - MethodOptions.prototype.idempotencyLevel = 0; - - /** - * MethodOptions features. - * @member {google.protobuf.IFeatureSet|null|undefined} features - * @memberof google.protobuf.MethodOptions - * @instance - */ - MethodOptions.prototype.features = null; - - /** - * MethodOptions uninterpretedOption. - * @member {Array.} uninterpretedOption - * @memberof google.protobuf.MethodOptions - * @instance - */ - MethodOptions.prototype.uninterpretedOption = $util.emptyArray; - - /** - * Creates a new MethodOptions instance using the specified properties. - * @function create - * @memberof google.protobuf.MethodOptions - * @static - * @param {google.protobuf.IMethodOptions=} [properties] Properties to set - * @returns {google.protobuf.MethodOptions} MethodOptions instance - */ - MethodOptions.create = function create(properties) { - return new MethodOptions(properties); - }; - - /** - * Encodes the specified MethodOptions message. Does not implicitly {@link google.protobuf.MethodOptions.verify|verify} messages. - * @function encode - * @memberof google.protobuf.MethodOptions - * @static - * @param {google.protobuf.IMethodOptions} message MethodOptions message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - MethodOptions.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if ( - message.deprecated != null && - Object.hasOwnProperty.call(message, "deprecated") - ) - writer.uint32(/* id 33, wireType 0 =*/ 264).bool(message.deprecated); - if ( - message.idempotencyLevel != null && - Object.hasOwnProperty.call(message, "idempotencyLevel") - ) - writer - .uint32(/* id 34, wireType 0 =*/ 272) - .int32(message.idempotencyLevel); - if ( - message.features != null && - Object.hasOwnProperty.call(message, "features") - ) - $root.google.protobuf.FeatureSet.encode( - message.features, - writer.uint32(/* id 35, wireType 2 =*/ 282).fork() - ).ldelim(); - if ( - message.uninterpretedOption != null && - message.uninterpretedOption.length - ) - for (var i = 0; i < message.uninterpretedOption.length; ++i) - $root.google.protobuf.UninterpretedOption.encode( - message.uninterpretedOption[i], - writer.uint32(/* id 999, wireType 2 =*/ 7994).fork() - ).ldelim(); - return writer; - }; - - /** - * Encodes the specified MethodOptions message, length delimited. Does not implicitly {@link google.protobuf.MethodOptions.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.MethodOptions - * @static - * @param {google.protobuf.IMethodOptions} message MethodOptions message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - MethodOptions.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a MethodOptions message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.MethodOptions - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.MethodOptions} MethodOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - MethodOptions.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.google.protobuf.MethodOptions(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 33: { - message.deprecated = reader.bool(); - break; - } - case 34: { - message.idempotencyLevel = reader.int32(); - break; - } - case 35: { - message.features = $root.google.protobuf.FeatureSet.decode( - reader, - reader.uint32() - ); - break; - } - case 999: { - if ( - !( - message.uninterpretedOption && - message.uninterpretedOption.length - ) - ) - message.uninterpretedOption = []; - message.uninterpretedOption.push( - $root.google.protobuf.UninterpretedOption.decode( - reader, - reader.uint32() - ) - ); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a MethodOptions message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.MethodOptions - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.MethodOptions} MethodOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - MethodOptions.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a MethodOptions message. - * @function verify - * @memberof google.protobuf.MethodOptions - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - MethodOptions.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - if (typeof message.deprecated !== "boolean") - return "deprecated: boolean expected"; - if ( - message.idempotencyLevel != null && - message.hasOwnProperty("idempotencyLevel") - ) - switch (message.idempotencyLevel) { - default: - return "idempotencyLevel: enum value expected"; - case 0: - case 1: - case 2: - break; - } - if (message.features != null && message.hasOwnProperty("features")) { - var error = $root.google.protobuf.FeatureSet.verify(message.features); - if (error) return "features." + error; - } - if ( - message.uninterpretedOption != null && - message.hasOwnProperty("uninterpretedOption") - ) { - if (!Array.isArray(message.uninterpretedOption)) - return "uninterpretedOption: array expected"; - for (var i = 0; i < message.uninterpretedOption.length; ++i) { - var error = $root.google.protobuf.UninterpretedOption.verify( - message.uninterpretedOption[i] - ); - if (error) return "uninterpretedOption." + error; - } - } - return null; - }; - - /** - * Creates a MethodOptions message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.MethodOptions - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.MethodOptions} MethodOptions - */ - MethodOptions.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.MethodOptions) - return object; - var message = new $root.google.protobuf.MethodOptions(); - if (object.deprecated != null) - message.deprecated = Boolean(object.deprecated); - switch (object.idempotencyLevel) { - default: - if (typeof object.idempotencyLevel === "number") { - message.idempotencyLevel = object.idempotencyLevel; - break; - } - break; - case "IDEMPOTENCY_UNKNOWN": - case 0: - message.idempotencyLevel = 0; - break; - case "NO_SIDE_EFFECTS": - case 1: - message.idempotencyLevel = 1; - break; - case "IDEMPOTENT": - case 2: - message.idempotencyLevel = 2; - break; - } - if (object.features != null) { - if (typeof object.features !== "object") - throw TypeError( - ".google.protobuf.MethodOptions.features: object expected" - ); - message.features = $root.google.protobuf.FeatureSet.fromObject( - object.features - ); - } - if (object.uninterpretedOption) { - if (!Array.isArray(object.uninterpretedOption)) - throw TypeError( - ".google.protobuf.MethodOptions.uninterpretedOption: array expected" - ); - message.uninterpretedOption = []; - for (var i = 0; i < object.uninterpretedOption.length; ++i) { - if (typeof object.uninterpretedOption[i] !== "object") - throw TypeError( - ".google.protobuf.MethodOptions.uninterpretedOption: object expected" - ); - message.uninterpretedOption[i] = - $root.google.protobuf.UninterpretedOption.fromObject( - object.uninterpretedOption[i] - ); - } - } - return message; - }; - - /** - * Creates a plain object from a MethodOptions message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.MethodOptions - * @static - * @param {google.protobuf.MethodOptions} message MethodOptions - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - MethodOptions.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.arrays || options.defaults) object.uninterpretedOption = []; - if (options.defaults) { - object.deprecated = false; - object.idempotencyLevel = - options.enums === String ? "IDEMPOTENCY_UNKNOWN" : 0; - object.features = null; - } - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - object.deprecated = message.deprecated; - if ( - message.idempotencyLevel != null && - message.hasOwnProperty("idempotencyLevel") - ) - object.idempotencyLevel = - options.enums === String - ? $root.google.protobuf.MethodOptions.IdempotencyLevel[ - message.idempotencyLevel - ] === undefined - ? message.idempotencyLevel - : $root.google.protobuf.MethodOptions.IdempotencyLevel[ - message.idempotencyLevel - ] - : message.idempotencyLevel; - if (message.features != null && message.hasOwnProperty("features")) - object.features = $root.google.protobuf.FeatureSet.toObject( - message.features, - options - ); - if (message.uninterpretedOption && message.uninterpretedOption.length) { - object.uninterpretedOption = []; - for (var j = 0; j < message.uninterpretedOption.length; ++j) - object.uninterpretedOption[j] = - $root.google.protobuf.UninterpretedOption.toObject( - message.uninterpretedOption[j], - options - ); - } - return object; - }; - - /** - * Converts this MethodOptions to JSON. - * @function toJSON - * @memberof google.protobuf.MethodOptions - * @instance - * @returns {Object.} JSON object - */ - MethodOptions.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for MethodOptions - * @function getTypeUrl - * @memberof google.protobuf.MethodOptions - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - MethodOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.MethodOptions"; - }; - - /** - * IdempotencyLevel enum. - * @name google.protobuf.MethodOptions.IdempotencyLevel - * @enum {number} - * @property {number} IDEMPOTENCY_UNKNOWN=0 IDEMPOTENCY_UNKNOWN value - * @property {number} NO_SIDE_EFFECTS=1 NO_SIDE_EFFECTS value - * @property {number} IDEMPOTENT=2 IDEMPOTENT value - */ - MethodOptions.IdempotencyLevel = (function () { - var valuesById = {}, - values = Object.create(valuesById); - values[(valuesById[0] = "IDEMPOTENCY_UNKNOWN")] = 0; - values[(valuesById[1] = "NO_SIDE_EFFECTS")] = 1; - values[(valuesById[2] = "IDEMPOTENT")] = 2; - return values; - })(); - - return MethodOptions; - })(); - - protobuf.UninterpretedOption = (function () { - /** - * Properties of an UninterpretedOption. - * @memberof google.protobuf - * @interface IUninterpretedOption - * @property {Array.|null} [name] UninterpretedOption name - * @property {string|null} [identifierValue] UninterpretedOption identifierValue - * @property {number|Long|null} [positiveIntValue] UninterpretedOption positiveIntValue - * @property {number|Long|null} [negativeIntValue] UninterpretedOption negativeIntValue - * @property {number|null} [doubleValue] UninterpretedOption doubleValue - * @property {Uint8Array|null} [stringValue] UninterpretedOption stringValue - * @property {string|null} [aggregateValue] UninterpretedOption aggregateValue - */ - - /** - * Constructs a new UninterpretedOption. - * @memberof google.protobuf - * @classdesc Represents an UninterpretedOption. - * @implements IUninterpretedOption - * @constructor - * @param {google.protobuf.IUninterpretedOption=} [properties] Properties to set - */ - function UninterpretedOption(properties) { - this.name = []; - 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]]; - } - - /** - * UninterpretedOption name. - * @member {Array.} name - * @memberof google.protobuf.UninterpretedOption - * @instance - */ - UninterpretedOption.prototype.name = $util.emptyArray; - - /** - * UninterpretedOption identifierValue. - * @member {string} identifierValue - * @memberof google.protobuf.UninterpretedOption - * @instance - */ - UninterpretedOption.prototype.identifierValue = ""; - - /** - * UninterpretedOption positiveIntValue. - * @member {number|Long} positiveIntValue - * @memberof google.protobuf.UninterpretedOption - * @instance - */ - UninterpretedOption.prototype.positiveIntValue = $util.Long - ? $util.Long.fromBits(0, 0, true) - : 0; - - /** - * UninterpretedOption negativeIntValue. - * @member {number|Long} negativeIntValue - * @memberof google.protobuf.UninterpretedOption - * @instance - */ - UninterpretedOption.prototype.negativeIntValue = $util.Long - ? $util.Long.fromBits(0, 0, false) - : 0; - - /** - * UninterpretedOption doubleValue. - * @member {number} doubleValue - * @memberof google.protobuf.UninterpretedOption - * @instance - */ - UninterpretedOption.prototype.doubleValue = 0; - - /** - * UninterpretedOption stringValue. - * @member {Uint8Array} stringValue - * @memberof google.protobuf.UninterpretedOption - * @instance - */ - UninterpretedOption.prototype.stringValue = $util.newBuffer([]); - - /** - * UninterpretedOption aggregateValue. - * @member {string} aggregateValue - * @memberof google.protobuf.UninterpretedOption - * @instance - */ - UninterpretedOption.prototype.aggregateValue = ""; - - /** - * Creates a new UninterpretedOption instance using the specified properties. - * @function create - * @memberof google.protobuf.UninterpretedOption - * @static - * @param {google.protobuf.IUninterpretedOption=} [properties] Properties to set - * @returns {google.protobuf.UninterpretedOption} UninterpretedOption instance - */ - UninterpretedOption.create = function create(properties) { - return new UninterpretedOption(properties); - }; - - /** - * Encodes the specified UninterpretedOption message. Does not implicitly {@link google.protobuf.UninterpretedOption.verify|verify} messages. - * @function encode - * @memberof google.protobuf.UninterpretedOption - * @static - * @param {google.protobuf.IUninterpretedOption} message UninterpretedOption message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - UninterpretedOption.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if (message.name != null && message.name.length) - for (var i = 0; i < message.name.length; ++i) - $root.google.protobuf.UninterpretedOption.NamePart.encode( - message.name[i], - writer.uint32(/* id 2, wireType 2 =*/ 18).fork() - ).ldelim(); - if ( - message.identifierValue != null && - Object.hasOwnProperty.call(message, "identifierValue") - ) - writer - .uint32(/* id 3, wireType 2 =*/ 26) - .string(message.identifierValue); - if ( - message.positiveIntValue != null && - Object.hasOwnProperty.call(message, "positiveIntValue") - ) - writer - .uint32(/* id 4, wireType 0 =*/ 32) - .uint64(message.positiveIntValue); - if ( - message.negativeIntValue != null && - Object.hasOwnProperty.call(message, "negativeIntValue") - ) - writer - .uint32(/* id 5, wireType 0 =*/ 40) - .int64(message.negativeIntValue); - if ( - message.doubleValue != null && - Object.hasOwnProperty.call(message, "doubleValue") - ) - writer.uint32(/* id 6, wireType 1 =*/ 49).double(message.doubleValue); - if ( - message.stringValue != null && - Object.hasOwnProperty.call(message, "stringValue") - ) - writer.uint32(/* id 7, wireType 2 =*/ 58).bytes(message.stringValue); - if ( - message.aggregateValue != null && - Object.hasOwnProperty.call(message, "aggregateValue") - ) - writer - .uint32(/* id 8, wireType 2 =*/ 66) - .string(message.aggregateValue); - return writer; - }; - - /** - * Encodes the specified UninterpretedOption message, length delimited. Does not implicitly {@link google.protobuf.UninterpretedOption.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.UninterpretedOption - * @static - * @param {google.protobuf.IUninterpretedOption} message UninterpretedOption message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - UninterpretedOption.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes an UninterpretedOption message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.UninterpretedOption - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.UninterpretedOption} UninterpretedOption - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - UninterpretedOption.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.google.protobuf.UninterpretedOption(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 2: { - if (!(message.name && message.name.length)) message.name = []; - message.name.push( - $root.google.protobuf.UninterpretedOption.NamePart.decode( - reader, - reader.uint32() - ) - ); - break; - } - case 3: { - message.identifierValue = reader.string(); - break; - } - case 4: { - message.positiveIntValue = reader.uint64(); - break; - } - case 5: { - message.negativeIntValue = reader.int64(); - break; - } - case 6: { - message.doubleValue = reader.double(); - break; - } - case 7: { - message.stringValue = reader.bytes(); - break; - } - case 8: { - message.aggregateValue = reader.string(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes an UninterpretedOption message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.UninterpretedOption - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.UninterpretedOption} UninterpretedOption - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - UninterpretedOption.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies an UninterpretedOption message. - * @function verify - * @memberof google.protobuf.UninterpretedOption - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - UninterpretedOption.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) { - if (!Array.isArray(message.name)) return "name: array expected"; - for (var i = 0; i < message.name.length; ++i) { - var error = - $root.google.protobuf.UninterpretedOption.NamePart.verify( - message.name[i] - ); - if (error) return "name." + error; - } - } - if ( - message.identifierValue != null && - message.hasOwnProperty("identifierValue") - ) - if (!$util.isString(message.identifierValue)) - return "identifierValue: string expected"; - if ( - message.positiveIntValue != null && - message.hasOwnProperty("positiveIntValue") - ) - if ( - !$util.isInteger(message.positiveIntValue) && - !( - message.positiveIntValue && - $util.isInteger(message.positiveIntValue.low) && - $util.isInteger(message.positiveIntValue.high) - ) - ) - return "positiveIntValue: integer|Long expected"; - if ( - message.negativeIntValue != null && - message.hasOwnProperty("negativeIntValue") - ) - if ( - !$util.isInteger(message.negativeIntValue) && - !( - message.negativeIntValue && - $util.isInteger(message.negativeIntValue.low) && - $util.isInteger(message.negativeIntValue.high) - ) - ) - return "negativeIntValue: integer|Long expected"; - if ( - message.doubleValue != null && - message.hasOwnProperty("doubleValue") - ) - if (typeof message.doubleValue !== "number") - return "doubleValue: number expected"; - if ( - message.stringValue != null && - message.hasOwnProperty("stringValue") - ) - if ( - !( - (message.stringValue && - typeof message.stringValue.length === "number") || - $util.isString(message.stringValue) - ) - ) - return "stringValue: buffer expected"; - if ( - message.aggregateValue != null && - message.hasOwnProperty("aggregateValue") - ) - if (!$util.isString(message.aggregateValue)) - return "aggregateValue: string expected"; - return null; - }; - - /** - * Creates an UninterpretedOption message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.UninterpretedOption - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.UninterpretedOption} UninterpretedOption - */ - UninterpretedOption.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.UninterpretedOption) - return object; - var message = new $root.google.protobuf.UninterpretedOption(); - if (object.name) { - if (!Array.isArray(object.name)) - throw TypeError( - ".google.protobuf.UninterpretedOption.name: array expected" - ); - message.name = []; - for (var i = 0; i < object.name.length; ++i) { - if (typeof object.name[i] !== "object") - throw TypeError( - ".google.protobuf.UninterpretedOption.name: object expected" - ); - message.name[i] = - $root.google.protobuf.UninterpretedOption.NamePart.fromObject( - object.name[i] - ); - } - } - if (object.identifierValue != null) - message.identifierValue = String(object.identifierValue); - if (object.positiveIntValue != null) - if ($util.Long) - (message.positiveIntValue = $util.Long.fromValue( - object.positiveIntValue - )).unsigned = true; - else if (typeof object.positiveIntValue === "string") - message.positiveIntValue = parseInt(object.positiveIntValue, 10); - else if (typeof object.positiveIntValue === "number") - message.positiveIntValue = object.positiveIntValue; - else if (typeof object.positiveIntValue === "object") - message.positiveIntValue = new $util.LongBits( - object.positiveIntValue.low >>> 0, - object.positiveIntValue.high >>> 0 - ).toNumber(true); - if (object.negativeIntValue != null) - if ($util.Long) - (message.negativeIntValue = $util.Long.fromValue( - object.negativeIntValue - )).unsigned = false; - else if (typeof object.negativeIntValue === "string") - message.negativeIntValue = parseInt(object.negativeIntValue, 10); - else if (typeof object.negativeIntValue === "number") - message.negativeIntValue = object.negativeIntValue; - else if (typeof object.negativeIntValue === "object") - message.negativeIntValue = new $util.LongBits( - object.negativeIntValue.low >>> 0, - object.negativeIntValue.high >>> 0 - ).toNumber(); - if (object.doubleValue != null) - message.doubleValue = Number(object.doubleValue); - if (object.stringValue != null) - if (typeof object.stringValue === "string") - $util.base64.decode( - object.stringValue, - (message.stringValue = $util.newBuffer( - $util.base64.length(object.stringValue) - )), - 0 - ); - else if (object.stringValue.length >= 0) - message.stringValue = object.stringValue; - if (object.aggregateValue != null) - message.aggregateValue = String(object.aggregateValue); - return message; - }; - - /** - * Creates a plain object from an UninterpretedOption message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.UninterpretedOption - * @static - * @param {google.protobuf.UninterpretedOption} message UninterpretedOption - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - UninterpretedOption.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.arrays || options.defaults) object.name = []; - if (options.defaults) { - object.identifierValue = ""; - if ($util.Long) { - var long = new $util.Long(0, 0, true); - object.positiveIntValue = - options.longs === String - ? long.toString() - : options.longs === Number - ? long.toNumber() - : long; - } else object.positiveIntValue = options.longs === String ? "0" : 0; - if ($util.Long) { - var long = new $util.Long(0, 0, false); - object.negativeIntValue = - options.longs === String - ? long.toString() - : options.longs === Number - ? long.toNumber() - : long; - } else object.negativeIntValue = options.longs === String ? "0" : 0; - object.doubleValue = 0; - if (options.bytes === String) object.stringValue = ""; - else { - object.stringValue = []; - if (options.bytes !== Array) - object.stringValue = $util.newBuffer(object.stringValue); - } - object.aggregateValue = ""; - } - if (message.name && message.name.length) { - object.name = []; - for (var j = 0; j < message.name.length; ++j) - object.name[j] = - $root.google.protobuf.UninterpretedOption.NamePart.toObject( - message.name[j], - options - ); - } - if ( - message.identifierValue != null && - message.hasOwnProperty("identifierValue") - ) - object.identifierValue = message.identifierValue; - if ( - message.positiveIntValue != null && - message.hasOwnProperty("positiveIntValue") - ) - if (typeof message.positiveIntValue === "number") - object.positiveIntValue = - options.longs === String - ? String(message.positiveIntValue) - : message.positiveIntValue; - else - object.positiveIntValue = - options.longs === String - ? $util.Long.prototype.toString.call(message.positiveIntValue) - : options.longs === Number - ? new $util.LongBits( - message.positiveIntValue.low >>> 0, - message.positiveIntValue.high >>> 0 - ).toNumber(true) - : message.positiveIntValue; - if ( - message.negativeIntValue != null && - message.hasOwnProperty("negativeIntValue") - ) - if (typeof message.negativeIntValue === "number") - object.negativeIntValue = - options.longs === String - ? String(message.negativeIntValue) - : message.negativeIntValue; - else - object.negativeIntValue = - options.longs === String - ? $util.Long.prototype.toString.call(message.negativeIntValue) - : options.longs === Number - ? new $util.LongBits( - message.negativeIntValue.low >>> 0, - message.negativeIntValue.high >>> 0 - ).toNumber() - : message.negativeIntValue; - if ( - message.doubleValue != null && - message.hasOwnProperty("doubleValue") - ) - object.doubleValue = - options.json && !isFinite(message.doubleValue) - ? String(message.doubleValue) - : message.doubleValue; - if ( - message.stringValue != null && - message.hasOwnProperty("stringValue") - ) - object.stringValue = - options.bytes === String - ? $util.base64.encode( - message.stringValue, - 0, - message.stringValue.length - ) - : options.bytes === Array - ? Array.prototype.slice.call(message.stringValue) - : message.stringValue; - if ( - message.aggregateValue != null && - message.hasOwnProperty("aggregateValue") - ) - object.aggregateValue = message.aggregateValue; - return object; - }; - - /** - * Converts this UninterpretedOption to JSON. - * @function toJSON - * @memberof google.protobuf.UninterpretedOption - * @instance - * @returns {Object.} JSON object - */ - UninterpretedOption.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for UninterpretedOption - * @function getTypeUrl - * @memberof google.protobuf.UninterpretedOption - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - UninterpretedOption.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.UninterpretedOption"; - }; - - UninterpretedOption.NamePart = (function () { /** - * Properties of a NamePart. - * @memberof google.protobuf.UninterpretedOption - * @interface INamePart - * @property {string} namePart NamePart namePart - * @property {boolean} isExtension NamePart isExtension + * Properties of a CSDailyRecommendReq. + * @memberof cs + * @interface ICSDailyRecommendReq */ /** - * Constructs a new NamePart. - * @memberof google.protobuf.UninterpretedOption - * @classdesc Represents a NamePart. - * @implements INamePart + * Constructs a new CSDailyRecommendReq. + * @memberof cs + * @classdesc Represents a CSDailyRecommendReq. + * @implements ICSDailyRecommendReq * @constructor - * @param {google.protobuf.UninterpretedOption.INamePart=} [properties] Properties to set + * @param {cs.ICSDailyRecommendReq=} [properties] Properties to set */ - function NamePart(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]]; + 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]]; } /** - * NamePart namePart. - * @member {string} namePart - * @memberof google.protobuf.UninterpretedOption.NamePart - * @instance - */ - NamePart.prototype.namePart = ""; - - /** - * NamePart isExtension. - * @member {boolean} isExtension - * @memberof google.protobuf.UninterpretedOption.NamePart - * @instance - */ - NamePart.prototype.isExtension = false; - - /** - * Creates a new NamePart instance using the specified properties. + * Creates a new CSDailyRecommendReq instance using the specified properties. * @function create - * @memberof google.protobuf.UninterpretedOption.NamePart + * @memberof cs.CSDailyRecommendReq * @static - * @param {google.protobuf.UninterpretedOption.INamePart=} [properties] Properties to set - * @returns {google.protobuf.UninterpretedOption.NamePart} NamePart instance + * @param {cs.ICSDailyRecommendReq=} [properties] Properties to set + * @returns {cs.CSDailyRecommendReq} CSDailyRecommendReq instance */ - NamePart.create = function create(properties) { - return new NamePart(properties); + CSDailyRecommendReq.create = function create(properties) { + return new CSDailyRecommendReq(properties); }; /** - * Encodes the specified NamePart message. Does not implicitly {@link google.protobuf.UninterpretedOption.NamePart.verify|verify} messages. + * Encodes the specified CSDailyRecommendReq message. Does not implicitly {@link cs.CSDailyRecommendReq.verify|verify} messages. * @function encode - * @memberof google.protobuf.UninterpretedOption.NamePart + * @memberof cs.CSDailyRecommendReq * @static - * @param {google.protobuf.UninterpretedOption.INamePart} message NamePart message or plain object to encode + * @param {cs.ICSDailyRecommendReq} message CSDailyRecommendReq message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - NamePart.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - writer.uint32(/* id 1, wireType 2 =*/ 10).string(message.namePart); - writer.uint32(/* id 2, wireType 0 =*/ 16).bool(message.isExtension); - return writer; + CSDailyRecommendReq.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + return writer; }; /** - * Encodes the specified NamePart message, length delimited. Does not implicitly {@link google.protobuf.UninterpretedOption.NamePart.verify|verify} messages. + * Encodes the specified CSDailyRecommendReq message, length delimited. Does not implicitly {@link cs.CSDailyRecommendReq.verify|verify} messages. * @function encodeDelimited - * @memberof google.protobuf.UninterpretedOption.NamePart + * @memberof cs.CSDailyRecommendReq * @static - * @param {google.protobuf.UninterpretedOption.INamePart} message NamePart message or plain object to encode + * @param {cs.ICSDailyRecommendReq} message CSDailyRecommendReq message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - NamePart.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); + CSDailyRecommendReq.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); }; /** - * Decodes a NamePart message from the specified reader or buffer. + * Decodes a CSDailyRecommendReq message from the specified reader or buffer. * @function decode - * @memberof google.protobuf.UninterpretedOption.NamePart + * @memberof cs.CSDailyRecommendReq * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.UninterpretedOption.NamePart} NamePart + * @returns {cs.CSDailyRecommendReq} CSDailyRecommendReq * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - NamePart.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.google.protobuf.UninterpretedOption.NamePart(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - message.namePart = reader.string(); - break; - } - case 2: { - message.isExtension = reader.bool(); - break; - } - default: - reader.skipType(tag & 7); - break; + 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; + } } - } - if (!message.hasOwnProperty("namePart")) - throw $util.ProtocolError("missing required 'namePart'", { - instance: message, - }); - if (!message.hasOwnProperty("isExtension")) - throw $util.ProtocolError("missing required 'isExtension'", { - instance: message, - }); - return message; + return message; }; /** - * Decodes a NamePart message from the specified reader or buffer, length delimited. + * Decodes a CSDailyRecommendReq message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.protobuf.UninterpretedOption.NamePart + * @memberof cs.CSDailyRecommendReq * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.UninterpretedOption.NamePart} NamePart + * @returns {cs.CSDailyRecommendReq} CSDailyRecommendReq * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - NamePart.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); + CSDailyRecommendReq.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); }; /** - * Verifies a NamePart message. + * Verifies a CSDailyRecommendReq message. * @function verify - * @memberof google.protobuf.UninterpretedOption.NamePart + * @memberof cs.CSDailyRecommendReq * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - NamePart.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (!$util.isString(message.namePart)) - return "namePart: string expected"; - if (typeof message.isExtension !== "boolean") - return "isExtension: boolean expected"; - return null; + CSDailyRecommendReq.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + return null; }; /** - * Creates a NamePart message from a plain object. Also converts values to their respective internal types. + * Creates a CSDailyRecommendReq message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.protobuf.UninterpretedOption.NamePart + * @memberof cs.CSDailyRecommendReq * @static * @param {Object.} object Plain object - * @returns {google.protobuf.UninterpretedOption.NamePart} NamePart + * @returns {cs.CSDailyRecommendReq} CSDailyRecommendReq */ - NamePart.fromObject = function fromObject(object) { - if ( - object instanceof $root.google.protobuf.UninterpretedOption.NamePart - ) - return object; - var message = - new $root.google.protobuf.UninterpretedOption.NamePart(); - if (object.namePart != null) - message.namePart = String(object.namePart); - if (object.isExtension != null) - message.isExtension = Boolean(object.isExtension); - return message; + CSDailyRecommendReq.fromObject = function fromObject(object) { + if (object instanceof $root.cs.CSDailyRecommendReq) + return object; + return new $root.cs.CSDailyRecommendReq(); }; /** - * Creates a plain object from a NamePart message. Also converts values to other types if specified. + * Creates a plain object from a CSDailyRecommendReq message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.UninterpretedOption.NamePart + * @memberof cs.CSDailyRecommendReq * @static - * @param {google.protobuf.UninterpretedOption.NamePart} message NamePart + * @param {cs.CSDailyRecommendReq} message CSDailyRecommendReq * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - NamePart.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.defaults) { - object.namePart = ""; - object.isExtension = false; - } - if (message.namePart != null && message.hasOwnProperty("namePart")) - object.namePart = message.namePart; - if ( - message.isExtension != null && - message.hasOwnProperty("isExtension") - ) - object.isExtension = message.isExtension; - return object; + CSDailyRecommendReq.toObject = function toObject() { + return {}; }; /** - * Converts this NamePart to JSON. + * Converts this CSDailyRecommendReq to JSON. * @function toJSON - * @memberof google.protobuf.UninterpretedOption.NamePart + * @memberof cs.CSDailyRecommendReq * @instance * @returns {Object.} JSON object */ - NamePart.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + CSDailyRecommendReq.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for NamePart + * Gets the default type url for CSDailyRecommendReq * @function getTypeUrl - * @memberof google.protobuf.UninterpretedOption.NamePart + * @memberof cs.CSDailyRecommendReq * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - NamePart.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return ( - typeUrlPrefix + "/google.protobuf.UninterpretedOption.NamePart" - ); + CSDailyRecommendReq.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/cs.CSDailyRecommendReq"; }; - return NamePart; - })(); - - return UninterpretedOption; + return CSDailyRecommendReq; })(); - protobuf.FeatureSet = (function () { - /** - * Properties of a FeatureSet. - * @memberof google.protobuf - * @interface IFeatureSet - * @property {google.protobuf.FeatureSet.FieldPresence|null} [fieldPresence] FeatureSet fieldPresence - * @property {google.protobuf.FeatureSet.EnumType|null} [enumType] FeatureSet enumType - * @property {google.protobuf.FeatureSet.RepeatedFieldEncoding|null} [repeatedFieldEncoding] FeatureSet repeatedFieldEncoding - * @property {google.protobuf.FeatureSet.Utf8Validation|null} [utf8Validation] FeatureSet utf8Validation - * @property {google.protobuf.FeatureSet.MessageEncoding|null} [messageEncoding] FeatureSet messageEncoding - * @property {google.protobuf.FeatureSet.JsonFormat|null} [jsonFormat] FeatureSet jsonFormat - * @property {google.protobuf.FeatureSet.EnforceNamingStyle|null} [enforceNamingStyle] FeatureSet enforceNamingStyle - * @property {google.protobuf.FeatureSet.VisibilityFeature.DefaultSymbolVisibility|null} [defaultSymbolVisibility] FeatureSet defaultSymbolVisibility - */ + cs.CSDailyRecommendRes = (function() { - /** - * Constructs a new FeatureSet. - * @memberof google.protobuf - * @classdesc Represents a FeatureSet. - * @implements IFeatureSet - * @constructor - * @param {google.protobuf.IFeatureSet=} [properties] Properties to set - */ - function FeatureSet(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]]; - } - - /** - * FeatureSet fieldPresence. - * @member {google.protobuf.FeatureSet.FieldPresence} fieldPresence - * @memberof google.protobuf.FeatureSet - * @instance - */ - FeatureSet.prototype.fieldPresence = 0; - - /** - * FeatureSet enumType. - * @member {google.protobuf.FeatureSet.EnumType} enumType - * @memberof google.protobuf.FeatureSet - * @instance - */ - FeatureSet.prototype.enumType = 0; - - /** - * FeatureSet repeatedFieldEncoding. - * @member {google.protobuf.FeatureSet.RepeatedFieldEncoding} repeatedFieldEncoding - * @memberof google.protobuf.FeatureSet - * @instance - */ - FeatureSet.prototype.repeatedFieldEncoding = 0; - - /** - * FeatureSet utf8Validation. - * @member {google.protobuf.FeatureSet.Utf8Validation} utf8Validation - * @memberof google.protobuf.FeatureSet - * @instance - */ - FeatureSet.prototype.utf8Validation = 0; - - /** - * FeatureSet messageEncoding. - * @member {google.protobuf.FeatureSet.MessageEncoding} messageEncoding - * @memberof google.protobuf.FeatureSet - * @instance - */ - FeatureSet.prototype.messageEncoding = 0; - - /** - * FeatureSet jsonFormat. - * @member {google.protobuf.FeatureSet.JsonFormat} jsonFormat - * @memberof google.protobuf.FeatureSet - * @instance - */ - FeatureSet.prototype.jsonFormat = 0; - - /** - * FeatureSet enforceNamingStyle. - * @member {google.protobuf.FeatureSet.EnforceNamingStyle} enforceNamingStyle - * @memberof google.protobuf.FeatureSet - * @instance - */ - FeatureSet.prototype.enforceNamingStyle = 0; - - /** - * FeatureSet defaultSymbolVisibility. - * @member {google.protobuf.FeatureSet.VisibilityFeature.DefaultSymbolVisibility} defaultSymbolVisibility - * @memberof google.protobuf.FeatureSet - * @instance - */ - FeatureSet.prototype.defaultSymbolVisibility = 0; - - /** - * Creates a new FeatureSet instance using the specified properties. - * @function create - * @memberof google.protobuf.FeatureSet - * @static - * @param {google.protobuf.IFeatureSet=} [properties] Properties to set - * @returns {google.protobuf.FeatureSet} FeatureSet instance - */ - FeatureSet.create = function create(properties) { - return new FeatureSet(properties); - }; - - /** - * Encodes the specified FeatureSet message. Does not implicitly {@link google.protobuf.FeatureSet.verify|verify} messages. - * @function encode - * @memberof google.protobuf.FeatureSet - * @static - * @param {google.protobuf.IFeatureSet} message FeatureSet message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - FeatureSet.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if ( - message.fieldPresence != null && - Object.hasOwnProperty.call(message, "fieldPresence") - ) - writer.uint32(/* id 1, wireType 0 =*/ 8).int32(message.fieldPresence); - if ( - message.enumType != null && - Object.hasOwnProperty.call(message, "enumType") - ) - writer.uint32(/* id 2, wireType 0 =*/ 16).int32(message.enumType); - if ( - message.repeatedFieldEncoding != null && - Object.hasOwnProperty.call(message, "repeatedFieldEncoding") - ) - writer - .uint32(/* id 3, wireType 0 =*/ 24) - .int32(message.repeatedFieldEncoding); - if ( - message.utf8Validation != null && - Object.hasOwnProperty.call(message, "utf8Validation") - ) - writer - .uint32(/* id 4, wireType 0 =*/ 32) - .int32(message.utf8Validation); - if ( - message.messageEncoding != null && - Object.hasOwnProperty.call(message, "messageEncoding") - ) - writer - .uint32(/* id 5, wireType 0 =*/ 40) - .int32(message.messageEncoding); - if ( - message.jsonFormat != null && - Object.hasOwnProperty.call(message, "jsonFormat") - ) - writer.uint32(/* id 6, wireType 0 =*/ 48).int32(message.jsonFormat); - if ( - message.enforceNamingStyle != null && - Object.hasOwnProperty.call(message, "enforceNamingStyle") - ) - writer - .uint32(/* id 7, wireType 0 =*/ 56) - .int32(message.enforceNamingStyle); - if ( - message.defaultSymbolVisibility != null && - Object.hasOwnProperty.call(message, "defaultSymbolVisibility") - ) - writer - .uint32(/* id 8, wireType 0 =*/ 64) - .int32(message.defaultSymbolVisibility); - return writer; - }; - - /** - * Encodes the specified FeatureSet message, length delimited. Does not implicitly {@link google.protobuf.FeatureSet.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.FeatureSet - * @static - * @param {google.protobuf.IFeatureSet} message FeatureSet message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - FeatureSet.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a FeatureSet message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.FeatureSet - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.FeatureSet} FeatureSet - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - FeatureSet.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.google.protobuf.FeatureSet(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - message.fieldPresence = reader.int32(); - break; - } - case 2: { - message.enumType = reader.int32(); - break; - } - case 3: { - message.repeatedFieldEncoding = reader.int32(); - break; - } - case 4: { - message.utf8Validation = reader.int32(); - break; - } - case 5: { - message.messageEncoding = reader.int32(); - break; - } - case 6: { - message.jsonFormat = reader.int32(); - break; - } - case 7: { - message.enforceNamingStyle = reader.int32(); - break; - } - case 8: { - message.defaultSymbolVisibility = reader.int32(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a FeatureSet message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.FeatureSet - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.FeatureSet} FeatureSet - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - FeatureSet.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a FeatureSet message. - * @function verify - * @memberof google.protobuf.FeatureSet - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - FeatureSet.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if ( - message.fieldPresence != null && - message.hasOwnProperty("fieldPresence") - ) - switch (message.fieldPresence) { - default: - return "fieldPresence: enum value expected"; - case 0: - case 1: - case 2: - case 3: - break; - } - if (message.enumType != null && message.hasOwnProperty("enumType")) - switch (message.enumType) { - default: - return "enumType: enum value expected"; - case 0: - case 1: - case 2: - break; - } - if ( - message.repeatedFieldEncoding != null && - message.hasOwnProperty("repeatedFieldEncoding") - ) - switch (message.repeatedFieldEncoding) { - default: - return "repeatedFieldEncoding: enum value expected"; - case 0: - case 1: - case 2: - break; - } - if ( - message.utf8Validation != null && - message.hasOwnProperty("utf8Validation") - ) - switch (message.utf8Validation) { - default: - return "utf8Validation: enum value expected"; - case 0: - case 2: - case 3: - break; - } - if ( - message.messageEncoding != null && - message.hasOwnProperty("messageEncoding") - ) - switch (message.messageEncoding) { - default: - return "messageEncoding: enum value expected"; - case 0: - case 1: - case 2: - break; - } - if (message.jsonFormat != null && message.hasOwnProperty("jsonFormat")) - switch (message.jsonFormat) { - default: - return "jsonFormat: enum value expected"; - case 0: - case 1: - case 2: - break; - } - if ( - message.enforceNamingStyle != null && - message.hasOwnProperty("enforceNamingStyle") - ) - switch (message.enforceNamingStyle) { - default: - return "enforceNamingStyle: enum value expected"; - case 0: - case 1: - case 2: - break; - } - if ( - message.defaultSymbolVisibility != null && - message.hasOwnProperty("defaultSymbolVisibility") - ) - switch (message.defaultSymbolVisibility) { - default: - return "defaultSymbolVisibility: enum value expected"; - case 0: - case 1: - case 2: - case 3: - case 4: - break; - } - return null; - }; - - /** - * Creates a FeatureSet message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.FeatureSet - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.FeatureSet} FeatureSet - */ - FeatureSet.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.FeatureSet) return object; - var message = new $root.google.protobuf.FeatureSet(); - switch (object.fieldPresence) { - default: - if (typeof object.fieldPresence === "number") { - message.fieldPresence = object.fieldPresence; - break; - } - break; - case "FIELD_PRESENCE_UNKNOWN": - case 0: - message.fieldPresence = 0; - break; - case "EXPLICIT": - case 1: - message.fieldPresence = 1; - break; - case "IMPLICIT": - case 2: - message.fieldPresence = 2; - break; - case "LEGACY_REQUIRED": - case 3: - message.fieldPresence = 3; - break; - } - switch (object.enumType) { - default: - if (typeof object.enumType === "number") { - message.enumType = object.enumType; - break; - } - break; - case "ENUM_TYPE_UNKNOWN": - case 0: - message.enumType = 0; - break; - case "OPEN": - case 1: - message.enumType = 1; - break; - case "CLOSED": - case 2: - message.enumType = 2; - break; - } - switch (object.repeatedFieldEncoding) { - default: - if (typeof object.repeatedFieldEncoding === "number") { - message.repeatedFieldEncoding = object.repeatedFieldEncoding; - break; - } - break; - case "REPEATED_FIELD_ENCODING_UNKNOWN": - case 0: - message.repeatedFieldEncoding = 0; - break; - case "PACKED": - case 1: - message.repeatedFieldEncoding = 1; - break; - case "EXPANDED": - case 2: - message.repeatedFieldEncoding = 2; - break; - } - switch (object.utf8Validation) { - default: - if (typeof object.utf8Validation === "number") { - message.utf8Validation = object.utf8Validation; - break; - } - break; - case "UTF8_VALIDATION_UNKNOWN": - case 0: - message.utf8Validation = 0; - break; - case "VERIFY": - case 2: - message.utf8Validation = 2; - break; - case "NONE": - case 3: - message.utf8Validation = 3; - break; - } - switch (object.messageEncoding) { - default: - if (typeof object.messageEncoding === "number") { - message.messageEncoding = object.messageEncoding; - break; - } - break; - case "MESSAGE_ENCODING_UNKNOWN": - case 0: - message.messageEncoding = 0; - break; - case "LENGTH_PREFIXED": - case 1: - message.messageEncoding = 1; - break; - case "DELIMITED": - case 2: - message.messageEncoding = 2; - break; - } - switch (object.jsonFormat) { - default: - if (typeof object.jsonFormat === "number") { - message.jsonFormat = object.jsonFormat; - break; - } - break; - case "JSON_FORMAT_UNKNOWN": - case 0: - message.jsonFormat = 0; - break; - case "ALLOW": - case 1: - message.jsonFormat = 1; - break; - case "LEGACY_BEST_EFFORT": - case 2: - message.jsonFormat = 2; - break; - } - switch (object.enforceNamingStyle) { - default: - if (typeof object.enforceNamingStyle === "number") { - message.enforceNamingStyle = object.enforceNamingStyle; - break; - } - break; - case "ENFORCE_NAMING_STYLE_UNKNOWN": - case 0: - message.enforceNamingStyle = 0; - break; - case "STYLE2024": - case 1: - message.enforceNamingStyle = 1; - break; - case "STYLE_LEGACY": - case 2: - message.enforceNamingStyle = 2; - break; - } - switch (object.defaultSymbolVisibility) { - default: - if (typeof object.defaultSymbolVisibility === "number") { - message.defaultSymbolVisibility = object.defaultSymbolVisibility; - break; - } - break; - case "DEFAULT_SYMBOL_VISIBILITY_UNKNOWN": - case 0: - message.defaultSymbolVisibility = 0; - break; - case "EXPORT_ALL": - case 1: - message.defaultSymbolVisibility = 1; - break; - case "EXPORT_TOP_LEVEL": - case 2: - message.defaultSymbolVisibility = 2; - break; - case "LOCAL_ALL": - case 3: - message.defaultSymbolVisibility = 3; - break; - case "STRICT": - case 4: - message.defaultSymbolVisibility = 4; - break; - } - return message; - }; - - /** - * Creates a plain object from a FeatureSet message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.FeatureSet - * @static - * @param {google.protobuf.FeatureSet} message FeatureSet - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - FeatureSet.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.defaults) { - object.fieldPresence = - options.enums === String ? "FIELD_PRESENCE_UNKNOWN" : 0; - object.enumType = options.enums === String ? "ENUM_TYPE_UNKNOWN" : 0; - object.repeatedFieldEncoding = - options.enums === String ? "REPEATED_FIELD_ENCODING_UNKNOWN" : 0; - object.utf8Validation = - options.enums === String ? "UTF8_VALIDATION_UNKNOWN" : 0; - object.messageEncoding = - options.enums === String ? "MESSAGE_ENCODING_UNKNOWN" : 0; - object.jsonFormat = - options.enums === String ? "JSON_FORMAT_UNKNOWN" : 0; - object.enforceNamingStyle = - options.enums === String ? "ENFORCE_NAMING_STYLE_UNKNOWN" : 0; - object.defaultSymbolVisibility = - options.enums === String ? "DEFAULT_SYMBOL_VISIBILITY_UNKNOWN" : 0; - } - if ( - message.fieldPresence != null && - message.hasOwnProperty("fieldPresence") - ) - object.fieldPresence = - options.enums === String - ? $root.google.protobuf.FeatureSet.FieldPresence[ - message.fieldPresence - ] === undefined - ? message.fieldPresence - : $root.google.protobuf.FeatureSet.FieldPresence[ - message.fieldPresence - ] - : message.fieldPresence; - if (message.enumType != null && message.hasOwnProperty("enumType")) - object.enumType = - options.enums === String - ? $root.google.protobuf.FeatureSet.EnumType[message.enumType] === - undefined - ? message.enumType - : $root.google.protobuf.FeatureSet.EnumType[message.enumType] - : message.enumType; - if ( - message.repeatedFieldEncoding != null && - message.hasOwnProperty("repeatedFieldEncoding") - ) - object.repeatedFieldEncoding = - options.enums === String - ? $root.google.protobuf.FeatureSet.RepeatedFieldEncoding[ - message.repeatedFieldEncoding - ] === undefined - ? message.repeatedFieldEncoding - : $root.google.protobuf.FeatureSet.RepeatedFieldEncoding[ - message.repeatedFieldEncoding - ] - : message.repeatedFieldEncoding; - if ( - message.utf8Validation != null && - message.hasOwnProperty("utf8Validation") - ) - object.utf8Validation = - options.enums === String - ? $root.google.protobuf.FeatureSet.Utf8Validation[ - message.utf8Validation - ] === undefined - ? message.utf8Validation - : $root.google.protobuf.FeatureSet.Utf8Validation[ - message.utf8Validation - ] - : message.utf8Validation; - if ( - message.messageEncoding != null && - message.hasOwnProperty("messageEncoding") - ) - object.messageEncoding = - options.enums === String - ? $root.google.protobuf.FeatureSet.MessageEncoding[ - message.messageEncoding - ] === undefined - ? message.messageEncoding - : $root.google.protobuf.FeatureSet.MessageEncoding[ - message.messageEncoding - ] - : message.messageEncoding; - if (message.jsonFormat != null && message.hasOwnProperty("jsonFormat")) - object.jsonFormat = - options.enums === String - ? $root.google.protobuf.FeatureSet.JsonFormat[ - message.jsonFormat - ] === undefined - ? message.jsonFormat - : $root.google.protobuf.FeatureSet.JsonFormat[ - message.jsonFormat - ] - : message.jsonFormat; - if ( - message.enforceNamingStyle != null && - message.hasOwnProperty("enforceNamingStyle") - ) - object.enforceNamingStyle = - options.enums === String - ? $root.google.protobuf.FeatureSet.EnforceNamingStyle[ - message.enforceNamingStyle - ] === undefined - ? message.enforceNamingStyle - : $root.google.protobuf.FeatureSet.EnforceNamingStyle[ - message.enforceNamingStyle - ] - : message.enforceNamingStyle; - if ( - message.defaultSymbolVisibility != null && - message.hasOwnProperty("defaultSymbolVisibility") - ) - object.defaultSymbolVisibility = - options.enums === String - ? $root.google.protobuf.FeatureSet.VisibilityFeature - .DefaultSymbolVisibility[message.defaultSymbolVisibility] === - undefined - ? message.defaultSymbolVisibility - : $root.google.protobuf.FeatureSet.VisibilityFeature - .DefaultSymbolVisibility[message.defaultSymbolVisibility] - : message.defaultSymbolVisibility; - return object; - }; - - /** - * Converts this FeatureSet to JSON. - * @function toJSON - * @memberof google.protobuf.FeatureSet - * @instance - * @returns {Object.} JSON object - */ - FeatureSet.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for FeatureSet - * @function getTypeUrl - * @memberof google.protobuf.FeatureSet - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - FeatureSet.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.FeatureSet"; - }; - - /** - * FieldPresence enum. - * @name google.protobuf.FeatureSet.FieldPresence - * @enum {number} - * @property {number} FIELD_PRESENCE_UNKNOWN=0 FIELD_PRESENCE_UNKNOWN value - * @property {number} EXPLICIT=1 EXPLICIT value - * @property {number} IMPLICIT=2 IMPLICIT value - * @property {number} LEGACY_REQUIRED=3 LEGACY_REQUIRED value - */ - FeatureSet.FieldPresence = (function () { - var valuesById = {}, - values = Object.create(valuesById); - values[(valuesById[0] = "FIELD_PRESENCE_UNKNOWN")] = 0; - values[(valuesById[1] = "EXPLICIT")] = 1; - values[(valuesById[2] = "IMPLICIT")] = 2; - values[(valuesById[3] = "LEGACY_REQUIRED")] = 3; - return values; - })(); - - /** - * EnumType enum. - * @name google.protobuf.FeatureSet.EnumType - * @enum {number} - * @property {number} ENUM_TYPE_UNKNOWN=0 ENUM_TYPE_UNKNOWN value - * @property {number} OPEN=1 OPEN value - * @property {number} CLOSED=2 CLOSED value - */ - FeatureSet.EnumType = (function () { - var valuesById = {}, - values = Object.create(valuesById); - values[(valuesById[0] = "ENUM_TYPE_UNKNOWN")] = 0; - values[(valuesById[1] = "OPEN")] = 1; - values[(valuesById[2] = "CLOSED")] = 2; - return values; - })(); - - /** - * RepeatedFieldEncoding enum. - * @name google.protobuf.FeatureSet.RepeatedFieldEncoding - * @enum {number} - * @property {number} REPEATED_FIELD_ENCODING_UNKNOWN=0 REPEATED_FIELD_ENCODING_UNKNOWN value - * @property {number} PACKED=1 PACKED value - * @property {number} EXPANDED=2 EXPANDED value - */ - FeatureSet.RepeatedFieldEncoding = (function () { - var valuesById = {}, - values = Object.create(valuesById); - values[(valuesById[0] = "REPEATED_FIELD_ENCODING_UNKNOWN")] = 0; - values[(valuesById[1] = "PACKED")] = 1; - values[(valuesById[2] = "EXPANDED")] = 2; - return values; - })(); - - /** - * Utf8Validation enum. - * @name google.protobuf.FeatureSet.Utf8Validation - * @enum {number} - * @property {number} UTF8_VALIDATION_UNKNOWN=0 UTF8_VALIDATION_UNKNOWN value - * @property {number} VERIFY=2 VERIFY value - * @property {number} NONE=3 NONE value - */ - FeatureSet.Utf8Validation = (function () { - var valuesById = {}, - values = Object.create(valuesById); - values[(valuesById[0] = "UTF8_VALIDATION_UNKNOWN")] = 0; - values[(valuesById[2] = "VERIFY")] = 2; - values[(valuesById[3] = "NONE")] = 3; - return values; - })(); - - /** - * MessageEncoding enum. - * @name google.protobuf.FeatureSet.MessageEncoding - * @enum {number} - * @property {number} MESSAGE_ENCODING_UNKNOWN=0 MESSAGE_ENCODING_UNKNOWN value - * @property {number} LENGTH_PREFIXED=1 LENGTH_PREFIXED value - * @property {number} DELIMITED=2 DELIMITED value - */ - FeatureSet.MessageEncoding = (function () { - var valuesById = {}, - values = Object.create(valuesById); - values[(valuesById[0] = "MESSAGE_ENCODING_UNKNOWN")] = 0; - values[(valuesById[1] = "LENGTH_PREFIXED")] = 1; - values[(valuesById[2] = "DELIMITED")] = 2; - return values; - })(); - - /** - * JsonFormat enum. - * @name google.protobuf.FeatureSet.JsonFormat - * @enum {number} - * @property {number} JSON_FORMAT_UNKNOWN=0 JSON_FORMAT_UNKNOWN value - * @property {number} ALLOW=1 ALLOW value - * @property {number} LEGACY_BEST_EFFORT=2 LEGACY_BEST_EFFORT value - */ - FeatureSet.JsonFormat = (function () { - var valuesById = {}, - values = Object.create(valuesById); - values[(valuesById[0] = "JSON_FORMAT_UNKNOWN")] = 0; - values[(valuesById[1] = "ALLOW")] = 1; - values[(valuesById[2] = "LEGACY_BEST_EFFORT")] = 2; - return values; - })(); - - /** - * EnforceNamingStyle enum. - * @name google.protobuf.FeatureSet.EnforceNamingStyle - * @enum {number} - * @property {number} ENFORCE_NAMING_STYLE_UNKNOWN=0 ENFORCE_NAMING_STYLE_UNKNOWN value - * @property {number} STYLE2024=1 STYLE2024 value - * @property {number} STYLE_LEGACY=2 STYLE_LEGACY value - */ - FeatureSet.EnforceNamingStyle = (function () { - var valuesById = {}, - values = Object.create(valuesById); - values[(valuesById[0] = "ENFORCE_NAMING_STYLE_UNKNOWN")] = 0; - values[(valuesById[1] = "STYLE2024")] = 1; - values[(valuesById[2] = "STYLE_LEGACY")] = 2; - return values; - })(); - - FeatureSet.VisibilityFeature = (function () { /** - * Properties of a VisibilityFeature. - * @memberof google.protobuf.FeatureSet - * @interface IVisibilityFeature + * Properties of a CSDailyRecommendRes. + * @memberof cs + * @interface ICSDailyRecommendRes + * @property {Array.|null} [girls] CSDailyRecommendRes girls */ /** - * Constructs a new VisibilityFeature. - * @memberof google.protobuf.FeatureSet - * @classdesc Represents a VisibilityFeature. - * @implements IVisibilityFeature + * Constructs a new CSDailyRecommendRes. + * @memberof cs + * @classdesc Represents a CSDailyRecommendRes. + * @implements ICSDailyRecommendRes * @constructor - * @param {google.protobuf.FeatureSet.IVisibilityFeature=} [properties] Properties to set + * @param {cs.ICSDailyRecommendRes=} [properties] Properties to set */ - function VisibilityFeature(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]]; + 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]]; } /** - * Creates a new VisibilityFeature instance using the specified properties. + * CSDailyRecommendRes girls. + * @member {Array.} girls + * @memberof cs.CSDailyRecommendRes + * @instance + */ + CSDailyRecommendRes.prototype.girls = $util.emptyArray; + + /** + * Creates a new CSDailyRecommendRes instance using the specified properties. * @function create - * @memberof google.protobuf.FeatureSet.VisibilityFeature + * @memberof cs.CSDailyRecommendRes * @static - * @param {google.protobuf.FeatureSet.IVisibilityFeature=} [properties] Properties to set - * @returns {google.protobuf.FeatureSet.VisibilityFeature} VisibilityFeature instance + * @param {cs.ICSDailyRecommendRes=} [properties] Properties to set + * @returns {cs.CSDailyRecommendRes} CSDailyRecommendRes instance */ - VisibilityFeature.create = function create(properties) { - return new VisibilityFeature(properties); + CSDailyRecommendRes.create = function create(properties) { + return new CSDailyRecommendRes(properties); }; /** - * Encodes the specified VisibilityFeature message. Does not implicitly {@link google.protobuf.FeatureSet.VisibilityFeature.verify|verify} messages. + * Encodes the specified CSDailyRecommendRes message. Does not implicitly {@link cs.CSDailyRecommendRes.verify|verify} messages. * @function encode - * @memberof google.protobuf.FeatureSet.VisibilityFeature + * @memberof cs.CSDailyRecommendRes * @static - * @param {google.protobuf.FeatureSet.IVisibilityFeature} message VisibilityFeature message or plain object to encode + * @param {cs.ICSDailyRecommendRes} message CSDailyRecommendRes message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - VisibilityFeature.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - return writer; + 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; }; /** - * Encodes the specified VisibilityFeature message, length delimited. Does not implicitly {@link google.protobuf.FeatureSet.VisibilityFeature.verify|verify} messages. + * Encodes the specified CSDailyRecommendRes message, length delimited. Does not implicitly {@link cs.CSDailyRecommendRes.verify|verify} messages. * @function encodeDelimited - * @memberof google.protobuf.FeatureSet.VisibilityFeature + * @memberof cs.CSDailyRecommendRes * @static - * @param {google.protobuf.FeatureSet.IVisibilityFeature} message VisibilityFeature message or plain object to encode + * @param {cs.ICSDailyRecommendRes} message CSDailyRecommendRes message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - VisibilityFeature.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); + CSDailyRecommendRes.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); }; /** - * Decodes a VisibilityFeature message from the specified reader or buffer. + * Decodes a CSDailyRecommendRes message from the specified reader or buffer. * @function decode - * @memberof google.protobuf.FeatureSet.VisibilityFeature + * @memberof cs.CSDailyRecommendRes * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.FeatureSet.VisibilityFeature} VisibilityFeature + * @returns {cs.CSDailyRecommendRes} CSDailyRecommendRes * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - VisibilityFeature.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.google.protobuf.FeatureSet.VisibilityFeature(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - default: - reader.skipType(tag & 7); - break; + 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; + } } - } - return message; + return message; }; /** - * Decodes a VisibilityFeature message from the specified reader or buffer, length delimited. + * Decodes a CSDailyRecommendRes message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.protobuf.FeatureSet.VisibilityFeature + * @memberof cs.CSDailyRecommendRes * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.FeatureSet.VisibilityFeature} VisibilityFeature + * @returns {cs.CSDailyRecommendRes} CSDailyRecommendRes * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - VisibilityFeature.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); + CSDailyRecommendRes.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); }; /** - * Verifies a VisibilityFeature message. + * Verifies a CSDailyRecommendRes message. * @function verify - * @memberof google.protobuf.FeatureSet.VisibilityFeature + * @memberof cs.CSDailyRecommendRes * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - VisibilityFeature.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - return null; + 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; }; /** - * Creates a VisibilityFeature message from a plain object. Also converts values to their respective internal types. + * Creates a CSDailyRecommendRes message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.protobuf.FeatureSet.VisibilityFeature + * @memberof cs.CSDailyRecommendRes * @static * @param {Object.} object Plain object - * @returns {google.protobuf.FeatureSet.VisibilityFeature} VisibilityFeature + * @returns {cs.CSDailyRecommendRes} CSDailyRecommendRes */ - VisibilityFeature.fromObject = function fromObject(object) { - if ( - object instanceof $root.google.protobuf.FeatureSet.VisibilityFeature - ) - return object; - return new $root.google.protobuf.FeatureSet.VisibilityFeature(); + 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; }; /** - * Creates a plain object from a VisibilityFeature message. Also converts values to other types if specified. + * Creates a plain object from a CSDailyRecommendRes message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.FeatureSet.VisibilityFeature + * @memberof cs.CSDailyRecommendRes * @static - * @param {google.protobuf.FeatureSet.VisibilityFeature} message VisibilityFeature + * @param {cs.CSDailyRecommendRes} message CSDailyRecommendRes * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - VisibilityFeature.toObject = function toObject() { - return {}; + 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; }; /** - * Converts this VisibilityFeature to JSON. + * Converts this CSDailyRecommendRes to JSON. * @function toJSON - * @memberof google.protobuf.FeatureSet.VisibilityFeature + * @memberof cs.CSDailyRecommendRes * @instance * @returns {Object.} JSON object */ - VisibilityFeature.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + CSDailyRecommendRes.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for VisibilityFeature + * Gets the default type url for CSDailyRecommendRes * @function getTypeUrl - * @memberof google.protobuf.FeatureSet.VisibilityFeature + * @memberof cs.CSDailyRecommendRes * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - VisibilityFeature.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return ( - typeUrlPrefix + "/google.protobuf.FeatureSet.VisibilityFeature" - ); + CSDailyRecommendRes.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/cs.CSDailyRecommendRes"; }; - /** - * DefaultSymbolVisibility enum. - * @name google.protobuf.FeatureSet.VisibilityFeature.DefaultSymbolVisibility - * @enum {number} - * @property {number} DEFAULT_SYMBOL_VISIBILITY_UNKNOWN=0 DEFAULT_SYMBOL_VISIBILITY_UNKNOWN value - * @property {number} EXPORT_ALL=1 EXPORT_ALL value - * @property {number} EXPORT_TOP_LEVEL=2 EXPORT_TOP_LEVEL value - * @property {number} LOCAL_ALL=3 LOCAL_ALL value - * @property {number} STRICT=4 STRICT value - */ - VisibilityFeature.DefaultSymbolVisibility = (function () { - var valuesById = {}, - values = Object.create(valuesById); - values[(valuesById[0] = "DEFAULT_SYMBOL_VISIBILITY_UNKNOWN")] = 0; - values[(valuesById[1] = "EXPORT_ALL")] = 1; - values[(valuesById[2] = "EXPORT_TOP_LEVEL")] = 2; - values[(valuesById[3] = "LOCAL_ALL")] = 3; - values[(valuesById[4] = "STRICT")] = 4; - return values; - })(); - - return VisibilityFeature; - })(); - - return FeatureSet; + return CSDailyRecommendRes; })(); - protobuf.FeatureSetDefaults = (function () { - /** - * Properties of a FeatureSetDefaults. - * @memberof google.protobuf - * @interface IFeatureSetDefaults - * @property {Array.|null} [defaults] FeatureSetDefaults defaults - * @property {google.protobuf.Edition|null} [minimumEdition] FeatureSetDefaults minimumEdition - * @property {google.protobuf.Edition|null} [maximumEdition] FeatureSetDefaults maximumEdition - */ + cs.CSHallThemeReq = (function() { - /** - * Constructs a new FeatureSetDefaults. - * @memberof google.protobuf - * @classdesc Represents a FeatureSetDefaults. - * @implements IFeatureSetDefaults - * @constructor - * @param {google.protobuf.IFeatureSetDefaults=} [properties] Properties to set - */ - function FeatureSetDefaults(properties) { - this.defaults = []; - 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]]; - } - - /** - * FeatureSetDefaults defaults. - * @member {Array.} defaults - * @memberof google.protobuf.FeatureSetDefaults - * @instance - */ - FeatureSetDefaults.prototype.defaults = $util.emptyArray; - - /** - * FeatureSetDefaults minimumEdition. - * @member {google.protobuf.Edition} minimumEdition - * @memberof google.protobuf.FeatureSetDefaults - * @instance - */ - FeatureSetDefaults.prototype.minimumEdition = 0; - - /** - * FeatureSetDefaults maximumEdition. - * @member {google.protobuf.Edition} maximumEdition - * @memberof google.protobuf.FeatureSetDefaults - * @instance - */ - FeatureSetDefaults.prototype.maximumEdition = 0; - - /** - * Creates a new FeatureSetDefaults instance using the specified properties. - * @function create - * @memberof google.protobuf.FeatureSetDefaults - * @static - * @param {google.protobuf.IFeatureSetDefaults=} [properties] Properties to set - * @returns {google.protobuf.FeatureSetDefaults} FeatureSetDefaults instance - */ - FeatureSetDefaults.create = function create(properties) { - return new FeatureSetDefaults(properties); - }; - - /** - * Encodes the specified FeatureSetDefaults message. Does not implicitly {@link google.protobuf.FeatureSetDefaults.verify|verify} messages. - * @function encode - * @memberof google.protobuf.FeatureSetDefaults - * @static - * @param {google.protobuf.IFeatureSetDefaults} message FeatureSetDefaults message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - FeatureSetDefaults.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if (message.defaults != null && message.defaults.length) - for (var i = 0; i < message.defaults.length; ++i) - $root.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.encode( - message.defaults[i], - writer.uint32(/* id 1, wireType 2 =*/ 10).fork() - ).ldelim(); - if ( - message.minimumEdition != null && - Object.hasOwnProperty.call(message, "minimumEdition") - ) - writer - .uint32(/* id 4, wireType 0 =*/ 32) - .int32(message.minimumEdition); - if ( - message.maximumEdition != null && - Object.hasOwnProperty.call(message, "maximumEdition") - ) - writer - .uint32(/* id 5, wireType 0 =*/ 40) - .int32(message.maximumEdition); - return writer; - }; - - /** - * Encodes the specified FeatureSetDefaults message, length delimited. Does not implicitly {@link google.protobuf.FeatureSetDefaults.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.FeatureSetDefaults - * @static - * @param {google.protobuf.IFeatureSetDefaults} message FeatureSetDefaults message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - FeatureSetDefaults.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a FeatureSetDefaults message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.FeatureSetDefaults - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.FeatureSetDefaults} FeatureSetDefaults - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - FeatureSetDefaults.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.google.protobuf.FeatureSetDefaults(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - if (!(message.defaults && message.defaults.length)) - message.defaults = []; - message.defaults.push( - $root.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.decode( - reader, - reader.uint32() - ) - ); - break; - } - case 4: { - message.minimumEdition = reader.int32(); - break; - } - case 5: { - message.maximumEdition = reader.int32(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a FeatureSetDefaults message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.FeatureSetDefaults - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.FeatureSetDefaults} FeatureSetDefaults - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - FeatureSetDefaults.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a FeatureSetDefaults message. - * @function verify - * @memberof google.protobuf.FeatureSetDefaults - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - FeatureSetDefaults.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.defaults != null && message.hasOwnProperty("defaults")) { - if (!Array.isArray(message.defaults)) - return "defaults: array expected"; - for (var i = 0; i < message.defaults.length; ++i) { - var error = - $root.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.verify( - message.defaults[i] - ); - if (error) return "defaults." + error; - } - } - if ( - message.minimumEdition != null && - message.hasOwnProperty("minimumEdition") - ) - switch (message.minimumEdition) { - default: - return "minimumEdition: enum value expected"; - case 0: - case 900: - case 998: - case 999: - case 1000: - case 1001: - case 1: - case 2: - case 99997: - case 99998: - case 99999: - case 2147483647: - break; - } - if ( - message.maximumEdition != null && - message.hasOwnProperty("maximumEdition") - ) - switch (message.maximumEdition) { - default: - return "maximumEdition: enum value expected"; - case 0: - case 900: - case 998: - case 999: - case 1000: - case 1001: - case 1: - case 2: - case 99997: - case 99998: - case 99999: - case 2147483647: - break; - } - return null; - }; - - /** - * Creates a FeatureSetDefaults message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.FeatureSetDefaults - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.FeatureSetDefaults} FeatureSetDefaults - */ - FeatureSetDefaults.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.FeatureSetDefaults) - return object; - var message = new $root.google.protobuf.FeatureSetDefaults(); - if (object.defaults) { - if (!Array.isArray(object.defaults)) - throw TypeError( - ".google.protobuf.FeatureSetDefaults.defaults: array expected" - ); - message.defaults = []; - for (var i = 0; i < object.defaults.length; ++i) { - if (typeof object.defaults[i] !== "object") - throw TypeError( - ".google.protobuf.FeatureSetDefaults.defaults: object expected" - ); - message.defaults[i] = - $root.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.fromObject( - object.defaults[i] - ); - } - } - switch (object.minimumEdition) { - default: - if (typeof object.minimumEdition === "number") { - message.minimumEdition = object.minimumEdition; - break; - } - break; - case "EDITION_UNKNOWN": - case 0: - message.minimumEdition = 0; - break; - case "EDITION_LEGACY": - case 900: - message.minimumEdition = 900; - break; - case "EDITION_PROTO2": - case 998: - message.minimumEdition = 998; - break; - case "EDITION_PROTO3": - case 999: - message.minimumEdition = 999; - break; - case "EDITION_2023": - case 1000: - message.minimumEdition = 1000; - break; - case "EDITION_2024": - case 1001: - message.minimumEdition = 1001; - break; - case "EDITION_1_TEST_ONLY": - case 1: - message.minimumEdition = 1; - break; - case "EDITION_2_TEST_ONLY": - case 2: - message.minimumEdition = 2; - break; - case "EDITION_99997_TEST_ONLY": - case 99997: - message.minimumEdition = 99997; - break; - case "EDITION_99998_TEST_ONLY": - case 99998: - message.minimumEdition = 99998; - break; - case "EDITION_99999_TEST_ONLY": - case 99999: - message.minimumEdition = 99999; - break; - case "EDITION_MAX": - case 2147483647: - message.minimumEdition = 2147483647; - break; - } - switch (object.maximumEdition) { - default: - if (typeof object.maximumEdition === "number") { - message.maximumEdition = object.maximumEdition; - break; - } - break; - case "EDITION_UNKNOWN": - case 0: - message.maximumEdition = 0; - break; - case "EDITION_LEGACY": - case 900: - message.maximumEdition = 900; - break; - case "EDITION_PROTO2": - case 998: - message.maximumEdition = 998; - break; - case "EDITION_PROTO3": - case 999: - message.maximumEdition = 999; - break; - case "EDITION_2023": - case 1000: - message.maximumEdition = 1000; - break; - case "EDITION_2024": - case 1001: - message.maximumEdition = 1001; - break; - case "EDITION_1_TEST_ONLY": - case 1: - message.maximumEdition = 1; - break; - case "EDITION_2_TEST_ONLY": - case 2: - message.maximumEdition = 2; - break; - case "EDITION_99997_TEST_ONLY": - case 99997: - message.maximumEdition = 99997; - break; - case "EDITION_99998_TEST_ONLY": - case 99998: - message.maximumEdition = 99998; - break; - case "EDITION_99999_TEST_ONLY": - case 99999: - message.maximumEdition = 99999; - break; - case "EDITION_MAX": - case 2147483647: - message.maximumEdition = 2147483647; - break; - } - return message; - }; - - /** - * Creates a plain object from a FeatureSetDefaults message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.FeatureSetDefaults - * @static - * @param {google.protobuf.FeatureSetDefaults} message FeatureSetDefaults - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - FeatureSetDefaults.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.arrays || options.defaults) object.defaults = []; - if (options.defaults) { - object.minimumEdition = - options.enums === String ? "EDITION_UNKNOWN" : 0; - object.maximumEdition = - options.enums === String ? "EDITION_UNKNOWN" : 0; - } - if (message.defaults && message.defaults.length) { - object.defaults = []; - for (var j = 0; j < message.defaults.length; ++j) - object.defaults[j] = - $root.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.toObject( - message.defaults[j], - options - ); - } - if ( - message.minimumEdition != null && - message.hasOwnProperty("minimumEdition") - ) - object.minimumEdition = - options.enums === String - ? $root.google.protobuf.Edition[message.minimumEdition] === - undefined - ? message.minimumEdition - : $root.google.protobuf.Edition[message.minimumEdition] - : message.minimumEdition; - if ( - message.maximumEdition != null && - message.hasOwnProperty("maximumEdition") - ) - object.maximumEdition = - options.enums === String - ? $root.google.protobuf.Edition[message.maximumEdition] === - undefined - ? message.maximumEdition - : $root.google.protobuf.Edition[message.maximumEdition] - : message.maximumEdition; - return object; - }; - - /** - * Converts this FeatureSetDefaults to JSON. - * @function toJSON - * @memberof google.protobuf.FeatureSetDefaults - * @instance - * @returns {Object.} JSON object - */ - FeatureSetDefaults.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for FeatureSetDefaults - * @function getTypeUrl - * @memberof google.protobuf.FeatureSetDefaults - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - FeatureSetDefaults.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.FeatureSetDefaults"; - }; - - FeatureSetDefaults.FeatureSetEditionDefault = (function () { /** - * Properties of a FeatureSetEditionDefault. - * @memberof google.protobuf.FeatureSetDefaults - * @interface IFeatureSetEditionDefault - * @property {google.protobuf.Edition|null} [edition] FeatureSetEditionDefault edition - * @property {google.protobuf.IFeatureSet|null} [overridableFeatures] FeatureSetEditionDefault overridableFeatures - * @property {google.protobuf.IFeatureSet|null} [fixedFeatures] FeatureSetEditionDefault fixedFeatures + * Properties of a CSHallThemeReq. + * @memberof cs + * @interface ICSHallThemeReq */ /** - * Constructs a new FeatureSetEditionDefault. - * @memberof google.protobuf.FeatureSetDefaults - * @classdesc Represents a FeatureSetEditionDefault. - * @implements IFeatureSetEditionDefault + * Constructs a new CSHallThemeReq. + * @memberof cs + * @classdesc Represents a CSHallThemeReq. + * @implements ICSHallThemeReq * @constructor - * @param {google.protobuf.FeatureSetDefaults.IFeatureSetEditionDefault=} [properties] Properties to set + * @param {cs.ICSHallThemeReq=} [properties] Properties to set */ - function FeatureSetEditionDefault(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]]; + 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]]; } /** - * FeatureSetEditionDefault edition. - * @member {google.protobuf.Edition} edition - * @memberof google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault - * @instance - */ - FeatureSetEditionDefault.prototype.edition = 0; - - /** - * FeatureSetEditionDefault overridableFeatures. - * @member {google.protobuf.IFeatureSet|null|undefined} overridableFeatures - * @memberof google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault - * @instance - */ - FeatureSetEditionDefault.prototype.overridableFeatures = null; - - /** - * FeatureSetEditionDefault fixedFeatures. - * @member {google.protobuf.IFeatureSet|null|undefined} fixedFeatures - * @memberof google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault - * @instance - */ - FeatureSetEditionDefault.prototype.fixedFeatures = null; - - /** - * Creates a new FeatureSetEditionDefault instance using the specified properties. + * Creates a new CSHallThemeReq instance using the specified properties. * @function create - * @memberof google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault + * @memberof cs.CSHallThemeReq * @static - * @param {google.protobuf.FeatureSetDefaults.IFeatureSetEditionDefault=} [properties] Properties to set - * @returns {google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault} FeatureSetEditionDefault instance + * @param {cs.ICSHallThemeReq=} [properties] Properties to set + * @returns {cs.CSHallThemeReq} CSHallThemeReq instance */ - FeatureSetEditionDefault.create = function create(properties) { - return new FeatureSetEditionDefault(properties); + CSHallThemeReq.create = function create(properties) { + return new CSHallThemeReq(properties); }; /** - * Encodes the specified FeatureSetEditionDefault message. Does not implicitly {@link google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.verify|verify} messages. + * Encodes the specified CSHallThemeReq message. Does not implicitly {@link cs.CSHallThemeReq.verify|verify} messages. * @function encode - * @memberof google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault + * @memberof cs.CSHallThemeReq * @static - * @param {google.protobuf.FeatureSetDefaults.IFeatureSetEditionDefault} message FeatureSetEditionDefault message or plain object to encode + * @param {cs.ICSHallThemeReq} message CSHallThemeReq message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - FeatureSetEditionDefault.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if ( - message.edition != null && - Object.hasOwnProperty.call(message, "edition") - ) - writer.uint32(/* id 3, wireType 0 =*/ 24).int32(message.edition); - if ( - message.overridableFeatures != null && - Object.hasOwnProperty.call(message, "overridableFeatures") - ) - $root.google.protobuf.FeatureSet.encode( - message.overridableFeatures, - writer.uint32(/* id 4, wireType 2 =*/ 34).fork() - ).ldelim(); - if ( - message.fixedFeatures != null && - Object.hasOwnProperty.call(message, "fixedFeatures") - ) - $root.google.protobuf.FeatureSet.encode( - message.fixedFeatures, - writer.uint32(/* id 5, wireType 2 =*/ 42).fork() - ).ldelim(); - return writer; + CSHallThemeReq.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + return writer; }; /** - * Encodes the specified FeatureSetEditionDefault message, length delimited. Does not implicitly {@link google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.verify|verify} messages. + * Encodes the specified CSHallThemeReq message, length delimited. Does not implicitly {@link cs.CSHallThemeReq.verify|verify} messages. * @function encodeDelimited - * @memberof google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault + * @memberof cs.CSHallThemeReq * @static - * @param {google.protobuf.FeatureSetDefaults.IFeatureSetEditionDefault} message FeatureSetEditionDefault message or plain object to encode + * @param {cs.ICSHallThemeReq} message CSHallThemeReq message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - FeatureSetEditionDefault.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); + CSHallThemeReq.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); }; /** - * Decodes a FeatureSetEditionDefault message from the specified reader or buffer. + * Decodes a CSHallThemeReq message from the specified reader or buffer. * @function decode - * @memberof google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault + * @memberof cs.CSHallThemeReq * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault} FeatureSetEditionDefault + * @returns {cs.CSHallThemeReq} CSHallThemeReq * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - FeatureSetEditionDefault.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.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 3: { - message.edition = reader.int32(); - break; - } - case 4: { - message.overridableFeatures = - $root.google.protobuf.FeatureSet.decode( - reader, - reader.uint32() - ); - break; - } - case 5: { - message.fixedFeatures = $root.google.protobuf.FeatureSet.decode( - reader, - reader.uint32() - ); - break; - } - default: - reader.skipType(tag & 7); - break; + 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; + } } - } - return message; + return message; }; /** - * Decodes a FeatureSetEditionDefault message from the specified reader or buffer, length delimited. + * Decodes a CSHallThemeReq message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault + * @memberof cs.CSHallThemeReq * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault} FeatureSetEditionDefault + * @returns {cs.CSHallThemeReq} CSHallThemeReq * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - FeatureSetEditionDefault.decodeDelimited = function decodeDelimited( - reader - ) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); + CSHallThemeReq.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); }; /** - * Verifies a FeatureSetEditionDefault message. + * Verifies a CSHallThemeReq message. * @function verify - * @memberof google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault + * @memberof cs.CSHallThemeReq * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - FeatureSetEditionDefault.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.edition != null && message.hasOwnProperty("edition")) - switch (message.edition) { - default: - return "edition: enum value expected"; - case 0: - case 900: - case 998: - case 999: - case 1000: - case 1001: - case 1: - case 2: - case 99997: - case 99998: - case 99999: - case 2147483647: - break; - } - if ( - message.overridableFeatures != null && - message.hasOwnProperty("overridableFeatures") - ) { - var error = $root.google.protobuf.FeatureSet.verify( - message.overridableFeatures - ); - if (error) return "overridableFeatures." + error; - } - if ( - message.fixedFeatures != null && - message.hasOwnProperty("fixedFeatures") - ) { - var error = $root.google.protobuf.FeatureSet.verify( - message.fixedFeatures - ); - if (error) return "fixedFeatures." + error; - } - return null; + CSHallThemeReq.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + return null; }; /** - * Creates a FeatureSetEditionDefault message from a plain object. Also converts values to their respective internal types. + * Creates a CSHallThemeReq message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault + * @memberof cs.CSHallThemeReq * @static * @param {Object.} object Plain object - * @returns {google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault} FeatureSetEditionDefault + * @returns {cs.CSHallThemeReq} CSHallThemeReq */ - FeatureSetEditionDefault.fromObject = function fromObject(object) { - if ( - object instanceof - $root.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault - ) - return object; - var message = - new $root.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault(); - switch (object.edition) { - default: - if (typeof object.edition === "number") { - message.edition = object.edition; - break; - } - break; - case "EDITION_UNKNOWN": - case 0: - message.edition = 0; - break; - case "EDITION_LEGACY": - case 900: - message.edition = 900; - break; - case "EDITION_PROTO2": - case 998: - message.edition = 998; - break; - case "EDITION_PROTO3": - case 999: - message.edition = 999; - break; - case "EDITION_2023": - case 1000: - message.edition = 1000; - break; - case "EDITION_2024": - case 1001: - message.edition = 1001; - break; - case "EDITION_1_TEST_ONLY": - case 1: - message.edition = 1; - break; - case "EDITION_2_TEST_ONLY": - case 2: - message.edition = 2; - break; - case "EDITION_99997_TEST_ONLY": - case 99997: - message.edition = 99997; - break; - case "EDITION_99998_TEST_ONLY": - case 99998: - message.edition = 99998; - break; - case "EDITION_99999_TEST_ONLY": - case 99999: - message.edition = 99999; - break; - case "EDITION_MAX": - case 2147483647: - message.edition = 2147483647; - break; - } - if (object.overridableFeatures != null) { - if (typeof object.overridableFeatures !== "object") - throw TypeError( - ".google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.overridableFeatures: object expected" - ); - message.overridableFeatures = - $root.google.protobuf.FeatureSet.fromObject( - object.overridableFeatures - ); - } - if (object.fixedFeatures != null) { - if (typeof object.fixedFeatures !== "object") - throw TypeError( - ".google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.fixedFeatures: object expected" - ); - message.fixedFeatures = $root.google.protobuf.FeatureSet.fromObject( - object.fixedFeatures - ); - } - return message; + CSHallThemeReq.fromObject = function fromObject(object) { + if (object instanceof $root.cs.CSHallThemeReq) + return object; + return new $root.cs.CSHallThemeReq(); }; /** - * Creates a plain object from a FeatureSetEditionDefault message. Also converts values to other types if specified. + * Creates a plain object from a CSHallThemeReq message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault + * @memberof cs.CSHallThemeReq * @static - * @param {google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault} message FeatureSetEditionDefault + * @param {cs.CSHallThemeReq} message CSHallThemeReq * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - FeatureSetEditionDefault.toObject = function toObject( - message, - options - ) { - if (!options) options = {}; - var object = {}; - if (options.defaults) { - object.edition = options.enums === String ? "EDITION_UNKNOWN" : 0; - object.overridableFeatures = null; - object.fixedFeatures = null; - } - if (message.edition != null && message.hasOwnProperty("edition")) - object.edition = - options.enums === String - ? $root.google.protobuf.Edition[message.edition] === undefined - ? message.edition - : $root.google.protobuf.Edition[message.edition] - : message.edition; - if ( - message.overridableFeatures != null && - message.hasOwnProperty("overridableFeatures") - ) - object.overridableFeatures = - $root.google.protobuf.FeatureSet.toObject( - message.overridableFeatures, - options - ); - if ( - message.fixedFeatures != null && - message.hasOwnProperty("fixedFeatures") - ) - object.fixedFeatures = $root.google.protobuf.FeatureSet.toObject( - message.fixedFeatures, - options - ); - return object; + CSHallThemeReq.toObject = function toObject() { + return {}; }; /** - * Converts this FeatureSetEditionDefault to JSON. + * Converts this CSHallThemeReq to JSON. * @function toJSON - * @memberof google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault + * @memberof cs.CSHallThemeReq * @instance * @returns {Object.} JSON object */ - FeatureSetEditionDefault.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + CSHallThemeReq.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for FeatureSetEditionDefault + * Gets the default type url for CSHallThemeReq * @function getTypeUrl - * @memberof google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault + * @memberof cs.CSHallThemeReq * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - FeatureSetEditionDefault.getTypeUrl = function getTypeUrl( - typeUrlPrefix - ) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return ( - typeUrlPrefix + - "/google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault" - ); + CSHallThemeReq.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/cs.CSHallThemeReq"; }; - return FeatureSetEditionDefault; - })(); - - return FeatureSetDefaults; + return CSHallThemeReq; })(); - protobuf.SourceCodeInfo = (function () { - /** - * Properties of a SourceCodeInfo. - * @memberof google.protobuf - * @interface ISourceCodeInfo - * @property {Array.|null} [location] SourceCodeInfo location - */ + cs.HallTheme = (function() { - /** - * Constructs a new SourceCodeInfo. - * @memberof google.protobuf - * @classdesc Represents a SourceCodeInfo. - * @implements ISourceCodeInfo - * @constructor - * @param {google.protobuf.ISourceCodeInfo=} [properties] Properties to set - */ - function SourceCodeInfo(properties) { - this.location = []; - 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]]; - } - - /** - * SourceCodeInfo location. - * @member {Array.} location - * @memberof google.protobuf.SourceCodeInfo - * @instance - */ - SourceCodeInfo.prototype.location = $util.emptyArray; - - /** - * Creates a new SourceCodeInfo instance using the specified properties. - * @function create - * @memberof google.protobuf.SourceCodeInfo - * @static - * @param {google.protobuf.ISourceCodeInfo=} [properties] Properties to set - * @returns {google.protobuf.SourceCodeInfo} SourceCodeInfo instance - */ - SourceCodeInfo.create = function create(properties) { - return new SourceCodeInfo(properties); - }; - - /** - * Encodes the specified SourceCodeInfo message. Does not implicitly {@link google.protobuf.SourceCodeInfo.verify|verify} messages. - * @function encode - * @memberof google.protobuf.SourceCodeInfo - * @static - * @param {google.protobuf.ISourceCodeInfo} message SourceCodeInfo message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - SourceCodeInfo.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if (message.location != null && message.location.length) - for (var i = 0; i < message.location.length; ++i) - $root.google.protobuf.SourceCodeInfo.Location.encode( - message.location[i], - writer.uint32(/* id 1, wireType 2 =*/ 10).fork() - ).ldelim(); - return writer; - }; - - /** - * Encodes the specified SourceCodeInfo message, length delimited. Does not implicitly {@link google.protobuf.SourceCodeInfo.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.SourceCodeInfo - * @static - * @param {google.protobuf.ISourceCodeInfo} message SourceCodeInfo message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - SourceCodeInfo.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a SourceCodeInfo message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.SourceCodeInfo - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.SourceCodeInfo} SourceCodeInfo - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - SourceCodeInfo.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.google.protobuf.SourceCodeInfo(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - if (!(message.location && message.location.length)) - message.location = []; - message.location.push( - $root.google.protobuf.SourceCodeInfo.Location.decode( - reader, - reader.uint32() - ) - ); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a SourceCodeInfo message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.SourceCodeInfo - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.SourceCodeInfo} SourceCodeInfo - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - SourceCodeInfo.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a SourceCodeInfo message. - * @function verify - * @memberof google.protobuf.SourceCodeInfo - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - SourceCodeInfo.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.location != null && message.hasOwnProperty("location")) { - if (!Array.isArray(message.location)) - return "location: array expected"; - for (var i = 0; i < message.location.length; ++i) { - var error = $root.google.protobuf.SourceCodeInfo.Location.verify( - message.location[i] - ); - if (error) return "location." + error; - } - } - return null; - }; - - /** - * Creates a SourceCodeInfo message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.SourceCodeInfo - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.SourceCodeInfo} SourceCodeInfo - */ - SourceCodeInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.SourceCodeInfo) - return object; - var message = new $root.google.protobuf.SourceCodeInfo(); - if (object.location) { - if (!Array.isArray(object.location)) - throw TypeError( - ".google.protobuf.SourceCodeInfo.location: array expected" - ); - message.location = []; - for (var i = 0; i < object.location.length; ++i) { - if (typeof object.location[i] !== "object") - throw TypeError( - ".google.protobuf.SourceCodeInfo.location: object expected" - ); - message.location[i] = - $root.google.protobuf.SourceCodeInfo.Location.fromObject( - object.location[i] - ); - } - } - return message; - }; - - /** - * Creates a plain object from a SourceCodeInfo message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.SourceCodeInfo - * @static - * @param {google.protobuf.SourceCodeInfo} message SourceCodeInfo - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - SourceCodeInfo.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.arrays || options.defaults) object.location = []; - if (message.location && message.location.length) { - object.location = []; - for (var j = 0; j < message.location.length; ++j) - object.location[j] = - $root.google.protobuf.SourceCodeInfo.Location.toObject( - message.location[j], - options - ); - } - return object; - }; - - /** - * Converts this SourceCodeInfo to JSON. - * @function toJSON - * @memberof google.protobuf.SourceCodeInfo - * @instance - * @returns {Object.} JSON object - */ - SourceCodeInfo.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for SourceCodeInfo - * @function getTypeUrl - * @memberof google.protobuf.SourceCodeInfo - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - SourceCodeInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.SourceCodeInfo"; - }; - - SourceCodeInfo.Location = (function () { /** - * Properties of a Location. - * @memberof google.protobuf.SourceCodeInfo - * @interface ILocation - * @property {Array.|null} [path] Location path - * @property {Array.|null} [span] Location span - * @property {string|null} [leadingComments] Location leadingComments - * @property {string|null} [trailingComments] Location trailingComments - * @property {Array.|null} [leadingDetachedComments] Location leadingDetachedComments + * 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 + * @property {boolean|null} [isLock] HallTheme isLock + * @property {string|null} [path] HallTheme path */ /** - * Constructs a new Location. - * @memberof google.protobuf.SourceCodeInfo - * @classdesc Represents a Location. - * @implements ILocation + * Constructs a new HallTheme. + * @memberof cs + * @classdesc Represents a HallTheme. + * @implements IHallTheme * @constructor - * @param {google.protobuf.SourceCodeInfo.ILocation=} [properties] Properties to set + * @param {cs.IHallTheme=} [properties] Properties to set */ - function Location(properties) { - this.path = []; - this.span = []; - this.leadingDetachedComments = []; - 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]]; + 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]]; } /** - * Location path. - * @member {Array.} path - * @memberof google.protobuf.SourceCodeInfo.Location + * HallTheme id. + * @member {number} id + * @memberof cs.HallTheme * @instance */ - Location.prototype.path = $util.emptyArray; + HallTheme.prototype.id = 0; /** - * Location span. - * @member {Array.} span - * @memberof google.protobuf.SourceCodeInfo.Location + * HallTheme key. + * @member {string} key + * @memberof cs.HallTheme * @instance */ - Location.prototype.span = $util.emptyArray; + HallTheme.prototype.key = ""; /** - * Location leadingComments. - * @member {string} leadingComments - * @memberof google.protobuf.SourceCodeInfo.Location + * HallTheme name. + * @member {string} name + * @memberof cs.HallTheme * @instance */ - Location.prototype.leadingComments = ""; + HallTheme.prototype.name = ""; /** - * Location trailingComments. - * @member {string} trailingComments - * @memberof google.protobuf.SourceCodeInfo.Location + * HallTheme category. + * @member {number} category + * @memberof cs.HallTheme * @instance */ - Location.prototype.trailingComments = ""; + HallTheme.prototype.category = 0; /** - * Location leadingDetachedComments. - * @member {Array.} leadingDetachedComments - * @memberof google.protobuf.SourceCodeInfo.Location + * HallTheme isLock. + * @member {boolean} isLock + * @memberof cs.HallTheme * @instance */ - Location.prototype.leadingDetachedComments = $util.emptyArray; + HallTheme.prototype.isLock = false; /** - * Creates a new Location instance using the specified properties. + * HallTheme path. + * @member {string} path + * @memberof cs.HallTheme + * @instance + */ + HallTheme.prototype.path = ""; + + /** + * Creates a new HallTheme instance using the specified properties. * @function create - * @memberof google.protobuf.SourceCodeInfo.Location + * @memberof cs.HallTheme * @static - * @param {google.protobuf.SourceCodeInfo.ILocation=} [properties] Properties to set - * @returns {google.protobuf.SourceCodeInfo.Location} Location instance + * @param {cs.IHallTheme=} [properties] Properties to set + * @returns {cs.HallTheme} HallTheme instance */ - Location.create = function create(properties) { - return new Location(properties); + HallTheme.create = function create(properties) { + return new HallTheme(properties); }; /** - * Encodes the specified Location message. Does not implicitly {@link google.protobuf.SourceCodeInfo.Location.verify|verify} messages. + * Encodes the specified HallTheme message. Does not implicitly {@link cs.HallTheme.verify|verify} messages. * @function encode - * @memberof google.protobuf.SourceCodeInfo.Location + * @memberof cs.HallTheme * @static - * @param {google.protobuf.SourceCodeInfo.ILocation} message Location message or plain object to encode + * @param {cs.IHallTheme} message HallTheme message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Location.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if (message.path != null && message.path.length) { - writer.uint32(/* id 1, wireType 2 =*/ 10).fork(); - for (var i = 0; i < message.path.length; ++i) - writer.int32(message.path[i]); - writer.ldelim(); - } - if (message.span != null && message.span.length) { - writer.uint32(/* id 2, wireType 2 =*/ 18).fork(); - for (var i = 0; i < message.span.length; ++i) - writer.int32(message.span[i]); - writer.ldelim(); - } - if ( - message.leadingComments != null && - Object.hasOwnProperty.call(message, "leadingComments") - ) - writer - .uint32(/* id 3, wireType 2 =*/ 26) - .string(message.leadingComments); - if ( - message.trailingComments != null && - Object.hasOwnProperty.call(message, "trailingComments") - ) - writer - .uint32(/* id 4, wireType 2 =*/ 34) - .string(message.trailingComments); - if ( - message.leadingDetachedComments != null && - message.leadingDetachedComments.length - ) - for (var i = 0; i < message.leadingDetachedComments.length; ++i) - writer - .uint32(/* id 6, wireType 2 =*/ 50) - .string(message.leadingDetachedComments[i]); - return writer; + 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); + if (message.isLock != null && Object.hasOwnProperty.call(message, "isLock")) + writer.uint32(/* id 5, wireType 0 =*/40).bool(message.isLock); + if (message.path != null && Object.hasOwnProperty.call(message, "path")) + writer.uint32(/* id 6, wireType 2 =*/50).string(message.path); + return writer; }; /** - * Encodes the specified Location message, length delimited. Does not implicitly {@link google.protobuf.SourceCodeInfo.Location.verify|verify} messages. + * Encodes the specified HallTheme message, length delimited. Does not implicitly {@link cs.HallTheme.verify|verify} messages. * @function encodeDelimited - * @memberof google.protobuf.SourceCodeInfo.Location + * @memberof cs.HallTheme * @static - * @param {google.protobuf.SourceCodeInfo.ILocation} message Location message or plain object to encode + * @param {cs.IHallTheme} message HallTheme message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Location.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); + HallTheme.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); }; /** - * Decodes a Location message from the specified reader or buffer. + * Decodes a HallTheme message from the specified reader or buffer. * @function decode - * @memberof google.protobuf.SourceCodeInfo.Location + * @memberof cs.HallTheme * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.SourceCodeInfo.Location} Location + * @returns {cs.HallTheme} HallTheme * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Location.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.google.protobuf.SourceCodeInfo.Location(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - if (!(message.path && message.path.length)) message.path = []; - if ((tag & 7) === 2) { - var end2 = reader.uint32() + reader.pos; - while (reader.pos < end2) message.path.push(reader.int32()); - } else message.path.push(reader.int32()); - break; - } - case 2: { - if (!(message.span && message.span.length)) message.span = []; - if ((tag & 7) === 2) { - var end2 = reader.uint32() + reader.pos; - while (reader.pos < end2) message.span.push(reader.int32()); - } else message.span.push(reader.int32()); - break; - } - case 3: { - message.leadingComments = reader.string(); - break; - } - case 4: { - message.trailingComments = reader.string(); - break; - } - case 6: { - if ( - !( - message.leadingDetachedComments && - message.leadingDetachedComments.length - ) - ) - message.leadingDetachedComments = []; - message.leadingDetachedComments.push(reader.string()); - break; - } - default: - reader.skipType(tag & 7); - break; + 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: { + message.isLock = reader.bool(); + break; + } + case 6: { + message.path = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } } - } - return message; + return message; }; /** - * Decodes a Location message from the specified reader or buffer, length delimited. + * Decodes a HallTheme message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.protobuf.SourceCodeInfo.Location + * @memberof cs.HallTheme * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.SourceCodeInfo.Location} Location + * @returns {cs.HallTheme} HallTheme * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Location.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); + HallTheme.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); }; /** - * Verifies a Location message. + * Verifies a HallTheme message. * @function verify - * @memberof google.protobuf.SourceCodeInfo.Location + * @memberof cs.HallTheme * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - Location.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.path != null && message.hasOwnProperty("path")) { - if (!Array.isArray(message.path)) return "path: array expected"; - for (var i = 0; i < message.path.length; ++i) - if (!$util.isInteger(message.path[i])) - return "path: integer[] expected"; - } - if (message.span != null && message.hasOwnProperty("span")) { - if (!Array.isArray(message.span)) return "span: array expected"; - for (var i = 0; i < message.span.length; ++i) - if (!$util.isInteger(message.span[i])) - return "span: integer[] expected"; - } - if ( - message.leadingComments != null && - message.hasOwnProperty("leadingComments") - ) - if (!$util.isString(message.leadingComments)) - return "leadingComments: string expected"; - if ( - message.trailingComments != null && - message.hasOwnProperty("trailingComments") - ) - if (!$util.isString(message.trailingComments)) - return "trailingComments: string expected"; - if ( - message.leadingDetachedComments != null && - message.hasOwnProperty("leadingDetachedComments") - ) { - if (!Array.isArray(message.leadingDetachedComments)) - return "leadingDetachedComments: array expected"; - for (var i = 0; i < message.leadingDetachedComments.length; ++i) - if (!$util.isString(message.leadingDetachedComments[i])) - return "leadingDetachedComments: string[] expected"; - } - return null; + 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"; + if (message.isLock != null && message.hasOwnProperty("isLock")) + if (typeof message.isLock !== "boolean") + return "isLock: boolean expected"; + if (message.path != null && message.hasOwnProperty("path")) + if (!$util.isString(message.path)) + return "path: string expected"; + return null; }; /** - * Creates a Location message from a plain object. Also converts values to their respective internal types. + * Creates a HallTheme message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.protobuf.SourceCodeInfo.Location + * @memberof cs.HallTheme * @static * @param {Object.} object Plain object - * @returns {google.protobuf.SourceCodeInfo.Location} Location + * @returns {cs.HallTheme} HallTheme */ - Location.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.SourceCodeInfo.Location) - return object; - var message = new $root.google.protobuf.SourceCodeInfo.Location(); - if (object.path) { - if (!Array.isArray(object.path)) - throw TypeError( - ".google.protobuf.SourceCodeInfo.Location.path: array expected" - ); - message.path = []; - for (var i = 0; i < object.path.length; ++i) - message.path[i] = object.path[i] | 0; - } - if (object.span) { - if (!Array.isArray(object.span)) - throw TypeError( - ".google.protobuf.SourceCodeInfo.Location.span: array expected" - ); - message.span = []; - for (var i = 0; i < object.span.length; ++i) - message.span[i] = object.span[i] | 0; - } - if (object.leadingComments != null) - message.leadingComments = String(object.leadingComments); - if (object.trailingComments != null) - message.trailingComments = String(object.trailingComments); - if (object.leadingDetachedComments) { - if (!Array.isArray(object.leadingDetachedComments)) - throw TypeError( - ".google.protobuf.SourceCodeInfo.Location.leadingDetachedComments: array expected" - ); - message.leadingDetachedComments = []; - for (var i = 0; i < object.leadingDetachedComments.length; ++i) - message.leadingDetachedComments[i] = String( - object.leadingDetachedComments[i] - ); - } - return message; + 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; + if (object.isLock != null) + message.isLock = Boolean(object.isLock); + if (object.path != null) + message.path = String(object.path); + return message; }; /** - * Creates a plain object from a Location message. Also converts values to other types if specified. + * Creates a plain object from a HallTheme message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.SourceCodeInfo.Location + * @memberof cs.HallTheme * @static - * @param {google.protobuf.SourceCodeInfo.Location} message Location + * @param {cs.HallTheme} message HallTheme * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - Location.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.arrays || options.defaults) { - object.path = []; - object.span = []; - object.leadingDetachedComments = []; - } - if (options.defaults) { - object.leadingComments = ""; - object.trailingComments = ""; - } - if (message.path && message.path.length) { - object.path = []; - for (var j = 0; j < message.path.length; ++j) - object.path[j] = message.path[j]; - } - if (message.span && message.span.length) { - object.span = []; - for (var j = 0; j < message.span.length; ++j) - object.span[j] = message.span[j]; - } - if ( - message.leadingComments != null && - message.hasOwnProperty("leadingComments") - ) - object.leadingComments = message.leadingComments; - if ( - message.trailingComments != null && - message.hasOwnProperty("trailingComments") - ) - object.trailingComments = message.trailingComments; - if ( - message.leadingDetachedComments && - message.leadingDetachedComments.length - ) { - object.leadingDetachedComments = []; - for (var j = 0; j < message.leadingDetachedComments.length; ++j) - object.leadingDetachedComments[j] = - message.leadingDetachedComments[j]; - } - return object; + HallTheme.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.id = 0; + object.key = ""; + object.name = ""; + object.category = 0; + object.isLock = false; + 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; + if (message.isLock != null && message.hasOwnProperty("isLock")) + object.isLock = message.isLock; + if (message.path != null && message.hasOwnProperty("path")) + object.path = message.path; + return object; }; /** - * Converts this Location to JSON. + * Converts this HallTheme to JSON. * @function toJSON - * @memberof google.protobuf.SourceCodeInfo.Location + * @memberof cs.HallTheme * @instance * @returns {Object.} JSON object */ - Location.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + HallTheme.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for Location + * Gets the default type url for HallTheme * @function getTypeUrl - * @memberof google.protobuf.SourceCodeInfo.Location + * @memberof cs.HallTheme * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - Location.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.SourceCodeInfo.Location"; + HallTheme.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/cs.HallTheme"; }; - return Location; - })(); - - return SourceCodeInfo; + return HallTheme; })(); - protobuf.GeneratedCodeInfo = (function () { - /** - * Properties of a GeneratedCodeInfo. - * @memberof google.protobuf - * @interface IGeneratedCodeInfo - * @property {Array.|null} [annotation] GeneratedCodeInfo annotation - */ + cs.CSHallThemeRes = (function() { - /** - * Constructs a new GeneratedCodeInfo. - * @memberof google.protobuf - * @classdesc Represents a GeneratedCodeInfo. - * @implements IGeneratedCodeInfo - * @constructor - * @param {google.protobuf.IGeneratedCodeInfo=} [properties] Properties to set - */ - function GeneratedCodeInfo(properties) { - this.annotation = []; - 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]]; - } - - /** - * GeneratedCodeInfo annotation. - * @member {Array.} annotation - * @memberof google.protobuf.GeneratedCodeInfo - * @instance - */ - GeneratedCodeInfo.prototype.annotation = $util.emptyArray; - - /** - * Creates a new GeneratedCodeInfo instance using the specified properties. - * @function create - * @memberof google.protobuf.GeneratedCodeInfo - * @static - * @param {google.protobuf.IGeneratedCodeInfo=} [properties] Properties to set - * @returns {google.protobuf.GeneratedCodeInfo} GeneratedCodeInfo instance - */ - GeneratedCodeInfo.create = function create(properties) { - return new GeneratedCodeInfo(properties); - }; - - /** - * Encodes the specified GeneratedCodeInfo message. Does not implicitly {@link google.protobuf.GeneratedCodeInfo.verify|verify} messages. - * @function encode - * @memberof google.protobuf.GeneratedCodeInfo - * @static - * @param {google.protobuf.IGeneratedCodeInfo} message GeneratedCodeInfo message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - GeneratedCodeInfo.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if (message.annotation != null && message.annotation.length) - for (var i = 0; i < message.annotation.length; ++i) - $root.google.protobuf.GeneratedCodeInfo.Annotation.encode( - message.annotation[i], - writer.uint32(/* id 1, wireType 2 =*/ 10).fork() - ).ldelim(); - return writer; - }; - - /** - * Encodes the specified GeneratedCodeInfo message, length delimited. Does not implicitly {@link google.protobuf.GeneratedCodeInfo.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.GeneratedCodeInfo - * @static - * @param {google.protobuf.IGeneratedCodeInfo} message GeneratedCodeInfo message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - GeneratedCodeInfo.encodeDelimited = function encodeDelimited( - message, - writer - ) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a GeneratedCodeInfo message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.GeneratedCodeInfo - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.GeneratedCodeInfo} GeneratedCodeInfo - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - GeneratedCodeInfo.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.google.protobuf.GeneratedCodeInfo(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - if (!(message.annotation && message.annotation.length)) - message.annotation = []; - message.annotation.push( - $root.google.protobuf.GeneratedCodeInfo.Annotation.decode( - reader, - reader.uint32() - ) - ); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a GeneratedCodeInfo message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.GeneratedCodeInfo - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.GeneratedCodeInfo} GeneratedCodeInfo - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - GeneratedCodeInfo.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a GeneratedCodeInfo message. - * @function verify - * @memberof google.protobuf.GeneratedCodeInfo - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - GeneratedCodeInfo.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if ( - message.annotation != null && - message.hasOwnProperty("annotation") - ) { - if (!Array.isArray(message.annotation)) - return "annotation: array expected"; - for (var i = 0; i < message.annotation.length; ++i) { - var error = - $root.google.protobuf.GeneratedCodeInfo.Annotation.verify( - message.annotation[i] - ); - if (error) return "annotation." + error; - } - } - return null; - }; - - /** - * Creates a GeneratedCodeInfo message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.GeneratedCodeInfo - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.GeneratedCodeInfo} GeneratedCodeInfo - */ - GeneratedCodeInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.GeneratedCodeInfo) - return object; - var message = new $root.google.protobuf.GeneratedCodeInfo(); - if (object.annotation) { - if (!Array.isArray(object.annotation)) - throw TypeError( - ".google.protobuf.GeneratedCodeInfo.annotation: array expected" - ); - message.annotation = []; - for (var i = 0; i < object.annotation.length; ++i) { - if (typeof object.annotation[i] !== "object") - throw TypeError( - ".google.protobuf.GeneratedCodeInfo.annotation: object expected" - ); - message.annotation[i] = - $root.google.protobuf.GeneratedCodeInfo.Annotation.fromObject( - object.annotation[i] - ); - } - } - return message; - }; - - /** - * Creates a plain object from a GeneratedCodeInfo message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.GeneratedCodeInfo - * @static - * @param {google.protobuf.GeneratedCodeInfo} message GeneratedCodeInfo - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - GeneratedCodeInfo.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.arrays || options.defaults) object.annotation = []; - if (message.annotation && message.annotation.length) { - object.annotation = []; - for (var j = 0; j < message.annotation.length; ++j) - object.annotation[j] = - $root.google.protobuf.GeneratedCodeInfo.Annotation.toObject( - message.annotation[j], - options - ); - } - return object; - }; - - /** - * Converts this GeneratedCodeInfo to JSON. - * @function toJSON - * @memberof google.protobuf.GeneratedCodeInfo - * @instance - * @returns {Object.} JSON object - */ - GeneratedCodeInfo.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for GeneratedCodeInfo - * @function getTypeUrl - * @memberof google.protobuf.GeneratedCodeInfo - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - GeneratedCodeInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.GeneratedCodeInfo"; - }; - - GeneratedCodeInfo.Annotation = (function () { /** - * Properties of an Annotation. - * @memberof google.protobuf.GeneratedCodeInfo - * @interface IAnnotation - * @property {Array.|null} [path] Annotation path - * @property {string|null} [sourceFile] Annotation sourceFile - * @property {number|null} [begin] Annotation begin - * @property {number|null} [end] Annotation end - * @property {google.protobuf.GeneratedCodeInfo.Annotation.Semantic|null} [semantic] Annotation semantic + * Properties of a CSHallThemeRes. + * @memberof cs + * @interface ICSHallThemeRes + * @property {Array.|null} [themes] CSHallThemeRes themes */ /** - * Constructs a new Annotation. - * @memberof google.protobuf.GeneratedCodeInfo - * @classdesc Represents an Annotation. - * @implements IAnnotation + * Constructs a new CSHallThemeRes. + * @memberof cs + * @classdesc Represents a CSHallThemeRes. + * @implements ICSHallThemeRes * @constructor - * @param {google.protobuf.GeneratedCodeInfo.IAnnotation=} [properties] Properties to set + * @param {cs.ICSHallThemeRes=} [properties] Properties to set */ - function Annotation(properties) { - this.path = []; - 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]]; + 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]]; } /** - * Annotation path. - * @member {Array.} path - * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * CSHallThemeRes themes. + * @member {Array.} themes + * @memberof cs.CSHallThemeRes * @instance */ - Annotation.prototype.path = $util.emptyArray; + CSHallThemeRes.prototype.themes = $util.emptyArray; /** - * Annotation sourceFile. - * @member {string} sourceFile - * @memberof google.protobuf.GeneratedCodeInfo.Annotation - * @instance - */ - Annotation.prototype.sourceFile = ""; - - /** - * Annotation begin. - * @member {number} begin - * @memberof google.protobuf.GeneratedCodeInfo.Annotation - * @instance - */ - Annotation.prototype.begin = 0; - - /** - * Annotation end. - * @member {number} end - * @memberof google.protobuf.GeneratedCodeInfo.Annotation - * @instance - */ - Annotation.prototype.end = 0; - - /** - * Annotation semantic. - * @member {google.protobuf.GeneratedCodeInfo.Annotation.Semantic} semantic - * @memberof google.protobuf.GeneratedCodeInfo.Annotation - * @instance - */ - Annotation.prototype.semantic = 0; - - /** - * Creates a new Annotation instance using the specified properties. + * Creates a new CSHallThemeRes instance using the specified properties. * @function create - * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @memberof cs.CSHallThemeRes * @static - * @param {google.protobuf.GeneratedCodeInfo.IAnnotation=} [properties] Properties to set - * @returns {google.protobuf.GeneratedCodeInfo.Annotation} Annotation instance + * @param {cs.ICSHallThemeRes=} [properties] Properties to set + * @returns {cs.CSHallThemeRes} CSHallThemeRes instance */ - Annotation.create = function create(properties) { - return new Annotation(properties); + CSHallThemeRes.create = function create(properties) { + return new CSHallThemeRes(properties); }; /** - * Encodes the specified Annotation message. Does not implicitly {@link google.protobuf.GeneratedCodeInfo.Annotation.verify|verify} messages. + * Encodes the specified CSHallThemeRes message. Does not implicitly {@link cs.CSHallThemeRes.verify|verify} messages. * @function encode - * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @memberof cs.CSHallThemeRes * @static - * @param {google.protobuf.GeneratedCodeInfo.IAnnotation} message Annotation message or plain object to encode + * @param {cs.ICSHallThemeRes} message CSHallThemeRes message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Annotation.encode = function encode(message, writer) { - if (!writer) writer = $Writer.create(); - if (message.path != null && message.path.length) { - writer.uint32(/* id 1, wireType 2 =*/ 10).fork(); - for (var i = 0; i < message.path.length; ++i) - writer.int32(message.path[i]); - writer.ldelim(); - } - if ( - message.sourceFile != null && - Object.hasOwnProperty.call(message, "sourceFile") - ) - writer - .uint32(/* id 2, wireType 2 =*/ 18) - .string(message.sourceFile); - if ( - message.begin != null && - Object.hasOwnProperty.call(message, "begin") - ) - writer.uint32(/* id 3, wireType 0 =*/ 24).int32(message.begin); - if (message.end != null && Object.hasOwnProperty.call(message, "end")) - writer.uint32(/* id 4, wireType 0 =*/ 32).int32(message.end); - if ( - message.semantic != null && - Object.hasOwnProperty.call(message, "semantic") - ) - writer.uint32(/* id 5, wireType 0 =*/ 40).int32(message.semantic); - return writer; + 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) + $root.cs.HallTheme.encode(message.themes[i], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + return writer; }; /** - * Encodes the specified Annotation message, length delimited. Does not implicitly {@link google.protobuf.GeneratedCodeInfo.Annotation.verify|verify} messages. + * Encodes the specified CSHallThemeRes message, length delimited. Does not implicitly {@link cs.CSHallThemeRes.verify|verify} messages. * @function encodeDelimited - * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @memberof cs.CSHallThemeRes * @static - * @param {google.protobuf.GeneratedCodeInfo.IAnnotation} message Annotation message or plain object to encode + * @param {cs.ICSHallThemeRes} message CSHallThemeRes message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Annotation.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); + CSHallThemeRes.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); }; /** - * Decodes an Annotation message from the specified reader or buffer. + * Decodes a CSHallThemeRes message from the specified reader or buffer. * @function decode - * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @memberof cs.CSHallThemeRes * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.GeneratedCodeInfo.Annotation} Annotation + * @returns {cs.CSHallThemeRes} CSHallThemeRes * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Annotation.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.google.protobuf.GeneratedCodeInfo.Annotation(); - while (reader.pos < end) { - var tag = reader.uint32(); - if (tag === error) break; - switch (tag >>> 3) { - case 1: { - if (!(message.path && message.path.length)) message.path = []; - if ((tag & 7) === 2) { - var end2 = reader.uint32() + reader.pos; - while (reader.pos < end2) message.path.push(reader.int32()); - } else message.path.push(reader.int32()); - break; - } - case 2: { - message.sourceFile = reader.string(); - break; - } - case 3: { - message.begin = reader.int32(); - break; - } - case 4: { - message.end = reader.int32(); - break; - } - case 5: { - message.semantic = reader.int32(); - break; - } - default: - reader.skipType(tag & 7); - break; + 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) { + case 2: { + 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; + } } - } - return message; + return message; }; /** - * Decodes an Annotation message from the specified reader or buffer, length delimited. + * Decodes a CSHallThemeRes message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @memberof cs.CSHallThemeRes * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.GeneratedCodeInfo.Annotation} Annotation + * @returns {cs.CSHallThemeRes} CSHallThemeRes * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Annotation.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); + CSHallThemeRes.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); }; /** - * Verifies an Annotation message. + * Verifies a CSHallThemeRes message. * @function verify - * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @memberof cs.CSHallThemeRes * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - Annotation.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.path != null && message.hasOwnProperty("path")) { - if (!Array.isArray(message.path)) return "path: array expected"; - for (var i = 0; i < message.path.length; ++i) - if (!$util.isInteger(message.path[i])) - return "path: integer[] expected"; - } - if ( - message.sourceFile != null && - message.hasOwnProperty("sourceFile") - ) - if (!$util.isString(message.sourceFile)) - return "sourceFile: string expected"; - if (message.begin != null && message.hasOwnProperty("begin")) - if (!$util.isInteger(message.begin)) - return "begin: integer expected"; - if (message.end != null && message.hasOwnProperty("end")) - if (!$util.isInteger(message.end)) return "end: integer expected"; - if (message.semantic != null && message.hasOwnProperty("semantic")) - switch (message.semantic) { - default: - return "semantic: enum value expected"; - case 0: - case 1: - case 2: - break; + 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; + } } - return null; + return null; }; /** - * Creates an Annotation message from a plain object. Also converts values to their respective internal types. + * Creates a CSHallThemeRes message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @memberof cs.CSHallThemeRes * @static * @param {Object.} object Plain object - * @returns {google.protobuf.GeneratedCodeInfo.Annotation} Annotation + * @returns {cs.CSHallThemeRes} CSHallThemeRes */ - Annotation.fromObject = function fromObject(object) { - if ( - object instanceof $root.google.protobuf.GeneratedCodeInfo.Annotation - ) - return object; - var message = - new $root.google.protobuf.GeneratedCodeInfo.Annotation(); - if (object.path) { - if (!Array.isArray(object.path)) - throw TypeError( - ".google.protobuf.GeneratedCodeInfo.Annotation.path: array expected" - ); - message.path = []; - for (var i = 0; i < object.path.length; ++i) - message.path[i] = object.path[i] | 0; - } - if (object.sourceFile != null) - message.sourceFile = String(object.sourceFile); - if (object.begin != null) message.begin = object.begin | 0; - if (object.end != null) message.end = object.end | 0; - switch (object.semantic) { - default: - if (typeof object.semantic === "number") { - message.semantic = object.semantic; - break; - } - break; - case "NONE": - case 0: - message.semantic = 0; - break; - case "SET": - case 1: - message.semantic = 1; - break; - case "ALIAS": - case 2: - message.semantic = 2; - break; - } - return message; + 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; }; /** - * Creates a plain object from an Annotation message. Also converts values to other types if specified. + * Creates a plain object from a CSHallThemeRes message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @memberof cs.CSHallThemeRes * @static - * @param {google.protobuf.GeneratedCodeInfo.Annotation} message Annotation + * @param {cs.CSHallThemeRes} message CSHallThemeRes * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - Annotation.toObject = function toObject(message, options) { - if (!options) options = {}; - var object = {}; - if (options.arrays || options.defaults) object.path = []; - if (options.defaults) { - object.sourceFile = ""; - object.begin = 0; - object.end = 0; - object.semantic = options.enums === String ? "NONE" : 0; - } - if (message.path && message.path.length) { - object.path = []; - for (var j = 0; j < message.path.length; ++j) - object.path[j] = message.path[j]; - } - if ( - message.sourceFile != null && - message.hasOwnProperty("sourceFile") - ) - object.sourceFile = message.sourceFile; - if (message.begin != null && message.hasOwnProperty("begin")) - object.begin = message.begin; - if (message.end != null && message.hasOwnProperty("end")) - object.end = message.end; - if (message.semantic != null && message.hasOwnProperty("semantic")) - object.semantic = - options.enums === String - ? $root.google.protobuf.GeneratedCodeInfo.Annotation.Semantic[ - message.semantic - ] === undefined - ? message.semantic - : $root.google.protobuf.GeneratedCodeInfo.Annotation.Semantic[ - message.semantic - ] - : message.semantic; - return object; + 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; }; /** - * Converts this Annotation to JSON. + * Converts this CSHallThemeRes to JSON. * @function toJSON - * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @memberof cs.CSHallThemeRes * @instance * @returns {Object.} JSON object */ - Annotation.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + CSHallThemeRes.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for Annotation + * Gets the default type url for CSHallThemeRes * @function getTypeUrl - * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @memberof cs.CSHallThemeRes * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - Annotation.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return ( - typeUrlPrefix + "/google.protobuf.GeneratedCodeInfo.Annotation" - ); + 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 + * @property {string|null} [category] CSGetGirlListReq category + * @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. + * @member {string} category + * @memberof cs.CSGetGirlListReq + * @instance + */ + CSGetGirlListReq.prototype.category = ""; + + /** + * 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); }; /** - * Semantic enum. - * @name google.protobuf.GeneratedCodeInfo.Annotation.Semantic - * @enum {number} - * @property {number} NONE=0 NONE value - * @property {number} SET=1 SET value - * @property {number} ALIAS=2 ALIAS value + * 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 */ - Annotation.Semantic = (function () { - var valuesById = {}, - values = Object.create(valuesById); - values[(valuesById[0] = "NONE")] = 0; - values[(valuesById[1] = "SET")] = 1; - values[(valuesById[2] = "ALIAS")] = 2; - return values; - })(); + CSGetGirlListReq.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.category != null && Object.hasOwnProperty.call(message, "category")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.category); + 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; + }; - return Annotation; - })(); + /** + * 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(); + }; - return GeneratedCodeInfo; + /** + * 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: { + message.category = reader.string(); + 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.} 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")) + if (!$util.isString(message.category)) + return "category: string 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 CSGetGirlListReq message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof cs.CSGetGirlListReq + * @static + * @param {Object.} 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) + message.category = String(object.category); + 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.} Plain object + */ + CSGetGirlListReq.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.category = ""; + 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.} 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.|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.} 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.} 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.} 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.} 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.} 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.} 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.} 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.} 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.} 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.} 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.} 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.} 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.} 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; + })(); + + cs.Diamond = (function() { + + /** + * Properties of a Diamond. + * @memberof cs + * @interface IDiamond + * @property {number|null} [id] Diamond id + * @property {string|null} [name] Diamond name + * @property {string|null} [price] Diamond price + * @property {number|null} [diamonCount] Diamond diamonCount + */ + + /** + * Constructs a new Diamond. + * @memberof cs + * @classdesc Represents a Diamond. + * @implements IDiamond + * @constructor + * @param {cs.IDiamond=} [properties] Properties to set + */ + function Diamond(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]]; + } + + /** + * Diamond id. + * @member {number} id + * @memberof cs.Diamond + * @instance + */ + Diamond.prototype.id = 0; + + /** + * Diamond name. + * @member {string} name + * @memberof cs.Diamond + * @instance + */ + Diamond.prototype.name = ""; + + /** + * Diamond price. + * @member {string} price + * @memberof cs.Diamond + * @instance + */ + Diamond.prototype.price = ""; + + /** + * Diamond diamonCount. + * @member {number} diamonCount + * @memberof cs.Diamond + * @instance + */ + Diamond.prototype.diamonCount = 0; + + /** + * Creates a new Diamond instance using the specified properties. + * @function create + * @memberof cs.Diamond + * @static + * @param {cs.IDiamond=} [properties] Properties to set + * @returns {cs.Diamond} Diamond instance + */ + Diamond.create = function create(properties) { + return new Diamond(properties); + }; + + /** + * Encodes the specified Diamond message. Does not implicitly {@link cs.Diamond.verify|verify} messages. + * @function encode + * @memberof cs.Diamond + * @static + * @param {cs.IDiamond} message Diamond message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + Diamond.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.diamonCount != null && Object.hasOwnProperty.call(message, "diamonCount")) + writer.uint32(/* id 3, wireType 0 =*/24).int32(message.diamonCount); + if (message.price != null && Object.hasOwnProperty.call(message, "price")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.price); + return writer; + }; + + /** + * Encodes the specified Diamond message, length delimited. Does not implicitly {@link cs.Diamond.verify|verify} messages. + * @function encodeDelimited + * @memberof cs.Diamond + * @static + * @param {cs.IDiamond} message Diamond message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + Diamond.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a Diamond message from the specified reader or buffer. + * @function decode + * @memberof cs.Diamond + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {cs.Diamond} Diamond + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + Diamond.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.Diamond(); + 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 4: { + message.price = reader.string(); + break; + } + case 3: { + message.diamonCount = reader.int32(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a Diamond message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof cs.Diamond + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {cs.Diamond} Diamond + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + Diamond.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a Diamond message. + * @function verify + * @memberof cs.Diamond + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + Diamond.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.price != null && message.hasOwnProperty("price")) + if (!$util.isString(message.price)) + return "price: string expected"; + if (message.diamonCount != null && message.hasOwnProperty("diamonCount")) + if (!$util.isInteger(message.diamonCount)) + return "diamonCount: integer expected"; + return null; + }; + + /** + * Creates a Diamond message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof cs.Diamond + * @static + * @param {Object.} object Plain object + * @returns {cs.Diamond} Diamond + */ + Diamond.fromObject = function fromObject(object) { + if (object instanceof $root.cs.Diamond) + return object; + var message = new $root.cs.Diamond(); + if (object.id != null) + message.id = object.id | 0; + if (object.name != null) + message.name = String(object.name); + if (object.price != null) + message.price = String(object.price); + if (object.diamonCount != null) + message.diamonCount = object.diamonCount | 0; + return message; + }; + + /** + * Creates a plain object from a Diamond message. Also converts values to other types if specified. + * @function toObject + * @memberof cs.Diamond + * @static + * @param {cs.Diamond} message Diamond + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + Diamond.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.id = 0; + object.name = ""; + object.diamonCount = 0; + object.price = ""; + } + if (message.id != null && message.hasOwnProperty("id")) + object.id = message.id; + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + if (message.diamonCount != null && message.hasOwnProperty("diamonCount")) + object.diamonCount = message.diamonCount; + if (message.price != null && message.hasOwnProperty("price")) + object.price = message.price; + return object; + }; + + /** + * Converts this Diamond to JSON. + * @function toJSON + * @memberof cs.Diamond + * @instance + * @returns {Object.} JSON object + */ + Diamond.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for Diamond + * @function getTypeUrl + * @memberof cs.Diamond + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + Diamond.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/cs.Diamond"; + }; + + return Diamond; + })(); + + cs.Vip = (function() { + + /** + * Properties of a Vip. + * @memberof cs + * @interface IVip + * @property {number|null} [id] Vip id + * @property {string|null} [name] Vip name + * @property {string|null} [desc] Vip desc + * @property {string|null} [price] Vip price + */ + + /** + * Constructs a new Vip. + * @memberof cs + * @classdesc Represents a Vip. + * @implements IVip + * @constructor + * @param {cs.IVip=} [properties] Properties to set + */ + function Vip(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]]; + } + + /** + * Vip id. + * @member {number} id + * @memberof cs.Vip + * @instance + */ + Vip.prototype.id = 0; + + /** + * Vip name. + * @member {string} name + * @memberof cs.Vip + * @instance + */ + Vip.prototype.name = ""; + + /** + * Vip desc. + * @member {string} desc + * @memberof cs.Vip + * @instance + */ + Vip.prototype.desc = ""; + + /** + * Vip price. + * @member {string} price + * @memberof cs.Vip + * @instance + */ + Vip.prototype.price = ""; + + /** + * Creates a new Vip instance using the specified properties. + * @function create + * @memberof cs.Vip + * @static + * @param {cs.IVip=} [properties] Properties to set + * @returns {cs.Vip} Vip instance + */ + Vip.create = function create(properties) { + return new Vip(properties); + }; + + /** + * Encodes the specified Vip message. Does not implicitly {@link cs.Vip.verify|verify} messages. + * @function encode + * @memberof cs.Vip + * @static + * @param {cs.IVip} message Vip message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + Vip.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.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); + return writer; + }; + + /** + * Encodes the specified Vip message, length delimited. Does not implicitly {@link cs.Vip.verify|verify} messages. + * @function encodeDelimited + * @memberof cs.Vip + * @static + * @param {cs.IVip} message Vip message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + Vip.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a Vip message from the specified reader or buffer. + * @function decode + * @memberof cs.Vip + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {cs.Vip} Vip + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + Vip.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.Vip(); + 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; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a Vip message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof cs.Vip + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {cs.Vip} Vip + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + Vip.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a Vip message. + * @function verify + * @memberof cs.Vip + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + Vip.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.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"; + return null; + }; + + /** + * Creates a Vip message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof cs.Vip + * @static + * @param {Object.} object Plain object + * @returns {cs.Vip} Vip + */ + Vip.fromObject = function fromObject(object) { + if (object instanceof $root.cs.Vip) + return object; + var message = new $root.cs.Vip(); + 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); + return message; + }; + + /** + * Creates a plain object from a Vip message. Also converts values to other types if specified. + * @function toObject + * @memberof cs.Vip + * @static + * @param {cs.Vip} message Vip + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + Vip.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.id = 0; + object.name = ""; + object.desc = ""; + object.price = ""; + } + 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; + return object; + }; + + /** + * Converts this Vip to JSON. + * @function toJSON + * @memberof cs.Vip + * @instance + * @returns {Object.} JSON object + */ + Vip.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for Vip + * @function getTypeUrl + * @memberof cs.Vip + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + Vip.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/cs.Vip"; + }; + + return Vip; + })(); + + 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.} 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.} 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.} Plain object + */ + CSGetShopReq.toObject = function toObject() { + return {}; + }; + + /** + * Converts this CSGetShopReq to JSON. + * @function toJSON + * @memberof cs.CSGetShopReq + * @instance + * @returns {Object.} 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 + * @property {Array.|null} [diamonds] CSGetShopRes diamonds + * @property {Array.|null} [vips] CSGetShopRes vips + */ + + /** + * Constructs a new CSGetShopRes. + * @memberof cs + * @classdesc Represents a CSGetShopRes. + * @implements ICSGetShopRes + * @constructor + * @param {cs.ICSGetShopRes=} [properties] Properties to set + */ + function CSGetShopRes(properties) { + this.diamonds = []; + this.vips = []; + 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]]; + } + + /** + * CSGetShopRes diamonds. + * @member {Array.} diamonds + * @memberof cs.CSGetShopRes + * @instance + */ + CSGetShopRes.prototype.diamonds = $util.emptyArray; + + /** + * CSGetShopRes vips. + * @member {Array.} vips + * @memberof cs.CSGetShopRes + * @instance + */ + CSGetShopRes.prototype.vips = $util.emptyArray; + + /** + * 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(); + if (message.diamonds != null && message.diamonds.length) + for (var i = 0; i < message.diamonds.length; ++i) + $root.cs.Diamond.encode(message.diamonds[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.vips != null && message.vips.length) + for (var i = 0; i < message.vips.length; ++i) + $root.cs.Vip.encode(message.vips[i], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + 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: { + if (!(message.diamonds && message.diamonds.length)) + message.diamonds = []; + message.diamonds.push($root.cs.Diamond.decode(reader, reader.uint32())); + break; + } + case 2: { + if (!(message.vips && message.vips.length)) + message.vips = []; + message.vips.push($root.cs.Vip.decode(reader, reader.uint32())); + 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.} 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"; + if (message.diamonds != null && message.hasOwnProperty("diamonds")) { + if (!Array.isArray(message.diamonds)) + return "diamonds: array expected"; + for (var i = 0; i < message.diamonds.length; ++i) { + var error = $root.cs.Diamond.verify(message.diamonds[i]); + if (error) + return "diamonds." + error; + } + } + if (message.vips != null && message.hasOwnProperty("vips")) { + if (!Array.isArray(message.vips)) + return "vips: array expected"; + for (var i = 0; i < message.vips.length; ++i) { + var error = $root.cs.Vip.verify(message.vips[i]); + if (error) + return "vips." + error; + } + } + 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.} 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(); + if (object.diamonds) { + if (!Array.isArray(object.diamonds)) + throw TypeError(".cs.CSGetShopRes.diamonds: array expected"); + message.diamonds = []; + for (var i = 0; i < object.diamonds.length; ++i) { + if (typeof object.diamonds[i] !== "object") + throw TypeError(".cs.CSGetShopRes.diamonds: object expected"); + message.diamonds[i] = $root.cs.Diamond.fromObject(object.diamonds[i]); + } + } + if (object.vips) { + if (!Array.isArray(object.vips)) + throw TypeError(".cs.CSGetShopRes.vips: array expected"); + message.vips = []; + for (var i = 0; i < object.vips.length; ++i) { + if (typeof object.vips[i] !== "object") + throw TypeError(".cs.CSGetShopRes.vips: object expected"); + message.vips[i] = $root.cs.Vip.fromObject(object.vips[i]); + } + } + 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.} Plain object + */ + CSGetShopRes.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) { + object.diamonds = []; + object.vips = []; + } + if (message.diamonds && message.diamonds.length) { + object.diamonds = []; + for (var j = 0; j < message.diamonds.length; ++j) + object.diamonds[j] = $root.cs.Diamond.toObject(message.diamonds[j], options); + } + if (message.vips && message.vips.length) { + object.vips = []; + for (var j = 0; j < message.vips.length; ++j) + object.vips[j] = $root.cs.Vip.toObject(message.vips[j], options); + } + return object; + }; + + /** + * Converts this CSGetShopRes to JSON. + * @function toJSON + * @memberof cs.CSGetShopRes + * @instance + * @returns {Object.} 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.} 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.} 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.} 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.} 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.} 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.} 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.} Plain object + */ + CSBuyChatRes.toObject = function toObject() { + return {}; + }; + + /** + * Converts this CSBuyChatRes to JSON. + * @function toJSON + * @memberof cs.CSBuyChatRes + * @instance + * @returns {Object.} 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.} 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.} 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.} 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.} 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 + */ + + /** + * 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 = ""; + + /** + * 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); + 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; + } + 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.} 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"; + 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.} 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); + 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.} Plain object + */ + CSCreateOrderRes.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) + object.payUrl = ""; + if (message.payUrl != null && message.hasOwnProperty("payUrl")) + object.payUrl = message.payUrl; + return object; + }; + + /** + * Converts this CSCreateOrderRes to JSON. + * @function toJSON + * @memberof cs.CSCreateOrderRes + * @instance + * @returns {Object.} 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; + })(); + + 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.} 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.} 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.} 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.} 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.} 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.} 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.} 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.} 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.} 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.} 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.} Plain object + */ + CSMyInfoReq.toObject = function toObject() { + return {}; + }; + + /** + * Converts this CSMyInfoReq to JSON. + * @function toJSON + * @memberof cs.CSMyInfoReq + * @instance + * @returns {Object.} 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.} 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.} 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.} 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.} 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; })(); /** - * SymbolVisibility enum. - * @name google.protobuf.SymbolVisibility + * EnmRetCode enum. + * @name cs.EnmRetCode * @enum {number} - * @property {number} VISIBILITY_UNSET=0 VISIBILITY_UNSET value - * @property {number} VISIBILITY_LOCAL=1 VISIBILITY_LOCAL value - * @property {number} VISIBILITY_EXPORT=2 VISIBILITY_EXPORT value + * @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 */ - protobuf.SymbolVisibility = (function () { - var valuesById = {}, - values = Object.create(valuesById); - values[(valuesById[0] = "VISIBILITY_UNSET")] = 0; - values[(valuesById[1] = "VISIBILITY_LOCAL")] = 1; - values[(valuesById[2] = "VISIBILITY_EXPORT")] = 2; - return values; + 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; })(); - return protobuf; - })(); - - return google; + return cs; })(); module.exports = $root; -module.exports.default = module.exports; +module.exports.default = module.exports; \ No newline at end of file diff --git a/proto_cs b/proto_cs index c1936f33..596a85ec 160000 --- a/proto_cs +++ b/proto_cs @@ -1 +1 @@ -Subproject commit c1936f33234bc324e68ff2549cbf0d93f65ed832 +Subproject commit 596a85eceabc1ca62e7ce5404d51df7edfa73a5f