diff --git a/.gitignore b/.gitignore index 5666627..99f91b9 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,5 @@ .vs compiler/cpp/compiler/Debug generated +tmp_go_check/meowmentnet/* +.vscode/* \ No newline at end of file diff --git a/PythonWorkSpace/IntegratedTool/Go包生成工具说明.md b/PythonWorkSpace/IntegratedTool/Go包生成工具说明.md new file mode 100644 index 0000000..16b6336 --- /dev/null +++ b/PythonWorkSpace/IntegratedTool/Go包生成工具说明.md @@ -0,0 +1,37 @@ +# Go 包生成工具 + +这个工具会批量读取 thrift-files/meowment-network 下的所有 thrift 文件,并生成一个统一的 Go 包目录。 + +默认输出位置: + +- compiled_output/golang/meowmentnet + +默认行为: + +- 自动优先使用仓库内的 compiler/exe/thrift.exe +- 如果仓库内编译器不可用,则回退到系统 PATH 中的 thrift +- 将全部 thrift 文件生成到同一个 Go package: meowmentnet +- 启用 ignore_initialisms,保留 Id、Uid 这类字段写法,不自动改成 ID、UID +- 生成完成后自动运行 gofmt +- 使用 --module 时会自动执行 go mod tidy + +直接运行: + +```bat +PythonWorkSpace\IntegratedTool\启动Go包生成工具.bat +``` + +常见参数: + +```bat +PythonWorkSpace\IntegratedTool\启动Go包生成工具.bat --output-dir D:\temp\meowmentnet +PythonWorkSpace\IntegratedTool\启动Go包生成工具.bat --package-name netpkg +PythonWorkSpace\IntegratedTool\启动Go包生成工具.bat --module github.com/yourname/meowmentnet +PythonWorkSpace\IntegratedTool\启动Go包生成工具.bat --compiler F:\Github\thrift\thrift.exe +``` + +如果你想把生成结果直接作为一个独立 Go module 使用,建议同时传入: + +```bat +PythonWorkSpace\IntegratedTool\启动Go包生成工具.bat --module github.com/yourname/meowmentnet --output-dir D:\work\meowmentnet +``` diff --git a/PythonWorkSpace/IntegratedTool/generate_go_package.py b/PythonWorkSpace/IntegratedTool/generate_go_package.py new file mode 100644 index 0000000..aeccf65 --- /dev/null +++ b/PythonWorkSpace/IntegratedTool/generate_go_package.py @@ -0,0 +1,302 @@ +"""Generate a Go package from thrift-files/meowment-network.""" + +from __future__ import annotations + +import argparse +import os +import shutil +import subprocess +import sys +import tempfile +from pathlib import Path +from typing import Iterable, Sequence + + +REPO_ROOT = Path(__file__).resolve().parents[2] +DEFAULT_SOURCE_DIR = REPO_ROOT / "thrift-files" / "meowment-network" +DEFAULT_OUTPUT_DIR = REPO_ROOT / "compiled_output" / "golang" / "meowmentnet" +DEFAULT_PACKAGE_NAME = "meowmentnet" +DEFAULT_THRIFT_IMPORT = "github.com/apache/thrift/lib/go/thrift" + + +class ToolError(RuntimeError): + pass + + +def parse_args() -> argparse.Namespace: + parser = argparse.ArgumentParser( + description="Generate a Go package from meowment-network thrift files.", + ) + parser.add_argument( + "--source-dir", + type=Path, + default=DEFAULT_SOURCE_DIR, + help="Directory containing .thrift files.", + ) + parser.add_argument( + "--output-dir", + type=Path, + default=DEFAULT_OUTPUT_DIR, + help="Destination directory of the generated Go package.", + ) + parser.add_argument( + "--package-name", + default=DEFAULT_PACKAGE_NAME, + help="Generated Go package name.", + ) + parser.add_argument( + "--compiler", + type=Path, + help="Explicit thrift compiler executable path.", + ) + parser.add_argument( + "--package-prefix", + default="", + help="Optional value passed to go:package_prefix=...", + ) + parser.add_argument( + "--thrift-import", + default=DEFAULT_THRIFT_IMPORT, + help="Import path of the Go thrift runtime.", + ) + parser.add_argument( + "--module", + default="", + help="If set, write a go.mod file with this module path.", + ) + parser.add_argument( + "--no-clean", + action="store_true", + help="Do not delete the existing output directory before copying files.", + ) + parser.add_argument( + "--skip-gofmt", + action="store_true", + help="Do not run gofmt after generation.", + ) + parser.add_argument( + "--skip-go-mod-tidy", + action="store_true", + help="Do not run go mod tidy after writing go.mod.", + ) + return parser.parse_args() + + +def candidate_compilers(explicit: Path | None) -> Iterable[Path]: + seen: set[str] = set() + + def emit(path: Path | None) -> Iterable[Path]: + if path is None: + return () + resolved = str(path) + if resolved in seen: + return () + seen.add(resolved) + return (path,) + + if explicit is not None: + yield from emit(explicit) + + env_compiler = Path(os.environ["THRIFT_COMPILER"]) if "THRIFT_COMPILER" in os.environ else None + yield from emit(env_compiler) + yield from emit(REPO_ROOT / "compiler" / "exe" / "thrift-go.exe") + + system_compiler = shutil.which("thrift") + if system_compiler: + yield from emit(Path(system_compiler)) + + +def probe_compiler(executable: Path) -> bool: + try: + completed = subprocess.run( + [str(executable), "-version"], + check=False, + capture_output=True, + text=True, + timeout=10, + ) + except OSError: + return False + except subprocess.TimeoutExpired: + return False + return completed.returncode == 0 + + +def resolve_compiler(explicit: Path | None) -> Path: + for compiler in candidate_compilers(explicit): + if probe_compiler(compiler): + return compiler + raise ToolError( + "No working thrift compiler was found. Use --compiler or set THRIFT_COMPILER." + ) + + +def find_thrift_files(source_dir: Path) -> list[Path]: + if not source_dir.exists(): + raise ToolError(f"Source directory does not exist: {source_dir}") + thrift_files = sorted(source_dir.glob("*.thrift")) + if not thrift_files: + raise ToolError(f"No .thrift files were found in: {source_dir}") + return thrift_files + + +def build_generator_option(args: argparse.Namespace) -> str: + options = [f"package={args.package_name}"] + options.append("ignore_initialisms") + if args.package_prefix: + options.append(f"package_prefix={normalize_package_prefix(args.package_prefix)}") + if args.thrift_import: + options.append(f"thrift_import={args.thrift_import}") + options.append("skip_remote") + return "go:" + ",".join(options) + + +def normalize_package_prefix(prefix: str) -> str: + normalized = prefix.strip() + if not normalized: + return normalized + return normalized if normalized.endswith("/") else normalized + "/" + + +def run_command(command: Sequence[str], cwd: Path) -> None: + completed = subprocess.run( + list(command), + cwd=str(cwd), + check=False, + capture_output=True, + text=True, + ) + if completed.returncode == 0: + return + + stdout = completed.stdout.strip() + stderr = completed.stderr.strip() + details = "\n".join(part for part in (stdout, stderr) if part) + if not details: + details = "The command exited with a non-zero status and produced no output." + raise ToolError(details) + + +def generate_go_sources( + compiler: Path, + source_dir: Path, + thrift_files: Sequence[Path], + package_name: str, + generator_option: str, + staging_root: Path, +) -> Path: + for thrift_file in thrift_files: + command = [ + str(compiler), + "-o", + str(staging_root), + "-strict", + "--gen", + generator_option, + str(thrift_file), + ] + try: + run_command(command, cwd=source_dir) + except ToolError as exc: + raise ToolError(f"Failed to generate {thrift_file.name}:\n{exc}") from exc + + package_dir = staging_root / "gen-go" / package_name + if not package_dir.exists(): + raise ToolError(f"Generated package directory not found: {package_dir}") + + return package_dir + + +def write_go_mod(output_dir: Path, module_name: str) -> None: + go_mod = output_dir / "go.mod" + go_mod.write_text( + "\n".join( + [ + f"module {module_name}", + "", + "go 1.22", + "", + "require github.com/apache/thrift v0.22.0", + "", + ] + ), + encoding="utf-8", + ) + + +def copy_output(staged_package_dir: Path, output_dir: Path, clean: bool) -> None: + if clean and output_dir.exists(): + shutil.rmtree(output_dir) + output_dir.parent.mkdir(parents=True, exist_ok=True) + shutil.copytree(staged_package_dir, output_dir, dirs_exist_ok=not clean) + + +def run_gofmt(output_dir: Path) -> None: + gofmt = shutil.which("gofmt") + if not gofmt: + print("[warn] gofmt was not found in PATH. Skipping formatting.") + return + + go_files = sorted(output_dir.glob("*.go")) + if not go_files: + return + + for go_file in go_files: + run_command([gofmt, "-w", str(go_file)], cwd=output_dir) + + +def run_go_mod_tidy(output_dir: Path) -> None: + go = shutil.which("go") + if not go: + print("[warn] go was not found in PATH. Skipping go mod tidy.") + return + + run_command([go, "mod", "tidy"], cwd=output_dir) + + +def validate_args(args: argparse.Namespace) -> None: + if not args.package_name.strip(): + raise ToolError("--package-name cannot be empty.") + + +def main() -> int: + args = parse_args() + try: + validate_args(args) + source_dir = args.source_dir.resolve() + output_dir = args.output_dir.resolve() + thrift_files = find_thrift_files(source_dir) + compiler = resolve_compiler(args.compiler.resolve() if args.compiler else None) + generator_option = build_generator_option(args) + with tempfile.TemporaryDirectory(prefix="thrift_go_") as tmp_dir: + staged_package_dir = generate_go_sources( + compiler=compiler, + source_dir=source_dir, + thrift_files=thrift_files, + package_name=args.package_name, + generator_option=generator_option, + staging_root=Path(tmp_dir), + ) + copy_output(staged_package_dir, output_dir, clean=not args.no_clean) + if args.module: + write_go_mod(output_dir, args.module) + if not args.skip_go_mod_tidy: + run_go_mod_tidy(output_dir) + if not args.skip_gofmt: + run_gofmt(output_dir) + + print(f"Compiler: {compiler}") + print(f"Source directory: {source_dir}") + print(f"Output directory: {output_dir}") + print(f"Package name: {args.package_name}") + print(f"Thrift files: {len(thrift_files)}") + if args.module: + print(f"go.mod: {args.module}") + return 0 + except ToolError as exc: + print(f"[error] {exc}", file=sys.stderr) + return 1 + + +if __name__ == "__main__": + raise SystemExit(main()) diff --git a/PythonWorkSpace/IntegratedTool/启动Go包生成工具.bat b/PythonWorkSpace/IntegratedTool/启动Go包生成工具.bat new file mode 100644 index 0000000..603de71 --- /dev/null +++ b/PythonWorkSpace/IntegratedTool/启动Go包生成工具.bat @@ -0,0 +1,13 @@ +@echo off +setlocal + +set SCRIPT_DIR=%~dp0 +set PYTHON_EXE=%SCRIPT_DIR%..\..\.venv\Scripts\python.exe + +if exist "%PYTHON_EXE%" ( + "%PYTHON_EXE%" "%SCRIPT_DIR%generate_go_package.py" %* +) else ( + python "%SCRIPT_DIR%generate_go_package.py" %* +) + +endlocal diff --git a/compiled_output/golang/meowmentnet/GoUnusedProtection__.go b/compiled_output/golang/meowmentnet/GoUnusedProtection__.go new file mode 100644 index 0000000..b756e61 --- /dev/null +++ b/compiled_output/golang/meowmentnet/GoUnusedProtection__.go @@ -0,0 +1,5 @@ +// Code generated by Thrift Compiler (0.22.0). DO NOT EDIT. + +package meowmentnet + +var GoUnusedProtection__ int diff --git a/compiled_output/golang/meowmentnet/Network-consts.go b/compiled_output/golang/meowmentnet/Network-consts.go new file mode 100644 index 0000000..9b197f5 --- /dev/null +++ b/compiled_output/golang/meowmentnet/Network-consts.go @@ -0,0 +1,33 @@ +// Code generated by Thrift Compiler (0.22.0). DO NOT EDIT. + +package meowmentnet + +import ( + "bytes" + "context" + "errors" + "fmt" + thrift "github.com/apache/thrift/lib/go/thrift" + "iter" + "log/slog" + "regexp" + "strings" + "time" +) + +// (needed to ensure safety because of naive import list construction.) +var _ = bytes.Equal +var _ = context.Background +var _ = errors.New +var _ = fmt.Printf +var _ = iter.Pull[int] +var _ = slog.Log +var _ = time.Now +var _ = thrift.ZERO + +// (needed by validator.) +var _ = strings.Contains +var _ = regexp.MatchString + +func init() { +} diff --git a/compiled_output/golang/meowmentnet/Network.go b/compiled_output/golang/meowmentnet/Network.go new file mode 100644 index 0000000..dfd59f9 --- /dev/null +++ b/compiled_output/golang/meowmentnet/Network.go @@ -0,0 +1,109841 @@ +// Code generated by Thrift Compiler (0.22.0). DO NOT EDIT. + +package meowmentnet + +import ( + "bytes" + "context" + "database/sql/driver" + "errors" + "fmt" + thrift "github.com/apache/thrift/lib/go/thrift" + "iter" + "log/slog" + "regexp" + "strings" + "time" +) + +// (needed to ensure safety because of naive import list construction.) +var _ = bytes.Equal +var _ = context.Background +var _ = errors.New +var _ = fmt.Printf +var _ = iter.Pull[int] +var _ = slog.Log +var _ = time.Now +var _ = thrift.ZERO + +// (needed by validator.) +var _ = strings.Contains +var _ = regexp.MatchString + +type ACTIVITY_TYPE int64 + +const ( + ACTIVITY_TYPE_DefaultType ACTIVITY_TYPE = 0 + ACTIVITY_TYPE_ActTypeMining ACTIVITY_TYPE = 1 + ACTIVITY_TYPE_ActTypeGuessColor ACTIVITY_TYPE = 2 + ACTIVITY_TYPE_ActTypeRace ACTIVITY_TYPE = 3 + ACTIVITY_TYPE_ActTypeDiscountGift ACTIVITY_TYPE = 4 + ACTIVITY_TYPE_ActTypeAddGift ACTIVITY_TYPE = 5 + ACTIVITY_TYPE_ActTypeSuperGift ACTIVITY_TYPE = 6 + ACTIVITY_TYPE_ActTypeCatnip ACTIVITY_TYPE = 7 + ACTIVITY_TYPE_ActTypePass ACTIVITY_TYPE = 8 +) + +var knownACTIVITY_TYPEValues = []ACTIVITY_TYPE{ + ACTIVITY_TYPE_DefaultType, + ACTIVITY_TYPE_ActTypeMining, + ACTIVITY_TYPE_ActTypeGuessColor, + ACTIVITY_TYPE_ActTypeRace, + ACTIVITY_TYPE_ActTypeDiscountGift, + ACTIVITY_TYPE_ActTypeAddGift, + ACTIVITY_TYPE_ActTypeSuperGift, + ACTIVITY_TYPE_ActTypeCatnip, + ACTIVITY_TYPE_ActTypePass, +} + +func ACTIVITY_TYPEValues() iter.Seq[ACTIVITY_TYPE] { + return func(yield func(ACTIVITY_TYPE) bool) { + for _, v := range knownACTIVITY_TYPEValues { + if !yield(v) { + return + } + } + } +} + +func (p ACTIVITY_TYPE) String() string { + switch p { + case ACTIVITY_TYPE_DefaultType: + return "DefaultType" + case ACTIVITY_TYPE_ActTypeMining: + return "ActTypeMining" + case ACTIVITY_TYPE_ActTypeGuessColor: + return "ActTypeGuessColor" + case ACTIVITY_TYPE_ActTypeRace: + return "ActTypeRace" + case ACTIVITY_TYPE_ActTypeDiscountGift: + return "ActTypeDiscountGift" + case ACTIVITY_TYPE_ActTypeAddGift: + return "ActTypeAddGift" + case ACTIVITY_TYPE_ActTypeSuperGift: + return "ActTypeSuperGift" + case ACTIVITY_TYPE_ActTypeCatnip: + return "ActTypeCatnip" + case ACTIVITY_TYPE_ActTypePass: + return "ActTypePass" + } + return "" +} + +func ACTIVITY_TYPEFromString(s string) (ACTIVITY_TYPE, error) { + switch s { + case "DefaultType": + return ACTIVITY_TYPE_DefaultType, nil + case "ActTypeMining": + return ACTIVITY_TYPE_ActTypeMining, nil + case "ActTypeGuessColor": + return ACTIVITY_TYPE_ActTypeGuessColor, nil + case "ActTypeRace": + return ACTIVITY_TYPE_ActTypeRace, nil + case "ActTypeDiscountGift": + return ACTIVITY_TYPE_ActTypeDiscountGift, nil + case "ActTypeAddGift": + return ACTIVITY_TYPE_ActTypeAddGift, nil + case "ActTypeSuperGift": + return ACTIVITY_TYPE_ActTypeSuperGift, nil + case "ActTypeCatnip": + return ACTIVITY_TYPE_ActTypeCatnip, nil + case "ActTypePass": + return ACTIVITY_TYPE_ActTypePass, nil + } + return ACTIVITY_TYPE(0), fmt.Errorf("not a valid ACTIVITY_TYPE string") +} + +func ACTIVITY_TYPEPtr(v ACTIVITY_TYPE) *ACTIVITY_TYPE { return &v } + +func (p ACTIVITY_TYPE) MarshalText() ([]byte, error) { + return []byte(p.String()), nil +} + +func (p *ACTIVITY_TYPE) UnmarshalText(text []byte) error { + q, err := ACTIVITY_TYPEFromString(string(text)) + if err != nil { + return err + } + *p = q + return nil +} + +func (p *ACTIVITY_TYPE) Scan(value interface{}) error { + v, ok := value.(int64) + if !ok { + return errors.New("Scan value is not int64") + } + *p = ACTIVITY_TYPE(v) + return nil +} + +func (p *ACTIVITY_TYPE) Value() (driver.Value, error) { + if p == nil { + return nil, nil + } + return int64(*p), nil +} + +type ActLogType int64 + +const ( + ActLogType_None ActLogType = 0 + ActLogType_FirstLogin ActLogType = 1 + ActLogType_CompleteRestroom ActLogType = 2 + ActLogType_CompleteRestaurant ActLogType = 3 + ActLogType_CompleteBathroom ActLogType = 4 + ActLogType_CompleteCloakroom ActLogType = 5 + ActLogType_GetNewAvatar ActLogType = 6 + ActLogType_GetNewAvatarFrame ActLogType = 7 + ActLogType_GetNewEmotion ActLogType = 8 + ActLogType_GetNewDecoration ActLogType = 9 + ActLogType_GetNewCostume ActLogType = 10 + ActLogType_CompleteCardAlbum ActLogType = 11 + ActLogType_CompleteAllCards ActLogType = 12 + ActLogType_GetChampionshipRank ActLogType = 13 + ActLogType_GetChampionshipPrize ActLogType = 14 + ActLogType_GetLimitedActivityPrize ActLogType = 15 + ActLogType_JoinFriendCoopActivity ActLogType = 16 + ActLogType_GetVisitGamePrize ActLogType = 17 + ActLogType_GetVisitGamePrize1 ActLogType = 18 + ActLogType_OpenPetTreasure ActLogType = 19 + ActLogType_VisitUpvote ActLogType = 20 + ActLogType_CompleteHandbookAchievement ActLogType = 21 + ActLogType_CompleteChapterScenes ActLogType = 22 + ActLogType_LostUserReturn ActLogType = 23 +) + +var knownActLogTypeValues = []ActLogType{ + ActLogType_None, + ActLogType_FirstLogin, + ActLogType_CompleteRestroom, + ActLogType_CompleteRestaurant, + ActLogType_CompleteBathroom, + ActLogType_CompleteCloakroom, + ActLogType_GetNewAvatar, + ActLogType_GetNewAvatarFrame, + ActLogType_GetNewEmotion, + ActLogType_GetNewDecoration, + ActLogType_GetNewCostume, + ActLogType_CompleteCardAlbum, + ActLogType_CompleteAllCards, + ActLogType_GetChampionshipRank, + ActLogType_GetChampionshipPrize, + ActLogType_GetLimitedActivityPrize, + ActLogType_JoinFriendCoopActivity, + ActLogType_GetVisitGamePrize, + ActLogType_GetVisitGamePrize1, + ActLogType_OpenPetTreasure, + ActLogType_VisitUpvote, + ActLogType_CompleteHandbookAchievement, + ActLogType_CompleteChapterScenes, + ActLogType_LostUserReturn, +} + +func ActLogTypeValues() iter.Seq[ActLogType] { + return func(yield func(ActLogType) bool) { + for _, v := range knownActLogTypeValues { + if !yield(v) { + return + } + } + } +} + +func (p ActLogType) String() string { + switch p { + case ActLogType_None: + return "None" + case ActLogType_FirstLogin: + return "FirstLogin" + case ActLogType_CompleteRestroom: + return "CompleteRestroom" + case ActLogType_CompleteRestaurant: + return "CompleteRestaurant" + case ActLogType_CompleteBathroom: + return "CompleteBathroom" + case ActLogType_CompleteCloakroom: + return "CompleteCloakroom" + case ActLogType_GetNewAvatar: + return "GetNewAvatar" + case ActLogType_GetNewAvatarFrame: + return "GetNewAvatarFrame" + case ActLogType_GetNewEmotion: + return "GetNewEmotion" + case ActLogType_GetNewDecoration: + return "GetNewDecoration" + case ActLogType_GetNewCostume: + return "GetNewCostume" + case ActLogType_CompleteCardAlbum: + return "CompleteCardAlbum" + case ActLogType_CompleteAllCards: + return "CompleteAllCards" + case ActLogType_GetChampionshipRank: + return "GetChampionshipRank" + case ActLogType_GetChampionshipPrize: + return "GetChampionshipPrize" + case ActLogType_GetLimitedActivityPrize: + return "GetLimitedActivityPrize" + case ActLogType_JoinFriendCoopActivity: + return "JoinFriendCoopActivity" + case ActLogType_GetVisitGamePrize: + return "GetVisitGamePrize" + case ActLogType_GetVisitGamePrize1: + return "GetVisitGamePrize1" + case ActLogType_OpenPetTreasure: + return "OpenPetTreasure" + case ActLogType_VisitUpvote: + return "VisitUpvote" + case ActLogType_CompleteHandbookAchievement: + return "CompleteHandbookAchievement" + case ActLogType_CompleteChapterScenes: + return "CompleteChapterScenes" + case ActLogType_LostUserReturn: + return "LostUserReturn" + } + return "" +} + +func ActLogTypeFromString(s string) (ActLogType, error) { + switch s { + case "None": + return ActLogType_None, nil + case "FirstLogin": + return ActLogType_FirstLogin, nil + case "CompleteRestroom": + return ActLogType_CompleteRestroom, nil + case "CompleteRestaurant": + return ActLogType_CompleteRestaurant, nil + case "CompleteBathroom": + return ActLogType_CompleteBathroom, nil + case "CompleteCloakroom": + return ActLogType_CompleteCloakroom, nil + case "GetNewAvatar": + return ActLogType_GetNewAvatar, nil + case "GetNewAvatarFrame": + return ActLogType_GetNewAvatarFrame, nil + case "GetNewEmotion": + return ActLogType_GetNewEmotion, nil + case "GetNewDecoration": + return ActLogType_GetNewDecoration, nil + case "GetNewCostume": + return ActLogType_GetNewCostume, nil + case "CompleteCardAlbum": + return ActLogType_CompleteCardAlbum, nil + case "CompleteAllCards": + return ActLogType_CompleteAllCards, nil + case "GetChampionshipRank": + return ActLogType_GetChampionshipRank, nil + case "GetChampionshipPrize": + return ActLogType_GetChampionshipPrize, nil + case "GetLimitedActivityPrize": + return ActLogType_GetLimitedActivityPrize, nil + case "JoinFriendCoopActivity": + return ActLogType_JoinFriendCoopActivity, nil + case "GetVisitGamePrize": + return ActLogType_GetVisitGamePrize, nil + case "GetVisitGamePrize1": + return ActLogType_GetVisitGamePrize1, nil + case "OpenPetTreasure": + return ActLogType_OpenPetTreasure, nil + case "VisitUpvote": + return ActLogType_VisitUpvote, nil + case "CompleteHandbookAchievement": + return ActLogType_CompleteHandbookAchievement, nil + case "CompleteChapterScenes": + return ActLogType_CompleteChapterScenes, nil + case "LostUserReturn": + return ActLogType_LostUserReturn, nil + } + return ActLogType(0), fmt.Errorf("not a valid ActLogType string") +} + +func ActLogTypePtr(v ActLogType) *ActLogType { return &v } + +func (p ActLogType) MarshalText() ([]byte, error) { + return []byte(p.String()), nil +} + +func (p *ActLogType) UnmarshalText(text []byte) error { + q, err := ActLogTypeFromString(string(text)) + if err != nil { + return err + } + *p = q + return nil +} + +func (p *ActLogType) Scan(value interface{}) error { + v, ok := value.(int64) + if !ok { + return errors.New("Scan value is not int64") + } + *p = ActLogType(v) + return nil +} + +func (p *ActLogType) Value() (driver.Value, error) { + if p == nil { + return nil, nil + } + return int64(*p), nil +} + +type CHESS_EX_TYPE int64 + +const ( + CHESS_EX_TYPE_ChessExNone CHESS_EX_TYPE = 0 + CHESS_EX_TYPE_ChessExBubble CHESS_EX_TYPE = 1 + CHESS_EX_TYPE_ChessExBox CHESS_EX_TYPE = 2 + CHESS_EX_TYPE_ChessExQuickBuy CHESS_EX_TYPE = 3 + CHESS_EX_TYPE_ChessExEvent CHESS_EX_TYPE = 4 + CHESS_EX_TYPE_ChessExEventLittleApprentice CHESS_EX_TYPE = 5 + CHESS_EX_TYPE_ChessExEmitRollback CHESS_EX_TYPE = 6 +) + +var knownCHESS_EX_TYPEValues = []CHESS_EX_TYPE{ + CHESS_EX_TYPE_ChessExNone, + CHESS_EX_TYPE_ChessExBubble, + CHESS_EX_TYPE_ChessExBox, + CHESS_EX_TYPE_ChessExQuickBuy, + CHESS_EX_TYPE_ChessExEvent, + CHESS_EX_TYPE_ChessExEventLittleApprentice, + CHESS_EX_TYPE_ChessExEmitRollback, +} + +func CHESS_EX_TYPEValues() iter.Seq[CHESS_EX_TYPE] { + return func(yield func(CHESS_EX_TYPE) bool) { + for _, v := range knownCHESS_EX_TYPEValues { + if !yield(v) { + return + } + } + } +} + +func (p CHESS_EX_TYPE) String() string { + switch p { + case CHESS_EX_TYPE_ChessExNone: + return "ChessExNone" + case CHESS_EX_TYPE_ChessExBubble: + return "ChessExBubble" + case CHESS_EX_TYPE_ChessExBox: + return "ChessExBox" + case CHESS_EX_TYPE_ChessExQuickBuy: + return "ChessExQuickBuy" + case CHESS_EX_TYPE_ChessExEvent: + return "ChessExEvent" + case CHESS_EX_TYPE_ChessExEventLittleApprentice: + return "ChessExEventLittleApprentice" + case CHESS_EX_TYPE_ChessExEmitRollback: + return "ChessExEmitRollback" + } + return "" +} + +func CHESS_EX_TYPEFromString(s string) (CHESS_EX_TYPE, error) { + switch s { + case "ChessExNone": + return CHESS_EX_TYPE_ChessExNone, nil + case "ChessExBubble": + return CHESS_EX_TYPE_ChessExBubble, nil + case "ChessExBox": + return CHESS_EX_TYPE_ChessExBox, nil + case "ChessExQuickBuy": + return CHESS_EX_TYPE_ChessExQuickBuy, nil + case "ChessExEvent": + return CHESS_EX_TYPE_ChessExEvent, nil + case "ChessExEventLittleApprentice": + return CHESS_EX_TYPE_ChessExEventLittleApprentice, nil + case "ChessExEmitRollback": + return CHESS_EX_TYPE_ChessExEmitRollback, nil + } + return CHESS_EX_TYPE(0), fmt.Errorf("not a valid CHESS_EX_TYPE string") +} + +func CHESS_EX_TYPEPtr(v CHESS_EX_TYPE) *CHESS_EX_TYPE { return &v } + +func (p CHESS_EX_TYPE) MarshalText() ([]byte, error) { + return []byte(p.String()), nil +} + +func (p *CHESS_EX_TYPE) UnmarshalText(text []byte) error { + q, err := CHESS_EX_TYPEFromString(string(text)) + if err != nil { + return err + } + *p = q + return nil +} + +func (p *CHESS_EX_TYPE) Scan(value interface{}) error { + v, ok := value.(int64) + if !ok { + return errors.New("Scan value is not int64") + } + *p = CHESS_EX_TYPE(v) + return nil +} + +func (p *CHESS_EX_TYPE) Value() (driver.Value, error) { + if p == nil { + return nil, nil + } + return int64(*p), nil +} + +type FRIEND_REPLY_HANDLE_ERR_TYPE int64 + +const ( + FRIEND_REPLY_HANDLE_ERR_TYPE_None FRIEND_REPLY_HANDLE_ERR_TYPE = 0 + FRIEND_REPLY_HANDLE_ERR_TYPE_Catnip FRIEND_REPLY_HANDLE_ERR_TYPE = 1 +) + +var knownFRIEND_REPLY_HANDLE_ERR_TYPEValues = []FRIEND_REPLY_HANDLE_ERR_TYPE{ + FRIEND_REPLY_HANDLE_ERR_TYPE_None, + FRIEND_REPLY_HANDLE_ERR_TYPE_Catnip, +} + +func FRIEND_REPLY_HANDLE_ERR_TYPEValues() iter.Seq[FRIEND_REPLY_HANDLE_ERR_TYPE] { + return func(yield func(FRIEND_REPLY_HANDLE_ERR_TYPE) bool) { + for _, v := range knownFRIEND_REPLY_HANDLE_ERR_TYPEValues { + if !yield(v) { + return + } + } + } +} + +func (p FRIEND_REPLY_HANDLE_ERR_TYPE) String() string { + switch p { + case FRIEND_REPLY_HANDLE_ERR_TYPE_None: + return "None" + case FRIEND_REPLY_HANDLE_ERR_TYPE_Catnip: + return "Catnip" + } + return "" +} + +func FRIEND_REPLY_HANDLE_ERR_TYPEFromString(s string) (FRIEND_REPLY_HANDLE_ERR_TYPE, error) { + switch s { + case "None": + return FRIEND_REPLY_HANDLE_ERR_TYPE_None, nil + case "Catnip": + return FRIEND_REPLY_HANDLE_ERR_TYPE_Catnip, nil + } + return FRIEND_REPLY_HANDLE_ERR_TYPE(0), fmt.Errorf("not a valid FRIEND_REPLY_HANDLE_ERR_TYPE string") +} + +func FRIEND_REPLY_HANDLE_ERR_TYPEPtr(v FRIEND_REPLY_HANDLE_ERR_TYPE) *FRIEND_REPLY_HANDLE_ERR_TYPE { + return &v +} + +func (p FRIEND_REPLY_HANDLE_ERR_TYPE) MarshalText() ([]byte, error) { + return []byte(p.String()), nil +} + +func (p *FRIEND_REPLY_HANDLE_ERR_TYPE) UnmarshalText(text []byte) error { + q, err := FRIEND_REPLY_HANDLE_ERR_TYPEFromString(string(text)) + if err != nil { + return err + } + *p = q + return nil +} + +func (p *FRIEND_REPLY_HANDLE_ERR_TYPE) Scan(value interface{}) error { + v, ok := value.(int64) + if !ok { + return errors.New("Scan value is not int64") + } + *p = FRIEND_REPLY_HANDLE_ERR_TYPE(v) + return nil +} + +func (p *FRIEND_REPLY_HANDLE_ERR_TYPE) Value() (driver.Value, error) { + if p == nil { + return nil, nil + } + return int64(*p), nil +} + +type FRIEND_REPLY_TYPE int64 + +const ( + FRIEND_REPLY_TYPE_None FRIEND_REPLY_TYPE = 0 + FRIEND_REPLY_TYPE_Greet FRIEND_REPLY_TYPE = 1 + FRIEND_REPLY_TYPE_ReturnGreet FRIEND_REPLY_TYPE = 2 + FRIEND_REPLY_TYPE_ReplyTypeCatnip FRIEND_REPLY_TYPE = 3 + FRIEND_REPLY_TYPE_ReplyTypeCatnipItems FRIEND_REPLY_TYPE = 4 +) + +var knownFRIEND_REPLY_TYPEValues = []FRIEND_REPLY_TYPE{ + FRIEND_REPLY_TYPE_None, + FRIEND_REPLY_TYPE_Greet, + FRIEND_REPLY_TYPE_ReturnGreet, + FRIEND_REPLY_TYPE_ReplyTypeCatnip, + FRIEND_REPLY_TYPE_ReplyTypeCatnipItems, +} + +func FRIEND_REPLY_TYPEValues() iter.Seq[FRIEND_REPLY_TYPE] { + return func(yield func(FRIEND_REPLY_TYPE) bool) { + for _, v := range knownFRIEND_REPLY_TYPEValues { + if !yield(v) { + return + } + } + } +} + +func (p FRIEND_REPLY_TYPE) String() string { + switch p { + case FRIEND_REPLY_TYPE_None: + return "None" + case FRIEND_REPLY_TYPE_Greet: + return "Greet" + case FRIEND_REPLY_TYPE_ReturnGreet: + return "ReturnGreet" + case FRIEND_REPLY_TYPE_ReplyTypeCatnip: + return "ReplyTypeCatnip" + case FRIEND_REPLY_TYPE_ReplyTypeCatnipItems: + return "ReplyTypeCatnipItems" + } + return "" +} + +func FRIEND_REPLY_TYPEFromString(s string) (FRIEND_REPLY_TYPE, error) { + switch s { + case "None": + return FRIEND_REPLY_TYPE_None, nil + case "Greet": + return FRIEND_REPLY_TYPE_Greet, nil + case "ReturnGreet": + return FRIEND_REPLY_TYPE_ReturnGreet, nil + case "ReplyTypeCatnip": + return FRIEND_REPLY_TYPE_ReplyTypeCatnip, nil + case "ReplyTypeCatnipItems": + return FRIEND_REPLY_TYPE_ReplyTypeCatnipItems, nil + } + return FRIEND_REPLY_TYPE(0), fmt.Errorf("not a valid FRIEND_REPLY_TYPE string") +} + +func FRIEND_REPLY_TYPEPtr(v FRIEND_REPLY_TYPE) *FRIEND_REPLY_TYPE { return &v } + +func (p FRIEND_REPLY_TYPE) MarshalText() ([]byte, error) { + return []byte(p.String()), nil +} + +func (p *FRIEND_REPLY_TYPE) UnmarshalText(text []byte) error { + q, err := FRIEND_REPLY_TYPEFromString(string(text)) + if err != nil { + return err + } + *p = q + return nil +} + +func (p *FRIEND_REPLY_TYPE) Scan(value interface{}) error { + v, ok := value.(int64) + if !ok { + return errors.New("Scan value is not int64") + } + *p = FRIEND_REPLY_TYPE(v) + return nil +} + +func (p *FRIEND_REPLY_TYPE) Value() (driver.Value, error) { + if p == nil { + return nil, nil + } + return int64(*p), nil +} + +type HANDLE_TYPE int64 + +const ( + HANDLE_TYPE_Add HANDLE_TYPE = 0 + HANDLE_TYPE_Compose HANDLE_TYPE = 1 + HANDLE_TYPE_Buy HANDLE_TYPE = 2 + HANDLE_TYPE_Sell HANDLE_TYPE = 3 + HANDLE_TYPE_Remove HANDLE_TYPE = 4 +) + +var knownHANDLE_TYPEValues = []HANDLE_TYPE{ + HANDLE_TYPE_Add, + HANDLE_TYPE_Compose, + HANDLE_TYPE_Buy, + HANDLE_TYPE_Sell, + HANDLE_TYPE_Remove, +} + +func HANDLE_TYPEValues() iter.Seq[HANDLE_TYPE] { + return func(yield func(HANDLE_TYPE) bool) { + for _, v := range knownHANDLE_TYPEValues { + if !yield(v) { + return + } + } + } +} + +func (p HANDLE_TYPE) String() string { + switch p { + case HANDLE_TYPE_Add: + return "Add" + case HANDLE_TYPE_Compose: + return "Compose" + case HANDLE_TYPE_Buy: + return "Buy" + case HANDLE_TYPE_Sell: + return "Sell" + case HANDLE_TYPE_Remove: + return "Remove" + } + return "" +} + +func HANDLE_TYPEFromString(s string) (HANDLE_TYPE, error) { + switch s { + case "Add": + return HANDLE_TYPE_Add, nil + case "Compose": + return HANDLE_TYPE_Compose, nil + case "Buy": + return HANDLE_TYPE_Buy, nil + case "Sell": + return HANDLE_TYPE_Sell, nil + case "Remove": + return HANDLE_TYPE_Remove, nil + } + return HANDLE_TYPE(0), fmt.Errorf("not a valid HANDLE_TYPE string") +} + +func HANDLE_TYPEPtr(v HANDLE_TYPE) *HANDLE_TYPE { return &v } + +func (p HANDLE_TYPE) MarshalText() ([]byte, error) { + return []byte(p.String()), nil +} + +func (p *HANDLE_TYPE) UnmarshalText(text []byte) error { + q, err := HANDLE_TYPEFromString(string(text)) + if err != nil { + return err + } + *p = q + return nil +} + +func (p *HANDLE_TYPE) Scan(value interface{}) error { + v, ok := value.(int64) + if !ok { + return errors.New("Scan value is not int64") + } + *p = HANDLE_TYPE(v) + return nil +} + +func (p *HANDLE_TYPE) Value() (driver.Value, error) { + if p == nil { + return nil, nil + } + return int64(*p), nil +} + +type ITEM_POP_LABEL int64 + +const ( + ITEM_POP_LABEL_Playroom ITEM_POP_LABEL = 0 + ITEM_POP_LABEL_PiggyBank ITEM_POP_LABEL = 1 + ITEM_POP_LABEL_Charge ITEM_POP_LABEL = 2 + ITEM_POP_LABEL_Endless ITEM_POP_LABEL = 3 + ITEM_POP_LABEL_LevUpReward ITEM_POP_LABEL = 4 + ITEM_POP_LABEL_HandleChess ITEM_POP_LABEL = 5 + ITEM_POP_LABEL_HandbookReward ITEM_POP_LABEL = 6 + ITEM_POP_LABEL_OrderReward ITEM_POP_LABEL = 7 + ITEM_POP_LABEL_DecorateCost ITEM_POP_LABEL = 8 + ITEM_POP_LABEL_DecorateAdd ITEM_POP_LABEL = 9 + ITEM_POP_LABEL_BuyChessBagGrid ITEM_POP_LABEL = 10 + ITEM_POP_LABEL_ChessEx ITEM_POP_LABEL = 11 + ITEM_POP_LABEL_CardCollectReward ITEM_POP_LABEL = 12 + ITEM_POP_LABEL_ExStarReward ITEM_POP_LABEL = 13 + ITEM_POP_LABEL_AllCollectReward ITEM_POP_LABEL = 14 + ITEM_POP_LABEL_GuideReward ITEM_POP_LABEL = 15 + ITEM_POP_LABEL_DailyTaskReward ITEM_POP_LABEL = 16 + ITEM_POP_LABEL_DailyWeekReward ITEM_POP_LABEL = 17 + ITEM_POP_LABEL_BuyEnergy ITEM_POP_LABEL = 18 + ITEM_POP_LABEL_SevenLoginRewardLabel ITEM_POP_LABEL = 19 + ITEM_POP_LABEL_MonthLoginReward ITEM_POP_LABEL = 20 + ITEM_POP_LABEL_FastProduceReward ITEM_POP_LABEL = 21 + ITEM_POP_LABEL_LimitSenceReward ITEM_POP_LABEL = 22 + ITEM_POP_LABEL_MailReward ITEM_POP_LABEL = 23 + ITEM_POP_LABEL_FreeShop ITEM_POP_LABEL = 24 + ITEM_POP_LABEL_ChessShop ITEM_POP_LABEL = 25 + ITEM_POP_LABEL_RefreshChessShop ITEM_POP_LABEL = 26 + ITEM_POP_LABEL_EndlessReward ITEM_POP_LABEL = 27 + ITEM_POP_LABEL_PiggyBankReward ITEM_POP_LABEL = 28 + ITEM_POP_LABEL_ChampshipReward ITEM_POP_LABEL = 29 + ITEM_POP_LABEL_LimitEventReward ITEM_POP_LABEL = 30 + ITEM_POP_LABEL_ChampshipRankReward ITEM_POP_LABEL = 31 + ITEM_POP_LABEL_invite ITEM_POP_LABEL = 32 + ITEM_POP_LABEL_SelectLimitEvent ITEM_POP_LABEL = 33 + ITEM_POP_LABEL_MiningTake ITEM_POP_LABEL = 34 + ITEM_POP_LABEL_MiningReward ITEM_POP_LABEL = 35 + ITEM_POP_LABEL_GuessColor ITEM_POP_LABEL = 36 + ITEM_POP_LABEL_GuessColorReward ITEM_POP_LABEL = 37 + ITEM_POP_LABEL_RaceReward ITEM_POP_LABEL = 38 + ITEM_POP_LABEL_PlayroomGame ITEM_POP_LABEL = 39 + ITEM_POP_LABEL_PlayroomDraw ITEM_POP_LABEL = 40 + ITEM_POP_LABEL_PlayroomChip ITEM_POP_LABEL = 41 + ITEM_POP_LABEL_PlayroomFlip ITEM_POP_LABEL = 42 + ITEM_POP_LABEL_FriendtreasureFilp ITEM_POP_LABEL = 43 + ITEM_POP_LABEL_FriendtreasureEnd ITEM_POP_LABEL = 44 + ITEM_POP_LABEL_Gm ITEM_POP_LABEL = 45 + ITEM_POP_LABEL_Friendtreasure ITEM_POP_LABEL = 46 + ITEM_POP_LABEL_CardHandbookReward ITEM_POP_LABEL = 47 + ITEM_POP_LABEL_LimitEventChestRain ITEM_POP_LABEL = 48 + ITEM_POP_LABEL_GetEnergyByAD ITEM_POP_LABEL = 49 + ITEM_POP_LABEL_SourceChest ITEM_POP_LABEL = 50 + ITEM_POP_LABEL_PlayroomBuyItem ITEM_POP_LABEL = 51 + ITEM_POP_LABEL_CardSeasonFirstReward ITEM_POP_LABEL = 52 + ITEM_POP_LABEL_AllCollectRewardHB ITEM_POP_LABEL = 53 + ITEM_POP_LABEL_PlayroomShop ITEM_POP_LABEL = 54 + ITEM_POP_LABEL_HandbookAllReward ITEM_POP_LABEL = 55 + ITEM_POP_LABEL_TLUpvote ITEM_POP_LABEL = 56 + ITEM_POP_LABEL_Collect ITEM_POP_LABEL = 57 + ITEM_POP_LABEL_ActivityGift ITEM_POP_LABEL = 58 + ITEM_POP_LABEL_ActivityReward ITEM_POP_LABEL = 59 + ITEM_POP_LABEL_CatTrickReward ITEM_POP_LABEL = 60 + ITEM_POP_LABEL_AddWish ITEM_POP_LABEL = 61 + ITEM_POP_LABEL_GetWish ITEM_POP_LABEL = 62 + ITEM_POP_LABEL_PlayroomTask ITEM_POP_LABEL = 63 + ITEM_POP_LABEL_PlayroomTaskReward ITEM_POP_LABEL = 64 + ITEM_POP_LABEL_PlayroomUpvote ITEM_POP_LABEL = 65 + ITEM_POP_LABEL_DecorateReward ITEM_POP_LABEL = 66 + ITEM_POP_LABEL_CatnipReward ITEM_POP_LABEL = 67 + ITEM_POP_LABEL_CatnipGrandReward ITEM_POP_LABEL = 68 + ITEM_POP_LABEL_CatnipPlay ITEM_POP_LABEL = 69 + ITEM_POP_LABEL_FriendTReward ITEM_POP_LABEL = 70 + ITEM_POP_LABEL_PetTheif ITEM_POP_LABEL = 71 + ITEM_POP_LABEL_GuideTaskReward ITEM_POP_LABEL = 72 + ITEM_POP_LABEL_GuideActiveReward ITEM_POP_LABEL = 73 + ITEM_POP_LABEL_PassCharge ITEM_POP_LABEL = 74 + ITEM_POP_LABEL_ActPassReward ITEM_POP_LABEL = 75 + ITEM_POP_LABEL_FriendReplyHandle ITEM_POP_LABEL = 76 + ITEM_POP_LABEL_GetChessRetireReward ITEM_POP_LABEL = 77 + ITEM_POP_LABEL_ApplyFriendSponsor ITEM_POP_LABEL = 78 + ITEM_POP_LABEL_PetFurShop ITEM_POP_LABEL = 79 + ITEM_POP_LABEL_ActTypeAddGift ITEM_POP_LABEL = 80 + ITEM_POP_LABEL_CatReturnGiftReward ITEM_POP_LABEL = 81 +) + +var knownITEM_POP_LABELValues = []ITEM_POP_LABEL{ + ITEM_POP_LABEL_Playroom, + ITEM_POP_LABEL_PiggyBank, + ITEM_POP_LABEL_Charge, + ITEM_POP_LABEL_Endless, + ITEM_POP_LABEL_LevUpReward, + ITEM_POP_LABEL_HandleChess, + ITEM_POP_LABEL_HandbookReward, + ITEM_POP_LABEL_OrderReward, + ITEM_POP_LABEL_DecorateCost, + ITEM_POP_LABEL_DecorateAdd, + ITEM_POP_LABEL_BuyChessBagGrid, + ITEM_POP_LABEL_ChessEx, + ITEM_POP_LABEL_CardCollectReward, + ITEM_POP_LABEL_ExStarReward, + ITEM_POP_LABEL_AllCollectReward, + ITEM_POP_LABEL_GuideReward, + ITEM_POP_LABEL_DailyTaskReward, + ITEM_POP_LABEL_DailyWeekReward, + ITEM_POP_LABEL_BuyEnergy, + ITEM_POP_LABEL_SevenLoginRewardLabel, + ITEM_POP_LABEL_MonthLoginReward, + ITEM_POP_LABEL_FastProduceReward, + ITEM_POP_LABEL_LimitSenceReward, + ITEM_POP_LABEL_MailReward, + ITEM_POP_LABEL_FreeShop, + ITEM_POP_LABEL_ChessShop, + ITEM_POP_LABEL_RefreshChessShop, + ITEM_POP_LABEL_EndlessReward, + ITEM_POP_LABEL_PiggyBankReward, + ITEM_POP_LABEL_ChampshipReward, + ITEM_POP_LABEL_LimitEventReward, + ITEM_POP_LABEL_ChampshipRankReward, + ITEM_POP_LABEL_invite, + ITEM_POP_LABEL_SelectLimitEvent, + ITEM_POP_LABEL_MiningTake, + ITEM_POP_LABEL_MiningReward, + ITEM_POP_LABEL_GuessColor, + ITEM_POP_LABEL_GuessColorReward, + ITEM_POP_LABEL_RaceReward, + ITEM_POP_LABEL_PlayroomGame, + ITEM_POP_LABEL_PlayroomDraw, + ITEM_POP_LABEL_PlayroomChip, + ITEM_POP_LABEL_PlayroomFlip, + ITEM_POP_LABEL_FriendtreasureFilp, + ITEM_POP_LABEL_FriendtreasureEnd, + ITEM_POP_LABEL_Gm, + ITEM_POP_LABEL_Friendtreasure, + ITEM_POP_LABEL_CardHandbookReward, + ITEM_POP_LABEL_LimitEventChestRain, + ITEM_POP_LABEL_GetEnergyByAD, + ITEM_POP_LABEL_SourceChest, + ITEM_POP_LABEL_PlayroomBuyItem, + ITEM_POP_LABEL_CardSeasonFirstReward, + ITEM_POP_LABEL_AllCollectRewardHB, + ITEM_POP_LABEL_PlayroomShop, + ITEM_POP_LABEL_HandbookAllReward, + ITEM_POP_LABEL_TLUpvote, + ITEM_POP_LABEL_Collect, + ITEM_POP_LABEL_ActivityGift, + ITEM_POP_LABEL_ActivityReward, + ITEM_POP_LABEL_CatTrickReward, + ITEM_POP_LABEL_AddWish, + ITEM_POP_LABEL_GetWish, + ITEM_POP_LABEL_PlayroomTask, + ITEM_POP_LABEL_PlayroomTaskReward, + ITEM_POP_LABEL_PlayroomUpvote, + ITEM_POP_LABEL_DecorateReward, + ITEM_POP_LABEL_CatnipReward, + ITEM_POP_LABEL_CatnipGrandReward, + ITEM_POP_LABEL_CatnipPlay, + ITEM_POP_LABEL_FriendTReward, + ITEM_POP_LABEL_PetTheif, + ITEM_POP_LABEL_GuideTaskReward, + ITEM_POP_LABEL_GuideActiveReward, + ITEM_POP_LABEL_PassCharge, + ITEM_POP_LABEL_ActPassReward, + ITEM_POP_LABEL_FriendReplyHandle, + ITEM_POP_LABEL_GetChessRetireReward, + ITEM_POP_LABEL_ApplyFriendSponsor, + ITEM_POP_LABEL_PetFurShop, + ITEM_POP_LABEL_ActTypeAddGift, + ITEM_POP_LABEL_CatReturnGiftReward, +} + +func ITEM_POP_LABELValues() iter.Seq[ITEM_POP_LABEL] { + return func(yield func(ITEM_POP_LABEL) bool) { + for _, v := range knownITEM_POP_LABELValues { + if !yield(v) { + return + } + } + } +} + +func (p ITEM_POP_LABEL) String() string { + switch p { + case ITEM_POP_LABEL_Playroom: + return "Playroom" + case ITEM_POP_LABEL_PiggyBank: + return "PiggyBank" + case ITEM_POP_LABEL_Charge: + return "Charge" + case ITEM_POP_LABEL_Endless: + return "Endless" + case ITEM_POP_LABEL_LevUpReward: + return "LevUpReward" + case ITEM_POP_LABEL_HandleChess: + return "HandleChess" + case ITEM_POP_LABEL_HandbookReward: + return "HandbookReward" + case ITEM_POP_LABEL_OrderReward: + return "OrderReward" + case ITEM_POP_LABEL_DecorateCost: + return "DecorateCost" + case ITEM_POP_LABEL_DecorateAdd: + return "DecorateAdd" + case ITEM_POP_LABEL_BuyChessBagGrid: + return "BuyChessBagGrid" + case ITEM_POP_LABEL_ChessEx: + return "ChessEx" + case ITEM_POP_LABEL_CardCollectReward: + return "CardCollectReward" + case ITEM_POP_LABEL_ExStarReward: + return "ExStarReward" + case ITEM_POP_LABEL_AllCollectReward: + return "AllCollectReward" + case ITEM_POP_LABEL_GuideReward: + return "GuideReward" + case ITEM_POP_LABEL_DailyTaskReward: + return "DailyTaskReward" + case ITEM_POP_LABEL_DailyWeekReward: + return "DailyWeekReward" + case ITEM_POP_LABEL_BuyEnergy: + return "BuyEnergy" + case ITEM_POP_LABEL_SevenLoginRewardLabel: + return "SevenLoginRewardLabel" + case ITEM_POP_LABEL_MonthLoginReward: + return "MonthLoginReward" + case ITEM_POP_LABEL_FastProduceReward: + return "FastProduceReward" + case ITEM_POP_LABEL_LimitSenceReward: + return "LimitSenceReward" + case ITEM_POP_LABEL_MailReward: + return "MailReward" + case ITEM_POP_LABEL_FreeShop: + return "FreeShop" + case ITEM_POP_LABEL_ChessShop: + return "ChessShop" + case ITEM_POP_LABEL_RefreshChessShop: + return "RefreshChessShop" + case ITEM_POP_LABEL_EndlessReward: + return "EndlessReward" + case ITEM_POP_LABEL_PiggyBankReward: + return "PiggyBankReward" + case ITEM_POP_LABEL_ChampshipReward: + return "ChampshipReward" + case ITEM_POP_LABEL_LimitEventReward: + return "LimitEventReward" + case ITEM_POP_LABEL_ChampshipRankReward: + return "ChampshipRankReward" + case ITEM_POP_LABEL_invite: + return "invite" + case ITEM_POP_LABEL_SelectLimitEvent: + return "SelectLimitEvent" + case ITEM_POP_LABEL_MiningTake: + return "MiningTake" + case ITEM_POP_LABEL_MiningReward: + return "MiningReward" + case ITEM_POP_LABEL_GuessColor: + return "GuessColor" + case ITEM_POP_LABEL_GuessColorReward: + return "GuessColorReward" + case ITEM_POP_LABEL_RaceReward: + return "RaceReward" + case ITEM_POP_LABEL_PlayroomGame: + return "PlayroomGame" + case ITEM_POP_LABEL_PlayroomDraw: + return "PlayroomDraw" + case ITEM_POP_LABEL_PlayroomChip: + return "PlayroomChip" + case ITEM_POP_LABEL_PlayroomFlip: + return "PlayroomFlip" + case ITEM_POP_LABEL_FriendtreasureFilp: + return "FriendtreasureFilp" + case ITEM_POP_LABEL_FriendtreasureEnd: + return "FriendtreasureEnd" + case ITEM_POP_LABEL_Gm: + return "Gm" + case ITEM_POP_LABEL_Friendtreasure: + return "Friendtreasure" + case ITEM_POP_LABEL_CardHandbookReward: + return "CardHandbookReward" + case ITEM_POP_LABEL_LimitEventChestRain: + return "LimitEventChestRain" + case ITEM_POP_LABEL_GetEnergyByAD: + return "GetEnergyByAD" + case ITEM_POP_LABEL_SourceChest: + return "SourceChest" + case ITEM_POP_LABEL_PlayroomBuyItem: + return "PlayroomBuyItem" + case ITEM_POP_LABEL_CardSeasonFirstReward: + return "CardSeasonFirstReward" + case ITEM_POP_LABEL_AllCollectRewardHB: + return "AllCollectRewardHB" + case ITEM_POP_LABEL_PlayroomShop: + return "PlayroomShop" + case ITEM_POP_LABEL_HandbookAllReward: + return "HandbookAllReward" + case ITEM_POP_LABEL_TLUpvote: + return "TLUpvote" + case ITEM_POP_LABEL_Collect: + return "Collect" + case ITEM_POP_LABEL_ActivityGift: + return "ActivityGift" + case ITEM_POP_LABEL_ActivityReward: + return "ActivityReward" + case ITEM_POP_LABEL_CatTrickReward: + return "CatTrickReward" + case ITEM_POP_LABEL_AddWish: + return "AddWish" + case ITEM_POP_LABEL_GetWish: + return "GetWish" + case ITEM_POP_LABEL_PlayroomTask: + return "PlayroomTask" + case ITEM_POP_LABEL_PlayroomTaskReward: + return "PlayroomTaskReward" + case ITEM_POP_LABEL_PlayroomUpvote: + return "PlayroomUpvote" + case ITEM_POP_LABEL_DecorateReward: + return "DecorateReward" + case ITEM_POP_LABEL_CatnipReward: + return "CatnipReward" + case ITEM_POP_LABEL_CatnipGrandReward: + return "CatnipGrandReward" + case ITEM_POP_LABEL_CatnipPlay: + return "CatnipPlay" + case ITEM_POP_LABEL_FriendTReward: + return "FriendTReward" + case ITEM_POP_LABEL_PetTheif: + return "PetTheif" + case ITEM_POP_LABEL_GuideTaskReward: + return "GuideTaskReward" + case ITEM_POP_LABEL_GuideActiveReward: + return "GuideActiveReward" + case ITEM_POP_LABEL_PassCharge: + return "PassCharge" + case ITEM_POP_LABEL_ActPassReward: + return "ActPassReward" + case ITEM_POP_LABEL_FriendReplyHandle: + return "FriendReplyHandle" + case ITEM_POP_LABEL_GetChessRetireReward: + return "GetChessRetireReward" + case ITEM_POP_LABEL_ApplyFriendSponsor: + return "ApplyFriendSponsor" + case ITEM_POP_LABEL_PetFurShop: + return "PetFurShop" + case ITEM_POP_LABEL_ActTypeAddGift: + return "ActTypeAddGift" + case ITEM_POP_LABEL_CatReturnGiftReward: + return "CatReturnGiftReward" + } + return "" +} + +func ITEM_POP_LABELFromString(s string) (ITEM_POP_LABEL, error) { + switch s { + case "Playroom": + return ITEM_POP_LABEL_Playroom, nil + case "PiggyBank": + return ITEM_POP_LABEL_PiggyBank, nil + case "Charge": + return ITEM_POP_LABEL_Charge, nil + case "Endless": + return ITEM_POP_LABEL_Endless, nil + case "LevUpReward": + return ITEM_POP_LABEL_LevUpReward, nil + case "HandleChess": + return ITEM_POP_LABEL_HandleChess, nil + case "HandbookReward": + return ITEM_POP_LABEL_HandbookReward, nil + case "OrderReward": + return ITEM_POP_LABEL_OrderReward, nil + case "DecorateCost": + return ITEM_POP_LABEL_DecorateCost, nil + case "DecorateAdd": + return ITEM_POP_LABEL_DecorateAdd, nil + case "BuyChessBagGrid": + return ITEM_POP_LABEL_BuyChessBagGrid, nil + case "ChessEx": + return ITEM_POP_LABEL_ChessEx, nil + case "CardCollectReward": + return ITEM_POP_LABEL_CardCollectReward, nil + case "ExStarReward": + return ITEM_POP_LABEL_ExStarReward, nil + case "AllCollectReward": + return ITEM_POP_LABEL_AllCollectReward, nil + case "GuideReward": + return ITEM_POP_LABEL_GuideReward, nil + case "DailyTaskReward": + return ITEM_POP_LABEL_DailyTaskReward, nil + case "DailyWeekReward": + return ITEM_POP_LABEL_DailyWeekReward, nil + case "BuyEnergy": + return ITEM_POP_LABEL_BuyEnergy, nil + case "SevenLoginRewardLabel": + return ITEM_POP_LABEL_SevenLoginRewardLabel, nil + case "MonthLoginReward": + return ITEM_POP_LABEL_MonthLoginReward, nil + case "FastProduceReward": + return ITEM_POP_LABEL_FastProduceReward, nil + case "LimitSenceReward": + return ITEM_POP_LABEL_LimitSenceReward, nil + case "MailReward": + return ITEM_POP_LABEL_MailReward, nil + case "FreeShop": + return ITEM_POP_LABEL_FreeShop, nil + case "ChessShop": + return ITEM_POP_LABEL_ChessShop, nil + case "RefreshChessShop": + return ITEM_POP_LABEL_RefreshChessShop, nil + case "EndlessReward": + return ITEM_POP_LABEL_EndlessReward, nil + case "PiggyBankReward": + return ITEM_POP_LABEL_PiggyBankReward, nil + case "ChampshipReward": + return ITEM_POP_LABEL_ChampshipReward, nil + case "LimitEventReward": + return ITEM_POP_LABEL_LimitEventReward, nil + case "ChampshipRankReward": + return ITEM_POP_LABEL_ChampshipRankReward, nil + case "invite": + return ITEM_POP_LABEL_invite, nil + case "SelectLimitEvent": + return ITEM_POP_LABEL_SelectLimitEvent, nil + case "MiningTake": + return ITEM_POP_LABEL_MiningTake, nil + case "MiningReward": + return ITEM_POP_LABEL_MiningReward, nil + case "GuessColor": + return ITEM_POP_LABEL_GuessColor, nil + case "GuessColorReward": + return ITEM_POP_LABEL_GuessColorReward, nil + case "RaceReward": + return ITEM_POP_LABEL_RaceReward, nil + case "PlayroomGame": + return ITEM_POP_LABEL_PlayroomGame, nil + case "PlayroomDraw": + return ITEM_POP_LABEL_PlayroomDraw, nil + case "PlayroomChip": + return ITEM_POP_LABEL_PlayroomChip, nil + case "PlayroomFlip": + return ITEM_POP_LABEL_PlayroomFlip, nil + case "FriendtreasureFilp": + return ITEM_POP_LABEL_FriendtreasureFilp, nil + case "FriendtreasureEnd": + return ITEM_POP_LABEL_FriendtreasureEnd, nil + case "Gm": + return ITEM_POP_LABEL_Gm, nil + case "Friendtreasure": + return ITEM_POP_LABEL_Friendtreasure, nil + case "CardHandbookReward": + return ITEM_POP_LABEL_CardHandbookReward, nil + case "LimitEventChestRain": + return ITEM_POP_LABEL_LimitEventChestRain, nil + case "GetEnergyByAD": + return ITEM_POP_LABEL_GetEnergyByAD, nil + case "SourceChest": + return ITEM_POP_LABEL_SourceChest, nil + case "PlayroomBuyItem": + return ITEM_POP_LABEL_PlayroomBuyItem, nil + case "CardSeasonFirstReward": + return ITEM_POP_LABEL_CardSeasonFirstReward, nil + case "AllCollectRewardHB": + return ITEM_POP_LABEL_AllCollectRewardHB, nil + case "PlayroomShop": + return ITEM_POP_LABEL_PlayroomShop, nil + case "HandbookAllReward": + return ITEM_POP_LABEL_HandbookAllReward, nil + case "TLUpvote": + return ITEM_POP_LABEL_TLUpvote, nil + case "Collect": + return ITEM_POP_LABEL_Collect, nil + case "ActivityGift": + return ITEM_POP_LABEL_ActivityGift, nil + case "ActivityReward": + return ITEM_POP_LABEL_ActivityReward, nil + case "CatTrickReward": + return ITEM_POP_LABEL_CatTrickReward, nil + case "AddWish": + return ITEM_POP_LABEL_AddWish, nil + case "GetWish": + return ITEM_POP_LABEL_GetWish, nil + case "PlayroomTask": + return ITEM_POP_LABEL_PlayroomTask, nil + case "PlayroomTaskReward": + return ITEM_POP_LABEL_PlayroomTaskReward, nil + case "PlayroomUpvote": + return ITEM_POP_LABEL_PlayroomUpvote, nil + case "DecorateReward": + return ITEM_POP_LABEL_DecorateReward, nil + case "CatnipReward": + return ITEM_POP_LABEL_CatnipReward, nil + case "CatnipGrandReward": + return ITEM_POP_LABEL_CatnipGrandReward, nil + case "CatnipPlay": + return ITEM_POP_LABEL_CatnipPlay, nil + case "FriendTReward": + return ITEM_POP_LABEL_FriendTReward, nil + case "PetTheif": + return ITEM_POP_LABEL_PetTheif, nil + case "GuideTaskReward": + return ITEM_POP_LABEL_GuideTaskReward, nil + case "GuideActiveReward": + return ITEM_POP_LABEL_GuideActiveReward, nil + case "PassCharge": + return ITEM_POP_LABEL_PassCharge, nil + case "ActPassReward": + return ITEM_POP_LABEL_ActPassReward, nil + case "FriendReplyHandle": + return ITEM_POP_LABEL_FriendReplyHandle, nil + case "GetChessRetireReward": + return ITEM_POP_LABEL_GetChessRetireReward, nil + case "ApplyFriendSponsor": + return ITEM_POP_LABEL_ApplyFriendSponsor, nil + case "PetFurShop": + return ITEM_POP_LABEL_PetFurShop, nil + case "ActTypeAddGift": + return ITEM_POP_LABEL_ActTypeAddGift, nil + case "CatReturnGiftReward": + return ITEM_POP_LABEL_CatReturnGiftReward, nil + } + return ITEM_POP_LABEL(0), fmt.Errorf("not a valid ITEM_POP_LABEL string") +} + +func ITEM_POP_LABELPtr(v ITEM_POP_LABEL) *ITEM_POP_LABEL { return &v } + +func (p ITEM_POP_LABEL) MarshalText() ([]byte, error) { + return []byte(p.String()), nil +} + +func (p *ITEM_POP_LABEL) UnmarshalText(text []byte) error { + q, err := ITEM_POP_LABELFromString(string(text)) + if err != nil { + return err + } + *p = q + return nil +} + +func (p *ITEM_POP_LABEL) Scan(value interface{}) error { + v, ok := value.(int64) + if !ok { + return errors.New("Scan value is not int64") + } + *p = ITEM_POP_LABEL(v) + return nil +} + +func (p *ITEM_POP_LABEL) Value() (driver.Value, error) { + if p == nil { + return nil, nil + } + return int64(*p), nil +} + +type ITEM_TYPE int64 + +const ( + ITEM_TYPE_Energy ITEM_TYPE = 0 + ITEM_TYPE_Star ITEM_TYPE = 1 + ITEM_TYPE_Diamond ITEM_TYPE = 2 +) + +var knownITEM_TYPEValues = []ITEM_TYPE{ + ITEM_TYPE_Energy, + ITEM_TYPE_Star, + ITEM_TYPE_Diamond, +} + +func ITEM_TYPEValues() iter.Seq[ITEM_TYPE] { + return func(yield func(ITEM_TYPE) bool) { + for _, v := range knownITEM_TYPEValues { + if !yield(v) { + return + } + } + } +} + +func (p ITEM_TYPE) String() string { + switch p { + case ITEM_TYPE_Energy: + return "Energy" + case ITEM_TYPE_Star: + return "Star" + case ITEM_TYPE_Diamond: + return "Diamond" + } + return "" +} + +func ITEM_TYPEFromString(s string) (ITEM_TYPE, error) { + switch s { + case "Energy": + return ITEM_TYPE_Energy, nil + case "Star": + return ITEM_TYPE_Star, nil + case "Diamond": + return ITEM_TYPE_Diamond, nil + } + return ITEM_TYPE(0), fmt.Errorf("not a valid ITEM_TYPE string") +} + +func ITEM_TYPEPtr(v ITEM_TYPE) *ITEM_TYPE { return &v } + +func (p ITEM_TYPE) MarshalText() ([]byte, error) { + return []byte(p.String()), nil +} + +func (p *ITEM_TYPE) UnmarshalText(text []byte) error { + q, err := ITEM_TYPEFromString(string(text)) + if err != nil { + return err + } + *p = q + return nil +} + +func (p *ITEM_TYPE) Scan(value interface{}) error { + v, ok := value.(int64) + if !ok { + return errors.New("Scan value is not int64") + } + *p = ITEM_TYPE(v) + return nil +} + +func (p *ITEM_TYPE) Value() (driver.Value, error) { + if p == nil { + return nil, nil + } + return int64(*p), nil +} + +type LANG_TYPE int64 + +const ( + LANG_TYPE_LangCn LANG_TYPE = 0 + LANG_TYPE_LangEn LANG_TYPE = 1 + LANG_TYPE_LangPtbr LANG_TYPE = 2 + LANG_TYPE_LangEsLatam LANG_TYPE = 3 +) + +var knownLANG_TYPEValues = []LANG_TYPE{ + LANG_TYPE_LangCn, + LANG_TYPE_LangEn, + LANG_TYPE_LangPtbr, + LANG_TYPE_LangEsLatam, +} + +func LANG_TYPEValues() iter.Seq[LANG_TYPE] { + return func(yield func(LANG_TYPE) bool) { + for _, v := range knownLANG_TYPEValues { + if !yield(v) { + return + } + } + } +} + +func (p LANG_TYPE) String() string { + switch p { + case LANG_TYPE_LangCn: + return "LangCn" + case LANG_TYPE_LangEn: + return "LangEn" + case LANG_TYPE_LangPtbr: + return "LangPtbr" + case LANG_TYPE_LangEsLatam: + return "LangEsLatam" + } + return "" +} + +func LANG_TYPEFromString(s string) (LANG_TYPE, error) { + switch s { + case "LangCn": + return LANG_TYPE_LangCn, nil + case "LangEn": + return LANG_TYPE_LangEn, nil + case "LangPtbr": + return LANG_TYPE_LangPtbr, nil + case "LangEsLatam": + return LANG_TYPE_LangEsLatam, nil + } + return LANG_TYPE(0), fmt.Errorf("not a valid LANG_TYPE string") +} + +func LANG_TYPEPtr(v LANG_TYPE) *LANG_TYPE { return &v } + +func (p LANG_TYPE) MarshalText() ([]byte, error) { + return []byte(p.String()), nil +} + +func (p *LANG_TYPE) UnmarshalText(text []byte) error { + q, err := LANG_TYPEFromString(string(text)) + if err != nil { + return err + } + *p = q + return nil +} + +func (p *LANG_TYPE) Scan(value interface{}) error { + v, ok := value.(int64) + if !ok { + return errors.New("Scan value is not int64") + } + *p = LANG_TYPE(v) + return nil +} + +func (p *LANG_TYPE) Value() (driver.Value, error) { + if p == nil { + return nil, nil + } + return int64(*p), nil +} + +type LOGIN_TYPE int64 + +const ( + LOGIN_TYPE_AccountLogin LOGIN_TYPE = 0 + LOGIN_TYPE_CodeLogin LOGIN_TYPE = 1 + LOGIN_TYPE_DeviceLogin LOGIN_TYPE = 2 + LOGIN_TYPE_SdkLogin LOGIN_TYPE = 3 +) + +var knownLOGIN_TYPEValues = []LOGIN_TYPE{ + LOGIN_TYPE_AccountLogin, + LOGIN_TYPE_CodeLogin, + LOGIN_TYPE_DeviceLogin, + LOGIN_TYPE_SdkLogin, +} + +func LOGIN_TYPEValues() iter.Seq[LOGIN_TYPE] { + return func(yield func(LOGIN_TYPE) bool) { + for _, v := range knownLOGIN_TYPEValues { + if !yield(v) { + return + } + } + } +} + +func (p LOGIN_TYPE) String() string { + switch p { + case LOGIN_TYPE_AccountLogin: + return "AccountLogin" + case LOGIN_TYPE_CodeLogin: + return "CodeLogin" + case LOGIN_TYPE_DeviceLogin: + return "DeviceLogin" + case LOGIN_TYPE_SdkLogin: + return "SdkLogin" + } + return "" +} + +func LOGIN_TYPEFromString(s string) (LOGIN_TYPE, error) { + switch s { + case "AccountLogin": + return LOGIN_TYPE_AccountLogin, nil + case "CodeLogin": + return LOGIN_TYPE_CodeLogin, nil + case "DeviceLogin": + return LOGIN_TYPE_DeviceLogin, nil + case "SdkLogin": + return LOGIN_TYPE_SdkLogin, nil + } + return LOGIN_TYPE(0), fmt.Errorf("not a valid LOGIN_TYPE string") +} + +func LOGIN_TYPEPtr(v LOGIN_TYPE) *LOGIN_TYPE { return &v } + +func (p LOGIN_TYPE) MarshalText() ([]byte, error) { + return []byte(p.String()), nil +} + +func (p *LOGIN_TYPE) UnmarshalText(text []byte) error { + q, err := LOGIN_TYPEFromString(string(text)) + if err != nil { + return err + } + *p = q + return nil +} + +func (p *LOGIN_TYPE) Scan(value interface{}) error { + v, ok := value.(int64) + if !ok { + return errors.New("Scan value is not int64") + } + *p = LOGIN_TYPE(v) + return nil +} + +func (p *LOGIN_TYPE) Value() (driver.Value, error) { + if p == nil { + return nil, nil + } + return int64(*p), nil +} + +type LimitEventParam int64 + +const ( + LimitEventParam_LepNone LimitEventParam = 0 + LimitEventParam_CatTrickEnergy LimitEventParam = 1 + LimitEventParam_CatTrickType LimitEventParam = 2 + LimitEventParam_PaybackDayCount LimitEventParam = 3 + LimitEventParam_LuckyCatEarnings LimitEventParam = 4 + LimitEventParam_SenceDashTimes LimitEventParam = 5 +) + +var knownLimitEventParamValues = []LimitEventParam{ + LimitEventParam_LepNone, + LimitEventParam_CatTrickEnergy, + LimitEventParam_CatTrickType, + LimitEventParam_PaybackDayCount, + LimitEventParam_LuckyCatEarnings, + LimitEventParam_SenceDashTimes, +} + +func LimitEventParamValues() iter.Seq[LimitEventParam] { + return func(yield func(LimitEventParam) bool) { + for _, v := range knownLimitEventParamValues { + if !yield(v) { + return + } + } + } +} + +func (p LimitEventParam) String() string { + switch p { + case LimitEventParam_LepNone: + return "LepNone" + case LimitEventParam_CatTrickEnergy: + return "CatTrickEnergy" + case LimitEventParam_CatTrickType: + return "CatTrickType" + case LimitEventParam_PaybackDayCount: + return "PaybackDayCount" + case LimitEventParam_LuckyCatEarnings: + return "LuckyCatEarnings" + case LimitEventParam_SenceDashTimes: + return "SenceDashTimes" + } + return "" +} + +func LimitEventParamFromString(s string) (LimitEventParam, error) { + switch s { + case "LepNone": + return LimitEventParam_LepNone, nil + case "CatTrickEnergy": + return LimitEventParam_CatTrickEnergy, nil + case "CatTrickType": + return LimitEventParam_CatTrickType, nil + case "PaybackDayCount": + return LimitEventParam_PaybackDayCount, nil + case "LuckyCatEarnings": + return LimitEventParam_LuckyCatEarnings, nil + case "SenceDashTimes": + return LimitEventParam_SenceDashTimes, nil + } + return LimitEventParam(0), fmt.Errorf("not a valid LimitEventParam string") +} + +func LimitEventParamPtr(v LimitEventParam) *LimitEventParam { return &v } + +func (p LimitEventParam) MarshalText() ([]byte, error) { + return []byte(p.String()), nil +} + +func (p *LimitEventParam) UnmarshalText(text []byte) error { + q, err := LimitEventParamFromString(string(text)) + if err != nil { + return err + } + *p = q + return nil +} + +func (p *LimitEventParam) Scan(value interface{}) error { + v, ok := value.(int64) + if !ok { + return errors.New("Scan value is not int64") + } + *p = LimitEventParam(v) + return nil +} + +func (p *LimitEventParam) Value() (driver.Value, error) { + if p == nil { + return nil, nil + } + return int64(*p), nil +} + +type ORDER_TYPE int64 + +const ( + ORDER_TYPE_Default ORDER_TYPE = 0 + ORDER_TYPE_CommonType ORDER_TYPE = 1 + ORDER_TYPE_ExtraType ORDER_TYPE = 2 + ORDER_TYPE_SuperType ORDER_TYPE = 3 + ORDER_TYPE_PreheatType ORDER_TYPE = 4 + ORDER_TYPE_TriggerType ORDER_TYPE = 5 + ORDER_TYPE_CleanType ORDER_TYPE = 6 + ORDER_TYPE_CleanOrderType ORDER_TYPE = 7 + ORDER_TYPE_CleanType2 ORDER_TYPE = 8 + ORDER_TYPE_ComfortType ORDER_TYPE = 9 + ORDER_TYPE_GuideType ORDER_TYPE = 10 + ORDER_TYPE_PetType ORDER_TYPE = 11 + ORDER_TYPE_PreviewType ORDER_TYPE = 12 + ORDER_TYPE_FixedType ORDER_TYPE = 13 + ORDER_TYPE_PlayroomType ORDER_TYPE = 14 +) + +var knownORDER_TYPEValues = []ORDER_TYPE{ + ORDER_TYPE_Default, + ORDER_TYPE_CommonType, + ORDER_TYPE_ExtraType, + ORDER_TYPE_SuperType, + ORDER_TYPE_PreheatType, + ORDER_TYPE_TriggerType, + ORDER_TYPE_CleanType, + ORDER_TYPE_CleanOrderType, + ORDER_TYPE_CleanType2, + ORDER_TYPE_ComfortType, + ORDER_TYPE_GuideType, + ORDER_TYPE_PetType, + ORDER_TYPE_PreviewType, + ORDER_TYPE_FixedType, + ORDER_TYPE_PlayroomType, +} + +func ORDER_TYPEValues() iter.Seq[ORDER_TYPE] { + return func(yield func(ORDER_TYPE) bool) { + for _, v := range knownORDER_TYPEValues { + if !yield(v) { + return + } + } + } +} + +func (p ORDER_TYPE) String() string { + switch p { + case ORDER_TYPE_Default: + return "Default" + case ORDER_TYPE_CommonType: + return "CommonType" + case ORDER_TYPE_ExtraType: + return "ExtraType" + case ORDER_TYPE_SuperType: + return "SuperType" + case ORDER_TYPE_PreheatType: + return "PreheatType" + case ORDER_TYPE_TriggerType: + return "TriggerType" + case ORDER_TYPE_CleanType: + return "CleanType" + case ORDER_TYPE_CleanOrderType: + return "CleanOrderType" + case ORDER_TYPE_CleanType2: + return "CleanType2" + case ORDER_TYPE_ComfortType: + return "ComfortType" + case ORDER_TYPE_GuideType: + return "GuideType" + case ORDER_TYPE_PetType: + return "PetType" + case ORDER_TYPE_PreviewType: + return "PreviewType" + case ORDER_TYPE_FixedType: + return "FixedType" + case ORDER_TYPE_PlayroomType: + return "PlayroomType" + } + return "" +} + +func ORDER_TYPEFromString(s string) (ORDER_TYPE, error) { + switch s { + case "Default": + return ORDER_TYPE_Default, nil + case "CommonType": + return ORDER_TYPE_CommonType, nil + case "ExtraType": + return ORDER_TYPE_ExtraType, nil + case "SuperType": + return ORDER_TYPE_SuperType, nil + case "PreheatType": + return ORDER_TYPE_PreheatType, nil + case "TriggerType": + return ORDER_TYPE_TriggerType, nil + case "CleanType": + return ORDER_TYPE_CleanType, nil + case "CleanOrderType": + return ORDER_TYPE_CleanOrderType, nil + case "CleanType2": + return ORDER_TYPE_CleanType2, nil + case "ComfortType": + return ORDER_TYPE_ComfortType, nil + case "GuideType": + return ORDER_TYPE_GuideType, nil + case "PetType": + return ORDER_TYPE_PetType, nil + case "PreviewType": + return ORDER_TYPE_PreviewType, nil + case "FixedType": + return ORDER_TYPE_FixedType, nil + case "PlayroomType": + return ORDER_TYPE_PlayroomType, nil + } + return ORDER_TYPE(0), fmt.Errorf("not a valid ORDER_TYPE string") +} + +func ORDER_TYPEPtr(v ORDER_TYPE) *ORDER_TYPE { return &v } + +func (p ORDER_TYPE) MarshalText() ([]byte, error) { + return []byte(p.String()), nil +} + +func (p *ORDER_TYPE) UnmarshalText(text []byte) error { + q, err := ORDER_TYPEFromString(string(text)) + if err != nil { + return err + } + *p = q + return nil +} + +func (p *ORDER_TYPE) Scan(value interface{}) error { + v, ok := value.(int64) + if !ok { + return errors.New("Scan value is not int64") + } + *p = ORDER_TYPE(v) + return nil +} + +func (p *ORDER_TYPE) Value() (driver.Value, error) { + if p == nil { + return nil, nil + } + return int64(*p), nil +} + +type RES_CODE int64 + +const ( + RES_CODE_Fail RES_CODE = 0 + RES_CODE_Success RES_CODE = 1 + RES_CODE_ProtocolErrorAccountExist RES_CODE = 100 + RES_CODE_ProtocolErrorAccountOrPwdError RES_CODE = 101 + RES_CODE_ProtocolErrorAccountOrPwdShort RES_CODE = 102 + RES_CODE_ProtocolErrorAccountFail RES_CODE = 103 + RES_CODE_ProtocolErrorAccountNoExsit RES_CODE = 104 + RES_CODE_ProtocolErrorAccountCodeError RES_CODE = 105 + RES_CODE_ProtocolErrorAccountDeviceError RES_CODE = 106 + RES_CODE_ProtocolErrorIdNotVerify RES_CODE = 107 + RES_CODE_ProtocolErrorIdVerifyError RES_CODE = 108 +) + +var knownRES_CODEValues = []RES_CODE{ + RES_CODE_Fail, + RES_CODE_Success, + RES_CODE_ProtocolErrorAccountExist, + RES_CODE_ProtocolErrorAccountOrPwdError, + RES_CODE_ProtocolErrorAccountOrPwdShort, + RES_CODE_ProtocolErrorAccountFail, + RES_CODE_ProtocolErrorAccountNoExsit, + RES_CODE_ProtocolErrorAccountCodeError, + RES_CODE_ProtocolErrorAccountDeviceError, + RES_CODE_ProtocolErrorIdNotVerify, + RES_CODE_ProtocolErrorIdVerifyError, +} + +func RES_CODEValues() iter.Seq[RES_CODE] { + return func(yield func(RES_CODE) bool) { + for _, v := range knownRES_CODEValues { + if !yield(v) { + return + } + } + } +} + +func (p RES_CODE) String() string { + switch p { + case RES_CODE_Fail: + return "Fail" + case RES_CODE_Success: + return "Success" + case RES_CODE_ProtocolErrorAccountExist: + return "ProtocolErrorAccountExist" + case RES_CODE_ProtocolErrorAccountOrPwdError: + return "ProtocolErrorAccountOrPwdError" + case RES_CODE_ProtocolErrorAccountOrPwdShort: + return "ProtocolErrorAccountOrPwdShort" + case RES_CODE_ProtocolErrorAccountFail: + return "ProtocolErrorAccountFail" + case RES_CODE_ProtocolErrorAccountNoExsit: + return "ProtocolErrorAccountNoExsit" + case RES_CODE_ProtocolErrorAccountCodeError: + return "ProtocolErrorAccountCodeError" + case RES_CODE_ProtocolErrorAccountDeviceError: + return "ProtocolErrorAccountDeviceError" + case RES_CODE_ProtocolErrorIdNotVerify: + return "ProtocolErrorIdNotVerify" + case RES_CODE_ProtocolErrorIdVerifyError: + return "ProtocolErrorIdVerifyError" + } + return "" +} + +func RES_CODEFromString(s string) (RES_CODE, error) { + switch s { + case "Fail": + return RES_CODE_Fail, nil + case "Success": + return RES_CODE_Success, nil + case "ProtocolErrorAccountExist": + return RES_CODE_ProtocolErrorAccountExist, nil + case "ProtocolErrorAccountOrPwdError": + return RES_CODE_ProtocolErrorAccountOrPwdError, nil + case "ProtocolErrorAccountOrPwdShort": + return RES_CODE_ProtocolErrorAccountOrPwdShort, nil + case "ProtocolErrorAccountFail": + return RES_CODE_ProtocolErrorAccountFail, nil + case "ProtocolErrorAccountNoExsit": + return RES_CODE_ProtocolErrorAccountNoExsit, nil + case "ProtocolErrorAccountCodeError": + return RES_CODE_ProtocolErrorAccountCodeError, nil + case "ProtocolErrorAccountDeviceError": + return RES_CODE_ProtocolErrorAccountDeviceError, nil + case "ProtocolErrorIdNotVerify": + return RES_CODE_ProtocolErrorIdNotVerify, nil + case "ProtocolErrorIdVerifyError": + return RES_CODE_ProtocolErrorIdVerifyError, nil + } + return RES_CODE(0), fmt.Errorf("not a valid RES_CODE string") +} + +func RES_CODEPtr(v RES_CODE) *RES_CODE { return &v } + +func (p RES_CODE) MarshalText() ([]byte, error) { + return []byte(p.String()), nil +} + +func (p *RES_CODE) UnmarshalText(text []byte) error { + q, err := RES_CODEFromString(string(text)) + if err != nil { + return err + } + *p = q + return nil +} + +func (p *RES_CODE) Scan(value interface{}) error { + v, ok := value.(int64) + if !ok { + return errors.New("Scan value is not int64") + } + *p = RES_CODE(v) + return nil +} + +func (p *RES_CODE) Value() (driver.Value, error) { + if p == nil { + return nil, nil + } + return int64(*p), nil +} + +type TIME_LINE_TYPE int64 + +const ( + TIME_LINE_TYPE_Default TIME_LINE_TYPE = 0 + TIME_LINE_TYPE_LogTypeFriendApply TIME_LINE_TYPE = 1 + TIME_LINE_TYPE_LogTypeFriendBecome TIME_LINE_TYPE = 2 + TIME_LINE_TYPE_LogTypeCardExSend TIME_LINE_TYPE = 3 + TIME_LINE_TYPE_LogTypeCardSend TIME_LINE_TYPE = 4 + TIME_LINE_TYPE_LogTypeCardGive TIME_LINE_TYPE = 5 + TIME_LINE_TYPE_LogTypeCardSelectGet TIME_LINE_TYPE = 6 + TIME_LINE_TYPE_LogTypeCardAcceptGive TIME_LINE_TYPE = 7 + TIME_LINE_TYPE_LogTypeCardExGet TIME_LINE_TYPE = 8 + TIME_LINE_TYPE_LogTypeCardSelectSend TIME_LINE_TYPE = 9 + TIME_LINE_TYPE_LogTypeCardExSuccess1 TIME_LINE_TYPE = 10 + TIME_LINE_TYPE_LogTypeCardExSuccess2 TIME_LINE_TYPE = 11 + TIME_LINE_TYPE_LogTypeFriendDelete TIME_LINE_TYPE = 14 + TIME_LINE_TYPE_LogTypePlayroomVisit TIME_LINE_TYPE = 15 + TIME_LINE_TYPE_LogTypeHandbook TIME_LINE_TYPE = 16 + TIME_LINE_TYPE_LogTypeHandbookUpvote TIME_LINE_TYPE = 17 + TIME_LINE_TYPE_LogTypeChargeSend TIME_LINE_TYPE = 18 + TIME_LINE_TYPE_LogTypeChargeReceived TIME_LINE_TYPE = 19 + TIME_LINE_TYPE_LogTypeWish TIME_LINE_TYPE = 20 + TIME_LINE_TYPE_LogTypeFriendBecomeNpc TIME_LINE_TYPE = 21 + TIME_LINE_TYPE_LogTypePlayroomUpvote TIME_LINE_TYPE = 22 + TIME_LINE_TYPE_LogTypePlayroomChampship TIME_LINE_TYPE = 23 + TIME_LINE_TYPE_LogTypeTreasure TIME_LINE_TYPE = 24 + TIME_LINE_TYPE_LogTypeCardSendAccept TIME_LINE_TYPE = 25 + TIME_LINE_TYPE_LogTypePlayroomCatWin TIME_LINE_TYPE = 26 + TIME_LINE_TYPE_LogTypePlayroomCatLose TIME_LINE_TYPE = 27 + TIME_LINE_TYPE_LogTypeCardGiveAccept TIME_LINE_TYPE = 28 + TIME_LINE_TYPE_LogTypeFriendInvite TIME_LINE_TYPE = 29 + TIME_LINE_TYPE_LogTypeTreasureHelp TIME_LINE_TYPE = 30 + TIME_LINE_TYPE_LogTypeFriendSponsor TIME_LINE_TYPE = 31 + TIME_LINE_TYPE_LogTypeFriendSponsorGet TIME_LINE_TYPE = 32 + TIME_LINE_TYPE_LogTypePlayroomBankruptcy TIME_LINE_TYPE = 33 +) + +var knownTIME_LINE_TYPEValues = []TIME_LINE_TYPE{ + TIME_LINE_TYPE_Default, + TIME_LINE_TYPE_LogTypeFriendApply, + TIME_LINE_TYPE_LogTypeFriendBecome, + TIME_LINE_TYPE_LogTypeCardExSend, + TIME_LINE_TYPE_LogTypeCardSend, + TIME_LINE_TYPE_LogTypeCardGive, + TIME_LINE_TYPE_LogTypeCardSelectGet, + TIME_LINE_TYPE_LogTypeCardAcceptGive, + TIME_LINE_TYPE_LogTypeCardExGet, + TIME_LINE_TYPE_LogTypeCardSelectSend, + TIME_LINE_TYPE_LogTypeCardExSuccess1, + TIME_LINE_TYPE_LogTypeCardExSuccess2, + TIME_LINE_TYPE_LogTypeFriendDelete, + TIME_LINE_TYPE_LogTypePlayroomVisit, + TIME_LINE_TYPE_LogTypeHandbook, + TIME_LINE_TYPE_LogTypeHandbookUpvote, + TIME_LINE_TYPE_LogTypeChargeSend, + TIME_LINE_TYPE_LogTypeChargeReceived, + TIME_LINE_TYPE_LogTypeWish, + TIME_LINE_TYPE_LogTypeFriendBecomeNpc, + TIME_LINE_TYPE_LogTypePlayroomUpvote, + TIME_LINE_TYPE_LogTypePlayroomChampship, + TIME_LINE_TYPE_LogTypeTreasure, + TIME_LINE_TYPE_LogTypeCardSendAccept, + TIME_LINE_TYPE_LogTypePlayroomCatWin, + TIME_LINE_TYPE_LogTypePlayroomCatLose, + TIME_LINE_TYPE_LogTypeCardGiveAccept, + TIME_LINE_TYPE_LogTypeFriendInvite, + TIME_LINE_TYPE_LogTypeTreasureHelp, + TIME_LINE_TYPE_LogTypeFriendSponsor, + TIME_LINE_TYPE_LogTypeFriendSponsorGet, + TIME_LINE_TYPE_LogTypePlayroomBankruptcy, +} + +func TIME_LINE_TYPEValues() iter.Seq[TIME_LINE_TYPE] { + return func(yield func(TIME_LINE_TYPE) bool) { + for _, v := range knownTIME_LINE_TYPEValues { + if !yield(v) { + return + } + } + } +} + +func (p TIME_LINE_TYPE) String() string { + switch p { + case TIME_LINE_TYPE_Default: + return "Default" + case TIME_LINE_TYPE_LogTypeFriendApply: + return "LogTypeFriendApply" + case TIME_LINE_TYPE_LogTypeFriendBecome: + return "LogTypeFriendBecome" + case TIME_LINE_TYPE_LogTypeCardExSend: + return "LogTypeCardExSend" + case TIME_LINE_TYPE_LogTypeCardSend: + return "LogTypeCardSend" + case TIME_LINE_TYPE_LogTypeCardGive: + return "LogTypeCardGive" + case TIME_LINE_TYPE_LogTypeCardSelectGet: + return "LogTypeCardSelectGet" + case TIME_LINE_TYPE_LogTypeCardAcceptGive: + return "LogTypeCardAcceptGive" + case TIME_LINE_TYPE_LogTypeCardExGet: + return "LogTypeCardExGet" + case TIME_LINE_TYPE_LogTypeCardSelectSend: + return "LogTypeCardSelectSend" + case TIME_LINE_TYPE_LogTypeCardExSuccess1: + return "LogTypeCardExSuccess1" + case TIME_LINE_TYPE_LogTypeCardExSuccess2: + return "LogTypeCardExSuccess2" + case TIME_LINE_TYPE_LogTypeFriendDelete: + return "LogTypeFriendDelete" + case TIME_LINE_TYPE_LogTypePlayroomVisit: + return "LogTypePlayroomVisit" + case TIME_LINE_TYPE_LogTypeHandbook: + return "LogTypeHandbook" + case TIME_LINE_TYPE_LogTypeHandbookUpvote: + return "LogTypeHandbookUpvote" + case TIME_LINE_TYPE_LogTypeChargeSend: + return "LogTypeChargeSend" + case TIME_LINE_TYPE_LogTypeChargeReceived: + return "LogTypeChargeReceived" + case TIME_LINE_TYPE_LogTypeWish: + return "LogTypeWish" + case TIME_LINE_TYPE_LogTypeFriendBecomeNpc: + return "LogTypeFriendBecomeNpc" + case TIME_LINE_TYPE_LogTypePlayroomUpvote: + return "LogTypePlayroomUpvote" + case TIME_LINE_TYPE_LogTypePlayroomChampship: + return "LogTypePlayroomChampship" + case TIME_LINE_TYPE_LogTypeTreasure: + return "LogTypeTreasure" + case TIME_LINE_TYPE_LogTypeCardSendAccept: + return "LogTypeCardSendAccept" + case TIME_LINE_TYPE_LogTypePlayroomCatWin: + return "LogTypePlayroomCatWin" + case TIME_LINE_TYPE_LogTypePlayroomCatLose: + return "LogTypePlayroomCatLose" + case TIME_LINE_TYPE_LogTypeCardGiveAccept: + return "LogTypeCardGiveAccept" + case TIME_LINE_TYPE_LogTypeFriendInvite: + return "LogTypeFriendInvite" + case TIME_LINE_TYPE_LogTypeTreasureHelp: + return "LogTypeTreasureHelp" + case TIME_LINE_TYPE_LogTypeFriendSponsor: + return "LogTypeFriendSponsor" + case TIME_LINE_TYPE_LogTypeFriendSponsorGet: + return "LogTypeFriendSponsorGet" + case TIME_LINE_TYPE_LogTypePlayroomBankruptcy: + return "LogTypePlayroomBankruptcy" + } + return "" +} + +func TIME_LINE_TYPEFromString(s string) (TIME_LINE_TYPE, error) { + switch s { + case "Default": + return TIME_LINE_TYPE_Default, nil + case "LogTypeFriendApply": + return TIME_LINE_TYPE_LogTypeFriendApply, nil + case "LogTypeFriendBecome": + return TIME_LINE_TYPE_LogTypeFriendBecome, nil + case "LogTypeCardExSend": + return TIME_LINE_TYPE_LogTypeCardExSend, nil + case "LogTypeCardSend": + return TIME_LINE_TYPE_LogTypeCardSend, nil + case "LogTypeCardGive": + return TIME_LINE_TYPE_LogTypeCardGive, nil + case "LogTypeCardSelectGet": + return TIME_LINE_TYPE_LogTypeCardSelectGet, nil + case "LogTypeCardAcceptGive": + return TIME_LINE_TYPE_LogTypeCardAcceptGive, nil + case "LogTypeCardExGet": + return TIME_LINE_TYPE_LogTypeCardExGet, nil + case "LogTypeCardSelectSend": + return TIME_LINE_TYPE_LogTypeCardSelectSend, nil + case "LogTypeCardExSuccess1": + return TIME_LINE_TYPE_LogTypeCardExSuccess1, nil + case "LogTypeCardExSuccess2": + return TIME_LINE_TYPE_LogTypeCardExSuccess2, nil + case "LogTypeFriendDelete": + return TIME_LINE_TYPE_LogTypeFriendDelete, nil + case "LogTypePlayroomVisit": + return TIME_LINE_TYPE_LogTypePlayroomVisit, nil + case "LogTypeHandbook": + return TIME_LINE_TYPE_LogTypeHandbook, nil + case "LogTypeHandbookUpvote": + return TIME_LINE_TYPE_LogTypeHandbookUpvote, nil + case "LogTypeChargeSend": + return TIME_LINE_TYPE_LogTypeChargeSend, nil + case "LogTypeChargeReceived": + return TIME_LINE_TYPE_LogTypeChargeReceived, nil + case "LogTypeWish": + return TIME_LINE_TYPE_LogTypeWish, nil + case "LogTypeFriendBecomeNpc": + return TIME_LINE_TYPE_LogTypeFriendBecomeNpc, nil + case "LogTypePlayroomUpvote": + return TIME_LINE_TYPE_LogTypePlayroomUpvote, nil + case "LogTypePlayroomChampship": + return TIME_LINE_TYPE_LogTypePlayroomChampship, nil + case "LogTypeTreasure": + return TIME_LINE_TYPE_LogTypeTreasure, nil + case "LogTypeCardSendAccept": + return TIME_LINE_TYPE_LogTypeCardSendAccept, nil + case "LogTypePlayroomCatWin": + return TIME_LINE_TYPE_LogTypePlayroomCatWin, nil + case "LogTypePlayroomCatLose": + return TIME_LINE_TYPE_LogTypePlayroomCatLose, nil + case "LogTypeCardGiveAccept": + return TIME_LINE_TYPE_LogTypeCardGiveAccept, nil + case "LogTypeFriendInvite": + return TIME_LINE_TYPE_LogTypeFriendInvite, nil + case "LogTypeTreasureHelp": + return TIME_LINE_TYPE_LogTypeTreasureHelp, nil + case "LogTypeFriendSponsor": + return TIME_LINE_TYPE_LogTypeFriendSponsor, nil + case "LogTypeFriendSponsorGet": + return TIME_LINE_TYPE_LogTypeFriendSponsorGet, nil + case "LogTypePlayroomBankruptcy": + return TIME_LINE_TYPE_LogTypePlayroomBankruptcy, nil + } + return TIME_LINE_TYPE(0), fmt.Errorf("not a valid TIME_LINE_TYPE string") +} + +func TIME_LINE_TYPEPtr(v TIME_LINE_TYPE) *TIME_LINE_TYPE { return &v } + +func (p TIME_LINE_TYPE) MarshalText() ([]byte, error) { + return []byte(p.String()), nil +} + +func (p *TIME_LINE_TYPE) UnmarshalText(text []byte) error { + q, err := TIME_LINE_TYPEFromString(string(text)) + if err != nil { + return err + } + *p = q + return nil +} + +func (p *TIME_LINE_TYPE) Scan(value interface{}) error { + v, ok := value.(int64) + if !ok { + return errors.New("Scan value is not int64") + } + *p = TIME_LINE_TYPE(v) + return nil +} + +func (p *TIME_LINE_TYPE) Value() (driver.Value, error) { + if p == nil { + return nil, nil + } + return int64(*p), nil +} + +// Attributes: +// - Type +// - Time +// - Param +// +type ActLog struct { + Type int32 `thrift:"Type,1" db:"Type" json:"Type"` + Time int64 `thrift:"Time,2" db:"Time" json:"Time"` + Param string `thrift:"Param,3" db:"Param" json:"Param"` +} + +func NewActLog() *ActLog { + return &ActLog{} +} + +func (p *ActLog) GetType() int32 { + return p.Type +} + +func (p *ActLog) GetTime() int64 { + return p.Time +} + +func (p *ActLog) GetParam() string { + return p.Param +} + +func (p *ActLog) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I64 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.STRING { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ActLog) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ActLog) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Time = v + } + return nil +} + +func (p *ActLog) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Param = v + } + return nil +} + +func (p *ActLog) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ActLog"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ActLog) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Type: ", p), err) + } + return err +} + +func (p *ActLog) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Time", thrift.I64, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Time: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Time)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Time (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Time: ", p), err) + } + return err +} + +func (p *ActLog) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Param", thrift.STRING, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Param: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Param)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Param (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Param: ", p), err) + } + return err +} + +func (p *ActLog) Equals(other *ActLog) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Type != other.Type { + return false + } + if p.Time != other.Time { + return false + } + if p.Param != other.Param { + return false + } + return true +} + +func (p *ActLog) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ActLog(%+v)", *p) +} + +func (p *ActLog) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ActLog", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ActLog)(nil) + +func (p *ActLog) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Type +// - Starttime +// - Endtime +// - Level +// - Title +// - MailTitle +// - MailContent +// - RewardItem +// - Extra +// +type ActivityCfg struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Type int32 `thrift:"Type,2" db:"Type" json:"Type"` + Starttime int64 `thrift:"Starttime,3" db:"Starttime" json:"Starttime"` + Endtime int64 `thrift:"Endtime,4" db:"Endtime" json:"Endtime"` + Level int32 `thrift:"Level,5" db:"Level" json:"Level"` + Title string `thrift:"Title,6" db:"Title" json:"Title"` + MailTitle string `thrift:"MailTitle,7" db:"MailTitle" json:"MailTitle"` + MailContent string `thrift:"MailContent,8" db:"MailContent" json:"MailContent"` + RewardItem string `thrift:"RewardItem,9" db:"RewardItem" json:"RewardItem"` + Extra string `thrift:"Extra,10" db:"Extra" json:"Extra"` +} + +func NewActivityCfg() *ActivityCfg { + return &ActivityCfg{} +} + +func (p *ActivityCfg) GetId() int32 { + return p.Id +} + +func (p *ActivityCfg) GetType() int32 { + return p.Type +} + +func (p *ActivityCfg) GetStarttime() int64 { + return p.Starttime +} + +func (p *ActivityCfg) GetEndtime() int64 { + return p.Endtime +} + +func (p *ActivityCfg) GetLevel() int32 { + return p.Level +} + +func (p *ActivityCfg) GetTitle() string { + return p.Title +} + +func (p *ActivityCfg) GetMailTitle() string { + return p.MailTitle +} + +func (p *ActivityCfg) GetMailContent() string { + return p.MailContent +} + +func (p *ActivityCfg) GetRewardItem() string { + return p.RewardItem +} + +func (p *ActivityCfg) GetExtra() string { + return p.Extra +} + +func (p *ActivityCfg) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I64 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I64 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.STRING { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.STRING { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 8: + if fieldTypeId == thrift.STRING { + if err := p.ReadField8(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 9: + if fieldTypeId == thrift.STRING { + if err := p.ReadField9(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 10: + if fieldTypeId == thrift.STRING { + if err := p.ReadField10(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ActivityCfg) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ActivityCfg) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ActivityCfg) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Starttime = v + } + return nil +} + +func (p *ActivityCfg) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Endtime = v + } + return nil +} + +func (p *ActivityCfg) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.Level = v + } + return nil +} + +func (p *ActivityCfg) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 6: ", err) + } else { + p.Title = v + } + return nil +} + +func (p *ActivityCfg) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 7: ", err) + } else { + p.MailTitle = v + } + return nil +} + +func (p *ActivityCfg) ReadField8(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 8: ", err) + } else { + p.MailContent = v + } + return nil +} + +func (p *ActivityCfg) ReadField9(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 9: ", err) + } else { + p.RewardItem = v + } + return nil +} + +func (p *ActivityCfg) ReadField10(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 10: ", err) + } else { + p.Extra = v + } + return nil +} + +func (p *ActivityCfg) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ActivityCfg"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + if err := p.writeField8(ctx, oprot); err != nil { + return err + } + if err := p.writeField9(ctx, oprot); err != nil { + return err + } + if err := p.writeField10(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ActivityCfg) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ActivityCfg) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Type: ", p), err) + } + return err +} + +func (p *ActivityCfg) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Starttime", thrift.I64, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Starttime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Starttime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Starttime (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Starttime: ", p), err) + } + return err +} + +func (p *ActivityCfg) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Endtime", thrift.I64, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Endtime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Endtime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Endtime (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Endtime: ", p), err) + } + return err +} + +func (p *ActivityCfg) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Level", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Level: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Level)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Level (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Level: ", p), err) + } + return err +} + +func (p *ActivityCfg) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Title", thrift.STRING, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:Title: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Title)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Title (6) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:Title: ", p), err) + } + return err +} + +func (p *ActivityCfg) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MailTitle", thrift.STRING, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:MailTitle: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.MailTitle)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.MailTitle (7) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:MailTitle: ", p), err) + } + return err +} + +func (p *ActivityCfg) writeField8(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MailContent", thrift.STRING, 8); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 8:MailContent: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.MailContent)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.MailContent (8) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 8:MailContent: ", p), err) + } + return err +} + +func (p *ActivityCfg) writeField9(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "RewardItem", thrift.STRING, 9); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 9:RewardItem: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.RewardItem)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.RewardItem (9) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 9:RewardItem: ", p), err) + } + return err +} + +func (p *ActivityCfg) writeField10(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Extra", thrift.STRING, 10); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 10:Extra: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Extra)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Extra (10) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 10:Extra: ", p), err) + } + return err +} + +func (p *ActivityCfg) Equals(other *ActivityCfg) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Type != other.Type { + return false + } + if p.Starttime != other.Starttime { + return false + } + if p.Endtime != other.Endtime { + return false + } + if p.Level != other.Level { + return false + } + if p.Title != other.Title { + return false + } + if p.MailTitle != other.MailTitle { + return false + } + if p.MailContent != other.MailContent { + return false + } + if p.RewardItem != other.RewardItem { + return false + } + if p.Extra != other.Extra { + return false + } + return true +} + +func (p *ActivityCfg) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ActivityCfg(%+v)", *p) +} + +func (p *ActivityCfg) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ActivityCfg", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ActivityCfg)(nil) + +func (p *ActivityCfg) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Type +// - StartTime +// - EndTime +// - Status +// - Title +// - Red +// +type ActivityInfo struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Type int32 `thrift:"Type,2" db:"Type" json:"Type"` + StartTime int32 `thrift:"StartTime,3" db:"StartTime" json:"StartTime"` + EndTime int32 `thrift:"EndTime,4" db:"EndTime" json:"EndTime"` + Status int32 `thrift:"Status,5" db:"Status" json:"Status"` + Title string `thrift:"Title,6" db:"Title" json:"Title"` + Red int32 `thrift:"Red,7" db:"Red" json:"Red"` +} + +func NewActivityInfo() *ActivityInfo { + return &ActivityInfo{} +} + +func (p *ActivityInfo) GetId() int32 { + return p.Id +} + +func (p *ActivityInfo) GetType() int32 { + return p.Type +} + +func (p *ActivityInfo) GetStartTime() int32 { + return p.StartTime +} + +func (p *ActivityInfo) GetEndTime() int32 { + return p.EndTime +} + +func (p *ActivityInfo) GetStatus() int32 { + return p.Status +} + +func (p *ActivityInfo) GetTitle() string { + return p.Title +} + +func (p *ActivityInfo) GetRed() int32 { + return p.Red +} + +func (p *ActivityInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.STRING { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.I32 { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ActivityInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ActivityInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ActivityInfo) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.StartTime = v + } + return nil +} + +func (p *ActivityInfo) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.EndTime = v + } + return nil +} + +func (p *ActivityInfo) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.Status = v + } + return nil +} + +func (p *ActivityInfo) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 6: ", err) + } else { + p.Title = v + } + return nil +} + +func (p *ActivityInfo) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 7: ", err) + } else { + p.Red = v + } + return nil +} + +func (p *ActivityInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ActivityInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ActivityInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ActivityInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Type: ", p), err) + } + return err +} + +func (p *ActivityInfo) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "StartTime", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:StartTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.StartTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.StartTime (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:StartTime: ", p), err) + } + return err +} + +func (p *ActivityInfo) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EndTime", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:EndTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.EndTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EndTime (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:EndTime: ", p), err) + } + return err +} + +func (p *ActivityInfo) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Status", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Status: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Status)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Status (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Status: ", p), err) + } + return err +} + +func (p *ActivityInfo) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Title", thrift.STRING, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:Title: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Title)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Title (6) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:Title: ", p), err) + } + return err +} + +func (p *ActivityInfo) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Red", thrift.I32, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:Red: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Red)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Red (7) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:Red: ", p), err) + } + return err +} + +func (p *ActivityInfo) Equals(other *ActivityInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Type != other.Type { + return false + } + if p.StartTime != other.StartTime { + return false + } + if p.EndTime != other.EndTime { + return false + } + if p.Status != other.Status { + return false + } + if p.Title != other.Title { + return false + } + if p.Red != other.Red { + return false + } + return true +} + +func (p *ActivityInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ActivityInfo(%+v)", *p) +} + +func (p *ActivityInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ActivityInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ActivityInfo)(nil) + +func (p *ActivityInfo) Validate() error { + return nil +} + +// Attributes: +// - Info +// +type ActivityNotify struct { + Info *ActivityInfo `thrift:"Info,1" db:"Info" json:"Info"` +} + +func NewActivityNotify() *ActivityNotify { + return &ActivityNotify{} +} + +var ActivityNotify_Info_DEFAULT *ActivityInfo + +func (p *ActivityNotify) GetInfo() *ActivityInfo { + if !p.IsSetInfo() { + return ActivityNotify_Info_DEFAULT + } + return p.Info +} + +func (p *ActivityNotify) IsSetInfo() bool { + return p.Info != nil +} + +func (p *ActivityNotify) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ActivityNotify) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + p.Info = &ActivityInfo{} + if err := p.Info.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.Info), err) + } + return nil +} + +func (p *ActivityNotify) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ActivityNotify"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ActivityNotify) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Info", thrift.STRUCT, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Info: ", p), err) + } + if err := p.Info.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.Info), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Info: ", p), err) + } + return err +} + +func (p *ActivityNotify) Equals(other *ActivityNotify) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if !p.Info.Equals(other.Info) { + return false + } + return true +} + +func (p *ActivityNotify) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ActivityNotify(%+v)", *p) +} + +func (p *ActivityNotify) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ActivityNotify", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ActivityNotify)(nil) + +func (p *ActivityNotify) Validate() error { + return nil +} + +// Attributes: +// - Watch +// - LastWatch +// - ItemId +// +type AdItem struct { + Watch int32 `thrift:"Watch,1" db:"Watch" json:"Watch"` + LastWatch int32 `thrift:"LastWatch,2" db:"LastWatch" json:"LastWatch"` + ItemId int32 `thrift:"ItemId,3" db:"ItemId" json:"ItemId"` +} + +func NewAdItem() *AdItem { + return &AdItem{} +} + +func (p *AdItem) GetWatch() int32 { + return p.Watch +} + +func (p *AdItem) GetLastWatch() int32 { + return p.LastWatch +} + +func (p *AdItem) GetItemId() int32 { + return p.ItemId +} + +func (p *AdItem) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *AdItem) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Watch = v + } + return nil +} + +func (p *AdItem) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.LastWatch = v + } + return nil +} + +func (p *AdItem) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.ItemId = v + } + return nil +} + +func (p *AdItem) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "AdItem"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *AdItem) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Watch", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Watch: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Watch)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Watch (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Watch: ", p), err) + } + return err +} + +func (p *AdItem) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "LastWatch", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:LastWatch: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.LastWatch)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.LastWatch (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:LastWatch: ", p), err) + } + return err +} + +func (p *AdItem) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ItemId", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:ItemId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ItemId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ItemId (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:ItemId: ", p), err) + } + return err +} + +func (p *AdItem) Equals(other *AdItem) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Watch != other.Watch { + return false + } + if p.LastWatch != other.LastWatch { + return false + } + if p.ItemId != other.ItemId { + return false + } + return true +} + +func (p *AdItem) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("AdItem(%+v)", *p) +} + +func (p *AdItem) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.AdItem", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*AdItem)(nil) + +func (p *AdItem) Validate() error { + return nil +} + +// Attributes: +// - Func +// - Info +// +type AdminReq struct { + Func string `thrift:"Func,1" db:"Func" json:"Func"` + Info []byte `thrift:"Info,2" db:"Info" json:"Info"` +} + +func NewAdminReq() *AdminReq { + return &AdminReq{} +} + +func (p *AdminReq) GetFunc() string { + return p.Func +} + +func (p *AdminReq) GetInfo() []byte { + return p.Info +} + +func (p *AdminReq) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *AdminReq) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Func = v + } + return nil +} + +func (p *AdminReq) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadBinary(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Info = v + } + return nil +} + +func (p *AdminReq) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "AdminReq"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *AdminReq) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Func", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Func: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Func)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Func (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Func: ", p), err) + } + return err +} + +func (p *AdminReq) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Info", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Info: ", p), err) + } + if err := oprot.WriteBinary(ctx, p.Info); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Info (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Info: ", p), err) + } + return err +} + +func (p *AdminReq) Equals(other *AdminReq) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Func != other.Func { + return false + } + if bytes.Compare(p.Info, other.Info) != 0 { + return false + } + return true +} + +func (p *AdminReq) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("AdminReq(%+v)", *p) +} + +func (p *AdminReq) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.AdminReq", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*AdminReq)(nil) + +func (p *AdminReq) Validate() error { + return nil +} + +// Attributes: +// - Func +// - Info +// +type AdminRes struct { + Func string `thrift:"Func,1" db:"Func" json:"Func"` + Info string `thrift:"Info,2" db:"Info" json:"Info"` +} + +func NewAdminRes() *AdminRes { + return &AdminRes{} +} + +func (p *AdminRes) GetFunc() string { + return p.Func +} + +func (p *AdminRes) GetInfo() string { + return p.Info +} + +func (p *AdminRes) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *AdminRes) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Func = v + } + return nil +} + +func (p *AdminRes) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Info = v + } + return nil +} + +func (p *AdminRes) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "AdminRes"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *AdminRes) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Func", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Func: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Func)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Func (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Func: ", p), err) + } + return err +} + +func (p *AdminRes) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Info", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Info: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Info)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Info (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Info: ", p), err) + } + return err +} + +func (p *AdminRes) Equals(other *AdminRes) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Func != other.Func { + return false + } + if p.Info != other.Info { + return false + } + return true +} + +func (p *AdminRes) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("AdminRes(%+v)", *p) +} + +func (p *AdminRes) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.AdminRes", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*AdminRes)(nil) + +func (p *AdminRes) Validate() error { + return nil +} + +// Attributes: +// - Id +// - EndTime +// - AddTime +// +type AvatarInfo struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + EndTime int64 `thrift:"EndTime,2" db:"EndTime" json:"EndTime"` + AddTime int64 `thrift:"AddTime,3" db:"AddTime" json:"AddTime"` +} + +func NewAvatarInfo() *AvatarInfo { + return &AvatarInfo{} +} + +func (p *AvatarInfo) GetId() int32 { + return p.Id +} + +func (p *AvatarInfo) GetEndTime() int64 { + return p.EndTime +} + +func (p *AvatarInfo) GetAddTime() int64 { + return p.AddTime +} + +func (p *AvatarInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I64 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I64 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *AvatarInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *AvatarInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.EndTime = v + } + return nil +} + +func (p *AvatarInfo) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.AddTime = v + } + return nil +} + +func (p *AvatarInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "AvatarInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *AvatarInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *AvatarInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EndTime", thrift.I64, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:EndTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.EndTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EndTime (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:EndTime: ", p), err) + } + return err +} + +func (p *AvatarInfo) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "AddTime", thrift.I64, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:AddTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.AddTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.AddTime (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:AddTime: ", p), err) + } + return err +} + +func (p *AvatarInfo) Equals(other *AvatarInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.EndTime != other.EndTime { + return false + } + if p.AddTime != other.AddTime { + return false + } + return true +} + +func (p *AvatarInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("AvatarInfo(%+v)", *p) +} + +func (p *AvatarInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.AvatarInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*AvatarInfo)(nil) + +func (p *AvatarInfo) Validate() error { + return nil +} + +// Attributes: +// - EnergyMul +// - IsFirstBuy +// - EnergyBuy +// - EnergyAD +// - Lang +// +type BaseInfo struct { + EnergyMul int32 `thrift:"EnergyMul,1" db:"EnergyMul" json:"EnergyMul"` + IsFirstBuy bool `thrift:"IsFirstBuy,2" db:"IsFirstBuy" json:"IsFirstBuy"` + EnergyBuy int32 `thrift:"EnergyBuy,3" db:"EnergyBuy" json:"EnergyBuy"` + EnergyAD int32 `thrift:"EnergyAD,4" db:"EnergyAD" json:"EnergyAD"` + Lang LANG_TYPE `thrift:"Lang,5" db:"Lang" json:"Lang"` +} + +func NewBaseInfo() *BaseInfo { + return &BaseInfo{} +} + +func (p *BaseInfo) GetEnergyMul() int32 { + return p.EnergyMul +} + +func (p *BaseInfo) GetIsFirstBuy() bool { + return p.IsFirstBuy +} + +func (p *BaseInfo) GetEnergyBuy() int32 { + return p.EnergyBuy +} + +func (p *BaseInfo) GetEnergyAD() int32 { + return p.EnergyAD +} + +func (p *BaseInfo) GetLang() LANG_TYPE { + return p.Lang +} + +func (p *BaseInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.BOOL { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *BaseInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.EnergyMul = v + } + return nil +} + +func (p *BaseInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadBool(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.IsFirstBuy = v + } + return nil +} + +func (p *BaseInfo) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.EnergyBuy = v + } + return nil +} + +func (p *BaseInfo) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.EnergyAD = v + } + return nil +} + +func (p *BaseInfo) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + temp := LANG_TYPE(v) + p.Lang = temp + } + return nil +} + +func (p *BaseInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "BaseInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *BaseInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EnergyMul", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:EnergyMul: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.EnergyMul)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EnergyMul (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:EnergyMul: ", p), err) + } + return err +} + +func (p *BaseInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "IsFirstBuy", thrift.BOOL, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:IsFirstBuy: ", p), err) + } + if err := oprot.WriteBool(ctx, bool(p.IsFirstBuy)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.IsFirstBuy (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:IsFirstBuy: ", p), err) + } + return err +} + +func (p *BaseInfo) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EnergyBuy", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:EnergyBuy: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.EnergyBuy)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EnergyBuy (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:EnergyBuy: ", p), err) + } + return err +} + +func (p *BaseInfo) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EnergyAD", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:EnergyAD: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.EnergyAD)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EnergyAD (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:EnergyAD: ", p), err) + } + return err +} + +func (p *BaseInfo) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Lang", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Lang: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Lang)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Lang (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Lang: ", p), err) + } + return err +} + +func (p *BaseInfo) Equals(other *BaseInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.EnergyMul != other.EnergyMul { + return false + } + if p.IsFirstBuy != other.IsFirstBuy { + return false + } + if p.EnergyBuy != other.EnergyBuy { + return false + } + if p.EnergyAD != other.EnergyAD { + return false + } + if p.Lang != other.Lang { + return false + } + return true +} + +func (p *BaseInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("BaseInfo(%+v)", *p) +} + +func (p *BaseInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.BaseInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*BaseInfo)(nil) + +func (p *BaseInfo) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Count +// +type Card struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Count int32 `thrift:"Count,2" db:"Count" json:"Count"` +} + +func NewCard() *Card { + return &Card{} +} + +func (p *Card) GetId() int32 { + return p.Id +} + +func (p *Card) GetCount() int32 { + return p.Count +} + +func (p *Card) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *Card) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *Card) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Count = v + } + return nil +} + +func (p *Card) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "Card"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *Card) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *Card) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Count", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Count: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Count)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Count (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Count: ", p), err) + } + return err +} + +func (p *Card) Equals(other *Card) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Count != other.Count { + return false + } + return true +} + +func (p *Card) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("Card(%+v)", *p) +} + +func (p *Card) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.Card", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*Card)(nil) + +func (p *Card) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Card +// +type CardPack struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Card []int32 `thrift:"Card,2" db:"Card" json:"Card"` +} + +func NewCardPack() *CardPack { + return &CardPack{} +} + +func (p *CardPack) GetId() int32 { + return p.Id +} + +func (p *CardPack) GetCard() []int32 { + return p.Card +} + +func (p *CardPack) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.LIST { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *CardPack) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *CardPack) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.Card = tSlice + for i := 0; i < size; i++ { + var _elem0 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem0 = v + } + p.Card = append(p.Card, _elem0) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *CardPack) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "CardPack"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *CardPack) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *CardPack) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Card", thrift.LIST, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Card: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.Card)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Card { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Card: ", p), err) + } + return err +} + +func (p *CardPack) Equals(other *CardPack) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if len(p.Card) != len(other.Card) { + return false + } + for i, _tgt := range p.Card { + _src1 := other.Card[i] + if _tgt != _src1 { + return false + } + } + return true +} + +func (p *CardPack) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("CardPack(%+v)", *p) +} + +func (p *CardPack) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.CardPack", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*CardPack)(nil) + +func (p *CardPack) Validate() error { + return nil +} + +// Attributes: +// - Skin +// - Prob +// - RewardList +// - ClearTime +// +type CatReturnGiftCfg struct { + Skin int32 `thrift:"Skin,1" db:"Skin" json:"Skin"` + Prob int32 `thrift:"Prob,2" db:"Prob" json:"Prob"` + RewardList []*CatReturnGiftCfgReward `thrift:"RewardList,3" db:"RewardList" json:"RewardList"` + ClearTime int32 `thrift:"ClearTime,4" db:"ClearTime" json:"ClearTime"` +} + +func NewCatReturnGiftCfg() *CatReturnGiftCfg { + return &CatReturnGiftCfg{} +} + +func (p *CatReturnGiftCfg) GetSkin() int32 { + return p.Skin +} + +func (p *CatReturnGiftCfg) GetProb() int32 { + return p.Prob +} + +func (p *CatReturnGiftCfg) GetRewardList() []*CatReturnGiftCfgReward { + return p.RewardList +} + +func (p *CatReturnGiftCfg) GetClearTime() int32 { + return p.ClearTime +} + +func (p *CatReturnGiftCfg) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.LIST { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *CatReturnGiftCfg) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Skin = v + } + return nil +} + +func (p *CatReturnGiftCfg) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Prob = v + } + return nil +} + +func (p *CatReturnGiftCfg) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*CatReturnGiftCfgReward, 0, size) + p.RewardList = tSlice + for i := 0; i < size; i++ { + _elem2 := &CatReturnGiftCfgReward{} + if err := _elem2.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem2), err) + } + p.RewardList = append(p.RewardList, _elem2) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *CatReturnGiftCfg) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.ClearTime = v + } + return nil +} + +func (p *CatReturnGiftCfg) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "CatReturnGiftCfg"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *CatReturnGiftCfg) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Skin", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Skin: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Skin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Skin (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Skin: ", p), err) + } + return err +} + +func (p *CatReturnGiftCfg) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Prob", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Prob: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Prob)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Prob (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Prob: ", p), err) + } + return err +} + +func (p *CatReturnGiftCfg) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "RewardList", thrift.LIST, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:RewardList: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.RewardList)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.RewardList { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:RewardList: ", p), err) + } + return err +} + +func (p *CatReturnGiftCfg) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ClearTime", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:ClearTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ClearTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ClearTime (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:ClearTime: ", p), err) + } + return err +} + +func (p *CatReturnGiftCfg) Equals(other *CatReturnGiftCfg) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Skin != other.Skin { + return false + } + if p.Prob != other.Prob { + return false + } + if len(p.RewardList) != len(other.RewardList) { + return false + } + for i, _tgt := range p.RewardList { + _src3 := other.RewardList[i] + if !_tgt.Equals(_src3) { + return false + } + } + if p.ClearTime != other.ClearTime { + return false + } + return true +} + +func (p *CatReturnGiftCfg) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("CatReturnGiftCfg(%+v)", *p) +} + +func (p *CatReturnGiftCfg) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.CatReturnGiftCfg", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*CatReturnGiftCfg)(nil) + +func (p *CatReturnGiftCfg) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Score +// - Reward +// - Total +// +type CatReturnGiftCfgReward struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Score int32 `thrift:"Score,2" db:"Score" json:"Score"` + Reward []*ItemInfo `thrift:"Reward,3" db:"Reward" json:"Reward"` + Total int32 `thrift:"Total,4" db:"Total" json:"Total"` +} + +func NewCatReturnGiftCfgReward() *CatReturnGiftCfgReward { + return &CatReturnGiftCfgReward{} +} + +func (p *CatReturnGiftCfgReward) GetId() int32 { + return p.Id +} + +func (p *CatReturnGiftCfgReward) GetScore() int32 { + return p.Score +} + +func (p *CatReturnGiftCfgReward) GetReward() []*ItemInfo { + return p.Reward +} + +func (p *CatReturnGiftCfgReward) GetTotal() int32 { + return p.Total +} + +func (p *CatReturnGiftCfgReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.LIST { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *CatReturnGiftCfgReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *CatReturnGiftCfgReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Score = v + } + return nil +} + +func (p *CatReturnGiftCfgReward) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ItemInfo, 0, size) + p.Reward = tSlice + for i := 0; i < size; i++ { + _elem4 := &ItemInfo{} + if err := _elem4.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem4), err) + } + p.Reward = append(p.Reward, _elem4) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *CatReturnGiftCfgReward) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Total = v + } + return nil +} + +func (p *CatReturnGiftCfgReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "CatReturnGiftCfgReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *CatReturnGiftCfgReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *CatReturnGiftCfgReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Score", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Score: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Score)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Score (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Score: ", p), err) + } + return err +} + +func (p *CatReturnGiftCfgReward) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Reward", thrift.LIST, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Reward: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Reward)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Reward { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Reward: ", p), err) + } + return err +} + +func (p *CatReturnGiftCfgReward) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Total", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Total: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Total)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Total (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Total: ", p), err) + } + return err +} + +func (p *CatReturnGiftCfgReward) Equals(other *CatReturnGiftCfgReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Score != other.Score { + return false + } + if len(p.Reward) != len(other.Reward) { + return false + } + for i, _tgt := range p.Reward { + _src5 := other.Reward[i] + if !_tgt.Equals(_src5) { + return false + } + } + if p.Total != other.Total { + return false + } + return true +} + +func (p *CatReturnGiftCfgReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("CatReturnGiftCfgReward(%+v)", *p) +} + +func (p *CatReturnGiftCfgReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.CatReturnGiftCfgReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*CatReturnGiftCfgReward)(nil) + +func (p *CatReturnGiftCfgReward) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Status +// - Progress +// - Reward +// - Partner +// - Emoji +// - SendEmoji +// - FriendProgress +// +type CatnipGame struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Status int32 `thrift:"Status,2" db:"Status" json:"Status"` + Progress int32 `thrift:"Progress,3" db:"Progress" json:"Progress"` + Reward []int32 `thrift:"Reward,4" db:"Reward" json:"Reward"` + Partner *ResPlayerSimple `thrift:"Partner,5" db:"Partner" json:"Partner"` + Emoji int32 `thrift:"Emoji,6" db:"Emoji" json:"Emoji"` + SendEmoji int32 `thrift:"SendEmoji,7" db:"SendEmoji" json:"SendEmoji"` + FriendProgress int32 `thrift:"FriendProgress,8" db:"FriendProgress" json:"FriendProgress"` +} + +func NewCatnipGame() *CatnipGame { + return &CatnipGame{} +} + +func (p *CatnipGame) GetId() int32 { + return p.Id +} + +func (p *CatnipGame) GetStatus() int32 { + return p.Status +} + +func (p *CatnipGame) GetProgress() int32 { + return p.Progress +} + +func (p *CatnipGame) GetReward() []int32 { + return p.Reward +} + +var CatnipGame_Partner_DEFAULT *ResPlayerSimple + +func (p *CatnipGame) GetPartner() *ResPlayerSimple { + if !p.IsSetPartner() { + return CatnipGame_Partner_DEFAULT + } + return p.Partner +} + +func (p *CatnipGame) GetEmoji() int32 { + return p.Emoji +} + +func (p *CatnipGame) GetSendEmoji() int32 { + return p.SendEmoji +} + +func (p *CatnipGame) GetFriendProgress() int32 { + return p.FriendProgress +} + +func (p *CatnipGame) IsSetPartner() bool { + return p.Partner != nil +} + +func (p *CatnipGame) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.LIST { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.I32 { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.I32 { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 8: + if fieldTypeId == thrift.I32 { + if err := p.ReadField8(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *CatnipGame) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *CatnipGame) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Status = v + } + return nil +} + +func (p *CatnipGame) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Progress = v + } + return nil +} + +func (p *CatnipGame) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.Reward = tSlice + for i := 0; i < size; i++ { + var _elem6 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem6 = v + } + p.Reward = append(p.Reward, _elem6) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *CatnipGame) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + p.Partner = &ResPlayerSimple{} + if err := p.Partner.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.Partner), err) + } + return nil +} + +func (p *CatnipGame) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 6: ", err) + } else { + p.Emoji = v + } + return nil +} + +func (p *CatnipGame) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 7: ", err) + } else { + p.SendEmoji = v + } + return nil +} + +func (p *CatnipGame) ReadField8(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 8: ", err) + } else { + p.FriendProgress = v + } + return nil +} + +func (p *CatnipGame) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "CatnipGame"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + if err := p.writeField8(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *CatnipGame) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *CatnipGame) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Status", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Status: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Status)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Status (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Status: ", p), err) + } + return err +} + +func (p *CatnipGame) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Progress", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Progress: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Progress)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Progress (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Progress: ", p), err) + } + return err +} + +func (p *CatnipGame) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Reward", thrift.LIST, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Reward: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.Reward)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Reward { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Reward: ", p), err) + } + return err +} + +func (p *CatnipGame) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Partner", thrift.STRUCT, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Partner: ", p), err) + } + if err := p.Partner.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.Partner), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Partner: ", p), err) + } + return err +} + +func (p *CatnipGame) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Emoji", thrift.I32, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:Emoji: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Emoji)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Emoji (6) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:Emoji: ", p), err) + } + return err +} + +func (p *CatnipGame) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "SendEmoji", thrift.I32, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:SendEmoji: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.SendEmoji)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.SendEmoji (7) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:SendEmoji: ", p), err) + } + return err +} + +func (p *CatnipGame) writeField8(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "FriendProgress", thrift.I32, 8); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 8:FriendProgress: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.FriendProgress)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.FriendProgress (8) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 8:FriendProgress: ", p), err) + } + return err +} + +func (p *CatnipGame) Equals(other *CatnipGame) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Status != other.Status { + return false + } + if p.Progress != other.Progress { + return false + } + if len(p.Reward) != len(other.Reward) { + return false + } + for i, _tgt := range p.Reward { + _src7 := other.Reward[i] + if _tgt != _src7 { + return false + } + } + if !p.Partner.Equals(other.Partner) { + return false + } + if p.Emoji != other.Emoji { + return false + } + if p.SendEmoji != other.SendEmoji { + return false + } + if p.FriendProgress != other.FriendProgress { + return false + } + return true +} + +func (p *CatnipGame) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("CatnipGame(%+v)", *p) +} + +func (p *CatnipGame) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.CatnipGame", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*CatnipGame)(nil) + +func (p *CatnipGame) Validate() error { + return nil +} + +// Attributes: +// - Uid +// - Time +// - Type +// - Player +// +type CatnipInvite struct { + Uid int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` + Time int64 `thrift:"Time,2" db:"Time" json:"Time"` + Type int32 `thrift:"Type,3" db:"Type" json:"Type"` + Player *ResPlayerSimple `thrift:"Player,4" db:"Player" json:"Player"` +} + +func NewCatnipInvite() *CatnipInvite { + return &CatnipInvite{} +} + +func (p *CatnipInvite) GetUid() int64 { + return p.Uid +} + +func (p *CatnipInvite) GetTime() int64 { + return p.Time +} + +func (p *CatnipInvite) GetType() int32 { + return p.Type +} + +var CatnipInvite_Player_DEFAULT *ResPlayerSimple + +func (p *CatnipInvite) GetPlayer() *ResPlayerSimple { + if !p.IsSetPlayer() { + return CatnipInvite_Player_DEFAULT + } + return p.Player +} + +func (p *CatnipInvite) IsSetPlayer() bool { + return p.Player != nil +} + +func (p *CatnipInvite) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I64 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *CatnipInvite) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *CatnipInvite) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Time = v + } + return nil +} + +func (p *CatnipInvite) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *CatnipInvite) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + p.Player = &ResPlayerSimple{} + if err := p.Player.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.Player), err) + } + return nil +} + +func (p *CatnipInvite) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "CatnipInvite"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *CatnipInvite) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *CatnipInvite) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Time", thrift.I64, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Time: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Time)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Time (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Time: ", p), err) + } + return err +} + +func (p *CatnipInvite) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Type: ", p), err) + } + return err +} + +func (p *CatnipInvite) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Player", thrift.STRUCT, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Player: ", p), err) + } + if err := p.Player.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.Player), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Player: ", p), err) + } + return err +} + +func (p *CatnipInvite) Equals(other *CatnipInvite) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Uid != other.Uid { + return false + } + if p.Time != other.Time { + return false + } + if p.Type != other.Type { + return false + } + if !p.Player.Equals(other.Player) { + return false + } + return true +} + +func (p *CatnipInvite) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("CatnipInvite(%+v)", *p) +} + +func (p *CatnipInvite) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.CatnipInvite", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*CatnipInvite)(nil) + +func (p *CatnipInvite) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Skin +// - JackpotList +// - RankList +// +type ChampionshipCfg struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Skin int32 `thrift:"Skin,2" db:"Skin" json:"Skin"` + JackpotList []*ChampionshipCfgJackpot `thrift:"JackpotList,3" db:"JackpotList" json:"JackpotList"` + RankList []*ChampionshipCfgRank `thrift:"RankList,4" db:"RankList" json:"RankList"` +} + +func NewChampionshipCfg() *ChampionshipCfg { + return &ChampionshipCfg{} +} + +func (p *ChampionshipCfg) GetId() int32 { + return p.Id +} + +func (p *ChampionshipCfg) GetSkin() int32 { + return p.Skin +} + +func (p *ChampionshipCfg) GetJackpotList() []*ChampionshipCfgJackpot { + return p.JackpotList +} + +func (p *ChampionshipCfg) GetRankList() []*ChampionshipCfgRank { + return p.RankList +} + +func (p *ChampionshipCfg) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.LIST { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.LIST { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ChampionshipCfg) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ChampionshipCfg) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Skin = v + } + return nil +} + +func (p *ChampionshipCfg) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ChampionshipCfgJackpot, 0, size) + p.JackpotList = tSlice + for i := 0; i < size; i++ { + _elem8 := &ChampionshipCfgJackpot{} + if err := _elem8.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem8), err) + } + p.JackpotList = append(p.JackpotList, _elem8) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ChampionshipCfg) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ChampionshipCfgRank, 0, size) + p.RankList = tSlice + for i := 0; i < size; i++ { + _elem9 := &ChampionshipCfgRank{} + if err := _elem9.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem9), err) + } + p.RankList = append(p.RankList, _elem9) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ChampionshipCfg) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ChampionshipCfg"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ChampionshipCfg) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ChampionshipCfg) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Skin", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Skin: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Skin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Skin (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Skin: ", p), err) + } + return err +} + +func (p *ChampionshipCfg) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "JackpotList", thrift.LIST, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:JackpotList: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.JackpotList)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.JackpotList { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:JackpotList: ", p), err) + } + return err +} + +func (p *ChampionshipCfg) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "RankList", thrift.LIST, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:RankList: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.RankList)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.RankList { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:RankList: ", p), err) + } + return err +} + +func (p *ChampionshipCfg) Equals(other *ChampionshipCfg) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Skin != other.Skin { + return false + } + if len(p.JackpotList) != len(other.JackpotList) { + return false + } + for i, _tgt := range p.JackpotList { + _src10 := other.JackpotList[i] + if !_tgt.Equals(_src10) { + return false + } + } + if len(p.RankList) != len(other.RankList) { + return false + } + for i, _tgt := range p.RankList { + _src11 := other.RankList[i] + if !_tgt.Equals(_src11) { + return false + } + } + return true +} + +func (p *ChampionshipCfg) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ChampionshipCfg(%+v)", *p) +} + +func (p *ChampionshipCfg) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ChampionshipCfg", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ChampionshipCfg)(nil) + +func (p *ChampionshipCfg) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Score +// - Total +// - Items +// - StarReward +// +type ChampionshipCfgJackpot struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Score int32 `thrift:"Score,2" db:"Score" json:"Score"` + Total int32 `thrift:"Total,3" db:"Total" json:"Total"` + Items []*ItemInfo `thrift:"Items,4" db:"Items" json:"Items"` + StarReward int32 `thrift:"StarReward,5" db:"StarReward" json:"StarReward"` +} + +func NewChampionshipCfgJackpot() *ChampionshipCfgJackpot { + return &ChampionshipCfgJackpot{} +} + +func (p *ChampionshipCfgJackpot) GetId() int32 { + return p.Id +} + +func (p *ChampionshipCfgJackpot) GetScore() int32 { + return p.Score +} + +func (p *ChampionshipCfgJackpot) GetTotal() int32 { + return p.Total +} + +func (p *ChampionshipCfgJackpot) GetItems() []*ItemInfo { + return p.Items +} + +func (p *ChampionshipCfgJackpot) GetStarReward() int32 { + return p.StarReward +} + +func (p *ChampionshipCfgJackpot) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.LIST { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ChampionshipCfgJackpot) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ChampionshipCfgJackpot) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Score = v + } + return nil +} + +func (p *ChampionshipCfgJackpot) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Total = v + } + return nil +} + +func (p *ChampionshipCfgJackpot) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ItemInfo, 0, size) + p.Items = tSlice + for i := 0; i < size; i++ { + _elem12 := &ItemInfo{} + if err := _elem12.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem12), err) + } + p.Items = append(p.Items, _elem12) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ChampionshipCfgJackpot) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.StarReward = v + } + return nil +} + +func (p *ChampionshipCfgJackpot) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ChampionshipCfgJackpot"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ChampionshipCfgJackpot) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ChampionshipCfgJackpot) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Score", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Score: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Score)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Score (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Score: ", p), err) + } + return err +} + +func (p *ChampionshipCfgJackpot) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Total", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Total: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Total)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Total (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Total: ", p), err) + } + return err +} + +func (p *ChampionshipCfgJackpot) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Items", thrift.LIST, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Items: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Items)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Items { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Items: ", p), err) + } + return err +} + +func (p *ChampionshipCfgJackpot) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "StarReward", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:StarReward: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.StarReward)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.StarReward (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:StarReward: ", p), err) + } + return err +} + +func (p *ChampionshipCfgJackpot) Equals(other *ChampionshipCfgJackpot) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Score != other.Score { + return false + } + if p.Total != other.Total { + return false + } + if len(p.Items) != len(other.Items) { + return false + } + for i, _tgt := range p.Items { + _src13 := other.Items[i] + if !_tgt.Equals(_src13) { + return false + } + } + if p.StarReward != other.StarReward { + return false + } + return true +} + +func (p *ChampionshipCfgJackpot) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ChampionshipCfgJackpot(%+v)", *p) +} + +func (p *ChampionshipCfgJackpot) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ChampionshipCfgJackpot", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ChampionshipCfgJackpot)(nil) + +func (p *ChampionshipCfgJackpot) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Min +// - Max +// - Items +// +type ChampionshipCfgRank struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Min int32 `thrift:"Min,2" db:"Min" json:"Min"` + Max int32 `thrift:"Max,3" db:"Max" json:"Max"` + Items []*ItemInfo `thrift:"Items,4" db:"Items" json:"Items"` +} + +func NewChampionshipCfgRank() *ChampionshipCfgRank { + return &ChampionshipCfgRank{} +} + +func (p *ChampionshipCfgRank) GetId() int32 { + return p.Id +} + +func (p *ChampionshipCfgRank) GetMin() int32 { + return p.Min +} + +func (p *ChampionshipCfgRank) GetMax() int32 { + return p.Max +} + +func (p *ChampionshipCfgRank) GetItems() []*ItemInfo { + return p.Items +} + +func (p *ChampionshipCfgRank) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.LIST { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ChampionshipCfgRank) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ChampionshipCfgRank) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Min = v + } + return nil +} + +func (p *ChampionshipCfgRank) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Max = v + } + return nil +} + +func (p *ChampionshipCfgRank) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ItemInfo, 0, size) + p.Items = tSlice + for i := 0; i < size; i++ { + _elem14 := &ItemInfo{} + if err := _elem14.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem14), err) + } + p.Items = append(p.Items, _elem14) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ChampionshipCfgRank) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ChampionshipCfgRank"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ChampionshipCfgRank) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ChampionshipCfgRank) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Min", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Min: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Min)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Min (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Min: ", p), err) + } + return err +} + +func (p *ChampionshipCfgRank) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Max", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Max: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Max)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Max (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Max: ", p), err) + } + return err +} + +func (p *ChampionshipCfgRank) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Items", thrift.LIST, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Items: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Items)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Items { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Items: ", p), err) + } + return err +} + +func (p *ChampionshipCfgRank) Equals(other *ChampionshipCfgRank) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Min != other.Min { + return false + } + if p.Max != other.Max { + return false + } + if len(p.Items) != len(other.Items) { + return false + } + for i, _tgt := range p.Items { + _src15 := other.Items[i] + if !_tgt.Equals(_src15) { + return false + } + } + return true +} + +func (p *ChampionshipCfgRank) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ChampionshipCfgRank(%+v)", *p) +} + +func (p *ChampionshipCfgRank) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ChampionshipCfgRank", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ChampionshipCfgRank)(nil) + +func (p *ChampionshipCfgRank) Validate() error { + return nil +} + +// Attributes: +// - ChessBagGrids +// - ChessBuyCnt +// - ChessFreeCnt +// +type ChessBag struct { + ChessBagGrids []*ChessBagGrid `thrift:"ChessBagGrids,1" db:"ChessBagGrids" json:"ChessBagGrids"` + ChessBuyCnt int32 `thrift:"ChessBuyCnt,2" db:"ChessBuyCnt" json:"ChessBuyCnt"` + ChessFreeCnt int32 `thrift:"ChessFreeCnt,3" db:"ChessFreeCnt" json:"ChessFreeCnt"` +} + +func NewChessBag() *ChessBag { + return &ChessBag{} +} + +func (p *ChessBag) GetChessBagGrids() []*ChessBagGrid { + return p.ChessBagGrids +} + +func (p *ChessBag) GetChessBuyCnt() int32 { + return p.ChessBuyCnt +} + +func (p *ChessBag) GetChessFreeCnt() int32 { + return p.ChessFreeCnt +} + +func (p *ChessBag) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ChessBag) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ChessBagGrid, 0, size) + p.ChessBagGrids = tSlice + for i := 0; i < size; i++ { + _elem16 := &ChessBagGrid{} + if err := _elem16.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem16), err) + } + p.ChessBagGrids = append(p.ChessBagGrids, _elem16) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ChessBag) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.ChessBuyCnt = v + } + return nil +} + +func (p *ChessBag) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.ChessFreeCnt = v + } + return nil +} + +func (p *ChessBag) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ChessBag"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ChessBag) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChessBagGrids", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ChessBagGrids: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.ChessBagGrids)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.ChessBagGrids { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ChessBagGrids: ", p), err) + } + return err +} + +func (p *ChessBag) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChessBuyCnt", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:ChessBuyCnt: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ChessBuyCnt)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ChessBuyCnt (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:ChessBuyCnt: ", p), err) + } + return err +} + +func (p *ChessBag) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChessFreeCnt", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:ChessFreeCnt: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ChessFreeCnt)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ChessFreeCnt (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:ChessFreeCnt: ", p), err) + } + return err +} + +func (p *ChessBag) Equals(other *ChessBag) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.ChessBagGrids) != len(other.ChessBagGrids) { + return false + } + for i, _tgt := range p.ChessBagGrids { + _src17 := other.ChessBagGrids[i] + if !_tgt.Equals(_src17) { + return false + } + } + if p.ChessBuyCnt != other.ChessBuyCnt { + return false + } + if p.ChessFreeCnt != other.ChessFreeCnt { + return false + } + return true +} + +func (p *ChessBag) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ChessBag(%+v)", *p) +} + +func (p *ChessBag) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ChessBag", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ChessBag)(nil) + +func (p *ChessBag) Validate() error { + return nil +} + +// Attributes: +// - Id +// - ChessId +// - EmitId +// +type ChessBagGrid struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + ChessId int32 `thrift:"ChessId,2" db:"ChessId" json:"ChessId"` + EmitId int32 `thrift:"EmitId,3" db:"EmitId" json:"EmitId"` +} + +func NewChessBagGrid() *ChessBagGrid { + return &ChessBagGrid{} +} + +func (p *ChessBagGrid) GetId() int32 { + return p.Id +} + +func (p *ChessBagGrid) GetChessId() int32 { + return p.ChessId +} + +func (p *ChessBagGrid) GetEmitId() int32 { + return p.EmitId +} + +func (p *ChessBagGrid) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ChessBagGrid) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ChessBagGrid) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.ChessId = v + } + return nil +} + +func (p *ChessBagGrid) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.EmitId = v + } + return nil +} + +func (p *ChessBagGrid) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ChessBagGrid"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ChessBagGrid) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ChessBagGrid) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChessId", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:ChessId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ChessId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ChessId (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:ChessId: ", p), err) + } + return err +} + +func (p *ChessBagGrid) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EmitId", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:EmitId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.EmitId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EmitId (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:EmitId: ", p), err) + } + return err +} + +func (p *ChessBagGrid) Equals(other *ChessBagGrid) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.ChessId != other.ChessId { + return false + } + if p.EmitId != other.EmitId { + return false + } + return true +} + +func (p *ChessBagGrid) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ChessBagGrid(%+v)", *p) +} + +func (p *ChessBagGrid) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ChessBagGrid", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ChessBagGrid)(nil) + +func (p *ChessBagGrid) Validate() error { + return nil +} + +// Attributes: +// - Type +// - Emit +// - ChessId +// - Id +// - ActType +// +type ChessHandle struct { + Type HANDLE_TYPE `thrift:"type,1" db:"type" json:"type"` + Emit int32 `thrift:"Emit,2" db:"Emit" json:"Emit"` + ChessId int32 `thrift:"ChessId,3" db:"ChessId" json:"ChessId"` + Id int32 `thrift:"Id,4" db:"Id" json:"Id"` + ActType []int32 `thrift:"ActType,5" db:"ActType" json:"ActType"` +} + +func NewChessHandle() *ChessHandle { + return &ChessHandle{} +} + +func (p *ChessHandle) GetType() HANDLE_TYPE { + return p.Type +} + +func (p *ChessHandle) GetEmit() int32 { + return p.Emit +} + +func (p *ChessHandle) GetChessId() int32 { + return p.ChessId +} + +func (p *ChessHandle) GetId() int32 { + return p.Id +} + +func (p *ChessHandle) GetActType() []int32 { + return p.ActType +} + +func (p *ChessHandle) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.LIST { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ChessHandle) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := HANDLE_TYPE(v) + p.Type = temp + } + return nil +} + +func (p *ChessHandle) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Emit = v + } + return nil +} + +func (p *ChessHandle) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.ChessId = v + } + return nil +} + +func (p *ChessHandle) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ChessHandle) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.ActType = tSlice + for i := 0; i < size; i++ { + var _elem18 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem18 = v + } + p.ActType = append(p.ActType, _elem18) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ChessHandle) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ChessHandle"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ChessHandle) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "type", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.type (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:type: ", p), err) + } + return err +} + +func (p *ChessHandle) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Emit", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Emit: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Emit)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Emit (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Emit: ", p), err) + } + return err +} + +func (p *ChessHandle) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChessId", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:ChessId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ChessId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ChessId (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:ChessId: ", p), err) + } + return err +} + +func (p *ChessHandle) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Id: ", p), err) + } + return err +} + +func (p *ChessHandle) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ActType", thrift.LIST, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:ActType: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.ActType)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.ActType { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:ActType: ", p), err) + } + return err +} + +func (p *ChessHandle) Equals(other *ChessHandle) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Type != other.Type { + return false + } + if p.Emit != other.Emit { + return false + } + if p.ChessId != other.ChessId { + return false + } + if p.Id != other.Id { + return false + } + if len(p.ActType) != len(other.ActType) { + return false + } + for i, _tgt := range p.ActType { + _src19 := other.ActType[i] + if _tgt != _src19 { + return false + } + } + return true +} + +func (p *ChessHandle) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ChessHandle(%+v)", *p) +} + +func (p *ChessHandle) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ChessHandle", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ChessHandle)(nil) + +func (p *ChessHandle) Validate() error { + return nil +} + +// Attributes: +// - Uid +// - EmojiId +// +type ChipInfo struct { + Uid int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` + EmojiId int32 `thrift:"EmojiId,2" db:"EmojiId" json:"EmojiId"` +} + +func NewChipInfo() *ChipInfo { + return &ChipInfo{} +} + +func (p *ChipInfo) GetUid() int64 { + return p.Uid +} + +func (p *ChipInfo) GetEmojiId() int32 { + return p.EmojiId +} + +func (p *ChipInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ChipInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ChipInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.EmojiId = v + } + return nil +} + +func (p *ChipInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ChipInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ChipInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *ChipInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EmojiId", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:EmojiId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.EmojiId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EmojiId (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:EmojiId: ", p), err) + } + return err +} + +func (p *ChipInfo) Equals(other *ChipInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Uid != other.Uid { + return false + } + if p.EmojiId != other.EmojiId { + return false + } + return true +} + +func (p *ChipInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ChipInfo(%+v)", *p) +} + +func (p *ChipInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ChipInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ChipInfo)(nil) + +func (p *ChipInfo) Validate() error { + return nil +} + +// Attributes: +// - Func +// - Cid +// - Info +// - SessionId +// - GatewayId +// - UserId +// - UserBase +// +type ClientReq struct { + Func string `thrift:"func,1" db:"func" json:"func"` + Cid string `thrift:"cid,2" db:"cid" json:"cid"` + Info []byte `thrift:"info,3" db:"info" json:"info"` + SessionId string `thrift:"sessionId,4" db:"sessionId" json:"sessionId"` + GatewayId string `thrift:"gatewayId,5" db:"gatewayId" json:"gatewayId"` + UserId string `thrift:"userId,6" db:"userId" json:"userId"` + UserBase string `thrift:"userBase,7" db:"userBase" json:"userBase"` +} + +func NewClientReq() *ClientReq { + return &ClientReq{} +} + +func (p *ClientReq) GetFunc() string { + return p.Func +} + +func (p *ClientReq) GetCid() string { + return p.Cid +} + +func (p *ClientReq) GetInfo() []byte { + return p.Info +} + +func (p *ClientReq) GetSessionId() string { + return p.SessionId +} + +func (p *ClientReq) GetGatewayId() string { + return p.GatewayId +} + +func (p *ClientReq) GetUserId() string { + return p.UserId +} + +func (p *ClientReq) GetUserBase() string { + return p.UserBase +} + +func (p *ClientReq) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.STRING { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.STRING { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.STRING { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.STRING { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.STRING { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ClientReq) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Func = v + } + return nil +} + +func (p *ClientReq) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Cid = v + } + return nil +} + +func (p *ClientReq) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadBinary(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Info = v + } + return nil +} + +func (p *ClientReq) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.SessionId = v + } + return nil +} + +func (p *ClientReq) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.GatewayId = v + } + return nil +} + +func (p *ClientReq) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 6: ", err) + } else { + p.UserId = v + } + return nil +} + +func (p *ClientReq) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 7: ", err) + } else { + p.UserBase = v + } + return nil +} + +func (p *ClientReq) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ClientReq"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ClientReq) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "func", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:func: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Func)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.func (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:func: ", p), err) + } + return err +} + +func (p *ClientReq) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "cid", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:cid: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Cid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.cid (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:cid: ", p), err) + } + return err +} + +func (p *ClientReq) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "info", thrift.STRING, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:info: ", p), err) + } + if err := oprot.WriteBinary(ctx, p.Info); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.info (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:info: ", p), err) + } + return err +} + +func (p *ClientReq) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "sessionId", thrift.STRING, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:sessionId: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.SessionId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.sessionId (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:sessionId: ", p), err) + } + return err +} + +func (p *ClientReq) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "gatewayId", thrift.STRING, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:gatewayId: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.GatewayId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.gatewayId (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:gatewayId: ", p), err) + } + return err +} + +func (p *ClientReq) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "userId", thrift.STRING, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:userId: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.UserId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.userId (6) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:userId: ", p), err) + } + return err +} + +func (p *ClientReq) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "userBase", thrift.STRING, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:userBase: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.UserBase)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.userBase (7) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:userBase: ", p), err) + } + return err +} + +func (p *ClientReq) Equals(other *ClientReq) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Func != other.Func { + return false + } + if p.Cid != other.Cid { + return false + } + if bytes.Compare(p.Info, other.Info) != 0 { + return false + } + if p.SessionId != other.SessionId { + return false + } + if p.GatewayId != other.GatewayId { + return false + } + if p.UserId != other.UserId { + return false + } + if p.UserBase != other.UserBase { + return false + } + return true +} + +func (p *ClientReq) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ClientReq(%+v)", *p) +} + +func (p *ClientReq) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ClientReq", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ClientReq)(nil) + +func (p *ClientReq) Validate() error { + return nil +} + +// Attributes: +// - Func +// - Cid +// - Info +// +type ClientRes struct { + Func string `thrift:"func,1" db:"func" json:"func"` + Cid string `thrift:"cid,2" db:"cid" json:"cid"` + Info []byte `thrift:"info,3" db:"info" json:"info"` +} + +func NewClientRes() *ClientRes { + return &ClientRes{} +} + +func (p *ClientRes) GetFunc() string { + return p.Func +} + +func (p *ClientRes) GetCid() string { + return p.Cid +} + +func (p *ClientRes) GetInfo() []byte { + return p.Info +} + +func (p *ClientRes) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.STRING { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ClientRes) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Func = v + } + return nil +} + +func (p *ClientRes) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Cid = v + } + return nil +} + +func (p *ClientRes) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadBinary(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Info = v + } + return nil +} + +func (p *ClientRes) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ClientRes"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ClientRes) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "func", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:func: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Func)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.func (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:func: ", p), err) + } + return err +} + +func (p *ClientRes) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "cid", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:cid: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Cid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.cid (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:cid: ", p), err) + } + return err +} + +func (p *ClientRes) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "info", thrift.STRING, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:info: ", p), err) + } + if err := oprot.WriteBinary(ctx, p.Info); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.info (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:info: ", p), err) + } + return err +} + +func (p *ClientRes) Equals(other *ClientRes) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Func != other.Func { + return false + } + if p.Cid != other.Cid { + return false + } + if bytes.Compare(p.Info, other.Info) != 0 { + return false + } + return true +} + +func (p *ClientRes) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ClientRes(%+v)", *p) +} + +func (p *ClientRes) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ClientRes", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ClientRes)(nil) + +func (p *ClientRes) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Items +// +type CollectItem struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Items []*ItemInfo `thrift:"Items,2" db:"Items" json:"Items"` +} + +func NewCollectItem() *CollectItem { + return &CollectItem{} +} + +func (p *CollectItem) GetId() int32 { + return p.Id +} + +func (p *CollectItem) GetItems() []*ItemInfo { + return p.Items +} + +func (p *CollectItem) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.LIST { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *CollectItem) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *CollectItem) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ItemInfo, 0, size) + p.Items = tSlice + for i := 0; i < size; i++ { + _elem20 := &ItemInfo{} + if err := _elem20.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem20), err) + } + p.Items = append(p.Items, _elem20) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *CollectItem) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "CollectItem"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *CollectItem) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *CollectItem) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Items", thrift.LIST, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Items: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Items)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Items { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Items: ", p), err) + } + return err +} + +func (p *CollectItem) Equals(other *CollectItem) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if len(p.Items) != len(other.Items) { + return false + } + for i, _tgt := range p.Items { + _src21 := other.Items[i] + if !_tgt.Equals(_src21) { + return false + } + } + return true +} + +func (p *CollectItem) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("CollectItem(%+v)", *p) +} + +func (p *CollectItem) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.CollectItem", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*CollectItem)(nil) + +func (p *CollectItem) Validate() error { + return nil +} + +// Attributes: +// - Status +// - UnLock +// - Progress +// - Items +// - Id +// - Index +// +type DailyTask struct { + Status int32 `thrift:"Status,1" db:"Status" json:"Status"` + UnLock bool `thrift:"UnLock,2" db:"UnLock" json:"UnLock"` + Progress *QuestProgress `thrift:"Progress,3" db:"Progress" json:"Progress"` + Items []*ItemInfo `thrift:"Items,4" db:"Items" json:"Items"` + Id int32 `thrift:"Id,5" db:"Id" json:"Id"` + Index int32 `thrift:"Index,6" db:"Index" json:"Index"` +} + +func NewDailyTask() *DailyTask { + return &DailyTask{} +} + +func (p *DailyTask) GetStatus() int32 { + return p.Status +} + +func (p *DailyTask) GetUnLock() bool { + return p.UnLock +} + +var DailyTask_Progress_DEFAULT *QuestProgress + +func (p *DailyTask) GetProgress() *QuestProgress { + if !p.IsSetProgress() { + return DailyTask_Progress_DEFAULT + } + return p.Progress +} + +func (p *DailyTask) GetItems() []*ItemInfo { + return p.Items +} + +func (p *DailyTask) GetId() int32 { + return p.Id +} + +func (p *DailyTask) GetIndex() int32 { + return p.Index +} + +func (p *DailyTask) IsSetProgress() bool { + return p.Progress != nil +} + +func (p *DailyTask) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.BOOL { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.LIST { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.I32 { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *DailyTask) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Status = v + } + return nil +} + +func (p *DailyTask) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadBool(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.UnLock = v + } + return nil +} + +func (p *DailyTask) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + p.Progress = &QuestProgress{} + if err := p.Progress.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.Progress), err) + } + return nil +} + +func (p *DailyTask) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ItemInfo, 0, size) + p.Items = tSlice + for i := 0; i < size; i++ { + _elem22 := &ItemInfo{} + if err := _elem22.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem22), err) + } + p.Items = append(p.Items, _elem22) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *DailyTask) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *DailyTask) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 6: ", err) + } else { + p.Index = v + } + return nil +} + +func (p *DailyTask) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "DailyTask"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *DailyTask) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Status", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Status: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Status)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Status (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Status: ", p), err) + } + return err +} + +func (p *DailyTask) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "UnLock", thrift.BOOL, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:UnLock: ", p), err) + } + if err := oprot.WriteBool(ctx, bool(p.UnLock)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.UnLock (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:UnLock: ", p), err) + } + return err +} + +func (p *DailyTask) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Progress", thrift.STRUCT, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Progress: ", p), err) + } + if err := p.Progress.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.Progress), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Progress: ", p), err) + } + return err +} + +func (p *DailyTask) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Items", thrift.LIST, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Items: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Items)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Items { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Items: ", p), err) + } + return err +} + +func (p *DailyTask) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Id: ", p), err) + } + return err +} + +func (p *DailyTask) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Index", thrift.I32, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:Index: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Index)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Index (6) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:Index: ", p), err) + } + return err +} + +func (p *DailyTask) Equals(other *DailyTask) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Status != other.Status { + return false + } + if p.UnLock != other.UnLock { + return false + } + if !p.Progress.Equals(other.Progress) { + return false + } + if len(p.Items) != len(other.Items) { + return false + } + for i, _tgt := range p.Items { + _src23 := other.Items[i] + if !_tgt.Equals(_src23) { + return false + } + } + if p.Id != other.Id { + return false + } + if p.Index != other.Index { + return false + } + return true +} + +func (p *DailyTask) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("DailyTask(%+v)", *p) +} + +func (p *DailyTask) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.DailyTask", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*DailyTask)(nil) + +func (p *DailyTask) Validate() error { + return nil +} + +// Attributes: +// - Items +// - Status +// - NeedActive +// +type DailyWeek struct { + Items []*ItemInfo `thrift:"Items,1" db:"Items" json:"Items"` + Status bool `thrift:"Status,2" db:"Status" json:"Status"` + NeedActive int32 `thrift:"NeedActive,3" db:"NeedActive" json:"NeedActive"` +} + +func NewDailyWeek() *DailyWeek { + return &DailyWeek{} +} + +func (p *DailyWeek) GetItems() []*ItemInfo { + return p.Items +} + +func (p *DailyWeek) GetStatus() bool { + return p.Status +} + +func (p *DailyWeek) GetNeedActive() int32 { + return p.NeedActive +} + +func (p *DailyWeek) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.BOOL { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *DailyWeek) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ItemInfo, 0, size) + p.Items = tSlice + for i := 0; i < size; i++ { + _elem24 := &ItemInfo{} + if err := _elem24.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem24), err) + } + p.Items = append(p.Items, _elem24) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *DailyWeek) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadBool(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Status = v + } + return nil +} + +func (p *DailyWeek) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.NeedActive = v + } + return nil +} + +func (p *DailyWeek) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "DailyWeek"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *DailyWeek) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Items", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Items: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Items)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Items { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Items: ", p), err) + } + return err +} + +func (p *DailyWeek) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Status", thrift.BOOL, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Status: ", p), err) + } + if err := oprot.WriteBool(ctx, bool(p.Status)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Status (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Status: ", p), err) + } + return err +} + +func (p *DailyWeek) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "NeedActive", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:NeedActive: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.NeedActive)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.NeedActive (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:NeedActive: ", p), err) + } + return err +} + +func (p *DailyWeek) Equals(other *DailyWeek) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.Items) != len(other.Items) { + return false + } + for i, _tgt := range p.Items { + _src25 := other.Items[i] + if !_tgt.Equals(_src25) { + return false + } + } + if p.Status != other.Status { + return false + } + if p.NeedActive != other.NeedActive { + return false + } + return true +} + +func (p *DailyWeek) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("DailyWeek(%+v)", *p) +} + +func (p *DailyWeek) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.DailyWeek", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*DailyWeek)(nil) + +func (p *DailyWeek) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Items +// +type DecoratePart struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Items []*ItemInfo `thrift:"Items,2" db:"Items" json:"Items"` +} + +func NewDecoratePart() *DecoratePart { + return &DecoratePart{} +} + +func (p *DecoratePart) GetId() int32 { + return p.Id +} + +func (p *DecoratePart) GetItems() []*ItemInfo { + return p.Items +} + +func (p *DecoratePart) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.LIST { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *DecoratePart) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *DecoratePart) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ItemInfo, 0, size) + p.Items = tSlice + for i := 0; i < size; i++ { + _elem26 := &ItemInfo{} + if err := _elem26.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem26), err) + } + p.Items = append(p.Items, _elem26) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *DecoratePart) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "DecoratePart"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *DecoratePart) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *DecoratePart) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Items", thrift.LIST, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Items: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Items)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Items { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Items: ", p), err) + } + return err +} + +func (p *DecoratePart) Equals(other *DecoratePart) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if len(p.Items) != len(other.Items) { + return false + } + for i, _tgt := range p.Items { + _src27 := other.Items[i] + if !_tgt.Equals(_src27) { + return false + } + } + return true +} + +func (p *DecoratePart) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("DecoratePart(%+v)", *p) +} + +func (p *DecoratePart) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.DecoratePart", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*DecoratePart)(nil) + +func (p *DecoratePart) Validate() error { + return nil +} + +// Attributes: +// - Id +// - EndTime +// - AddTime +// +type EmojiInfo struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + EndTime int64 `thrift:"EndTime,2" db:"EndTime" json:"EndTime"` + AddTime int64 `thrift:"AddTime,3" db:"AddTime" json:"AddTime"` +} + +func NewEmojiInfo() *EmojiInfo { + return &EmojiInfo{} +} + +func (p *EmojiInfo) GetId() int32 { + return p.Id +} + +func (p *EmojiInfo) GetEndTime() int64 { + return p.EndTime +} + +func (p *EmojiInfo) GetAddTime() int64 { + return p.AddTime +} + +func (p *EmojiInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I64 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I64 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *EmojiInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *EmojiInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.EndTime = v + } + return nil +} + +func (p *EmojiInfo) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.AddTime = v + } + return nil +} + +func (p *EmojiInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "EmojiInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *EmojiInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *EmojiInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EndTime", thrift.I64, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:EndTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.EndTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EndTime (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:EndTime: ", p), err) + } + return err +} + +func (p *EmojiInfo) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "AddTime", thrift.I64, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:AddTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.AddTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.AddTime (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:AddTime: ", p), err) + } + return err +} + +func (p *EmojiInfo) Equals(other *EmojiInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.EndTime != other.EndTime { + return false + } + if p.AddTime != other.AddTime { + return false + } + return true +} + +func (p *EmojiInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("EmojiInfo(%+v)", *p) +} + +func (p *EmojiInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.EmojiInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*EmojiInfo)(nil) + +func (p *EmojiInfo) Validate() error { + return nil +} + +// Attributes: +// - Id +// - EndTime +// - AddTime +// +type FaceInfo struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + EndTime int64 `thrift:"EndTime,2" db:"EndTime" json:"EndTime"` + AddTime int64 `thrift:"AddTime,3" db:"AddTime" json:"AddTime"` +} + +func NewFaceInfo() *FaceInfo { + return &FaceInfo{} +} + +func (p *FaceInfo) GetId() int32 { + return p.Id +} + +func (p *FaceInfo) GetEndTime() int64 { + return p.EndTime +} + +func (p *FaceInfo) GetAddTime() int64 { + return p.AddTime +} + +func (p *FaceInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I64 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I64 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *FaceInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *FaceInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.EndTime = v + } + return nil +} + +func (p *FaceInfo) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.AddTime = v + } + return nil +} + +func (p *FaceInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "FaceInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *FaceInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *FaceInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EndTime", thrift.I64, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:EndTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.EndTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EndTime (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:EndTime: ", p), err) + } + return err +} + +func (p *FaceInfo) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "AddTime", thrift.I64, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:AddTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.AddTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.AddTime (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:AddTime: ", p), err) + } + return err +} + +func (p *FaceInfo) Equals(other *FaceInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.EndTime != other.EndTime { + return false + } + if p.AddTime != other.AddTime { + return false + } + return true +} + +func (p *FaceInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("FaceInfo(%+v)", *p) +} + +func (p *FaceInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.FaceInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*FaceInfo)(nil) + +func (p *FaceInfo) Validate() error { + return nil +} + +type ForceKickOut struct { +} + +func NewForceKickOut() *ForceKickOut { + return &ForceKickOut{} +} + +func (p *ForceKickOut) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ForceKickOut) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ForceKickOut"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ForceKickOut) Equals(other *ForceKickOut) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ForceKickOut) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ForceKickOut(%+v)", *p) +} + +func (p *ForceKickOut) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ForceKickOut", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ForceKickOut)(nil) + +func (p *ForceKickOut) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Type +// - Items +// +type FriendBubbleInfo struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Type int32 `thrift:"Type,2" db:"Type" json:"Type"` + Items []*ItemInfo `thrift:"Items,3" db:"Items" json:"Items"` +} + +func NewFriendBubbleInfo() *FriendBubbleInfo { + return &FriendBubbleInfo{} +} + +func (p *FriendBubbleInfo) GetId() int32 { + return p.Id +} + +func (p *FriendBubbleInfo) GetType() int32 { + return p.Type +} + +func (p *FriendBubbleInfo) GetItems() []*ItemInfo { + return p.Items +} + +func (p *FriendBubbleInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.LIST { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *FriendBubbleInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *FriendBubbleInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *FriendBubbleInfo) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ItemInfo, 0, size) + p.Items = tSlice + for i := 0; i < size; i++ { + _elem28 := &ItemInfo{} + if err := _elem28.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem28), err) + } + p.Items = append(p.Items, _elem28) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *FriendBubbleInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "FriendBubbleInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *FriendBubbleInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *FriendBubbleInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Type: ", p), err) + } + return err +} + +func (p *FriendBubbleInfo) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Items", thrift.LIST, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Items: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Items)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Items { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Items: ", p), err) + } + return err +} + +func (p *FriendBubbleInfo) Equals(other *FriendBubbleInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Type != other.Type { + return false + } + if len(p.Items) != len(other.Items) { + return false + } + for i, _tgt := range p.Items { + _src29 := other.Items[i] + if !_tgt.Equals(_src29) { + return false + } + } + return true +} + +func (p *FriendBubbleInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("FriendBubbleInfo(%+v)", *p) +} + +func (p *FriendBubbleInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.FriendBubbleInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*FriendBubbleInfo)(nil) + +func (p *FriendBubbleInfo) Validate() error { + return nil +} + +// Attributes: +// - Uid +// - Name +// - Face +// - Avatar +// - Times +// +type FriendRoom struct { + Uid int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` + Name string `thrift:"Name,2" db:"Name" json:"Name"` + Face int32 `thrift:"Face,3" db:"Face" json:"Face"` + Avatar int32 `thrift:"Avatar,4" db:"Avatar" json:"Avatar"` + Times int32 `thrift:"Times,5" db:"Times" json:"Times"` +} + +func NewFriendRoom() *FriendRoom { + return &FriendRoom{} +} + +func (p *FriendRoom) GetUid() int64 { + return p.Uid +} + +func (p *FriendRoom) GetName() string { + return p.Name +} + +func (p *FriendRoom) GetFace() int32 { + return p.Face +} + +func (p *FriendRoom) GetAvatar() int32 { + return p.Avatar +} + +func (p *FriendRoom) GetTimes() int32 { + return p.Times +} + +func (p *FriendRoom) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *FriendRoom) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *FriendRoom) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Name = v + } + return nil +} + +func (p *FriendRoom) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Face = v + } + return nil +} + +func (p *FriendRoom) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Avatar = v + } + return nil +} + +func (p *FriendRoom) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.Times = v + } + return nil +} + +func (p *FriendRoom) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "FriendRoom"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *FriendRoom) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *FriendRoom) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Name", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Name: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Name)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Name (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Name: ", p), err) + } + return err +} + +func (p *FriendRoom) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Face", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Face: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Face)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Face (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Face: ", p), err) + } + return err +} + +func (p *FriendRoom) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Avatar", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Avatar: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Avatar)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Avatar (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Avatar: ", p), err) + } + return err +} + +func (p *FriendRoom) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Times", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Times: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Times)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Times (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Times: ", p), err) + } + return err +} + +func (p *FriendRoom) Equals(other *FriendRoom) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Uid != other.Uid { + return false + } + if p.Name != other.Name { + return false + } + if p.Face != other.Face { + return false + } + if p.Avatar != other.Avatar { + return false + } + if p.Times != other.Times { + return false + } + return true +} + +func (p *FriendRoom) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("FriendRoom(%+v)", *p) +} + +func (p *FriendRoom) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.FriendRoom", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*FriendRoom)(nil) + +func (p *FriendRoom) Validate() error { + return nil +} + +// Attributes: +// - Map +// +type GuessColorInfo struct { + Map map[int32]int32 `thrift:"Map,1" db:"Map" json:"Map"` +} + +func NewGuessColorInfo() *GuessColorInfo { + return &GuessColorInfo{} +} + +func (p *GuessColorInfo) GetMap() map[int32]int32 { + return p.Map +} + +func (p *GuessColorInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.MAP { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *GuessColorInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.Map = tMap + for i := 0; i < size; i++ { + var _key30 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key30 = v + } + var _val31 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val31 = v + } + p.Map[_key30] = _val31 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *GuessColorInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "GuessColorInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *GuessColorInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Map", thrift.MAP, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Map: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.Map)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Map { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Map: ", p), err) + } + return err +} + +func (p *GuessColorInfo) Equals(other *GuessColorInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.Map) != len(other.Map) { + return false + } + for k, _tgt := range p.Map { + _src32 := other.Map[k] + if _tgt != _src32 { + return false + } + } + return true +} + +func (p *GuessColorInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("GuessColorInfo(%+v)", *p) +} + +func (p *GuessColorInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.GuessColorInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*GuessColorInfo)(nil) + +func (p *GuessColorInfo) Validate() error { + return nil +} + +// Attributes: +// - Status +// - Progress +// - Id +// +type GuideTask struct { + Status int32 `thrift:"Status,1" db:"Status" json:"Status"` + Progress *QuestProgress `thrift:"Progress,2" db:"Progress" json:"Progress"` + Id int32 `thrift:"Id,3" db:"Id" json:"Id"` +} + +func NewGuideTask() *GuideTask { + return &GuideTask{} +} + +func (p *GuideTask) GetStatus() int32 { + return p.Status +} + +var GuideTask_Progress_DEFAULT *QuestProgress + +func (p *GuideTask) GetProgress() *QuestProgress { + if !p.IsSetProgress() { + return GuideTask_Progress_DEFAULT + } + return p.Progress +} + +func (p *GuideTask) GetId() int32 { + return p.Id +} + +func (p *GuideTask) IsSetProgress() bool { + return p.Progress != nil +} + +func (p *GuideTask) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *GuideTask) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Status = v + } + return nil +} + +func (p *GuideTask) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + p.Progress = &QuestProgress{} + if err := p.Progress.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.Progress), err) + } + return nil +} + +func (p *GuideTask) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *GuideTask) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "GuideTask"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *GuideTask) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Status", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Status: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Status)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Status (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Status: ", p), err) + } + return err +} + +func (p *GuideTask) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Progress", thrift.STRUCT, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Progress: ", p), err) + } + if err := p.Progress.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.Progress), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Progress: ", p), err) + } + return err +} + +func (p *GuideTask) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Id: ", p), err) + } + return err +} + +func (p *GuideTask) Equals(other *GuideTask) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Status != other.Status { + return false + } + if !p.Progress.Equals(other.Progress) { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *GuideTask) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("GuideTask(%+v)", *p) +} + +func (p *GuideTask) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.GuideTask", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*GuideTask)(nil) + +func (p *GuideTask) Validate() error { + return nil +} + +// Attributes: +// - Handbooks +// - Collect +// +type Handbook struct { + Handbooks []*HandbookInfo `thrift:"Handbooks,1" db:"Handbooks" json:"Handbooks"` + Collect []string `thrift:"Collect,2" db:"Collect" json:"Collect"` +} + +func NewHandbook() *Handbook { + return &Handbook{} +} + +func (p *Handbook) GetHandbooks() []*HandbookInfo { + return p.Handbooks +} + +func (p *Handbook) GetCollect() []string { + return p.Collect +} + +func (p *Handbook) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.LIST { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *Handbook) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*HandbookInfo, 0, size) + p.Handbooks = tSlice + for i := 0; i < size; i++ { + _elem33 := &HandbookInfo{} + if err := _elem33.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem33), err) + } + p.Handbooks = append(p.Handbooks, _elem33) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *Handbook) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]string, 0, size) + p.Collect = tSlice + for i := 0; i < size; i++ { + var _elem34 string + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem34 = v + } + p.Collect = append(p.Collect, _elem34) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *Handbook) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "Handbook"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *Handbook) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Handbooks", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Handbooks: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Handbooks)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Handbooks { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Handbooks: ", p), err) + } + return err +} + +func (p *Handbook) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Collect", thrift.LIST, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Collect: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRING, len(p.Collect)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Collect { + if err := oprot.WriteString(ctx, string(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Collect: ", p), err) + } + return err +} + +func (p *Handbook) Equals(other *Handbook) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.Handbooks) != len(other.Handbooks) { + return false + } + for i, _tgt := range p.Handbooks { + _src35 := other.Handbooks[i] + if !_tgt.Equals(_src35) { + return false + } + } + if len(p.Collect) != len(other.Collect) { + return false + } + for i, _tgt := range p.Collect { + _src36 := other.Collect[i] + if _tgt != _src36 { + return false + } + } + return true +} + +func (p *Handbook) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("Handbook(%+v)", *p) +} + +func (p *Handbook) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.Handbook", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*Handbook)(nil) + +func (p *Handbook) Validate() error { + return nil +} + +// Attributes: +// - ChessId +// - Status +// +type HandbookInfo struct { + ChessId int32 `thrift:"ChessId,1" db:"ChessId" json:"ChessId"` + Status int32 `thrift:"Status,2" db:"Status" json:"Status"` +} + +func NewHandbookInfo() *HandbookInfo { + return &HandbookInfo{} +} + +func (p *HandbookInfo) GetChessId() int32 { + return p.ChessId +} + +func (p *HandbookInfo) GetStatus() int32 { + return p.Status +} + +func (p *HandbookInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *HandbookInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.ChessId = v + } + return nil +} + +func (p *HandbookInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Status = v + } + return nil +} + +func (p *HandbookInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "HandbookInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *HandbookInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChessId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ChessId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ChessId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ChessId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ChessId: ", p), err) + } + return err +} + +func (p *HandbookInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Status", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Status: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Status)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Status (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Status: ", p), err) + } + return err +} + +func (p *HandbookInfo) Equals(other *HandbookInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ChessId != other.ChessId { + return false + } + if p.Status != other.Status { + return false + } + return true +} + +func (p *HandbookInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("HandbookInfo(%+v)", *p) +} + +func (p *HandbookInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.HandbookInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*HandbookInfo)(nil) + +func (p *HandbookInfo) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Num +// +type ItemInfo struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Num int32 `thrift:"Num,2" db:"Num" json:"Num"` +} + +func NewItemInfo() *ItemInfo { + return &ItemInfo{} +} + +func (p *ItemInfo) GetId() int32 { + return p.Id +} + +func (p *ItemInfo) GetNum() int32 { + return p.Num +} + +func (p *ItemInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ItemInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ItemInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Num = v + } + return nil +} + +func (p *ItemInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ItemInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ItemInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ItemInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Num", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Num: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Num)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Num (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Num: ", p), err) + } + return err +} + +func (p *ItemInfo) Equals(other *ItemInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Num != other.Num { + return false + } + return true +} + +func (p *ItemInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ItemInfo(%+v)", *p) +} + +func (p *ItemInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ItemInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ItemInfo)(nil) + +func (p *ItemInfo) Validate() error { + return nil +} + +// Attributes: +// - List +// +type ItemList struct { + List []*ItemInfo `thrift:"List,1" db:"List" json:"List"` +} + +func NewItemList() *ItemList { + return &ItemList{} +} + +func (p *ItemList) GetList() []*ItemInfo { + return p.List +} + +func (p *ItemList) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ItemList) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ItemInfo, 0, size) + p.List = tSlice + for i := 0; i < size; i++ { + _elem37 := &ItemInfo{} + if err := _elem37.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem37), err) + } + p.List = append(p.List, _elem37) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ItemList) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ItemList"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ItemList) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "List", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:List: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.List)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.List { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:List: ", p), err) + } + return err +} + +func (p *ItemList) Equals(other *ItemList) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.List) != len(other.List) { + return false + } + for i, _tgt := range p.List { + _src38 := other.List[i] + if !_tgt.Equals(_src38) { + return false + } + } + return true +} + +func (p *ItemList) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ItemList(%+v)", *p) +} + +func (p *ItemList) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ItemList", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ItemList)(nil) + +func (p *ItemList) Validate() error { + return nil +} + +// Attributes: +// - Item +// +type ItemNotify struct { + Item map[int32]int32 `thrift:"Item,1" db:"Item" json:"Item"` +} + +func NewItemNotify() *ItemNotify { + return &ItemNotify{} +} + +func (p *ItemNotify) GetItem() map[int32]int32 { + return p.Item +} + +func (p *ItemNotify) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.MAP { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ItemNotify) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.Item = tMap + for i := 0; i < size; i++ { + var _key39 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key39 = v + } + var _val40 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val40 = v + } + p.Item[_key39] = _val40 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ItemNotify) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ItemNotify"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ItemNotify) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Item", thrift.MAP, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Item: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.Item)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Item { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Item: ", p), err) + } + return err +} + +func (p *ItemNotify) Equals(other *ItemNotify) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.Item) != len(other.Item) { + return false + } + for k, _tgt := range p.Item { + _src41 := other.Item[k] + if _tgt != _src41 { + return false + } + } + return true +} + +func (p *ItemNotify) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ItemNotify(%+v)", *p) +} + +func (p *ItemNotify) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ItemNotify", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ItemNotify)(nil) + +func (p *ItemNotify) Validate() error { + return nil +} + +// Attributes: +// - EndTime +// - Cd +// - Mul +// - StartTime +// - Param +// - ShowTime +// +type LimitEvent struct { + EndTime int32 `thrift:"EndTime,1" db:"EndTime" json:"EndTime"` + Cd int32 `thrift:"Cd,2" db:"Cd" json:"Cd"` + Mul float64 `thrift:"mul,3" db:"mul" json:"mul"` + StartTime int32 `thrift:"StartTime,4" db:"StartTime" json:"StartTime"` + Param map[string]int32 `thrift:"Param,5" db:"Param" json:"Param"` + ShowTime int32 `thrift:"ShowTime,6" db:"ShowTime" json:"ShowTime"` +} + +func NewLimitEvent() *LimitEvent { + return &LimitEvent{} +} + +func (p *LimitEvent) GetEndTime() int32 { + return p.EndTime +} + +func (p *LimitEvent) GetCd() int32 { + return p.Cd +} + +func (p *LimitEvent) GetMul() float64 { + return p.Mul +} + +func (p *LimitEvent) GetStartTime() int32 { + return p.StartTime +} + +func (p *LimitEvent) GetParam() map[string]int32 { + return p.Param +} + +func (p *LimitEvent) GetShowTime() int32 { + return p.ShowTime +} + +func (p *LimitEvent) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.DOUBLE { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.MAP { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.I32 { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *LimitEvent) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.EndTime = v + } + return nil +} + +func (p *LimitEvent) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Cd = v + } + return nil +} + +func (p *LimitEvent) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadDouble(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Mul = v + } + return nil +} + +func (p *LimitEvent) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.StartTime = v + } + return nil +} + +func (p *LimitEvent) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[string]int32, size) + p.Param = tMap + for i := 0; i < size; i++ { + var _key42 string + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key42 = v + } + var _val43 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val43 = v + } + p.Param[_key42] = _val43 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *LimitEvent) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 6: ", err) + } else { + p.ShowTime = v + } + return nil +} + +func (p *LimitEvent) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "LimitEvent"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *LimitEvent) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EndTime", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:EndTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.EndTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EndTime (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:EndTime: ", p), err) + } + return err +} + +func (p *LimitEvent) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Cd", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Cd: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Cd)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Cd (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Cd: ", p), err) + } + return err +} + +func (p *LimitEvent) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "mul", thrift.DOUBLE, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:mul: ", p), err) + } + if err := oprot.WriteDouble(ctx, float64(p.Mul)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.mul (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:mul: ", p), err) + } + return err +} + +func (p *LimitEvent) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "StartTime", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:StartTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.StartTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.StartTime (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:StartTime: ", p), err) + } + return err +} + +func (p *LimitEvent) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Param", thrift.MAP, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Param: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.STRING, thrift.I32, len(p.Param)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Param { + if err := oprot.WriteString(ctx, string(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Param: ", p), err) + } + return err +} + +func (p *LimitEvent) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ShowTime", thrift.I32, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:ShowTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ShowTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ShowTime (6) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:ShowTime: ", p), err) + } + return err +} + +func (p *LimitEvent) Equals(other *LimitEvent) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.EndTime != other.EndTime { + return false + } + if p.Cd != other.Cd { + return false + } + if p.Mul != other.Mul { + return false + } + if p.StartTime != other.StartTime { + return false + } + if len(p.Param) != len(other.Param) { + return false + } + for k, _tgt := range p.Param { + _src44 := other.Param[k] + if _tgt != _src44 { + return false + } + } + if p.ShowTime != other.ShowTime { + return false + } + return true +} + +func (p *LimitEvent) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("LimitEvent(%+v)", *p) +} + +func (p *LimitEvent) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.LimitEvent", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*LimitEvent)(nil) + +func (p *LimitEvent) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Type +// - EndTime +// - Cd +// +type LimitEventNotify struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Type int32 `thrift:"Type,2" db:"Type" json:"Type"` + EndTime int32 `thrift:"EndTime,3" db:"EndTime" json:"EndTime"` + Cd int32 `thrift:"Cd,4" db:"Cd" json:"Cd"` +} + +func NewLimitEventNotify() *LimitEventNotify { + return &LimitEventNotify{} +} + +func (p *LimitEventNotify) GetId() int32 { + return p.Id +} + +func (p *LimitEventNotify) GetType() int32 { + return p.Type +} + +func (p *LimitEventNotify) GetEndTime() int32 { + return p.EndTime +} + +func (p *LimitEventNotify) GetCd() int32 { + return p.Cd +} + +func (p *LimitEventNotify) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *LimitEventNotify) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *LimitEventNotify) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *LimitEventNotify) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.EndTime = v + } + return nil +} + +func (p *LimitEventNotify) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Cd = v + } + return nil +} + +func (p *LimitEventNotify) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "LimitEventNotify"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *LimitEventNotify) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *LimitEventNotify) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Type: ", p), err) + } + return err +} + +func (p *LimitEventNotify) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EndTime", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:EndTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.EndTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EndTime (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:EndTime: ", p), err) + } + return err +} + +func (p *LimitEventNotify) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Cd", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Cd: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Cd)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Cd (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Cd: ", p), err) + } + return err +} + +func (p *LimitEventNotify) Equals(other *LimitEventNotify) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Type != other.Type { + return false + } + if p.EndTime != other.EndTime { + return false + } + if p.Cd != other.Cd { + return false + } + return true +} + +func (p *LimitEventNotify) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("LimitEventNotify(%+v)", *p) +} + +func (p *LimitEventNotify) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.LimitEventNotify", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*LimitEventNotify)(nil) + +func (p *LimitEventNotify) Validate() error { + return nil +} + +// Attributes: +// - WorkTime +// - RemainTime +// +type LogoutPetWork struct { + WorkTime int64 `thrift:"WorkTime,1" db:"WorkTime" json:"WorkTime"` + RemainTime int64 `thrift:"RemainTime,2" db:"RemainTime" json:"RemainTime"` +} + +func NewLogoutPetWork() *LogoutPetWork { + return &LogoutPetWork{} +} + +func (p *LogoutPetWork) GetWorkTime() int64 { + return p.WorkTime +} + +func (p *LogoutPetWork) GetRemainTime() int64 { + return p.RemainTime +} + +func (p *LogoutPetWork) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I64 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *LogoutPetWork) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.WorkTime = v + } + return nil +} + +func (p *LogoutPetWork) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.RemainTime = v + } + return nil +} + +func (p *LogoutPetWork) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "LogoutPetWork"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *LogoutPetWork) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "WorkTime", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:WorkTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.WorkTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.WorkTime (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:WorkTime: ", p), err) + } + return err +} + +func (p *LogoutPetWork) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "RemainTime", thrift.I64, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:RemainTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.RemainTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.RemainTime (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:RemainTime: ", p), err) + } + return err +} + +func (p *LogoutPetWork) Equals(other *LogoutPetWork) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.WorkTime != other.WorkTime { + return false + } + if p.RemainTime != other.RemainTime { + return false + } + return true +} + +func (p *LogoutPetWork) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("LogoutPetWork(%+v)", *p) +} + +func (p *LogoutPetWork) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.LogoutPetWork", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*LogoutPetWork)(nil) + +func (p *LogoutPetWork) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Title +// - Content +// - Time +// - Status +// - Items +// - Type +// - TitleEn +// - ContentEn +// - SubTitle +// - SubTitleEn +// - TitlePtBr +// - ContentPtBr +// - SubTitlePtBr +// - TitleEsLa +// - SubTitleEsLa +// - ContentEsLa +// +type MailInfo struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Title string `thrift:"Title,2" db:"Title" json:"Title"` + Content string `thrift:"Content,3" db:"Content" json:"Content"` + Time int32 `thrift:"Time,4" db:"Time" json:"Time"` + Status int32 `thrift:"Status,5" db:"Status" json:"Status"` + Items []*ItemInfo `thrift:"Items,6" db:"Items" json:"Items"` + Type int32 `thrift:"Type,7" db:"Type" json:"Type"` + TitleEn string `thrift:"TitleEn,8" db:"TitleEn" json:"TitleEn"` + ContentEn string `thrift:"ContentEn,9" db:"ContentEn" json:"ContentEn"` + SubTitle string `thrift:"SubTitle,10" db:"SubTitle" json:"SubTitle"` + SubTitleEn string `thrift:"SubTitleEn,11" db:"SubTitleEn" json:"SubTitleEn"` + TitlePtBr string `thrift:"TitlePtBr,12" db:"TitlePtBr" json:"TitlePtBr"` + ContentPtBr string `thrift:"ContentPtBr,13" db:"ContentPtBr" json:"ContentPtBr"` + SubTitlePtBr string `thrift:"SubTitlePtBr,14" db:"SubTitlePtBr" json:"SubTitlePtBr"` + TitleEsLa string `thrift:"TitleEsLa,15" db:"TitleEsLa" json:"TitleEsLa"` + SubTitleEsLa string `thrift:"SubTitleEsLa,16" db:"SubTitleEsLa" json:"SubTitleEsLa"` + ContentEsLa string `thrift:"ContentEsLa,17" db:"ContentEsLa" json:"ContentEsLa"` +} + +func NewMailInfo() *MailInfo { + return &MailInfo{} +} + +func (p *MailInfo) GetId() int32 { + return p.Id +} + +func (p *MailInfo) GetTitle() string { + return p.Title +} + +func (p *MailInfo) GetContent() string { + return p.Content +} + +func (p *MailInfo) GetTime() int32 { + return p.Time +} + +func (p *MailInfo) GetStatus() int32 { + return p.Status +} + +func (p *MailInfo) GetItems() []*ItemInfo { + return p.Items +} + +func (p *MailInfo) GetType() int32 { + return p.Type +} + +func (p *MailInfo) GetTitleEn() string { + return p.TitleEn +} + +func (p *MailInfo) GetContentEn() string { + return p.ContentEn +} + +func (p *MailInfo) GetSubTitle() string { + return p.SubTitle +} + +func (p *MailInfo) GetSubTitleEn() string { + return p.SubTitleEn +} + +func (p *MailInfo) GetTitlePtBr() string { + return p.TitlePtBr +} + +func (p *MailInfo) GetContentPtBr() string { + return p.ContentPtBr +} + +func (p *MailInfo) GetSubTitlePtBr() string { + return p.SubTitlePtBr +} + +func (p *MailInfo) GetTitleEsLa() string { + return p.TitleEsLa +} + +func (p *MailInfo) GetSubTitleEsLa() string { + return p.SubTitleEsLa +} + +func (p *MailInfo) GetContentEsLa() string { + return p.ContentEsLa +} + +func (p *MailInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.STRING { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.LIST { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.I32 { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 8: + if fieldTypeId == thrift.STRING { + if err := p.ReadField8(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 9: + if fieldTypeId == thrift.STRING { + if err := p.ReadField9(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 10: + if fieldTypeId == thrift.STRING { + if err := p.ReadField10(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 11: + if fieldTypeId == thrift.STRING { + if err := p.ReadField11(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 12: + if fieldTypeId == thrift.STRING { + if err := p.ReadField12(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 13: + if fieldTypeId == thrift.STRING { + if err := p.ReadField13(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 14: + if fieldTypeId == thrift.STRING { + if err := p.ReadField14(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 15: + if fieldTypeId == thrift.STRING { + if err := p.ReadField15(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 16: + if fieldTypeId == thrift.STRING { + if err := p.ReadField16(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 17: + if fieldTypeId == thrift.STRING { + if err := p.ReadField17(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *MailInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *MailInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Title = v + } + return nil +} + +func (p *MailInfo) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Content = v + } + return nil +} + +func (p *MailInfo) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Time = v + } + return nil +} + +func (p *MailInfo) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.Status = v + } + return nil +} + +func (p *MailInfo) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ItemInfo, 0, size) + p.Items = tSlice + for i := 0; i < size; i++ { + _elem45 := &ItemInfo{} + if err := _elem45.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem45), err) + } + p.Items = append(p.Items, _elem45) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *MailInfo) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 7: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *MailInfo) ReadField8(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 8: ", err) + } else { + p.TitleEn = v + } + return nil +} + +func (p *MailInfo) ReadField9(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 9: ", err) + } else { + p.ContentEn = v + } + return nil +} + +func (p *MailInfo) ReadField10(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 10: ", err) + } else { + p.SubTitle = v + } + return nil +} + +func (p *MailInfo) ReadField11(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 11: ", err) + } else { + p.SubTitleEn = v + } + return nil +} + +func (p *MailInfo) ReadField12(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 12: ", err) + } else { + p.TitlePtBr = v + } + return nil +} + +func (p *MailInfo) ReadField13(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 13: ", err) + } else { + p.ContentPtBr = v + } + return nil +} + +func (p *MailInfo) ReadField14(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 14: ", err) + } else { + p.SubTitlePtBr = v + } + return nil +} + +func (p *MailInfo) ReadField15(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 15: ", err) + } else { + p.TitleEsLa = v + } + return nil +} + +func (p *MailInfo) ReadField16(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 16: ", err) + } else { + p.SubTitleEsLa = v + } + return nil +} + +func (p *MailInfo) ReadField17(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 17: ", err) + } else { + p.ContentEsLa = v + } + return nil +} + +func (p *MailInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "MailInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + if err := p.writeField8(ctx, oprot); err != nil { + return err + } + if err := p.writeField9(ctx, oprot); err != nil { + return err + } + if err := p.writeField10(ctx, oprot); err != nil { + return err + } + if err := p.writeField11(ctx, oprot); err != nil { + return err + } + if err := p.writeField12(ctx, oprot); err != nil { + return err + } + if err := p.writeField13(ctx, oprot); err != nil { + return err + } + if err := p.writeField14(ctx, oprot); err != nil { + return err + } + if err := p.writeField15(ctx, oprot); err != nil { + return err + } + if err := p.writeField16(ctx, oprot); err != nil { + return err + } + if err := p.writeField17(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *MailInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *MailInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Title", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Title: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Title)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Title (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Title: ", p), err) + } + return err +} + +func (p *MailInfo) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Content", thrift.STRING, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Content: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Content)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Content (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Content: ", p), err) + } + return err +} + +func (p *MailInfo) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Time", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Time: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Time)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Time (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Time: ", p), err) + } + return err +} + +func (p *MailInfo) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Status", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Status: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Status)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Status (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Status: ", p), err) + } + return err +} + +func (p *MailInfo) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Items", thrift.LIST, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:Items: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Items)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Items { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:Items: ", p), err) + } + return err +} + +func (p *MailInfo) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (7) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:Type: ", p), err) + } + return err +} + +func (p *MailInfo) writeField8(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "TitleEn", thrift.STRING, 8); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 8:TitleEn: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.TitleEn)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.TitleEn (8) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 8:TitleEn: ", p), err) + } + return err +} + +func (p *MailInfo) writeField9(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ContentEn", thrift.STRING, 9); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 9:ContentEn: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.ContentEn)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ContentEn (9) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 9:ContentEn: ", p), err) + } + return err +} + +func (p *MailInfo) writeField10(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "SubTitle", thrift.STRING, 10); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 10:SubTitle: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.SubTitle)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.SubTitle (10) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 10:SubTitle: ", p), err) + } + return err +} + +func (p *MailInfo) writeField11(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "SubTitleEn", thrift.STRING, 11); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 11:SubTitleEn: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.SubTitleEn)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.SubTitleEn (11) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 11:SubTitleEn: ", p), err) + } + return err +} + +func (p *MailInfo) writeField12(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "TitlePtBr", thrift.STRING, 12); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 12:TitlePtBr: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.TitlePtBr)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.TitlePtBr (12) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 12:TitlePtBr: ", p), err) + } + return err +} + +func (p *MailInfo) writeField13(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ContentPtBr", thrift.STRING, 13); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 13:ContentPtBr: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.ContentPtBr)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ContentPtBr (13) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 13:ContentPtBr: ", p), err) + } + return err +} + +func (p *MailInfo) writeField14(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "SubTitlePtBr", thrift.STRING, 14); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 14:SubTitlePtBr: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.SubTitlePtBr)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.SubTitlePtBr (14) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 14:SubTitlePtBr: ", p), err) + } + return err +} + +func (p *MailInfo) writeField15(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "TitleEsLa", thrift.STRING, 15); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 15:TitleEsLa: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.TitleEsLa)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.TitleEsLa (15) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 15:TitleEsLa: ", p), err) + } + return err +} + +func (p *MailInfo) writeField16(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "SubTitleEsLa", thrift.STRING, 16); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 16:SubTitleEsLa: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.SubTitleEsLa)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.SubTitleEsLa (16) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 16:SubTitleEsLa: ", p), err) + } + return err +} + +func (p *MailInfo) writeField17(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ContentEsLa", thrift.STRING, 17); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 17:ContentEsLa: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.ContentEsLa)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ContentEsLa (17) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 17:ContentEsLa: ", p), err) + } + return err +} + +func (p *MailInfo) Equals(other *MailInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Title != other.Title { + return false + } + if p.Content != other.Content { + return false + } + if p.Time != other.Time { + return false + } + if p.Status != other.Status { + return false + } + if len(p.Items) != len(other.Items) { + return false + } + for i, _tgt := range p.Items { + _src46 := other.Items[i] + if !_tgt.Equals(_src46) { + return false + } + } + if p.Type != other.Type { + return false + } + if p.TitleEn != other.TitleEn { + return false + } + if p.ContentEn != other.ContentEn { + return false + } + if p.SubTitle != other.SubTitle { + return false + } + if p.SubTitleEn != other.SubTitleEn { + return false + } + if p.TitlePtBr != other.TitlePtBr { + return false + } + if p.ContentPtBr != other.ContentPtBr { + return false + } + if p.SubTitlePtBr != other.SubTitlePtBr { + return false + } + if p.TitleEsLa != other.TitleEsLa { + return false + } + if p.SubTitleEsLa != other.SubTitleEsLa { + return false + } + if p.ContentEsLa != other.ContentEsLa { + return false + } + return true +} + +func (p *MailInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("MailInfo(%+v)", *p) +} + +func (p *MailInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.MailInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*MailInfo)(nil) + +func (p *MailInfo) Validate() error { + return nil +} + +// Attributes: +// - Info +// +type MailNotify struct { + Info *MailInfo `thrift:"Info,1" db:"Info" json:"Info"` +} + +func NewMailNotify() *MailNotify { + return &MailNotify{} +} + +var MailNotify_Info_DEFAULT *MailInfo + +func (p *MailNotify) GetInfo() *MailInfo { + if !p.IsSetInfo() { + return MailNotify_Info_DEFAULT + } + return p.Info +} + +func (p *MailNotify) IsSetInfo() bool { + return p.Info != nil +} + +func (p *MailNotify) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *MailNotify) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + p.Info = &MailInfo{} + if err := p.Info.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.Info), err) + } + return nil +} + +func (p *MailNotify) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "MailNotify"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *MailNotify) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Info", thrift.STRUCT, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Info: ", p), err) + } + if err := p.Info.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.Info), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Info: ", p), err) + } + return err +} + +func (p *MailNotify) Equals(other *MailNotify) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if !p.Info.Equals(other.Info) { + return false + } + return true +} + +func (p *MailNotify) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("MailNotify(%+v)", *p) +} + +func (p *MailNotify) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.MailNotify", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*MailNotify)(nil) + +func (p *MailNotify) Validate() error { + return nil +} + +// Attributes: +// - Area +// +type MinigCfgGem struct { + Area string `thrift:"Area,1" db:"Area" json:"Area"` +} + +func NewMinigCfgGem() *MinigCfgGem { + return &MinigCfgGem{} +} + +func (p *MinigCfgGem) GetArea() string { + return p.Area +} + +func (p *MinigCfgGem) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *MinigCfgGem) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Area = v + } + return nil +} + +func (p *MinigCfgGem) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "MinigCfgGem"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *MinigCfgGem) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Area", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Area: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Area)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Area (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Area: ", p), err) + } + return err +} + +func (p *MinigCfgGem) Equals(other *MinigCfgGem) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Area != other.Area { + return false + } + return true +} + +func (p *MinigCfgGem) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("MinigCfgGem(%+v)", *p) +} + +func (p *MinigCfgGem) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.MinigCfgGem", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*MinigCfgGem)(nil) + +func (p *MinigCfgGem) Validate() error { + return nil +} + +// Attributes: +// - Name +// - PassNum +// - ItemCost +// - ItemId +// - StartItemnum +// - Gem +// - Jackpot +// - Pass +// +type MiningCfg struct { + Name string `thrift:"Name,1" db:"Name" json:"Name"` + PassNum int32 `thrift:"PassNum,2" db:"PassNum" json:"PassNum"` + ItemCost []*ItemInfo `thrift:"itemCost,3" db:"itemCost" json:"itemCost"` + ItemId int32 `thrift:"ItemId,4" db:"ItemId" json:"ItemId"` + StartItemnum int32 `thrift:"startItemnum,5" db:"startItemnum" json:"startItemnum"` + Gem map[string]*MinigCfgGem `thrift:"Gem,6" db:"Gem" json:"Gem"` + Jackpot map[string]*MiningCfgJackpot `thrift:"Jackpot,7" db:"Jackpot" json:"Jackpot"` + Pass map[string]*MiningCfgPass `thrift:"Pass,8" db:"Pass" json:"Pass"` +} + +func NewMiningCfg() *MiningCfg { + return &MiningCfg{} +} + +func (p *MiningCfg) GetName() string { + return p.Name +} + +func (p *MiningCfg) GetPassNum() int32 { + return p.PassNum +} + +func (p *MiningCfg) GetItemCost() []*ItemInfo { + return p.ItemCost +} + +func (p *MiningCfg) GetItemId() int32 { + return p.ItemId +} + +func (p *MiningCfg) GetStartItemnum() int32 { + return p.StartItemnum +} + +func (p *MiningCfg) GetGem() map[string]*MinigCfgGem { + return p.Gem +} + +func (p *MiningCfg) GetJackpot() map[string]*MiningCfgJackpot { + return p.Jackpot +} + +func (p *MiningCfg) GetPass() map[string]*MiningCfgPass { + return p.Pass +} + +func (p *MiningCfg) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.LIST { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.MAP { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.MAP { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 8: + if fieldTypeId == thrift.MAP { + if err := p.ReadField8(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *MiningCfg) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Name = v + } + return nil +} + +func (p *MiningCfg) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.PassNum = v + } + return nil +} + +func (p *MiningCfg) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ItemInfo, 0, size) + p.ItemCost = tSlice + for i := 0; i < size; i++ { + _elem47 := &ItemInfo{} + if err := _elem47.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem47), err) + } + p.ItemCost = append(p.ItemCost, _elem47) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *MiningCfg) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.ItemId = v + } + return nil +} + +func (p *MiningCfg) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.StartItemnum = v + } + return nil +} + +func (p *MiningCfg) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[string]*MinigCfgGem, size) + p.Gem = tMap + for i := 0; i < size; i++ { + var _key48 string + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key48 = v + } + _val49 := &MinigCfgGem{} + if err := _val49.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _val49), err) + } + p.Gem[_key48] = _val49 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *MiningCfg) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[string]*MiningCfgJackpot, size) + p.Jackpot = tMap + for i := 0; i < size; i++ { + var _key50 string + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key50 = v + } + _val51 := &MiningCfgJackpot{} + if err := _val51.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _val51), err) + } + p.Jackpot[_key50] = _val51 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *MiningCfg) ReadField8(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[string]*MiningCfgPass, size) + p.Pass = tMap + for i := 0; i < size; i++ { + var _key52 string + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key52 = v + } + _val53 := &MiningCfgPass{} + if err := _val53.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _val53), err) + } + p.Pass[_key52] = _val53 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *MiningCfg) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "MiningCfg"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + if err := p.writeField8(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *MiningCfg) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Name", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Name: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Name)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Name (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Name: ", p), err) + } + return err +} + +func (p *MiningCfg) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "PassNum", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:PassNum: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.PassNum)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.PassNum (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:PassNum: ", p), err) + } + return err +} + +func (p *MiningCfg) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "itemCost", thrift.LIST, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:itemCost: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.ItemCost)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.ItemCost { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:itemCost: ", p), err) + } + return err +} + +func (p *MiningCfg) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ItemId", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:ItemId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ItemId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ItemId (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:ItemId: ", p), err) + } + return err +} + +func (p *MiningCfg) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "startItemnum", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:startItemnum: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.StartItemnum)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.startItemnum (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:startItemnum: ", p), err) + } + return err +} + +func (p *MiningCfg) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Gem", thrift.MAP, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:Gem: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.STRING, thrift.STRUCT, len(p.Gem)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Gem { + if err := oprot.WriteString(ctx, string(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:Gem: ", p), err) + } + return err +} + +func (p *MiningCfg) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Jackpot", thrift.MAP, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:Jackpot: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.STRING, thrift.STRUCT, len(p.Jackpot)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Jackpot { + if err := oprot.WriteString(ctx, string(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:Jackpot: ", p), err) + } + return err +} + +func (p *MiningCfg) writeField8(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Pass", thrift.MAP, 8); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 8:Pass: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.STRING, thrift.STRUCT, len(p.Pass)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Pass { + if err := oprot.WriteString(ctx, string(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 8:Pass: ", p), err) + } + return err +} + +func (p *MiningCfg) Equals(other *MiningCfg) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Name != other.Name { + return false + } + if p.PassNum != other.PassNum { + return false + } + if len(p.ItemCost) != len(other.ItemCost) { + return false + } + for i, _tgt := range p.ItemCost { + _src54 := other.ItemCost[i] + if !_tgt.Equals(_src54) { + return false + } + } + if p.ItemId != other.ItemId { + return false + } + if p.StartItemnum != other.StartItemnum { + return false + } + if len(p.Gem) != len(other.Gem) { + return false + } + for k, _tgt := range p.Gem { + _src55 := other.Gem[k] + if !_tgt.Equals(_src55) { + return false + } + } + if len(p.Jackpot) != len(other.Jackpot) { + return false + } + for k, _tgt := range p.Jackpot { + _src56 := other.Jackpot[k] + if !_tgt.Equals(_src56) { + return false + } + } + if len(p.Pass) != len(other.Pass) { + return false + } + for k, _tgt := range p.Pass { + _src57 := other.Pass[k] + if !_tgt.Equals(_src57) { + return false + } + } + return true +} + +func (p *MiningCfg) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("MiningCfg(%+v)", *p) +} + +func (p *MiningCfg) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.MiningCfg", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*MiningCfg)(nil) + +func (p *MiningCfg) Validate() error { + return nil +} + +// Attributes: +// - Prob +// - Items +// +type MiningCfgJackpot struct { + Prob int32 `thrift:"Prob,1" db:"Prob" json:"Prob"` + Items []*ItemInfo `thrift:"Items,2" db:"Items" json:"Items"` +} + +func NewMiningCfgJackpot() *MiningCfgJackpot { + return &MiningCfgJackpot{} +} + +func (p *MiningCfgJackpot) GetProb() int32 { + return p.Prob +} + +func (p *MiningCfgJackpot) GetItems() []*ItemInfo { + return p.Items +} + +func (p *MiningCfgJackpot) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.LIST { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *MiningCfgJackpot) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Prob = v + } + return nil +} + +func (p *MiningCfgJackpot) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ItemInfo, 0, size) + p.Items = tSlice + for i := 0; i < size; i++ { + _elem58 := &ItemInfo{} + if err := _elem58.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem58), err) + } + p.Items = append(p.Items, _elem58) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *MiningCfgJackpot) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "MiningCfgJackpot"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *MiningCfgJackpot) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Prob", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Prob: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Prob)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Prob (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Prob: ", p), err) + } + return err +} + +func (p *MiningCfgJackpot) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Items", thrift.LIST, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Items: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Items)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Items { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Items: ", p), err) + } + return err +} + +func (p *MiningCfgJackpot) Equals(other *MiningCfgJackpot) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Prob != other.Prob { + return false + } + if len(p.Items) != len(other.Items) { + return false + } + for i, _tgt := range p.Items { + _src59 := other.Items[i] + if !_tgt.Equals(_src59) { + return false + } + } + return true +} + +func (p *MiningCfgJackpot) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("MiningCfgJackpot(%+v)", *p) +} + +func (p *MiningCfgJackpot) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.MiningCfgJackpot", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*MiningCfgJackpot)(nil) + +func (p *MiningCfgJackpot) Validate() error { + return nil +} + +// Attributes: +// - Items +// - Area +// - Gem +// - StarReward +// +type MiningCfgPass struct { + Items []*ItemInfo `thrift:"Items,1" db:"Items" json:"Items"` + Area string `thrift:"Area,2" db:"Area" json:"Area"` + Gem int32 `thrift:"Gem,3" db:"Gem" json:"Gem"` + StarReward int32 `thrift:"StarReward,4" db:"StarReward" json:"StarReward"` +} + +func NewMiningCfgPass() *MiningCfgPass { + return &MiningCfgPass{} +} + +func (p *MiningCfgPass) GetItems() []*ItemInfo { + return p.Items +} + +func (p *MiningCfgPass) GetArea() string { + return p.Area +} + +func (p *MiningCfgPass) GetGem() int32 { + return p.Gem +} + +func (p *MiningCfgPass) GetStarReward() int32 { + return p.StarReward +} + +func (p *MiningCfgPass) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *MiningCfgPass) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ItemInfo, 0, size) + p.Items = tSlice + for i := 0; i < size; i++ { + _elem60 := &ItemInfo{} + if err := _elem60.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem60), err) + } + p.Items = append(p.Items, _elem60) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *MiningCfgPass) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Area = v + } + return nil +} + +func (p *MiningCfgPass) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Gem = v + } + return nil +} + +func (p *MiningCfgPass) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.StarReward = v + } + return nil +} + +func (p *MiningCfgPass) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "MiningCfgPass"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *MiningCfgPass) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Items", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Items: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Items)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Items { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Items: ", p), err) + } + return err +} + +func (p *MiningCfgPass) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Area", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Area: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Area)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Area (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Area: ", p), err) + } + return err +} + +func (p *MiningCfgPass) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Gem", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Gem: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Gem)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Gem (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Gem: ", p), err) + } + return err +} + +func (p *MiningCfgPass) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "StarReward", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:StarReward: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.StarReward)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.StarReward (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:StarReward: ", p), err) + } + return err +} + +func (p *MiningCfgPass) Equals(other *MiningCfgPass) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.Items) != len(other.Items) { + return false + } + for i, _tgt := range p.Items { + _src61 := other.Items[i] + if !_tgt.Equals(_src61) { + return false + } + } + if p.Area != other.Area { + return false + } + if p.Gem != other.Gem { + return false + } + if p.StarReward != other.StarReward { + return false + } + return true +} + +func (p *MiningCfgPass) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("MiningCfgPass(%+v)", *p) +} + +func (p *MiningCfgPass) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.MiningCfgPass", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*MiningCfgPass)(nil) + +func (p *MiningCfgPass) Validate() error { + return nil +} + +// Attributes: +// - WorkOutline +// +type NofiPlayroomStatus struct { + WorkOutline int32 `thrift:"WorkOutline,1" db:"WorkOutline" json:"WorkOutline"` +} + +func NewNofiPlayroomStatus() *NofiPlayroomStatus { + return &NofiPlayroomStatus{} +} + +func (p *NofiPlayroomStatus) GetWorkOutline() int32 { + return p.WorkOutline +} + +func (p *NofiPlayroomStatus) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *NofiPlayroomStatus) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.WorkOutline = v + } + return nil +} + +func (p *NofiPlayroomStatus) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "NofiPlayroomStatus"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *NofiPlayroomStatus) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "WorkOutline", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:WorkOutline: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.WorkOutline)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.WorkOutline (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:WorkOutline: ", p), err) + } + return err +} + +func (p *NofiPlayroomStatus) Equals(other *NofiPlayroomStatus) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.WorkOutline != other.WorkOutline { + return false + } + return true +} + +func (p *NofiPlayroomStatus) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("NofiPlayroomStatus(%+v)", *p) +} + +func (p *NofiPlayroomStatus) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.NofiPlayroomStatus", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*NofiPlayroomStatus)(nil) + +func (p *NofiPlayroomStatus) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Red +// +type NotifyActRed struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Red int32 `thrift:"Red,2" db:"Red" json:"Red"` +} + +func NewNotifyActRed() *NotifyActRed { + return &NotifyActRed{} +} + +func (p *NotifyActRed) GetId() int32 { + return p.Id +} + +func (p *NotifyActRed) GetRed() int32 { + return p.Red +} + +func (p *NotifyActRed) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *NotifyActRed) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *NotifyActRed) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Red = v + } + return nil +} + +func (p *NotifyActRed) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "NotifyActRed"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *NotifyActRed) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *NotifyActRed) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Red", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Red: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Red)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Red (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Red: ", p), err) + } + return err +} + +func (p *NotifyActRed) Equals(other *NotifyActRed) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Red != other.Red { + return false + } + return true +} + +func (p *NotifyActRed) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("NotifyActRed(%+v)", *p) +} + +func (p *NotifyActRed) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.NotifyActRed", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*NotifyActRed)(nil) + +func (p *NotifyActRed) Validate() error { + return nil +} + +// Attributes: +// - DwUin +// - AddCnt +// +type NotifyAddEnergy struct { + DwUin int64 `thrift:"dwUin,1" db:"dwUin" json:"dwUin"` + AddCnt int32 `thrift:"addCnt,2" db:"addCnt" json:"addCnt"` +} + +func NewNotifyAddEnergy() *NotifyAddEnergy { + return &NotifyAddEnergy{} +} + +func (p *NotifyAddEnergy) GetDwUin() int64 { + return p.DwUin +} + +func (p *NotifyAddEnergy) GetAddCnt() int32 { + return p.AddCnt +} + +func (p *NotifyAddEnergy) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *NotifyAddEnergy) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.DwUin = v + } + return nil +} + +func (p *NotifyAddEnergy) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.AddCnt = v + } + return nil +} + +func (p *NotifyAddEnergy) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "NotifyAddEnergy"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *NotifyAddEnergy) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "dwUin", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:dwUin: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.DwUin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.dwUin (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:dwUin: ", p), err) + } + return err +} + +func (p *NotifyAddEnergy) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "addCnt", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:addCnt: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.AddCnt)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.addCnt (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:addCnt: ", p), err) + } + return err +} + +func (p *NotifyAddEnergy) Equals(other *NotifyAddEnergy) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.DwUin != other.DwUin { + return false + } + if p.AddCnt != other.AddCnt { + return false + } + return true +} + +func (p *NotifyAddEnergy) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("NotifyAddEnergy(%+v)", *p) +} + +func (p *NotifyAddEnergy) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.NotifyAddEnergy", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*NotifyAddEnergy)(nil) + +func (p *NotifyAddEnergy) Validate() error { + return nil +} + +// Attributes: +// - Info +// +type NotifyFriendCard struct { + Info *ResFriendCard `thrift:"Info,1" db:"Info" json:"Info"` +} + +func NewNotifyFriendCard() *NotifyFriendCard { + return &NotifyFriendCard{} +} + +var NotifyFriendCard_Info_DEFAULT *ResFriendCard + +func (p *NotifyFriendCard) GetInfo() *ResFriendCard { + if !p.IsSetInfo() { + return NotifyFriendCard_Info_DEFAULT + } + return p.Info +} + +func (p *NotifyFriendCard) IsSetInfo() bool { + return p.Info != nil +} + +func (p *NotifyFriendCard) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *NotifyFriendCard) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + p.Info = &ResFriendCard{} + if err := p.Info.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.Info), err) + } + return nil +} + +func (p *NotifyFriendCard) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "NotifyFriendCard"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *NotifyFriendCard) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Info", thrift.STRUCT, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Info: ", p), err) + } + if err := p.Info.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.Info), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Info: ", p), err) + } + return err +} + +func (p *NotifyFriendCard) Equals(other *NotifyFriendCard) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if !p.Info.Equals(other.Info) { + return false + } + return true +} + +func (p *NotifyFriendCard) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("NotifyFriendCard(%+v)", *p) +} + +func (p *NotifyFriendCard) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.NotifyFriendCard", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*NotifyFriendCard)(nil) + +func (p *NotifyFriendCard) Validate() error { + return nil +} + +// Attributes: +// - Info +// - Bubble +// +type NotifyFriendLog struct { + Info *ResFriendLog `thrift:"info,1" db:"info" json:"info"` + Bubble *FriendBubbleInfo `thrift:"Bubble,2" db:"Bubble" json:"Bubble"` +} + +func NewNotifyFriendLog() *NotifyFriendLog { + return &NotifyFriendLog{} +} + +var NotifyFriendLog_Info_DEFAULT *ResFriendLog + +func (p *NotifyFriendLog) GetInfo() *ResFriendLog { + if !p.IsSetInfo() { + return NotifyFriendLog_Info_DEFAULT + } + return p.Info +} + +var NotifyFriendLog_Bubble_DEFAULT *FriendBubbleInfo + +func (p *NotifyFriendLog) GetBubble() *FriendBubbleInfo { + if !p.IsSetBubble() { + return NotifyFriendLog_Bubble_DEFAULT + } + return p.Bubble +} + +func (p *NotifyFriendLog) IsSetInfo() bool { + return p.Info != nil +} + +func (p *NotifyFriendLog) IsSetBubble() bool { + return p.Bubble != nil +} + +func (p *NotifyFriendLog) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *NotifyFriendLog) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + p.Info = &ResFriendLog{} + if err := p.Info.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.Info), err) + } + return nil +} + +func (p *NotifyFriendLog) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + p.Bubble = &FriendBubbleInfo{} + if err := p.Bubble.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.Bubble), err) + } + return nil +} + +func (p *NotifyFriendLog) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "NotifyFriendLog"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *NotifyFriendLog) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "info", thrift.STRUCT, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:info: ", p), err) + } + if err := p.Info.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.Info), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:info: ", p), err) + } + return err +} + +func (p *NotifyFriendLog) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Bubble", thrift.STRUCT, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Bubble: ", p), err) + } + if err := p.Bubble.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.Bubble), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Bubble: ", p), err) + } + return err +} + +func (p *NotifyFriendLog) Equals(other *NotifyFriendLog) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if !p.Info.Equals(other.Info) { + return false + } + if !p.Bubble.Equals(other.Bubble) { + return false + } + return true +} + +func (p *NotifyFriendLog) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("NotifyFriendLog(%+v)", *p) +} + +func (p *NotifyFriendLog) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.NotifyFriendLog", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*NotifyFriendLog)(nil) + +func (p *NotifyFriendLog) Validate() error { + return nil +} + +// Attributes: +// - ResultCode +// - IdLists +// +type NotifyInvitedSuccess struct { + ResultCode int32 `thrift:"ResultCode,1" db:"ResultCode" json:"ResultCode"` + IdLists []int32 `thrift:"IdLists,2" db:"IdLists" json:"IdLists"` +} + +func NewNotifyInvitedSuccess() *NotifyInvitedSuccess { + return &NotifyInvitedSuccess{} +} + +func (p *NotifyInvitedSuccess) GetResultCode() int32 { + return p.ResultCode +} + +func (p *NotifyInvitedSuccess) GetIdLists() []int32 { + return p.IdLists +} + +func (p *NotifyInvitedSuccess) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.LIST { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *NotifyInvitedSuccess) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.ResultCode = v + } + return nil +} + +func (p *NotifyInvitedSuccess) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.IdLists = tSlice + for i := 0; i < size; i++ { + var _elem62 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem62 = v + } + p.IdLists = append(p.IdLists, _elem62) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *NotifyInvitedSuccess) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "NotifyInvitedSuccess"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *NotifyInvitedSuccess) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ResultCode", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ResultCode: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ResultCode)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ResultCode (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ResultCode: ", p), err) + } + return err +} + +func (p *NotifyInvitedSuccess) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "IdLists", thrift.LIST, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:IdLists: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.IdLists)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.IdLists { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:IdLists: ", p), err) + } + return err +} + +func (p *NotifyInvitedSuccess) Equals(other *NotifyInvitedSuccess) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ResultCode != other.ResultCode { + return false + } + if len(p.IdLists) != len(other.IdLists) { + return false + } + for i, _tgt := range p.IdLists { + _src63 := other.IdLists[i] + if _tgt != _src63 { + return false + } + } + return true +} + +func (p *NotifyInvitedSuccess) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("NotifyInvitedSuccess(%+v)", *p) +} + +func (p *NotifyInvitedSuccess) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.NotifyInvitedSuccess", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*NotifyInvitedSuccess)(nil) + +func (p *NotifyInvitedSuccess) Validate() error { + return nil +} + +// Attributes: +// - Player +// +type NotifyPlayroomBroken struct { + Player *ResPlayerSimple `thrift:"Player,1" db:"Player" json:"Player"` +} + +func NewNotifyPlayroomBroken() *NotifyPlayroomBroken { + return &NotifyPlayroomBroken{} +} + +var NotifyPlayroomBroken_Player_DEFAULT *ResPlayerSimple + +func (p *NotifyPlayroomBroken) GetPlayer() *ResPlayerSimple { + if !p.IsSetPlayer() { + return NotifyPlayroomBroken_Player_DEFAULT + } + return p.Player +} + +func (p *NotifyPlayroomBroken) IsSetPlayer() bool { + return p.Player != nil +} + +func (p *NotifyPlayroomBroken) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *NotifyPlayroomBroken) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + p.Player = &ResPlayerSimple{} + if err := p.Player.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.Player), err) + } + return nil +} + +func (p *NotifyPlayroomBroken) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "NotifyPlayroomBroken"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *NotifyPlayroomBroken) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Player", thrift.STRUCT, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Player: ", p), err) + } + if err := p.Player.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.Player), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Player: ", p), err) + } + return err +} + +func (p *NotifyPlayroomBroken) Equals(other *NotifyPlayroomBroken) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if !p.Player.Equals(other.Player) { + return false + } + return true +} + +func (p *NotifyPlayroomBroken) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("NotifyPlayroomBroken(%+v)", *p) +} + +func (p *NotifyPlayroomBroken) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.NotifyPlayroomBroken", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*NotifyPlayroomBroken)(nil) + +func (p *NotifyPlayroomBroken) Validate() error { + return nil +} + +// Attributes: +// - Kiss +// +type NotifyPlayroomKiss struct { + Kiss int32 `thrift:"Kiss,1" db:"Kiss" json:"Kiss"` +} + +func NewNotifyPlayroomKiss() *NotifyPlayroomKiss { + return &NotifyPlayroomKiss{} +} + +func (p *NotifyPlayroomKiss) GetKiss() int32 { + return p.Kiss +} + +func (p *NotifyPlayroomKiss) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *NotifyPlayroomKiss) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Kiss = v + } + return nil +} + +func (p *NotifyPlayroomKiss) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "NotifyPlayroomKiss"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *NotifyPlayroomKiss) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Kiss", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Kiss: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Kiss)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Kiss (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Kiss: ", p), err) + } + return err +} + +func (p *NotifyPlayroomKiss) Equals(other *NotifyPlayroomKiss) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Kiss != other.Kiss { + return false + } + return true +} + +func (p *NotifyPlayroomKiss) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("NotifyPlayroomKiss(%+v)", *p) +} + +func (p *NotifyPlayroomKiss) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.NotifyPlayroomKiss", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*NotifyPlayroomKiss)(nil) + +func (p *NotifyPlayroomKiss) Validate() error { + return nil +} + +// Attributes: +// - LoseItem +// - Chip +// - Revenge +// +type NotifyPlayroomLose struct { + LoseItem []*ItemInfo `thrift:"LoseItem,1" db:"LoseItem" json:"LoseItem"` + Chip []*ChipInfo `thrift:"Chip,2" db:"Chip" json:"Chip"` + Revenge int64 `thrift:"Revenge,3" db:"Revenge" json:"Revenge"` +} + +func NewNotifyPlayroomLose() *NotifyPlayroomLose { + return &NotifyPlayroomLose{} +} + +func (p *NotifyPlayroomLose) GetLoseItem() []*ItemInfo { + return p.LoseItem +} + +func (p *NotifyPlayroomLose) GetChip() []*ChipInfo { + return p.Chip +} + +func (p *NotifyPlayroomLose) GetRevenge() int64 { + return p.Revenge +} + +func (p *NotifyPlayroomLose) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.LIST { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I64 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *NotifyPlayroomLose) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ItemInfo, 0, size) + p.LoseItem = tSlice + for i := 0; i < size; i++ { + _elem64 := &ItemInfo{} + if err := _elem64.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem64), err) + } + p.LoseItem = append(p.LoseItem, _elem64) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *NotifyPlayroomLose) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ChipInfo, 0, size) + p.Chip = tSlice + for i := 0; i < size; i++ { + _elem65 := &ChipInfo{} + if err := _elem65.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem65), err) + } + p.Chip = append(p.Chip, _elem65) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *NotifyPlayroomLose) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Revenge = v + } + return nil +} + +func (p *NotifyPlayroomLose) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "NotifyPlayroomLose"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *NotifyPlayroomLose) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "LoseItem", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:LoseItem: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.LoseItem)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.LoseItem { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:LoseItem: ", p), err) + } + return err +} + +func (p *NotifyPlayroomLose) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Chip", thrift.LIST, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Chip: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Chip)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Chip { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Chip: ", p), err) + } + return err +} + +func (p *NotifyPlayroomLose) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Revenge", thrift.I64, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Revenge: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Revenge)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Revenge (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Revenge: ", p), err) + } + return err +} + +func (p *NotifyPlayroomLose) Equals(other *NotifyPlayroomLose) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.LoseItem) != len(other.LoseItem) { + return false + } + for i, _tgt := range p.LoseItem { + _src66 := other.LoseItem[i] + if !_tgt.Equals(_src66) { + return false + } + } + if len(p.Chip) != len(other.Chip) { + return false + } + for i, _tgt := range p.Chip { + _src67 := other.Chip[i] + if !_tgt.Equals(_src67) { + return false + } + } + if p.Revenge != other.Revenge { + return false + } + return true +} + +func (p *NotifyPlayroomLose) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("NotifyPlayroomLose(%+v)", *p) +} + +func (p *NotifyPlayroomLose) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.NotifyPlayroomLose", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*NotifyPlayroomLose)(nil) + +func (p *NotifyPlayroomLose) Validate() error { + return nil +} + +// Attributes: +// - AllMood +// - Mood +// - Physiology +// - AdItem +// +type NotifyPlayroomMood struct { + AllMood int32 `thrift:"AllMood,1" db:"AllMood" json:"AllMood"` + Mood map[int32]int32 `thrift:"Mood,2" db:"Mood" json:"Mood"` + Physiology map[int32]int32 `thrift:"Physiology,3" db:"Physiology" json:"Physiology"` + AdItem []*AdItem `thrift:"AdItem,4" db:"AdItem" json:"AdItem"` +} + +func NewNotifyPlayroomMood() *NotifyPlayroomMood { + return &NotifyPlayroomMood{} +} + +func (p *NotifyPlayroomMood) GetAllMood() int32 { + return p.AllMood +} + +func (p *NotifyPlayroomMood) GetMood() map[int32]int32 { + return p.Mood +} + +func (p *NotifyPlayroomMood) GetPhysiology() map[int32]int32 { + return p.Physiology +} + +func (p *NotifyPlayroomMood) GetAdItem() []*AdItem { + return p.AdItem +} + +func (p *NotifyPlayroomMood) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.MAP { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.MAP { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.LIST { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *NotifyPlayroomMood) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.AllMood = v + } + return nil +} + +func (p *NotifyPlayroomMood) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.Mood = tMap + for i := 0; i < size; i++ { + var _key68 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key68 = v + } + var _val69 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val69 = v + } + p.Mood[_key68] = _val69 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *NotifyPlayroomMood) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.Physiology = tMap + for i := 0; i < size; i++ { + var _key70 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key70 = v + } + var _val71 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val71 = v + } + p.Physiology[_key70] = _val71 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *NotifyPlayroomMood) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*AdItem, 0, size) + p.AdItem = tSlice + for i := 0; i < size; i++ { + _elem72 := &AdItem{} + if err := _elem72.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem72), err) + } + p.AdItem = append(p.AdItem, _elem72) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *NotifyPlayroomMood) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "NotifyPlayroomMood"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *NotifyPlayroomMood) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "AllMood", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:AllMood: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.AllMood)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.AllMood (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:AllMood: ", p), err) + } + return err +} + +func (p *NotifyPlayroomMood) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Mood", thrift.MAP, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Mood: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.Mood)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Mood { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Mood: ", p), err) + } + return err +} + +func (p *NotifyPlayroomMood) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Physiology", thrift.MAP, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Physiology: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.Physiology)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Physiology { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Physiology: ", p), err) + } + return err +} + +func (p *NotifyPlayroomMood) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "AdItem", thrift.LIST, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:AdItem: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.AdItem)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.AdItem { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:AdItem: ", p), err) + } + return err +} + +func (p *NotifyPlayroomMood) Equals(other *NotifyPlayroomMood) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.AllMood != other.AllMood { + return false + } + if len(p.Mood) != len(other.Mood) { + return false + } + for k, _tgt := range p.Mood { + _src73 := other.Mood[k] + if _tgt != _src73 { + return false + } + } + if len(p.Physiology) != len(other.Physiology) { + return false + } + for k, _tgt := range p.Physiology { + _src74 := other.Physiology[k] + if _tgt != _src74 { + return false + } + } + if len(p.AdItem) != len(other.AdItem) { + return false + } + for i, _tgt := range p.AdItem { + _src75 := other.AdItem[i] + if !_tgt.Equals(_src75) { + return false + } + } + return true +} + +func (p *NotifyPlayroomMood) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("NotifyPlayroomMood(%+v)", *p) +} + +func (p *NotifyPlayroomMood) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.NotifyPlayroomMood", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*NotifyPlayroomMood)(nil) + +func (p *NotifyPlayroomMood) Validate() error { + return nil +} + +// Attributes: +// - DailyTask +// - DailyTaskReward +// +type NotifyPlayroomTask struct { + DailyTask []*DailyTask `thrift:"DailyTask,1" db:"DailyTask" json:"DailyTask"` + DailyTaskReward []int32 `thrift:"DailyTaskReward,2" db:"DailyTaskReward" json:"DailyTaskReward"` +} + +func NewNotifyPlayroomTask() *NotifyPlayroomTask { + return &NotifyPlayroomTask{} +} + +func (p *NotifyPlayroomTask) GetDailyTask() []*DailyTask { + return p.DailyTask +} + +func (p *NotifyPlayroomTask) GetDailyTaskReward() []int32 { + return p.DailyTaskReward +} + +func (p *NotifyPlayroomTask) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.LIST { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *NotifyPlayroomTask) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*DailyTask, 0, size) + p.DailyTask = tSlice + for i := 0; i < size; i++ { + _elem76 := &DailyTask{} + if err := _elem76.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem76), err) + } + p.DailyTask = append(p.DailyTask, _elem76) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *NotifyPlayroomTask) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.DailyTaskReward = tSlice + for i := 0; i < size; i++ { + var _elem77 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem77 = v + } + p.DailyTaskReward = append(p.DailyTaskReward, _elem77) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *NotifyPlayroomTask) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "NotifyPlayroomTask"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *NotifyPlayroomTask) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "DailyTask", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:DailyTask: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.DailyTask)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.DailyTask { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:DailyTask: ", p), err) + } + return err +} + +func (p *NotifyPlayroomTask) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "DailyTaskReward", thrift.LIST, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:DailyTaskReward: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.DailyTaskReward)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.DailyTaskReward { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:DailyTaskReward: ", p), err) + } + return err +} + +func (p *NotifyPlayroomTask) Equals(other *NotifyPlayroomTask) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.DailyTask) != len(other.DailyTask) { + return false + } + for i, _tgt := range p.DailyTask { + _src78 := other.DailyTask[i] + if !_tgt.Equals(_src78) { + return false + } + } + if len(p.DailyTaskReward) != len(other.DailyTaskReward) { + return false + } + for i, _tgt := range p.DailyTaskReward { + _src79 := other.DailyTaskReward[i] + if _tgt != _src79 { + return false + } + } + return true +} + +func (p *NotifyPlayroomTask) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("NotifyPlayroomTask(%+v)", *p) +} + +func (p *NotifyPlayroomTask) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.NotifyPlayroomTask", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*NotifyPlayroomTask)(nil) + +func (p *NotifyPlayroomTask) Validate() error { + return nil +} + +// Attributes: +// - StartTime +// - WorkStatus +// +type NotifyPlayroomWork struct { + StartTime int32 `thrift:"StartTime,1" db:"StartTime" json:"StartTime"` + WorkStatus int32 `thrift:"WorkStatus,2" db:"WorkStatus" json:"WorkStatus"` +} + +func NewNotifyPlayroomWork() *NotifyPlayroomWork { + return &NotifyPlayroomWork{} +} + +func (p *NotifyPlayroomWork) GetStartTime() int32 { + return p.StartTime +} + +func (p *NotifyPlayroomWork) GetWorkStatus() int32 { + return p.WorkStatus +} + +func (p *NotifyPlayroomWork) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *NotifyPlayroomWork) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.StartTime = v + } + return nil +} + +func (p *NotifyPlayroomWork) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.WorkStatus = v + } + return nil +} + +func (p *NotifyPlayroomWork) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "NotifyPlayroomWork"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *NotifyPlayroomWork) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "StartTime", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:StartTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.StartTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.StartTime (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:StartTime: ", p), err) + } + return err +} + +func (p *NotifyPlayroomWork) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "WorkStatus", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:WorkStatus: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.WorkStatus)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.WorkStatus (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:WorkStatus: ", p), err) + } + return err +} + +func (p *NotifyPlayroomWork) Equals(other *NotifyPlayroomWork) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.StartTime != other.StartTime { + return false + } + if p.WorkStatus != other.WorkStatus { + return false + } + return true +} + +func (p *NotifyPlayroomWork) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("NotifyPlayroomWork(%+v)", *p) +} + +func (p *NotifyPlayroomWork) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.NotifyPlayroomWork", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*NotifyPlayroomWork)(nil) + +func (p *NotifyPlayroomWork) Validate() error { + return nil +} + +// Attributes: +// - DwUin +// - CurCnt +// +type NotifyRenewBuyEnergyCnt struct { + DwUin int64 `thrift:"dwUin,1" db:"dwUin" json:"dwUin"` + CurCnt int32 `thrift:"CurCnt,2" db:"CurCnt" json:"CurCnt"` +} + +func NewNotifyRenewBuyEnergyCnt() *NotifyRenewBuyEnergyCnt { + return &NotifyRenewBuyEnergyCnt{} +} + +func (p *NotifyRenewBuyEnergyCnt) GetDwUin() int64 { + return p.DwUin +} + +func (p *NotifyRenewBuyEnergyCnt) GetCurCnt() int32 { + return p.CurCnt +} + +func (p *NotifyRenewBuyEnergyCnt) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *NotifyRenewBuyEnergyCnt) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.DwUin = v + } + return nil +} + +func (p *NotifyRenewBuyEnergyCnt) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.CurCnt = v + } + return nil +} + +func (p *NotifyRenewBuyEnergyCnt) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "NotifyRenewBuyEnergyCnt"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *NotifyRenewBuyEnergyCnt) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "dwUin", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:dwUin: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.DwUin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.dwUin (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:dwUin: ", p), err) + } + return err +} + +func (p *NotifyRenewBuyEnergyCnt) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "CurCnt", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:CurCnt: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.CurCnt)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.CurCnt (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:CurCnt: ", p), err) + } + return err +} + +func (p *NotifyRenewBuyEnergyCnt) Equals(other *NotifyRenewBuyEnergyCnt) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.DwUin != other.DwUin { + return false + } + if p.CurCnt != other.CurCnt { + return false + } + return true +} + +func (p *NotifyRenewBuyEnergyCnt) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("NotifyRenewBuyEnergyCnt(%+v)", *p) +} + +func (p *NotifyRenewBuyEnergyCnt) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.NotifyRenewBuyEnergyCnt", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*NotifyRenewBuyEnergyCnt)(nil) + +func (p *NotifyRenewBuyEnergyCnt) Validate() error { + return nil +} + +// Attributes: +// - Id +// - ChessId +// - Type +// - Items +// +type Order struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + ChessId []int32 `thrift:"ChessId,2" db:"ChessId" json:"ChessId"` + Type int32 `thrift:"type,3" db:"type" json:"type"` + Items []*ItemInfo `thrift:"Items,4" db:"Items" json:"Items"` +} + +func NewOrder() *Order { + return &Order{} +} + +func (p *Order) GetId() int32 { + return p.Id +} + +func (p *Order) GetChessId() []int32 { + return p.ChessId +} + +func (p *Order) GetType() int32 { + return p.Type +} + +func (p *Order) GetItems() []*ItemInfo { + return p.Items +} + +func (p *Order) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.LIST { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.LIST { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *Order) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *Order) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.ChessId = tSlice + for i := 0; i < size; i++ { + var _elem80 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem80 = v + } + p.ChessId = append(p.ChessId, _elem80) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *Order) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *Order) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ItemInfo, 0, size) + p.Items = tSlice + for i := 0; i < size; i++ { + _elem81 := &ItemInfo{} + if err := _elem81.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem81), err) + } + p.Items = append(p.Items, _elem81) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *Order) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "Order"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *Order) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *Order) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChessId", thrift.LIST, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:ChessId: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.ChessId)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.ChessId { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:ChessId: ", p), err) + } + return err +} + +func (p *Order) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "type", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.type (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:type: ", p), err) + } + return err +} + +func (p *Order) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Items", thrift.LIST, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Items: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Items)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Items { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Items: ", p), err) + } + return err +} + +func (p *Order) Equals(other *Order) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if len(p.ChessId) != len(other.ChessId) { + return false + } + for i, _tgt := range p.ChessId { + _src82 := other.ChessId[i] + if _tgt != _src82 { + return false + } + } + if p.Type != other.Type { + return false + } + if len(p.Items) != len(other.Items) { + return false + } + for i, _tgt := range p.Items { + _src83 := other.Items[i] + if !_tgt.Equals(_src83) { + return false + } + } + return true +} + +func (p *Order) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("Order(%+v)", *p) +} + +func (p *Order) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.Order", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*Order)(nil) + +func (p *Order) Validate() error { + return nil +} + +// Attributes: +// - PartBagGrids +// +type PartBag struct { + PartBagGrids []*PartBagGrid `thrift:"PartBagGrids,1" db:"PartBagGrids" json:"PartBagGrids"` +} + +func NewPartBag() *PartBag { + return &PartBag{} +} + +func (p *PartBag) GetPartBagGrids() []*PartBagGrid { + return p.PartBagGrids +} + +func (p *PartBag) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *PartBag) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*PartBagGrid, 0, size) + p.PartBagGrids = tSlice + for i := 0; i < size; i++ { + _elem84 := &PartBagGrid{} + if err := _elem84.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem84), err) + } + p.PartBagGrids = append(p.PartBagGrids, _elem84) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *PartBag) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "PartBag"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *PartBag) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "PartBagGrids", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:PartBagGrids: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.PartBagGrids)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.PartBagGrids { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:PartBagGrids: ", p), err) + } + return err +} + +func (p *PartBag) Equals(other *PartBag) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.PartBagGrids) != len(other.PartBagGrids) { + return false + } + for i, _tgt := range p.PartBagGrids { + _src85 := other.PartBagGrids[i] + if !_tgt.Equals(_src85) { + return false + } + } + return true +} + +func (p *PartBag) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("PartBag(%+v)", *p) +} + +func (p *PartBag) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.PartBag", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*PartBag)(nil) + +func (p *PartBag) Validate() error { + return nil +} + +// Attributes: +// - PartId +// - Count +// +type PartBagGrid struct { + PartId int32 `thrift:"PartId,1" db:"PartId" json:"PartId"` + Count int32 `thrift:"Count,2" db:"Count" json:"Count"` +} + +func NewPartBagGrid() *PartBagGrid { + return &PartBagGrid{} +} + +func (p *PartBagGrid) GetPartId() int32 { + return p.PartId +} + +func (p *PartBagGrid) GetCount() int32 { + return p.Count +} + +func (p *PartBagGrid) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *PartBagGrid) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.PartId = v + } + return nil +} + +func (p *PartBagGrid) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Count = v + } + return nil +} + +func (p *PartBagGrid) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "PartBagGrid"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *PartBagGrid) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "PartId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:PartId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.PartId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.PartId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:PartId: ", p), err) + } + return err +} + +func (p *PartBagGrid) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Count", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Count: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Count)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Count (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Count: ", p), err) + } + return err +} + +func (p *PartBagGrid) Equals(other *PartBagGrid) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.PartId != other.PartId { + return false + } + if p.Count != other.Count { + return false + } + return true +} + +func (p *PartBagGrid) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("PartBagGrid(%+v)", *p) +} + +func (p *PartBagGrid) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.PartBagGrid", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*PartBagGrid)(nil) + +func (p *PartBagGrid) Validate() error { + return nil +} + +// Attributes: +// - Id +// - EndTime +// - AddTime +// - Label +// +type PlayroomAirInfo struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + EndTime int64 `thrift:"EndTime,2" db:"EndTime" json:"EndTime"` + AddTime int64 `thrift:"AddTime,3" db:"AddTime" json:"AddTime"` + Label string `thrift:"Label,4" db:"Label" json:"Label"` +} + +func NewPlayroomAirInfo() *PlayroomAirInfo { + return &PlayroomAirInfo{} +} + +func (p *PlayroomAirInfo) GetId() int32 { + return p.Id +} + +func (p *PlayroomAirInfo) GetEndTime() int64 { + return p.EndTime +} + +func (p *PlayroomAirInfo) GetAddTime() int64 { + return p.AddTime +} + +func (p *PlayroomAirInfo) GetLabel() string { + return p.Label +} + +func (p *PlayroomAirInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I64 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I64 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.STRING { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *PlayroomAirInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *PlayroomAirInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.EndTime = v + } + return nil +} + +func (p *PlayroomAirInfo) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.AddTime = v + } + return nil +} + +func (p *PlayroomAirInfo) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Label = v + } + return nil +} + +func (p *PlayroomAirInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "PlayroomAirInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *PlayroomAirInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *PlayroomAirInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EndTime", thrift.I64, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:EndTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.EndTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EndTime (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:EndTime: ", p), err) + } + return err +} + +func (p *PlayroomAirInfo) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "AddTime", thrift.I64, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:AddTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.AddTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.AddTime (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:AddTime: ", p), err) + } + return err +} + +func (p *PlayroomAirInfo) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Label", thrift.STRING, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Label: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Label)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Label (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Label: ", p), err) + } + return err +} + +func (p *PlayroomAirInfo) Equals(other *PlayroomAirInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.EndTime != other.EndTime { + return false + } + if p.AddTime != other.AddTime { + return false + } + if p.Label != other.Label { + return false + } + return true +} + +func (p *PlayroomAirInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("PlayroomAirInfo(%+v)", *p) +} + +func (p *PlayroomAirInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.PlayroomAirInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*PlayroomAirInfo)(nil) + +func (p *PlayroomAirInfo) Validate() error { + return nil +} + +// Attributes: +// - Id +// - EndTime +// - AddTime +// - Label +// +type PlayroomCollectInfo struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + EndTime int64 `thrift:"EndTime,2" db:"EndTime" json:"EndTime"` + AddTime int64 `thrift:"AddTime,3" db:"AddTime" json:"AddTime"` + Label string `thrift:"Label,4" db:"Label" json:"Label"` +} + +func NewPlayroomCollectInfo() *PlayroomCollectInfo { + return &PlayroomCollectInfo{} +} + +func (p *PlayroomCollectInfo) GetId() int32 { + return p.Id +} + +func (p *PlayroomCollectInfo) GetEndTime() int64 { + return p.EndTime +} + +func (p *PlayroomCollectInfo) GetAddTime() int64 { + return p.AddTime +} + +func (p *PlayroomCollectInfo) GetLabel() string { + return p.Label +} + +func (p *PlayroomCollectInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I64 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I64 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.STRING { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *PlayroomCollectInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *PlayroomCollectInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.EndTime = v + } + return nil +} + +func (p *PlayroomCollectInfo) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.AddTime = v + } + return nil +} + +func (p *PlayroomCollectInfo) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Label = v + } + return nil +} + +func (p *PlayroomCollectInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "PlayroomCollectInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *PlayroomCollectInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *PlayroomCollectInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EndTime", thrift.I64, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:EndTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.EndTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EndTime (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:EndTime: ", p), err) + } + return err +} + +func (p *PlayroomCollectInfo) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "AddTime", thrift.I64, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:AddTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.AddTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.AddTime (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:AddTime: ", p), err) + } + return err +} + +func (p *PlayroomCollectInfo) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Label", thrift.STRING, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Label: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Label)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Label (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Label: ", p), err) + } + return err +} + +func (p *PlayroomCollectInfo) Equals(other *PlayroomCollectInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.EndTime != other.EndTime { + return false + } + if p.AddTime != other.AddTime { + return false + } + if p.Label != other.Label { + return false + } + return true +} + +func (p *PlayroomCollectInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("PlayroomCollectInfo(%+v)", *p) +} + +func (p *PlayroomCollectInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.PlayroomCollectInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*PlayroomCollectInfo)(nil) + +func (p *PlayroomCollectInfo) Validate() error { + return nil +} + +// Attributes: +// - List +// +type PlayroomDress struct { + List []*PlayroomDressInfo `thrift:"List,1" db:"List" json:"List"` +} + +func NewPlayroomDress() *PlayroomDress { + return &PlayroomDress{} +} + +func (p *PlayroomDress) GetList() []*PlayroomDressInfo { + return p.List +} + +func (p *PlayroomDress) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *PlayroomDress) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*PlayroomDressInfo, 0, size) + p.List = tSlice + for i := 0; i < size; i++ { + _elem86 := &PlayroomDressInfo{} + if err := _elem86.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem86), err) + } + p.List = append(p.List, _elem86) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *PlayroomDress) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "PlayroomDress"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *PlayroomDress) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "List", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:List: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.List)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.List { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:List: ", p), err) + } + return err +} + +func (p *PlayroomDress) Equals(other *PlayroomDress) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.List) != len(other.List) { + return false + } + for i, _tgt := range p.List { + _src87 := other.List[i] + if !_tgt.Equals(_src87) { + return false + } + } + return true +} + +func (p *PlayroomDress) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("PlayroomDress(%+v)", *p) +} + +func (p *PlayroomDress) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.PlayroomDress", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*PlayroomDress)(nil) + +func (p *PlayroomDress) Validate() error { + return nil +} + +// Attributes: +// - Id +// - EndTime +// - AddTime +// - Label +// +type PlayroomDressInfo struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + EndTime int64 `thrift:"EndTime,2" db:"EndTime" json:"EndTime"` + AddTime int64 `thrift:"AddTime,3" db:"AddTime" json:"AddTime"` + Label string `thrift:"Label,4" db:"Label" json:"Label"` +} + +func NewPlayroomDressInfo() *PlayroomDressInfo { + return &PlayroomDressInfo{} +} + +func (p *PlayroomDressInfo) GetId() int32 { + return p.Id +} + +func (p *PlayroomDressInfo) GetEndTime() int64 { + return p.EndTime +} + +func (p *PlayroomDressInfo) GetAddTime() int64 { + return p.AddTime +} + +func (p *PlayroomDressInfo) GetLabel() string { + return p.Label +} + +func (p *PlayroomDressInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I64 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I64 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.STRING { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *PlayroomDressInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *PlayroomDressInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.EndTime = v + } + return nil +} + +func (p *PlayroomDressInfo) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.AddTime = v + } + return nil +} + +func (p *PlayroomDressInfo) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Label = v + } + return nil +} + +func (p *PlayroomDressInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "PlayroomDressInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *PlayroomDressInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *PlayroomDressInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EndTime", thrift.I64, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:EndTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.EndTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EndTime (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:EndTime: ", p), err) + } + return err +} + +func (p *PlayroomDressInfo) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "AddTime", thrift.I64, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:AddTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.AddTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.AddTime (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:AddTime: ", p), err) + } + return err +} + +func (p *PlayroomDressInfo) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Label", thrift.STRING, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Label: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Label)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Label (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Label: ", p), err) + } + return err +} + +func (p *PlayroomDressInfo) Equals(other *PlayroomDressInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.EndTime != other.EndTime { + return false + } + if p.AddTime != other.AddTime { + return false + } + if p.Label != other.Label { + return false + } + return true +} + +func (p *PlayroomDressInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("PlayroomDressInfo(%+v)", *p) +} + +func (p *PlayroomDressInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.PlayroomDressInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*PlayroomDressInfo)(nil) + +func (p *PlayroomDressInfo) Validate() error { + return nil +} + +// Attributes: +// - Label +// - Num +// - Target +// - Status +// - Param +// +type QuestProgress struct { + Label string `thrift:"Label,1" db:"Label" json:"Label"` + Num int32 `thrift:"Num,2" db:"Num" json:"Num"` + Target int32 `thrift:"Target,3" db:"Target" json:"Target"` + Status bool `thrift:"Status,4" db:"Status" json:"Status"` + Param int32 `thrift:"Param,5" db:"Param" json:"Param"` +} + +func NewQuestProgress() *QuestProgress { + return &QuestProgress{} +} + +func (p *QuestProgress) GetLabel() string { + return p.Label +} + +func (p *QuestProgress) GetNum() int32 { + return p.Num +} + +func (p *QuestProgress) GetTarget() int32 { + return p.Target +} + +func (p *QuestProgress) GetStatus() bool { + return p.Status +} + +func (p *QuestProgress) GetParam() int32 { + return p.Param +} + +func (p *QuestProgress) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.BOOL { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *QuestProgress) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Label = v + } + return nil +} + +func (p *QuestProgress) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Num = v + } + return nil +} + +func (p *QuestProgress) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Target = v + } + return nil +} + +func (p *QuestProgress) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadBool(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Status = v + } + return nil +} + +func (p *QuestProgress) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.Param = v + } + return nil +} + +func (p *QuestProgress) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "QuestProgress"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *QuestProgress) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Label", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Label: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Label)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Label (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Label: ", p), err) + } + return err +} + +func (p *QuestProgress) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Num", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Num: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Num)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Num (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Num: ", p), err) + } + return err +} + +func (p *QuestProgress) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Target", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Target: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Target)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Target (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Target: ", p), err) + } + return err +} + +func (p *QuestProgress) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Status", thrift.BOOL, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Status: ", p), err) + } + if err := oprot.WriteBool(ctx, bool(p.Status)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Status (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Status: ", p), err) + } + return err +} + +func (p *QuestProgress) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Param", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Param: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Param)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Param (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Param: ", p), err) + } + return err +} + +func (p *QuestProgress) Equals(other *QuestProgress) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Label != other.Label { + return false + } + if p.Num != other.Num { + return false + } + if p.Target != other.Target { + return false + } + if p.Status != other.Status { + return false + } + if p.Param != other.Param { + return false + } + return true +} + +func (p *QuestProgress) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("QuestProgress(%+v)", *p) +} + +func (p *QuestProgress) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.QuestProgress", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*QuestProgress)(nil) + +func (p *QuestProgress) Validate() error { + return nil +} + +// Attributes: +// - Type +// +type RegHandbookAllReward struct { + Type string `thrift:"Type,1" db:"Type" json:"Type"` +} + +func NewRegHandbookAllReward() *RegHandbookAllReward { + return &RegHandbookAllReward{} +} + +func (p *RegHandbookAllReward) GetType() string { + return p.Type +} + +func (p *RegHandbookAllReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *RegHandbookAllReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *RegHandbookAllReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "RegHandbookAllReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *RegHandbookAllReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Type: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Type: ", p), err) + } + return err +} + +func (p *RegHandbookAllReward) Equals(other *RegHandbookAllReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Type != other.Type { + return false + } + return true +} + +func (p *RegHandbookAllReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("RegHandbookAllReward(%+v)", *p) +} + +func (p *RegHandbookAllReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.RegHandbookAllReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*RegHandbookAllReward)(nil) + +func (p *RegHandbookAllReward) Validate() error { + return nil +} + +type ReqActPass struct { +} + +func NewReqActPass() *ReqActPass { + return &ReqActPass{} +} + +func (p *ReqActPass) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqActPass) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqActPass"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqActPass) Equals(other *ReqActPass) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqActPass) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqActPass(%+v)", *p) +} + +func (p *ReqActPass) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqActPass", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqActPass)(nil) + +func (p *ReqActPass) Validate() error { + return nil +} + +type ReqActPassReward struct { +} + +func NewReqActPassReward() *ReqActPassReward { + return &ReqActPassReward{} +} + +func (p *ReqActPassReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqActPassReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqActPassReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqActPassReward) Equals(other *ReqActPassReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqActPassReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqActPassReward(%+v)", *p) +} + +func (p *ReqActPassReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqActPassReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqActPassReward)(nil) + +func (p *ReqActPassReward) Validate() error { + return nil +} + +// Attributes: +// - List +// +type ReqActivityCfgReload struct { + List []*ActivityCfg `thrift:"List,1" db:"List" json:"List"` +} + +func NewReqActivityCfgReload() *ReqActivityCfgReload { + return &ReqActivityCfgReload{} +} + +func (p *ReqActivityCfgReload) GetList() []*ActivityCfg { + return p.List +} + +func (p *ReqActivityCfgReload) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqActivityCfgReload) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ActivityCfg, 0, size) + p.List = tSlice + for i := 0; i < size; i++ { + _elem88 := &ActivityCfg{} + if err := _elem88.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem88), err) + } + p.List = append(p.List, _elem88) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ReqActivityCfgReload) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqActivityCfgReload"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqActivityCfgReload) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "List", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:List: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.List)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.List { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:List: ", p), err) + } + return err +} + +func (p *ReqActivityCfgReload) Equals(other *ReqActivityCfgReload) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.List) != len(other.List) { + return false + } + for i, _tgt := range p.List { + _src89 := other.List[i] + if !_tgt.Equals(_src89) { + return false + } + } + return true +} + +func (p *ReqActivityCfgReload) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqActivityCfgReload(%+v)", *p) +} + +func (p *ReqActivityCfgReload) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqActivityCfgReload", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqActivityCfgReload)(nil) + +func (p *ReqActivityCfgReload) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqActivityReward struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqActivityReward() *ReqActivityReward { + return &ReqActivityReward{} +} + +func (p *ReqActivityReward) GetId() int32 { + return p.Id +} + +func (p *ReqActivityReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqActivityReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqActivityReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqActivityReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqActivityReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqActivityReward) Equals(other *ReqActivityReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqActivityReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqActivityReward(%+v)", *p) +} + +func (p *ReqActivityReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqActivityReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqActivityReward)(nil) + +func (p *ReqActivityReward) Validate() error { + return nil +} + +// Attributes: +// - Type +// +type ReqAdWatch struct { + Type int32 `thrift:"Type,1" db:"Type" json:"Type"` +} + +func NewReqAdWatch() *ReqAdWatch { + return &ReqAdWatch{} +} + +func (p *ReqAdWatch) GetType() int32 { + return p.Type +} + +func (p *ReqAdWatch) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqAdWatch) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ReqAdWatch) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqAdWatch"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqAdWatch) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Type: ", p), err) + } + return err +} + +func (p *ReqAdWatch) Equals(other *ReqAdWatch) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Type != other.Type { + return false + } + return true +} + +func (p *ReqAdWatch) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqAdWatch(%+v)", *p) +} + +func (p *ReqAdWatch) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqAdWatch", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqAdWatch)(nil) + +func (p *ReqAdWatch) Validate() error { + return nil +} + +type ReqAddGiftReward struct { +} + +func NewReqAddGiftReward() *ReqAddGiftReward { + return &ReqAddGiftReward{} +} + +func (p *ReqAddGiftReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqAddGiftReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqAddGiftReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqAddGiftReward) Equals(other *ReqAddGiftReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqAddGiftReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqAddGiftReward(%+v)", *p) +} + +func (p *ReqAddGiftReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqAddGiftReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqAddGiftReward)(nil) + +func (p *ReqAddGiftReward) Validate() error { + return nil +} + +// Attributes: +// - NpcId +// +type ReqAddNpc struct { + NpcId int32 `thrift:"NpcId,1" db:"NpcId" json:"NpcId"` +} + +func NewReqAddNpc() *ReqAddNpc { + return &ReqAddNpc{} +} + +func (p *ReqAddNpc) GetNpcId() int32 { + return p.NpcId +} + +func (p *ReqAddNpc) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqAddNpc) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.NpcId = v + } + return nil +} + +func (p *ReqAddNpc) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqAddNpc"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqAddNpc) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "NpcId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:NpcId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.NpcId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.NpcId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:NpcId: ", p), err) + } + return err +} + +func (p *ReqAddNpc) Equals(other *ReqAddNpc) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.NpcId != other.NpcId { + return false + } + return true +} + +func (p *ReqAddNpc) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqAddNpc(%+v)", *p) +} + +func (p *ReqAddNpc) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqAddNpc", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqAddNpc)(nil) + +func (p *ReqAddNpc) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Type +// +type ReqAddWish struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Type int32 `thrift:"Type,2" db:"Type" json:"Type"` +} + +func NewReqAddWish() *ReqAddWish { + return &ReqAddWish{} +} + +func (p *ReqAddWish) GetId() int32 { + return p.Id +} + +func (p *ReqAddWish) GetType() int32 { + return p.Type +} + +func (p *ReqAddWish) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqAddWish) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqAddWish) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ReqAddWish) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqAddWish"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqAddWish) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqAddWish) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Type: ", p), err) + } + return err +} + +func (p *ReqAddWish) Equals(other *ReqAddWish) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Type != other.Type { + return false + } + return true +} + +func (p *ReqAddWish) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqAddWish(%+v)", *p) +} + +func (p *ReqAddWish) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqAddWish", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqAddWish)(nil) + +func (p *ReqAddWish) Validate() error { + return nil +} + +// Attributes: +// - Uid +// - Time +// - Reason +// +type ReqAdminBan struct { + Uid int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` + Time int64 `thrift:"Time,2" db:"Time" json:"Time"` + Reason string `thrift:"Reason,3" db:"Reason" json:"Reason"` +} + +func NewReqAdminBan() *ReqAdminBan { + return &ReqAdminBan{} +} + +func (p *ReqAdminBan) GetUid() int64 { + return p.Uid +} + +func (p *ReqAdminBan) GetTime() int64 { + return p.Time +} + +func (p *ReqAdminBan) GetReason() string { + return p.Reason +} + +func (p *ReqAdminBan) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I64 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.STRING { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqAdminBan) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ReqAdminBan) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Time = v + } + return nil +} + +func (p *ReqAdminBan) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Reason = v + } + return nil +} + +func (p *ReqAdminBan) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqAdminBan"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqAdminBan) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *ReqAdminBan) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Time", thrift.I64, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Time: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Time)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Time (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Time: ", p), err) + } + return err +} + +func (p *ReqAdminBan) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Reason", thrift.STRING, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Reason: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Reason)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Reason (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Reason: ", p), err) + } + return err +} + +func (p *ReqAdminBan) Equals(other *ReqAdminBan) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Uid != other.Uid { + return false + } + if p.Time != other.Time { + return false + } + if p.Reason != other.Reason { + return false + } + return true +} + +func (p *ReqAdminBan) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqAdminBan(%+v)", *p) +} + +func (p *ReqAdminBan) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqAdminBan", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqAdminBan)(nil) + +func (p *ReqAdminBan) Validate() error { + return nil +} + +// Attributes: +// - Uid +// - Command +// +type ReqAdminGm struct { + Uid int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` + Command string `thrift:"Command,2" db:"Command" json:"Command"` +} + +func NewReqAdminGm() *ReqAdminGm { + return &ReqAdminGm{} +} + +func (p *ReqAdminGm) GetUid() int64 { + return p.Uid +} + +func (p *ReqAdminGm) GetCommand() string { + return p.Command +} + +func (p *ReqAdminGm) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqAdminGm) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ReqAdminGm) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Command = v + } + return nil +} + +func (p *ReqAdminGm) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqAdminGm"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqAdminGm) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *ReqAdminGm) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Command", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Command: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Command)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Command (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Command: ", p), err) + } + return err +} + +func (p *ReqAdminGm) Equals(other *ReqAdminGm) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Uid != other.Uid { + return false + } + if p.Command != other.Command { + return false + } + return true +} + +func (p *ReqAdminGm) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqAdminGm(%+v)", *p) +} + +func (p *ReqAdminGm) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqAdminGm", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqAdminGm)(nil) + +func (p *ReqAdminGm) Validate() error { + return nil +} + +// Attributes: +// - Uid +// +type ReqAdminInfo struct { + Uid int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` +} + +func NewReqAdminInfo() *ReqAdminInfo { + return &ReqAdminInfo{} +} + +func (p *ReqAdminInfo) GetUid() int64 { + return p.Uid +} + +func (p *ReqAdminInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqAdminInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ReqAdminInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqAdminInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqAdminInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *ReqAdminInfo) Equals(other *ReqAdminInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Uid != other.Uid { + return false + } + return true +} + +func (p *ReqAdminInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqAdminInfo(%+v)", *p) +} + +func (p *ReqAdminInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqAdminInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqAdminInfo)(nil) + +func (p *ReqAdminInfo) Validate() error { + return nil +} + +// Attributes: +// - OrderSn +// - Status +// - ChannelOrderSn +// +type ReqAdminShipping struct { + OrderSn string `thrift:"OrderSn,1" db:"OrderSn" json:"OrderSn"` + Status int32 `thrift:"Status,2" db:"Status" json:"Status"` + ChannelOrderSn string `thrift:"ChannelOrderSn,3" db:"ChannelOrderSn" json:"ChannelOrderSn"` +} + +func NewReqAdminShipping() *ReqAdminShipping { + return &ReqAdminShipping{} +} + +func (p *ReqAdminShipping) GetOrderSn() string { + return p.OrderSn +} + +func (p *ReqAdminShipping) GetStatus() int32 { + return p.Status +} + +func (p *ReqAdminShipping) GetChannelOrderSn() string { + return p.ChannelOrderSn +} + +func (p *ReqAdminShipping) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.STRING { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqAdminShipping) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.OrderSn = v + } + return nil +} + +func (p *ReqAdminShipping) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Status = v + } + return nil +} + +func (p *ReqAdminShipping) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.ChannelOrderSn = v + } + return nil +} + +func (p *ReqAdminShipping) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqAdminShipping"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqAdminShipping) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "OrderSn", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:OrderSn: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.OrderSn)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.OrderSn (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:OrderSn: ", p), err) + } + return err +} + +func (p *ReqAdminShipping) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Status", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Status: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Status)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Status (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Status: ", p), err) + } + return err +} + +func (p *ReqAdminShipping) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChannelOrderSn", thrift.STRING, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:ChannelOrderSn: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.ChannelOrderSn)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ChannelOrderSn (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:ChannelOrderSn: ", p), err) + } + return err +} + +func (p *ReqAdminShipping) Equals(other *ReqAdminShipping) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.OrderSn != other.OrderSn { + return false + } + if p.Status != other.Status { + return false + } + if p.ChannelOrderSn != other.ChannelOrderSn { + return false + } + return true +} + +func (p *ReqAdminShipping) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqAdminShipping(%+v)", *p) +} + +func (p *ReqAdminShipping) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqAdminShipping", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqAdminShipping)(nil) + +func (p *ReqAdminShipping) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqAgreeCardExchange struct { + Id string `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqAgreeCardExchange() *ReqAgreeCardExchange { + return &ReqAgreeCardExchange{} +} + +func (p *ReqAgreeCardExchange) GetId() string { + return p.Id +} + +func (p *ReqAgreeCardExchange) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqAgreeCardExchange) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqAgreeCardExchange) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqAgreeCardExchange"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqAgreeCardExchange) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqAgreeCardExchange) Equals(other *ReqAgreeCardExchange) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqAgreeCardExchange) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqAgreeCardExchange(%+v)", *p) +} + +func (p *ReqAgreeCardExchange) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqAgreeCardExchange", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqAgreeCardExchange)(nil) + +func (p *ReqAgreeCardExchange) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqAgreeCardGive struct { + Id string `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqAgreeCardGive() *ReqAgreeCardGive { + return &ReqAgreeCardGive{} +} + +func (p *ReqAgreeCardGive) GetId() string { + return p.Id +} + +func (p *ReqAgreeCardGive) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqAgreeCardGive) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqAgreeCardGive) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqAgreeCardGive"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqAgreeCardGive) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqAgreeCardGive) Equals(other *ReqAgreeCardGive) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqAgreeCardGive) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqAgreeCardGive(%+v)", *p) +} + +func (p *ReqAgreeCardGive) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqAgreeCardGive", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqAgreeCardGive)(nil) + +func (p *ReqAgreeCardGive) Validate() error { + return nil +} + +// Attributes: +// - Uid +// +type ReqAgreeFriend struct { + Uid int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` +} + +func NewReqAgreeFriend() *ReqAgreeFriend { + return &ReqAgreeFriend{} +} + +func (p *ReqAgreeFriend) GetUid() int64 { + return p.Uid +} + +func (p *ReqAgreeFriend) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqAgreeFriend) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ReqAgreeFriend) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqAgreeFriend"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqAgreeFriend) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *ReqAgreeFriend) Equals(other *ReqAgreeFriend) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Uid != other.Uid { + return false + } + return true +} + +func (p *ReqAgreeFriend) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqAgreeFriend(%+v)", *p) +} + +func (p *ReqAgreeFriend) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqAgreeFriend", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqAgreeFriend)(nil) + +func (p *ReqAgreeFriend) Validate() error { + return nil +} + +type ReqAllCollectReward struct { +} + +func NewReqAllCollectReward() *ReqAllCollectReward { + return &ReqAllCollectReward{} +} + +func (p *ReqAllCollectReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqAllCollectReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqAllCollectReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqAllCollectReward) Equals(other *ReqAllCollectReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqAllCollectReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqAllCollectReward(%+v)", *p) +} + +func (p *ReqAllCollectReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqAllCollectReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqAllCollectReward)(nil) + +func (p *ReqAllCollectReward) Validate() error { + return nil +} + +// Attributes: +// - Uid +// - Type +// +type ReqApplyFriend struct { + Uid int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` + Type int32 `thrift:"Type,2" db:"Type" json:"Type"` +} + +func NewReqApplyFriend() *ReqApplyFriend { + return &ReqApplyFriend{} +} + +func (p *ReqApplyFriend) GetUid() int64 { + return p.Uid +} + +func (p *ReqApplyFriend) GetType() int32 { + return p.Type +} + +func (p *ReqApplyFriend) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqApplyFriend) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ReqApplyFriend) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ReqApplyFriend) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqApplyFriend"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqApplyFriend) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *ReqApplyFriend) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Type: ", p), err) + } + return err +} + +func (p *ReqApplyFriend) Equals(other *ReqApplyFriend) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Uid != other.Uid { + return false + } + if p.Type != other.Type { + return false + } + return true +} + +func (p *ReqApplyFriend) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqApplyFriend(%+v)", *p) +} + +func (p *ReqApplyFriend) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqApplyFriend", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqApplyFriend)(nil) + +func (p *ReqApplyFriend) Validate() error { + return nil +} + +// Attributes: +// - AreaId +// +type ReqAreaReward struct { + AreaId int32 `thrift:"AreaId,1" db:"AreaId" json:"AreaId"` +} + +func NewReqAreaReward() *ReqAreaReward { + return &ReqAreaReward{} +} + +func (p *ReqAreaReward) GetAreaId() int32 { + return p.AreaId +} + +func (p *ReqAreaReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqAreaReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.AreaId = v + } + return nil +} + +func (p *ReqAreaReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqAreaReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqAreaReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "AreaId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:AreaId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.AreaId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.AreaId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:AreaId: ", p), err) + } + return err +} + +func (p *ReqAreaReward) Equals(other *ReqAreaReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.AreaId != other.AreaId { + return false + } + return true +} + +func (p *ReqAreaReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqAreaReward(%+v)", *p) +} + +func (p *ReqAreaReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqAreaReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqAreaReward)(nil) + +func (p *ReqAreaReward) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqAutoAddInviteFriend struct { + Id int64 `thrift:"id,1" db:"id" json:"id"` +} + +func NewReqAutoAddInviteFriend() *ReqAutoAddInviteFriend { + return &ReqAutoAddInviteFriend{} +} + +func (p *ReqAutoAddInviteFriend) GetId() int64 { + return p.Id +} + +func (p *ReqAutoAddInviteFriend) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqAutoAddInviteFriend) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqAutoAddInviteFriend) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqAutoAddInviteFriend"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqAutoAddInviteFriend) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "id", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:id: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:id: ", p), err) + } + return err +} + +func (p *ReqAutoAddInviteFriend) Equals(other *ReqAutoAddInviteFriend) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqAutoAddInviteFriend) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqAutoAddInviteFriend(%+v)", *p) +} + +func (p *ReqAutoAddInviteFriend) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqAutoAddInviteFriend", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqAutoAddInviteFriend)(nil) + +func (p *ReqAutoAddInviteFriend) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqAutoAddInviteFriend2 struct { + Id string `thrift:"id,1" db:"id" json:"id"` +} + +func NewReqAutoAddInviteFriend2() *ReqAutoAddInviteFriend2 { + return &ReqAutoAddInviteFriend2{} +} + +func (p *ReqAutoAddInviteFriend2) GetId() string { + return p.Id +} + +func (p *ReqAutoAddInviteFriend2) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqAutoAddInviteFriend2) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqAutoAddInviteFriend2) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqAutoAddInviteFriend2"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqAutoAddInviteFriend2) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "id", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:id: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:id: ", p), err) + } + return err +} + +func (p *ReqAutoAddInviteFriend2) Equals(other *ReqAutoAddInviteFriend2) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqAutoAddInviteFriend2) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqAutoAddInviteFriend2(%+v)", *p) +} + +func (p *ReqAutoAddInviteFriend2) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqAutoAddInviteFriend2", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqAutoAddInviteFriend2)(nil) + +func (p *ReqAutoAddInviteFriend2) Validate() error { + return nil +} + +// Attributes: +// - DwUin +// - BindAccountId +// +type ReqBindFacebookAccount struct { + DwUin int64 `thrift:"dwUin,1" db:"dwUin" json:"dwUin"` + BindAccountId string `thrift:"BindAccountId,2" db:"BindAccountId" json:"BindAccountId"` +} + +func NewReqBindFacebookAccount() *ReqBindFacebookAccount { + return &ReqBindFacebookAccount{} +} + +func (p *ReqBindFacebookAccount) GetDwUin() int64 { + return p.DwUin +} + +func (p *ReqBindFacebookAccount) GetBindAccountId() string { + return p.BindAccountId +} + +func (p *ReqBindFacebookAccount) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqBindFacebookAccount) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.DwUin = v + } + return nil +} + +func (p *ReqBindFacebookAccount) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.BindAccountId = v + } + return nil +} + +func (p *ReqBindFacebookAccount) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqBindFacebookAccount"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqBindFacebookAccount) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "dwUin", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:dwUin: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.DwUin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.dwUin (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:dwUin: ", p), err) + } + return err +} + +func (p *ReqBindFacebookAccount) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "BindAccountId", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:BindAccountId: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.BindAccountId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.BindAccountId (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:BindAccountId: ", p), err) + } + return err +} + +func (p *ReqBindFacebookAccount) Equals(other *ReqBindFacebookAccount) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.DwUin != other.DwUin { + return false + } + if p.BindAccountId != other.BindAccountId { + return false + } + return true +} + +func (p *ReqBindFacebookAccount) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqBindFacebookAccount(%+v)", *p) +} + +func (p *ReqBindFacebookAccount) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqBindFacebookAccount", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqBindFacebookAccount)(nil) + +func (p *ReqBindFacebookAccount) Validate() error { + return nil +} + +type ReqBuyChessBagGrid struct { +} + +func NewReqBuyChessBagGrid() *ReqBuyChessBagGrid { + return &ReqBuyChessBagGrid{} +} + +func (p *ReqBuyChessBagGrid) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqBuyChessBagGrid) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqBuyChessBagGrid"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqBuyChessBagGrid) Equals(other *ReqBuyChessBagGrid) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqBuyChessBagGrid) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqBuyChessBagGrid(%+v)", *p) +} + +func (p *ReqBuyChessBagGrid) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqBuyChessBagGrid", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqBuyChessBagGrid)(nil) + +func (p *ReqBuyChessBagGrid) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqBuyChessShop struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqBuyChessShop() *ReqBuyChessShop { + return &ReqBuyChessShop{} +} + +func (p *ReqBuyChessShop) GetId() int32 { + return p.Id +} + +func (p *ReqBuyChessShop) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqBuyChessShop) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqBuyChessShop) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqBuyChessShop"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqBuyChessShop) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqBuyChessShop) Equals(other *ReqBuyChessShop) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqBuyChessShop) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqBuyChessShop(%+v)", *p) +} + +func (p *ReqBuyChessShop) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqBuyChessShop", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqBuyChessShop)(nil) + +func (p *ReqBuyChessShop) Validate() error { + return nil +} + +// Attributes: +// - Id +// - MChessData +// +type ReqBuyChessShop2 struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + MChessData map[string]int32 `thrift:"MChessData,2" db:"MChessData" json:"MChessData"` +} + +func NewReqBuyChessShop2() *ReqBuyChessShop2 { + return &ReqBuyChessShop2{} +} + +func (p *ReqBuyChessShop2) GetId() int32 { + return p.Id +} + +func (p *ReqBuyChessShop2) GetMChessData() map[string]int32 { + return p.MChessData +} + +func (p *ReqBuyChessShop2) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.MAP { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqBuyChessShop2) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqBuyChessShop2) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[string]int32, size) + p.MChessData = tMap + for i := 0; i < size; i++ { + var _key90 string + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key90 = v + } + var _val91 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val91 = v + } + p.MChessData[_key90] = _val91 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ReqBuyChessShop2) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqBuyChessShop2"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqBuyChessShop2) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqBuyChessShop2) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MChessData", thrift.MAP, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:MChessData: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.STRING, thrift.I32, len(p.MChessData)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.MChessData { + if err := oprot.WriteString(ctx, string(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:MChessData: ", p), err) + } + return err +} + +func (p *ReqBuyChessShop2) Equals(other *ReqBuyChessShop2) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if len(p.MChessData) != len(other.MChessData) { + return false + } + for k, _tgt := range p.MChessData { + _src92 := other.MChessData[k] + if _tgt != _src92 { + return false + } + } + return true +} + +func (p *ReqBuyChessShop2) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqBuyChessShop2(%+v)", *p) +} + +func (p *ReqBuyChessShop2) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqBuyChessShop2", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqBuyChessShop2)(nil) + +func (p *ReqBuyChessShop2) Validate() error { + return nil +} + +// Attributes: +// - Energy +// +type ReqBuyEnergy struct { + Energy int32 `thrift:"Energy,1" db:"Energy" json:"Energy"` +} + +func NewReqBuyEnergy() *ReqBuyEnergy { + return &ReqBuyEnergy{} +} + +func (p *ReqBuyEnergy) GetEnergy() int32 { + return p.Energy +} + +func (p *ReqBuyEnergy) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqBuyEnergy) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Energy = v + } + return nil +} + +func (p *ReqBuyEnergy) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqBuyEnergy"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqBuyEnergy) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Energy", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Energy: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Energy)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Energy (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Energy: ", p), err) + } + return err +} + +func (p *ReqBuyEnergy) Equals(other *ReqBuyEnergy) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Energy != other.Energy { + return false + } + return true +} + +func (p *ReqBuyEnergy) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqBuyEnergy(%+v)", *p) +} + +func (p *ReqBuyEnergy) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqBuyEnergy", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqBuyEnergy)(nil) + +func (p *ReqBuyEnergy) Validate() error { + return nil +} + +// Attributes: +// - Color +// +type ReqCardCollectReward struct { + Color int32 `thrift:"Color,1" db:"Color" json:"Color"` +} + +func NewReqCardCollectReward() *ReqCardCollectReward { + return &ReqCardCollectReward{} +} + +func (p *ReqCardCollectReward) GetColor() int32 { + return p.Color +} + +func (p *ReqCardCollectReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqCardCollectReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Color = v + } + return nil +} + +func (p *ReqCardCollectReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqCardCollectReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqCardCollectReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Color", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Color: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Color)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Color (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Color: ", p), err) + } + return err +} + +func (p *ReqCardCollectReward) Equals(other *ReqCardCollectReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Color != other.Color { + return false + } + return true +} + +func (p *ReqCardCollectReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqCardCollectReward(%+v)", *p) +} + +func (p *ReqCardCollectReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqCardCollectReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqCardCollectReward)(nil) + +func (p *ReqCardCollectReward) Validate() error { + return nil +} + +// Attributes: +// - Uid +// - CardId +// - Emoji +// +type ReqCardExchange struct { + Uid int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` + CardId int32 `thrift:"CardId,2" db:"CardId" json:"CardId"` + Emoji int32 `thrift:"Emoji,3" db:"Emoji" json:"Emoji"` +} + +func NewReqCardExchange() *ReqCardExchange { + return &ReqCardExchange{} +} + +func (p *ReqCardExchange) GetUid() int64 { + return p.Uid +} + +func (p *ReqCardExchange) GetCardId() int32 { + return p.CardId +} + +func (p *ReqCardExchange) GetEmoji() int32 { + return p.Emoji +} + +func (p *ReqCardExchange) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqCardExchange) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ReqCardExchange) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.CardId = v + } + return nil +} + +func (p *ReqCardExchange) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Emoji = v + } + return nil +} + +func (p *ReqCardExchange) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqCardExchange"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqCardExchange) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *ReqCardExchange) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "CardId", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:CardId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.CardId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.CardId (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:CardId: ", p), err) + } + return err +} + +func (p *ReqCardExchange) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Emoji", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Emoji: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Emoji)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Emoji (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Emoji: ", p), err) + } + return err +} + +func (p *ReqCardExchange) Equals(other *ReqCardExchange) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Uid != other.Uid { + return false + } + if p.CardId != other.CardId { + return false + } + if p.Emoji != other.Emoji { + return false + } + return true +} + +func (p *ReqCardExchange) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqCardExchange(%+v)", *p) +} + +func (p *ReqCardExchange) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqCardExchange", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqCardExchange)(nil) + +func (p *ReqCardExchange) Validate() error { + return nil +} + +// Attributes: +// - Uid +// - CardId +// +type ReqCardGive struct { + Uid []int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` + CardId int32 `thrift:"CardId,2" db:"CardId" json:"CardId"` +} + +func NewReqCardGive() *ReqCardGive { + return &ReqCardGive{} +} + +func (p *ReqCardGive) GetUid() []int64 { + return p.Uid +} + +func (p *ReqCardGive) GetCardId() int32 { + return p.CardId +} + +func (p *ReqCardGive) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqCardGive) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int64, 0, size) + p.Uid = tSlice + for i := 0; i < size; i++ { + var _elem93 int64 + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem93 = v + } + p.Uid = append(p.Uid, _elem93) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ReqCardGive) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.CardId = v + } + return nil +} + +func (p *ReqCardGive) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqCardGive"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqCardGive) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I64, len(p.Uid)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Uid { + if err := oprot.WriteI64(ctx, int64(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *ReqCardGive) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "CardId", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:CardId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.CardId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.CardId (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:CardId: ", p), err) + } + return err +} + +func (p *ReqCardGive) Equals(other *ReqCardGive) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.Uid) != len(other.Uid) { + return false + } + for i, _tgt := range p.Uid { + _src94 := other.Uid[i] + if _tgt != _src94 { + return false + } + } + if p.CardId != other.CardId { + return false + } + return true +} + +func (p *ReqCardGive) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqCardGive(%+v)", *p) +} + +func (p *ReqCardGive) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqCardGive", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqCardGive)(nil) + +func (p *ReqCardGive) Validate() error { + return nil +} + +// Attributes: +// - CardId +// +type ReqCardHandbookReward struct { + CardId int32 `thrift:"CardId,1" db:"CardId" json:"CardId"` +} + +func NewReqCardHandbookReward() *ReqCardHandbookReward { + return &ReqCardHandbookReward{} +} + +func (p *ReqCardHandbookReward) GetCardId() int32 { + return p.CardId +} + +func (p *ReqCardHandbookReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqCardHandbookReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.CardId = v + } + return nil +} + +func (p *ReqCardHandbookReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqCardHandbookReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqCardHandbookReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "CardId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:CardId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.CardId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.CardId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:CardId: ", p), err) + } + return err +} + +func (p *ReqCardHandbookReward) Equals(other *ReqCardHandbookReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.CardId != other.CardId { + return false + } + return true +} + +func (p *ReqCardHandbookReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqCardHandbookReward(%+v)", *p) +} + +func (p *ReqCardHandbookReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqCardHandbookReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqCardHandbookReward)(nil) + +func (p *ReqCardHandbookReward) Validate() error { + return nil +} + +type ReqCardInfo struct { +} + +func NewReqCardInfo() *ReqCardInfo { + return &ReqCardInfo{} +} + +func (p *ReqCardInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqCardInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqCardInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqCardInfo) Equals(other *ReqCardInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqCardInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqCardInfo(%+v)", *p) +} + +func (p *ReqCardInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqCardInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqCardInfo)(nil) + +func (p *ReqCardInfo) Validate() error { + return nil +} + +type ReqCardSeasonFirstReward struct { +} + +func NewReqCardSeasonFirstReward() *ReqCardSeasonFirstReward { + return &ReqCardSeasonFirstReward{} +} + +func (p *ReqCardSeasonFirstReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqCardSeasonFirstReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqCardSeasonFirstReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqCardSeasonFirstReward) Equals(other *ReqCardSeasonFirstReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqCardSeasonFirstReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqCardSeasonFirstReward(%+v)", *p) +} + +func (p *ReqCardSeasonFirstReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqCardSeasonFirstReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqCardSeasonFirstReward)(nil) + +func (p *ReqCardSeasonFirstReward) Validate() error { + return nil +} + +// Attributes: +// - Uid +// - CardId +// - Emoji +// +type ReqCardSend struct { + Uid int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` + CardId int32 `thrift:"CardId,2" db:"CardId" json:"CardId"` + Emoji int32 `thrift:"Emoji,3" db:"Emoji" json:"Emoji"` +} + +func NewReqCardSend() *ReqCardSend { + return &ReqCardSend{} +} + +func (p *ReqCardSend) GetUid() int64 { + return p.Uid +} + +func (p *ReqCardSend) GetCardId() int32 { + return p.CardId +} + +func (p *ReqCardSend) GetEmoji() int32 { + return p.Emoji +} + +func (p *ReqCardSend) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqCardSend) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ReqCardSend) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.CardId = v + } + return nil +} + +func (p *ReqCardSend) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Emoji = v + } + return nil +} + +func (p *ReqCardSend) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqCardSend"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqCardSend) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *ReqCardSend) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "CardId", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:CardId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.CardId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.CardId (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:CardId: ", p), err) + } + return err +} + +func (p *ReqCardSend) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Emoji", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Emoji: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Emoji)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Emoji (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Emoji: ", p), err) + } + return err +} + +func (p *ReqCardSend) Equals(other *ReqCardSend) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Uid != other.Uid { + return false + } + if p.CardId != other.CardId { + return false + } + if p.Emoji != other.Emoji { + return false + } + return true +} + +func (p *ReqCardSend) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqCardSend(%+v)", *p) +} + +func (p *ReqCardSend) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqCardSend", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqCardSend)(nil) + +func (p *ReqCardSend) Validate() error { + return nil +} + +type ReqCatReturnGift struct { +} + +func NewReqCatReturnGift() *ReqCatReturnGift { + return &ReqCatReturnGift{} +} + +func (p *ReqCatReturnGift) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqCatReturnGift) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqCatReturnGift"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqCatReturnGift) Equals(other *ReqCatReturnGift) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqCatReturnGift) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqCatReturnGift(%+v)", *p) +} + +func (p *ReqCatReturnGift) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqCatReturnGift", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqCatReturnGift)(nil) + +func (p *ReqCatReturnGift) Validate() error { + return nil +} + +type ReqCatReturnGiftReward struct { +} + +func NewReqCatReturnGiftReward() *ReqCatReturnGiftReward { + return &ReqCatReturnGiftReward{} +} + +func (p *ReqCatReturnGiftReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqCatReturnGiftReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqCatReturnGiftReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqCatReturnGiftReward) Equals(other *ReqCatReturnGiftReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqCatReturnGiftReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqCatReturnGiftReward(%+v)", *p) +} + +func (p *ReqCatReturnGiftReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqCatReturnGiftReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqCatReturnGiftReward)(nil) + +func (p *ReqCatReturnGiftReward) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqCatReturnGiftRewardGift struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqCatReturnGiftRewardGift() *ReqCatReturnGiftRewardGift { + return &ReqCatReturnGiftRewardGift{} +} + +func (p *ReqCatReturnGiftRewardGift) GetId() int32 { + return p.Id +} + +func (p *ReqCatReturnGiftRewardGift) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqCatReturnGiftRewardGift) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqCatReturnGiftRewardGift) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqCatReturnGiftRewardGift"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqCatReturnGiftRewardGift) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqCatReturnGiftRewardGift) Equals(other *ReqCatReturnGiftRewardGift) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqCatReturnGiftRewardGift) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqCatReturnGiftRewardGift(%+v)", *p) +} + +func (p *ReqCatReturnGiftRewardGift) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqCatReturnGiftRewardGift", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqCatReturnGiftRewardGift)(nil) + +func (p *ReqCatReturnGiftRewardGift) Validate() error { + return nil +} + +// Attributes: +// - Score +// +type ReqCatReturnGiftScore struct { + Score int32 `thrift:"Score,1" db:"Score" json:"Score"` +} + +func NewReqCatReturnGiftScore() *ReqCatReturnGiftScore { + return &ReqCatReturnGiftScore{} +} + +func (p *ReqCatReturnGiftScore) GetScore() int32 { + return p.Score +} + +func (p *ReqCatReturnGiftScore) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqCatReturnGiftScore) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Score = v + } + return nil +} + +func (p *ReqCatReturnGiftScore) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqCatReturnGiftScore"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqCatReturnGiftScore) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Score", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Score: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Score)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Score (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Score: ", p), err) + } + return err +} + +func (p *ReqCatReturnGiftScore) Equals(other *ReqCatReturnGiftScore) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Score != other.Score { + return false + } + return true +} + +func (p *ReqCatReturnGiftScore) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqCatReturnGiftScore(%+v)", *p) +} + +func (p *ReqCatReturnGiftScore) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqCatReturnGiftScore", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqCatReturnGiftScore)(nil) + +func (p *ReqCatReturnGiftScore) Validate() error { + return nil +} + +type ReqCatTrickReward struct { +} + +func NewReqCatTrickReward() *ReqCatTrickReward { + return &ReqCatTrickReward{} +} + +func (p *ReqCatTrickReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqCatTrickReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqCatTrickReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqCatTrickReward) Equals(other *ReqCatTrickReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqCatTrickReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqCatTrickReward(%+v)", *p) +} + +func (p *ReqCatTrickReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqCatTrickReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqCatTrickReward)(nil) + +func (p *ReqCatTrickReward) Validate() error { + return nil +} + +type ReqCatnip struct { +} + +func NewReqCatnip() *ReqCatnip { + return &ReqCatnip{} +} + +func (p *ReqCatnip) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqCatnip) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqCatnip"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqCatnip) Equals(other *ReqCatnip) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqCatnip) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqCatnip(%+v)", *p) +} + +func (p *ReqCatnip) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqCatnip", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqCatnip)(nil) + +func (p *ReqCatnip) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Uid +// +type ReqCatnipAgree struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Uid int64 `thrift:"Uid,2" db:"Uid" json:"Uid"` +} + +func NewReqCatnipAgree() *ReqCatnipAgree { + return &ReqCatnipAgree{} +} + +func (p *ReqCatnipAgree) GetId() int32 { + return p.Id +} + +func (p *ReqCatnipAgree) GetUid() int64 { + return p.Uid +} + +func (p *ReqCatnipAgree) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I64 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqCatnipAgree) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqCatnipAgree) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ReqCatnipAgree) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqCatnipAgree"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqCatnipAgree) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqCatnipAgree) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Uid: ", p), err) + } + return err +} + +func (p *ReqCatnipAgree) Equals(other *ReqCatnipAgree) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Uid != other.Uid { + return false + } + return true +} + +func (p *ReqCatnipAgree) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqCatnipAgree(%+v)", *p) +} + +func (p *ReqCatnipAgree) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqCatnipAgree", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqCatnipAgree)(nil) + +func (p *ReqCatnipAgree) Validate() error { + return nil +} + +// Attributes: +// - Id +// - EmojiId +// +type ReqCatnipEmoji struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + EmojiId int32 `thrift:"EmojiId,2" db:"EmojiId" json:"EmojiId"` +} + +func NewReqCatnipEmoji() *ReqCatnipEmoji { + return &ReqCatnipEmoji{} +} + +func (p *ReqCatnipEmoji) GetId() int32 { + return p.Id +} + +func (p *ReqCatnipEmoji) GetEmojiId() int32 { + return p.EmojiId +} + +func (p *ReqCatnipEmoji) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqCatnipEmoji) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqCatnipEmoji) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.EmojiId = v + } + return nil +} + +func (p *ReqCatnipEmoji) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqCatnipEmoji"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqCatnipEmoji) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqCatnipEmoji) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EmojiId", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:EmojiId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.EmojiId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EmojiId (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:EmojiId: ", p), err) + } + return err +} + +func (p *ReqCatnipEmoji) Equals(other *ReqCatnipEmoji) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.EmojiId != other.EmojiId { + return false + } + return true +} + +func (p *ReqCatnipEmoji) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqCatnipEmoji(%+v)", *p) +} + +func (p *ReqCatnipEmoji) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqCatnipEmoji", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqCatnipEmoji)(nil) + +func (p *ReqCatnipEmoji) Validate() error { + return nil +} + +type ReqCatnipGrandReward struct { +} + +func NewReqCatnipGrandReward() *ReqCatnipGrandReward { + return &ReqCatnipGrandReward{} +} + +func (p *ReqCatnipGrandReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqCatnipGrandReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqCatnipGrandReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqCatnipGrandReward) Equals(other *ReqCatnipGrandReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqCatnipGrandReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqCatnipGrandReward(%+v)", *p) +} + +func (p *ReqCatnipGrandReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqCatnipGrandReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqCatnipGrandReward)(nil) + +func (p *ReqCatnipGrandReward) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Uid +// +type ReqCatnipInvite struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Uid int64 `thrift:"Uid,2" db:"Uid" json:"Uid"` +} + +func NewReqCatnipInvite() *ReqCatnipInvite { + return &ReqCatnipInvite{} +} + +func (p *ReqCatnipInvite) GetId() int32 { + return p.Id +} + +func (p *ReqCatnipInvite) GetUid() int64 { + return p.Uid +} + +func (p *ReqCatnipInvite) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I64 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqCatnipInvite) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqCatnipInvite) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ReqCatnipInvite) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqCatnipInvite"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqCatnipInvite) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqCatnipInvite) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Uid: ", p), err) + } + return err +} + +func (p *ReqCatnipInvite) Equals(other *ReqCatnipInvite) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Uid != other.Uid { + return false + } + return true +} + +func (p *ReqCatnipInvite) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqCatnipInvite(%+v)", *p) +} + +func (p *ReqCatnipInvite) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqCatnipInvite", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqCatnipInvite)(nil) + +func (p *ReqCatnipInvite) Validate() error { + return nil +} + +// Attributes: +// - Multiply +// +type ReqCatnipMultiply struct { + Multiply int32 `thrift:"Multiply,1" db:"Multiply" json:"Multiply"` +} + +func NewReqCatnipMultiply() *ReqCatnipMultiply { + return &ReqCatnipMultiply{} +} + +func (p *ReqCatnipMultiply) GetMultiply() int32 { + return p.Multiply +} + +func (p *ReqCatnipMultiply) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqCatnipMultiply) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Multiply = v + } + return nil +} + +func (p *ReqCatnipMultiply) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqCatnipMultiply"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqCatnipMultiply) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Multiply", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Multiply: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Multiply)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Multiply (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Multiply: ", p), err) + } + return err +} + +func (p *ReqCatnipMultiply) Equals(other *ReqCatnipMultiply) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Multiply != other.Multiply { + return false + } + return true +} + +func (p *ReqCatnipMultiply) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqCatnipMultiply(%+v)", *p) +} + +func (p *ReqCatnipMultiply) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqCatnipMultiply", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqCatnipMultiply)(nil) + +func (p *ReqCatnipMultiply) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqCatnipPlay struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqCatnipPlay() *ReqCatnipPlay { + return &ReqCatnipPlay{} +} + +func (p *ReqCatnipPlay) GetId() int32 { + return p.Id +} + +func (p *ReqCatnipPlay) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqCatnipPlay) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqCatnipPlay) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqCatnipPlay"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqCatnipPlay) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqCatnipPlay) Equals(other *ReqCatnipPlay) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqCatnipPlay) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqCatnipPlay(%+v)", *p) +} + +func (p *ReqCatnipPlay) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqCatnipPlay", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqCatnipPlay)(nil) + +func (p *ReqCatnipPlay) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Uid +// +type ReqCatnipRefuse struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Uid int64 `thrift:"Uid,2" db:"Uid" json:"Uid"` +} + +func NewReqCatnipRefuse() *ReqCatnipRefuse { + return &ReqCatnipRefuse{} +} + +func (p *ReqCatnipRefuse) GetId() int32 { + return p.Id +} + +func (p *ReqCatnipRefuse) GetUid() int64 { + return p.Uid +} + +func (p *ReqCatnipRefuse) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I64 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqCatnipRefuse) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqCatnipRefuse) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ReqCatnipRefuse) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqCatnipRefuse"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqCatnipRefuse) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqCatnipRefuse) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Uid: ", p), err) + } + return err +} + +func (p *ReqCatnipRefuse) Equals(other *ReqCatnipRefuse) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Uid != other.Uid { + return false + } + return true +} + +func (p *ReqCatnipRefuse) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqCatnipRefuse(%+v)", *p) +} + +func (p *ReqCatnipRefuse) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqCatnipRefuse", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqCatnipRefuse)(nil) + +func (p *ReqCatnipRefuse) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqCatnipReward struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqCatnipReward() *ReqCatnipReward { + return &ReqCatnipReward{} +} + +func (p *ReqCatnipReward) GetId() int32 { + return p.Id +} + +func (p *ReqCatnipReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqCatnipReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqCatnipReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqCatnipReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqCatnipReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqCatnipReward) Equals(other *ReqCatnipReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqCatnipReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqCatnipReward(%+v)", *p) +} + +func (p *ReqCatnipReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqCatnipReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqCatnipReward)(nil) + +func (p *ReqCatnipReward) Validate() error { + return nil +} + +type ReqChampship struct { +} + +func NewReqChampship() *ReqChampship { + return &ReqChampship{} +} + +func (p *ReqChampship) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqChampship) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqChampship"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqChampship) Equals(other *ReqChampship) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqChampship) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqChampship(%+v)", *p) +} + +func (p *ReqChampship) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqChampship", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqChampship)(nil) + +func (p *ReqChampship) Validate() error { + return nil +} + +type ReqChampshipPreRank struct { +} + +func NewReqChampshipPreRank() *ReqChampshipPreRank { + return &ReqChampshipPreRank{} +} + +func (p *ReqChampshipPreRank) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqChampshipPreRank) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqChampshipPreRank"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqChampshipPreRank) Equals(other *ReqChampshipPreRank) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqChampshipPreRank) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqChampshipPreRank(%+v)", *p) +} + +func (p *ReqChampshipPreRank) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqChampshipPreRank", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqChampshipPreRank)(nil) + +func (p *ReqChampshipPreRank) Validate() error { + return nil +} + +type ReqChampshipRank struct { +} + +func NewReqChampshipRank() *ReqChampshipRank { + return &ReqChampshipRank{} +} + +func (p *ReqChampshipRank) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqChampshipRank) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqChampshipRank"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqChampshipRank) Equals(other *ReqChampshipRank) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqChampshipRank) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqChampshipRank(%+v)", *p) +} + +func (p *ReqChampshipRank) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqChampshipRank", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqChampshipRank)(nil) + +func (p *ReqChampshipRank) Validate() error { + return nil +} + +type ReqChampshipRankReward struct { +} + +func NewReqChampshipRankReward() *ReqChampshipRankReward { + return &ReqChampshipRankReward{} +} + +func (p *ReqChampshipRankReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqChampshipRankReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqChampshipRankReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqChampshipRankReward) Equals(other *ReqChampshipRankReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqChampshipRankReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqChampshipRankReward(%+v)", *p) +} + +func (p *ReqChampshipRankReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqChampshipRankReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqChampshipRankReward)(nil) + +func (p *ReqChampshipRankReward) Validate() error { + return nil +} + +type ReqChampshipReward struct { +} + +func NewReqChampshipReward() *ReqChampshipReward { + return &ReqChampshipReward{} +} + +func (p *ReqChampshipReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqChampshipReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqChampshipReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqChampshipReward) Equals(other *ReqChampshipReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqChampshipReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqChampshipReward(%+v)", *p) +} + +func (p *ReqChampshipReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqChampshipReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqChampshipReward)(nil) + +func (p *ReqChampshipReward) Validate() error { + return nil +} + +// Attributes: +// - UserName +// - OldPwd +// - NewPwd_ +// +type ReqChangePassword struct { + UserName string `thrift:"UserName,1" db:"UserName" json:"UserName"` + OldPwd string `thrift:"OldPwd,2" db:"OldPwd" json:"OldPwd"` + NewPwd_ string `thrift:"NewPwd,3" db:"NewPwd" json:"NewPwd"` +} + +func NewReqChangePassword() *ReqChangePassword { + return &ReqChangePassword{} +} + +func (p *ReqChangePassword) GetUserName() string { + return p.UserName +} + +func (p *ReqChangePassword) GetOldPwd() string { + return p.OldPwd +} + +func (p *ReqChangePassword) GetNewPwd_() string { + return p.NewPwd_ +} + +func (p *ReqChangePassword) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.STRING { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqChangePassword) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.UserName = v + } + return nil +} + +func (p *ReqChangePassword) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.OldPwd = v + } + return nil +} + +func (p *ReqChangePassword) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.NewPwd_ = v + } + return nil +} + +func (p *ReqChangePassword) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqChangePassword"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqChangePassword) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "UserName", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:UserName: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.UserName)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.UserName (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:UserName: ", p), err) + } + return err +} + +func (p *ReqChangePassword) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "OldPwd", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:OldPwd: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.OldPwd)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.OldPwd (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:OldPwd: ", p), err) + } + return err +} + +func (p *ReqChangePassword) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "NewPwd", thrift.STRING, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:NewPwd: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.NewPwd_)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.NewPwd (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:NewPwd: ", p), err) + } + return err +} + +func (p *ReqChangePassword) Equals(other *ReqChangePassword) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.UserName != other.UserName { + return false + } + if p.OldPwd != other.OldPwd { + return false + } + if p.NewPwd_ != other.NewPwd_ { + return false + } + return true +} + +func (p *ReqChangePassword) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqChangePassword(%+v)", *p) +} + +func (p *ReqChangePassword) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqChangePassword", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqChangePassword)(nil) + +func (p *ReqChangePassword) Validate() error { + return nil +} + +// Attributes: +// - Uid +// - Content +// +type ReqChargeReceive struct { + Uid int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` + Content string `thrift:"Content,2" db:"Content" json:"Content"` +} + +func NewReqChargeReceive() *ReqChargeReceive { + return &ReqChargeReceive{} +} + +func (p *ReqChargeReceive) GetUid() int64 { + return p.Uid +} + +func (p *ReqChargeReceive) GetContent() string { + return p.Content +} + +func (p *ReqChargeReceive) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqChargeReceive) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ReqChargeReceive) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Content = v + } + return nil +} + +func (p *ReqChargeReceive) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqChargeReceive"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqChargeReceive) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *ReqChargeReceive) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Content", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Content: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Content)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Content (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Content: ", p), err) + } + return err +} + +func (p *ReqChargeReceive) Equals(other *ReqChargeReceive) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Uid != other.Uid { + return false + } + if p.Content != other.Content { + return false + } + return true +} + +func (p *ReqChargeReceive) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqChargeReceive(%+v)", *p) +} + +func (p *ReqChargeReceive) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqChargeReceive", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqChargeReceive)(nil) + +func (p *ReqChargeReceive) Validate() error { + return nil +} + +// Attributes: +// - OldChessId +// - NewChessId_ +// - CostDia +// - Type +// - MChessData +// - CostStar +// +type ReqChessEx struct { + OldChessId int32 `thrift:"OldChessId,1" db:"OldChessId" json:"OldChessId"` + NewChessId_ int32 `thrift:"NewChessId,2" db:"NewChessId" json:"NewChessId"` + CostDia int32 `thrift:"CostDia,3" db:"CostDia" json:"CostDia"` + Type CHESS_EX_TYPE `thrift:"Type,4" db:"Type" json:"Type"` + MChessData map[string]int32 `thrift:"MChessData,5" db:"MChessData" json:"MChessData"` + CostStar int32 `thrift:"CostStar,6" db:"CostStar" json:"CostStar"` +} + +func NewReqChessEx() *ReqChessEx { + return &ReqChessEx{} +} + +func (p *ReqChessEx) GetOldChessId() int32 { + return p.OldChessId +} + +func (p *ReqChessEx) GetNewChessId_() int32 { + return p.NewChessId_ +} + +func (p *ReqChessEx) GetCostDia() int32 { + return p.CostDia +} + +func (p *ReqChessEx) GetType() CHESS_EX_TYPE { + return p.Type +} + +func (p *ReqChessEx) GetMChessData() map[string]int32 { + return p.MChessData +} + +func (p *ReqChessEx) GetCostStar() int32 { + return p.CostStar +} + +func (p *ReqChessEx) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.MAP { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.I32 { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqChessEx) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.OldChessId = v + } + return nil +} + +func (p *ReqChessEx) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.NewChessId_ = v + } + return nil +} + +func (p *ReqChessEx) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.CostDia = v + } + return nil +} + +func (p *ReqChessEx) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + temp := CHESS_EX_TYPE(v) + p.Type = temp + } + return nil +} + +func (p *ReqChessEx) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[string]int32, size) + p.MChessData = tMap + for i := 0; i < size; i++ { + var _key95 string + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key95 = v + } + var _val96 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val96 = v + } + p.MChessData[_key95] = _val96 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ReqChessEx) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 6: ", err) + } else { + p.CostStar = v + } + return nil +} + +func (p *ReqChessEx) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqChessEx"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqChessEx) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "OldChessId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:OldChessId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.OldChessId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.OldChessId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:OldChessId: ", p), err) + } + return err +} + +func (p *ReqChessEx) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "NewChessId", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:NewChessId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.NewChessId_)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.NewChessId (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:NewChessId: ", p), err) + } + return err +} + +func (p *ReqChessEx) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "CostDia", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:CostDia: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.CostDia)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.CostDia (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:CostDia: ", p), err) + } + return err +} + +func (p *ReqChessEx) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Type: ", p), err) + } + return err +} + +func (p *ReqChessEx) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MChessData", thrift.MAP, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:MChessData: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.STRING, thrift.I32, len(p.MChessData)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.MChessData { + if err := oprot.WriteString(ctx, string(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:MChessData: ", p), err) + } + return err +} + +func (p *ReqChessEx) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "CostStar", thrift.I32, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:CostStar: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.CostStar)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.CostStar (6) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:CostStar: ", p), err) + } + return err +} + +func (p *ReqChessEx) Equals(other *ReqChessEx) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.OldChessId != other.OldChessId { + return false + } + if p.NewChessId_ != other.NewChessId_ { + return false + } + if p.CostDia != other.CostDia { + return false + } + if p.Type != other.Type { + return false + } + if len(p.MChessData) != len(other.MChessData) { + return false + } + for k, _tgt := range p.MChessData { + _src97 := other.MChessData[k] + if _tgt != _src97 { + return false + } + } + if p.CostStar != other.CostStar { + return false + } + return true +} + +func (p *ReqChessEx) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqChessEx(%+v)", *p) +} + +func (p *ReqChessEx) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqChessEx", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqChessEx)(nil) + +func (p *ReqChessEx) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqCollect struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqCollect() *ReqCollect { + return &ReqCollect{} +} + +func (p *ReqCollect) GetId() int32 { + return p.Id +} + +func (p *ReqCollect) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqCollect) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqCollect) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqCollect"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqCollect) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqCollect) Equals(other *ReqCollect) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqCollect) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqCollect(%+v)", *p) +} + +func (p *ReqCollect) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqCollect", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqCollect)(nil) + +func (p *ReqCollect) Validate() error { + return nil +} + +type ReqCollectInfo struct { +} + +func NewReqCollectInfo() *ReqCollectInfo { + return &ReqCollectInfo{} +} + +func (p *ReqCollectInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqCollectInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqCollectInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqCollectInfo) Equals(other *ReqCollectInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqCollectInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqCollectInfo(%+v)", *p) +} + +func (p *ReqCollectInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqCollectInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqCollectInfo)(nil) + +func (p *ReqCollectInfo) Validate() error { + return nil +} + +// Attributes: +// - ChargeId +// - PlatForm +// - Channel +// - Type +// - Uid +// +type ReqCreateOrderSn struct { + ChargeId int32 `thrift:"ChargeId,1" db:"ChargeId" json:"ChargeId"` + PlatForm string `thrift:"PlatForm,2" db:"PlatForm" json:"PlatForm"` + Channel string `thrift:"channel,3" db:"channel" json:"channel"` + Type int32 `thrift:"Type,4" db:"Type" json:"Type"` + Uid int64 `thrift:"Uid,5" db:"Uid" json:"Uid"` +} + +func NewReqCreateOrderSn() *ReqCreateOrderSn { + return &ReqCreateOrderSn{} +} + +func (p *ReqCreateOrderSn) GetChargeId() int32 { + return p.ChargeId +} + +func (p *ReqCreateOrderSn) GetPlatForm() string { + return p.PlatForm +} + +func (p *ReqCreateOrderSn) GetChannel() string { + return p.Channel +} + +func (p *ReqCreateOrderSn) GetType() int32 { + return p.Type +} + +func (p *ReqCreateOrderSn) GetUid() int64 { + return p.Uid +} + +func (p *ReqCreateOrderSn) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.STRING { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I64 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqCreateOrderSn) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.ChargeId = v + } + return nil +} + +func (p *ReqCreateOrderSn) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.PlatForm = v + } + return nil +} + +func (p *ReqCreateOrderSn) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Channel = v + } + return nil +} + +func (p *ReqCreateOrderSn) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ReqCreateOrderSn) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ReqCreateOrderSn) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqCreateOrderSn"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqCreateOrderSn) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChargeId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ChargeId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ChargeId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ChargeId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ChargeId: ", p), err) + } + return err +} + +func (p *ReqCreateOrderSn) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "PlatForm", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:PlatForm: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.PlatForm)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.PlatForm (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:PlatForm: ", p), err) + } + return err +} + +func (p *ReqCreateOrderSn) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "channel", thrift.STRING, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:channel: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Channel)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.channel (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:channel: ", p), err) + } + return err +} + +func (p *ReqCreateOrderSn) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Type: ", p), err) + } + return err +} + +func (p *ReqCreateOrderSn) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Uid: ", p), err) + } + return err +} + +func (p *ReqCreateOrderSn) Equals(other *ReqCreateOrderSn) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ChargeId != other.ChargeId { + return false + } + if p.PlatForm != other.PlatForm { + return false + } + if p.Channel != other.Channel { + return false + } + if p.Type != other.Type { + return false + } + if p.Uid != other.Uid { + return false + } + return true +} + +func (p *ReqCreateOrderSn) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqCreateOrderSn(%+v)", *p) +} + +func (p *ReqCreateOrderSn) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqCreateOrderSn", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqCreateOrderSn)(nil) + +func (p *ReqCreateOrderSn) Validate() error { + return nil +} + +type ReqCreatePetOrder struct { +} + +func NewReqCreatePetOrder() *ReqCreatePetOrder { + return &ReqCreatePetOrder{} +} + +func (p *ReqCreatePetOrder) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqCreatePetOrder) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqCreatePetOrder"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqCreatePetOrder) Equals(other *ReqCreatePetOrder) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqCreatePetOrder) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqCreatePetOrder(%+v)", *p) +} + +func (p *ReqCreatePetOrder) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqCreatePetOrder", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqCreatePetOrder)(nil) + +func (p *ReqCreatePetOrder) Validate() error { + return nil +} + +type ReqDailyUnlock struct { +} + +func NewReqDailyUnlock() *ReqDailyUnlock { + return &ReqDailyUnlock{} +} + +func (p *ReqDailyUnlock) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqDailyUnlock) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqDailyUnlock"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqDailyUnlock) Equals(other *ReqDailyUnlock) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqDailyUnlock) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqDailyUnlock(%+v)", *p) +} + +func (p *ReqDailyUnlock) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqDailyUnlock", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqDailyUnlock)(nil) + +func (p *ReqDailyUnlock) Validate() error { + return nil +} + +// Attributes: +// - AreaId +// - DecorateId +// +type ReqDecorate struct { + AreaId int32 `thrift:"AreaId,1" db:"AreaId" json:"AreaId"` + DecorateId int32 `thrift:"DecorateId,2" db:"DecorateId" json:"DecorateId"` +} + +func NewReqDecorate() *ReqDecorate { + return &ReqDecorate{} +} + +func (p *ReqDecorate) GetAreaId() int32 { + return p.AreaId +} + +func (p *ReqDecorate) GetDecorateId() int32 { + return p.DecorateId +} + +func (p *ReqDecorate) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqDecorate) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.AreaId = v + } + return nil +} + +func (p *ReqDecorate) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.DecorateId = v + } + return nil +} + +func (p *ReqDecorate) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqDecorate"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqDecorate) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "AreaId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:AreaId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.AreaId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.AreaId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:AreaId: ", p), err) + } + return err +} + +func (p *ReqDecorate) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "DecorateId", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:DecorateId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.DecorateId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.DecorateId (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:DecorateId: ", p), err) + } + return err +} + +func (p *ReqDecorate) Equals(other *ReqDecorate) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.AreaId != other.AreaId { + return false + } + if p.DecorateId != other.DecorateId { + return false + } + return true +} + +func (p *ReqDecorate) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqDecorate(%+v)", *p) +} + +func (p *ReqDecorate) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqDecorate", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqDecorate)(nil) + +func (p *ReqDecorate) Validate() error { + return nil +} + +type ReqDecorateAll struct { +} + +func NewReqDecorateAll() *ReqDecorateAll { + return &ReqDecorateAll{} +} + +func (p *ReqDecorateAll) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqDecorateAll) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqDecorateAll"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqDecorateAll) Equals(other *ReqDecorateAll) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqDecorateAll) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqDecorateAll(%+v)", *p) +} + +func (p *ReqDecorateAll) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqDecorateAll", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqDecorateAll)(nil) + +func (p *ReqDecorateAll) Validate() error { + return nil +} + +// Attributes: +// - Uid +// +type ReqDelFriend struct { + Uid int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` +} + +func NewReqDelFriend() *ReqDelFriend { + return &ReqDelFriend{} +} + +func (p *ReqDelFriend) GetUid() int64 { + return p.Uid +} + +func (p *ReqDelFriend) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqDelFriend) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ReqDelFriend) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqDelFriend"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqDelFriend) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *ReqDelFriend) Equals(other *ReqDelFriend) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Uid != other.Uid { + return false + } + return true +} + +func (p *ReqDelFriend) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqDelFriend(%+v)", *p) +} + +func (p *ReqDelFriend) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqDelFriend", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqDelFriend)(nil) + +func (p *ReqDelFriend) Validate() error { + return nil +} + +// Attributes: +// - OrderId +// +type ReqDelOrder struct { + OrderId int32 `thrift:"OrderId,1" db:"OrderId" json:"OrderId"` +} + +func NewReqDelOrder() *ReqDelOrder { + return &ReqDelOrder{} +} + +func (p *ReqDelOrder) GetOrderId() int32 { + return p.OrderId +} + +func (p *ReqDelOrder) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqDelOrder) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.OrderId = v + } + return nil +} + +func (p *ReqDelOrder) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqDelOrder"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqDelOrder) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "OrderId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:OrderId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.OrderId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.OrderId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:OrderId: ", p), err) + } + return err +} + +func (p *ReqDelOrder) Equals(other *ReqDelOrder) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.OrderId != other.OrderId { + return false + } + return true +} + +func (p *ReqDelOrder) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqDelOrder(%+v)", *p) +} + +func (p *ReqDelOrder) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqDelOrder", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqDelOrder)(nil) + +func (p *ReqDelOrder) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqDeleteMail struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqDeleteMail() *ReqDeleteMail { + return &ReqDeleteMail{} +} + +func (p *ReqDeleteMail) GetId() int32 { + return p.Id +} + +func (p *ReqDeleteMail) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqDeleteMail) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqDeleteMail) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqDeleteMail"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqDeleteMail) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqDeleteMail) Equals(other *ReqDeleteMail) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqDeleteMail) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqDeleteMail(%+v)", *p) +} + +func (p *ReqDeleteMail) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqDeleteMail", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqDeleteMail)(nil) + +func (p *ReqDeleteMail) Validate() error { + return nil +} + +type ReqEndless struct { +} + +func NewReqEndless() *ReqEndless { + return &ReqEndless{} +} + +func (p *ReqEndless) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqEndless) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqEndless"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqEndless) Equals(other *ReqEndless) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqEndless) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqEndless(%+v)", *p) +} + +func (p *ReqEndless) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqEndless", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqEndless)(nil) + +func (p *ReqEndless) Validate() error { + return nil +} + +type ReqEndlessReward struct { +} + +func NewReqEndlessReward() *ReqEndlessReward { + return &ReqEndlessReward{} +} + +func (p *ReqEndlessReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqEndlessReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqEndlessReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqEndlessReward) Equals(other *ReqEndlessReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqEndlessReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqEndlessReward(%+v)", *p) +} + +func (p *ReqEndlessReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqEndlessReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqEndlessReward)(nil) + +func (p *ReqEndlessReward) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqExStarReward struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqExStarReward() *ReqExStarReward { + return &ReqExStarReward{} +} + +func (p *ReqExStarReward) GetId() int32 { + return p.Id +} + +func (p *ReqExStarReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqExStarReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqExStarReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqExStarReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqExStarReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqExStarReward) Equals(other *ReqExStarReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqExStarReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqExStarReward(%+v)", *p) +} + +func (p *ReqExStarReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqExStarReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqExStarReward)(nil) + +func (p *ReqExStarReward) Validate() error { + return nil +} + +type ReqFastProduceInfo struct { +} + +func NewReqFastProduceInfo() *ReqFastProduceInfo { + return &ReqFastProduceInfo{} +} + +func (p *ReqFastProduceInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqFastProduceInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqFastProduceInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqFastProduceInfo) Equals(other *ReqFastProduceInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqFastProduceInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqFastProduceInfo(%+v)", *p) +} + +func (p *ReqFastProduceInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqFastProduceInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqFastProduceInfo)(nil) + +func (p *ReqFastProduceInfo) Validate() error { + return nil +} + +// Attributes: +// - Energy +// +type ReqFastProduceReward struct { + Energy int32 `thrift:"Energy,1" db:"Energy" json:"Energy"` +} + +func NewReqFastProduceReward() *ReqFastProduceReward { + return &ReqFastProduceReward{} +} + +func (p *ReqFastProduceReward) GetEnergy() int32 { + return p.Energy +} + +func (p *ReqFastProduceReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqFastProduceReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Energy = v + } + return nil +} + +func (p *ReqFastProduceReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqFastProduceReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqFastProduceReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Energy", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Energy: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Energy)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Energy (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Energy: ", p), err) + } + return err +} + +func (p *ReqFastProduceReward) Equals(other *ReqFastProduceReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Energy != other.Energy { + return false + } + return true +} + +func (p *ReqFastProduceReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqFastProduceReward(%+v)", *p) +} + +func (p *ReqFastProduceReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqFastProduceReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqFastProduceReward)(nil) + +func (p *ReqFastProduceReward) Validate() error { + return nil +} + +type ReqFreeShop struct { +} + +func NewReqFreeShop() *ReqFreeShop { + return &ReqFreeShop{} +} + +func (p *ReqFreeShop) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqFreeShop) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqFreeShop"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqFreeShop) Equals(other *ReqFreeShop) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqFreeShop) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqFreeShop(%+v)", *p) +} + +func (p *ReqFreeShop) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqFreeShop", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqFreeShop)(nil) + +func (p *ReqFreeShop) Validate() error { + return nil +} + +// Attributes: +// - Type +// +type ReqFriendApply struct { + Type int32 `thrift:"Type,1" db:"Type" json:"Type"` +} + +func NewReqFriendApply() *ReqFriendApply { + return &ReqFriendApply{} +} + +func (p *ReqFriendApply) GetType() int32 { + return p.Type +} + +func (p *ReqFriendApply) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqFriendApply) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ReqFriendApply) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqFriendApply"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqFriendApply) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Type: ", p), err) + } + return err +} + +func (p *ReqFriendApply) Equals(other *ReqFriendApply) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Type != other.Type { + return false + } + return true +} + +func (p *ReqFriendApply) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqFriendApply(%+v)", *p) +} + +func (p *ReqFriendApply) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqFriendApply", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqFriendApply)(nil) + +func (p *ReqFriendApply) Validate() error { + return nil +} + +// Attributes: +// - Code +// +type ReqFriendByCode struct { + Code string `thrift:"Code,1" db:"Code" json:"Code"` +} + +func NewReqFriendByCode() *ReqFriendByCode { + return &ReqFriendByCode{} +} + +func (p *ReqFriendByCode) GetCode() string { + return p.Code +} + +func (p *ReqFriendByCode) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqFriendByCode) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Code = v + } + return nil +} + +func (p *ReqFriendByCode) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqFriendByCode"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqFriendByCode) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ReqFriendByCode) Equals(other *ReqFriendByCode) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + return true +} + +func (p *ReqFriendByCode) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqFriendByCode(%+v)", *p) +} + +func (p *ReqFriendByCode) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqFriendByCode", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqFriendByCode)(nil) + +func (p *ReqFriendByCode) Validate() error { + return nil +} + +type ReqFriendCardMsg struct { +} + +func NewReqFriendCardMsg() *ReqFriendCardMsg { + return &ReqFriendCardMsg{} +} + +func (p *ReqFriendCardMsg) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqFriendCardMsg) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqFriendCardMsg"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqFriendCardMsg) Equals(other *ReqFriendCardMsg) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqFriendCardMsg) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqFriendCardMsg(%+v)", *p) +} + +func (p *ReqFriendCardMsg) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqFriendCardMsg", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqFriendCardMsg)(nil) + +func (p *ReqFriendCardMsg) Validate() error { + return nil +} + +// Attributes: +// - Uid +// +type ReqFriendIgnore struct { + Uid int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` +} + +func NewReqFriendIgnore() *ReqFriendIgnore { + return &ReqFriendIgnore{} +} + +func (p *ReqFriendIgnore) GetUid() int64 { + return p.Uid +} + +func (p *ReqFriendIgnore) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqFriendIgnore) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ReqFriendIgnore) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqFriendIgnore"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqFriendIgnore) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *ReqFriendIgnore) Equals(other *ReqFriendIgnore) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Uid != other.Uid { + return false + } + return true +} + +func (p *ReqFriendIgnore) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqFriendIgnore(%+v)", *p) +} + +func (p *ReqFriendIgnore) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqFriendIgnore", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqFriendIgnore)(nil) + +func (p *ReqFriendIgnore) Validate() error { + return nil +} + +type ReqFriendList struct { +} + +func NewReqFriendList() *ReqFriendList { + return &ReqFriendList{} +} + +func (p *ReqFriendList) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqFriendList) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqFriendList"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqFriendList) Equals(other *ReqFriendList) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqFriendList) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqFriendList(%+v)", *p) +} + +func (p *ReqFriendList) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqFriendList", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqFriendList)(nil) + +func (p *ReqFriendList) Validate() error { + return nil +} + +// Attributes: +// - Uid +// +type ReqFriendPlayerSimple struct { + Uid int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` +} + +func NewReqFriendPlayerSimple() *ReqFriendPlayerSimple { + return &ReqFriendPlayerSimple{} +} + +func (p *ReqFriendPlayerSimple) GetUid() int64 { + return p.Uid +} + +func (p *ReqFriendPlayerSimple) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqFriendPlayerSimple) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ReqFriendPlayerSimple) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqFriendPlayerSimple"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqFriendPlayerSimple) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *ReqFriendPlayerSimple) Equals(other *ReqFriendPlayerSimple) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Uid != other.Uid { + return false + } + return true +} + +func (p *ReqFriendPlayerSimple) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqFriendPlayerSimple(%+v)", *p) +} + +func (p *ReqFriendPlayerSimple) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqFriendPlayerSimple", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqFriendPlayerSimple)(nil) + +func (p *ReqFriendPlayerSimple) Validate() error { + return nil +} + +type ReqFriendRecommend struct { +} + +func NewReqFriendRecommend() *ReqFriendRecommend { + return &ReqFriendRecommend{} +} + +func (p *ReqFriendRecommend) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqFriendRecommend) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqFriendRecommend"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqFriendRecommend) Equals(other *ReqFriendRecommend) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqFriendRecommend) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqFriendRecommend(%+v)", *p) +} + +func (p *ReqFriendRecommend) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqFriendRecommend", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqFriendRecommend)(nil) + +func (p *ReqFriendRecommend) Validate() error { + return nil +} + +// Attributes: +// - LogId +// - Param +// - Type +// +type ReqFriendReplyHandle struct { + LogId int32 `thrift:"LogId,1" db:"LogId" json:"LogId"` + Param string `thrift:"Param,2" db:"Param" json:"Param"` + Type int32 `thrift:"Type,3" db:"Type" json:"Type"` +} + +func NewReqFriendReplyHandle() *ReqFriendReplyHandle { + return &ReqFriendReplyHandle{} +} + +func (p *ReqFriendReplyHandle) GetLogId() int32 { + return p.LogId +} + +func (p *ReqFriendReplyHandle) GetParam() string { + return p.Param +} + +func (p *ReqFriendReplyHandle) GetType() int32 { + return p.Type +} + +func (p *ReqFriendReplyHandle) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqFriendReplyHandle) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.LogId = v + } + return nil +} + +func (p *ReqFriendReplyHandle) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Param = v + } + return nil +} + +func (p *ReqFriendReplyHandle) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ReqFriendReplyHandle) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqFriendReplyHandle"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqFriendReplyHandle) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "LogId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:LogId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.LogId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.LogId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:LogId: ", p), err) + } + return err +} + +func (p *ReqFriendReplyHandle) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Param", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Param: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Param)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Param (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Param: ", p), err) + } + return err +} + +func (p *ReqFriendReplyHandle) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Type: ", p), err) + } + return err +} + +func (p *ReqFriendReplyHandle) Equals(other *ReqFriendReplyHandle) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.LogId != other.LogId { + return false + } + if p.Param != other.Param { + return false + } + if p.Type != other.Type { + return false + } + return true +} + +func (p *ReqFriendReplyHandle) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqFriendReplyHandle(%+v)", *p) +} + +func (p *ReqFriendReplyHandle) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqFriendReplyHandle", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqFriendReplyHandle)(nil) + +func (p *ReqFriendReplyHandle) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqFriendTLUpvote struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqFriendTLUpvote() *ReqFriendTLUpvote { + return &ReqFriendTLUpvote{} +} + +func (p *ReqFriendTLUpvote) GetId() int32 { + return p.Id +} + +func (p *ReqFriendTLUpvote) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqFriendTLUpvote) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqFriendTLUpvote) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqFriendTLUpvote"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqFriendTLUpvote) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqFriendTLUpvote) Equals(other *ReqFriendTLUpvote) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqFriendTLUpvote) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqFriendTLUpvote(%+v)", *p) +} + +func (p *ReqFriendTLUpvote) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqFriendTLUpvote", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqFriendTLUpvote)(nil) + +func (p *ReqFriendTLUpvote) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqFriendTReward struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqFriendTReward() *ReqFriendTReward { + return &ReqFriendTReward{} +} + +func (p *ReqFriendTReward) GetId() int32 { + return p.Id +} + +func (p *ReqFriendTReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqFriendTReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqFriendTReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqFriendTReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqFriendTReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqFriendTReward) Equals(other *ReqFriendTReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqFriendTReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqFriendTReward(%+v)", *p) +} + +func (p *ReqFriendTReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqFriendTReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqFriendTReward)(nil) + +func (p *ReqFriendTReward) Validate() error { + return nil +} + +type ReqFriendTimeLine struct { +} + +func NewReqFriendTimeLine() *ReqFriendTimeLine { + return &ReqFriendTimeLine{} +} + +func (p *ReqFriendTimeLine) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqFriendTimeLine) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqFriendTimeLine"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqFriendTimeLine) Equals(other *ReqFriendTimeLine) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqFriendTimeLine) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqFriendTimeLine(%+v)", *p) +} + +func (p *ReqFriendTimeLine) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqFriendTimeLine", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqFriendTimeLine)(nil) + +func (p *ReqFriendTimeLine) Validate() error { + return nil +} + +type ReqFriendTreasure struct { +} + +func NewReqFriendTreasure() *ReqFriendTreasure { + return &ReqFriendTreasure{} +} + +func (p *ReqFriendTreasure) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqFriendTreasure) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqFriendTreasure"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqFriendTreasure) Equals(other *ReqFriendTreasure) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqFriendTreasure) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqFriendTreasure(%+v)", *p) +} + +func (p *ReqFriendTreasure) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqFriendTreasure", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqFriendTreasure)(nil) + +func (p *ReqFriendTreasure) Validate() error { + return nil +} + +type ReqFriendTreasureEnd struct { +} + +func NewReqFriendTreasureEnd() *ReqFriendTreasureEnd { + return &ReqFriendTreasureEnd{} +} + +func (p *ReqFriendTreasureEnd) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqFriendTreasureEnd) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqFriendTreasureEnd"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqFriendTreasureEnd) Equals(other *ReqFriendTreasureEnd) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqFriendTreasureEnd) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqFriendTreasureEnd(%+v)", *p) +} + +func (p *ReqFriendTreasureEnd) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqFriendTreasureEnd", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqFriendTreasureEnd)(nil) + +func (p *ReqFriendTreasureEnd) Validate() error { + return nil +} + +// Attributes: +// - Pos +// +type ReqFriendTreasureFilp struct { + Pos int32 `thrift:"Pos,1" db:"Pos" json:"Pos"` +} + +func NewReqFriendTreasureFilp() *ReqFriendTreasureFilp { + return &ReqFriendTreasureFilp{} +} + +func (p *ReqFriendTreasureFilp) GetPos() int32 { + return p.Pos +} + +func (p *ReqFriendTreasureFilp) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqFriendTreasureFilp) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Pos = v + } + return nil +} + +func (p *ReqFriendTreasureFilp) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqFriendTreasureFilp"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqFriendTreasureFilp) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Pos", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Pos: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Pos)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Pos (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Pos: ", p), err) + } + return err +} + +func (p *ReqFriendTreasureFilp) Equals(other *ReqFriendTreasureFilp) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Pos != other.Pos { + return false + } + return true +} + +func (p *ReqFriendTreasureFilp) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqFriendTreasureFilp(%+v)", *p) +} + +func (p *ReqFriendTreasureFilp) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqFriendTreasureFilp", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqFriendTreasureFilp)(nil) + +func (p *ReqFriendTreasureFilp) Validate() error { + return nil +} + +// Attributes: +// - List +// - List2 +// +type ReqFriendTreasureStart struct { + List []*TreasureInfo `thrift:"List,1" db:"List" json:"List"` + List2 []int32 `thrift:"List2,2" db:"List2" json:"List2"` +} + +func NewReqFriendTreasureStart() *ReqFriendTreasureStart { + return &ReqFriendTreasureStart{} +} + +func (p *ReqFriendTreasureStart) GetList() []*TreasureInfo { + return p.List +} + +func (p *ReqFriendTreasureStart) GetList2() []int32 { + return p.List2 +} + +func (p *ReqFriendTreasureStart) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.LIST { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqFriendTreasureStart) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*TreasureInfo, 0, size) + p.List = tSlice + for i := 0; i < size; i++ { + _elem98 := &TreasureInfo{} + if err := _elem98.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem98), err) + } + p.List = append(p.List, _elem98) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ReqFriendTreasureStart) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.List2 = tSlice + for i := 0; i < size; i++ { + var _elem99 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem99 = v + } + p.List2 = append(p.List2, _elem99) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ReqFriendTreasureStart) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqFriendTreasureStart"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqFriendTreasureStart) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "List", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:List: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.List)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.List { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:List: ", p), err) + } + return err +} + +func (p *ReqFriendTreasureStart) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "List2", thrift.LIST, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:List2: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.List2)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.List2 { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:List2: ", p), err) + } + return err +} + +func (p *ReqFriendTreasureStart) Equals(other *ReqFriendTreasureStart) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.List) != len(other.List) { + return false + } + for i, _tgt := range p.List { + _src100 := other.List[i] + if !_tgt.Equals(_src100) { + return false + } + } + if len(p.List2) != len(other.List2) { + return false + } + for i, _tgt := range p.List2 { + _src101 := other.List2[i] + if _tgt != _src101 { + return false + } + } + return true +} + +func (p *ReqFriendTreasureStart) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqFriendTreasureStart(%+v)", *p) +} + +func (p *ReqFriendTreasureStart) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqFriendTreasureStart", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqFriendTreasureStart)(nil) + +func (p *ReqFriendTreasureStart) Validate() error { + return nil +} + +// Attributes: +// - FurId +// +type ReqFurSet struct { + FurId int32 `thrift:"FurId,1" db:"FurId" json:"FurId"` +} + +func NewReqFurSet() *ReqFurSet { + return &ReqFurSet{} +} + +func (p *ReqFurSet) GetFurId() int32 { + return p.FurId +} + +func (p *ReqFurSet) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqFurSet) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.FurId = v + } + return nil +} + +func (p *ReqFurSet) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqFurSet"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqFurSet) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "FurId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:FurId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.FurId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.FurId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:FurId: ", p), err) + } + return err +} + +func (p *ReqFurSet) Equals(other *ReqFurSet) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.FurId != other.FurId { + return false + } + return true +} + +func (p *ReqFurSet) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqFurSet(%+v)", *p) +} + +func (p *ReqFurSet) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqFurSet", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqFurSet)(nil) + +func (p *ReqFurSet) Validate() error { + return nil +} + +// Attributes: +// - ChessId +// - MChessData +// +type ReqGetChessFromBuff struct { + ChessId int32 `thrift:"ChessId,1" db:"ChessId" json:"ChessId"` + MChessData map[string]int32 `thrift:"MChessData,2" db:"MChessData" json:"MChessData"` +} + +func NewReqGetChessFromBuff() *ReqGetChessFromBuff { + return &ReqGetChessFromBuff{} +} + +func (p *ReqGetChessFromBuff) GetChessId() int32 { + return p.ChessId +} + +func (p *ReqGetChessFromBuff) GetMChessData() map[string]int32 { + return p.MChessData +} + +func (p *ReqGetChessFromBuff) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.MAP { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqGetChessFromBuff) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.ChessId = v + } + return nil +} + +func (p *ReqGetChessFromBuff) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[string]int32, size) + p.MChessData = tMap + for i := 0; i < size; i++ { + var _key102 string + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key102 = v + } + var _val103 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val103 = v + } + p.MChessData[_key102] = _val103 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ReqGetChessFromBuff) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqGetChessFromBuff"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqGetChessFromBuff) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChessId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ChessId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ChessId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ChessId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ChessId: ", p), err) + } + return err +} + +func (p *ReqGetChessFromBuff) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MChessData", thrift.MAP, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:MChessData: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.STRING, thrift.I32, len(p.MChessData)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.MChessData { + if err := oprot.WriteString(ctx, string(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:MChessData: ", p), err) + } + return err +} + +func (p *ReqGetChessFromBuff) Equals(other *ReqGetChessFromBuff) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ChessId != other.ChessId { + return false + } + if len(p.MChessData) != len(other.MChessData) { + return false + } + for k, _tgt := range p.MChessData { + _src104 := other.MChessData[k] + if _tgt != _src104 { + return false + } + } + return true +} + +func (p *ReqGetChessFromBuff) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqGetChessFromBuff(%+v)", *p) +} + +func (p *ReqGetChessFromBuff) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqGetChessFromBuff", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqGetChessFromBuff)(nil) + +func (p *ReqGetChessFromBuff) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqGetChessRetireReward struct { + Id string `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqGetChessRetireReward() *ReqGetChessRetireReward { + return &ReqGetChessRetireReward{} +} + +func (p *ReqGetChessRetireReward) GetId() string { + return p.Id +} + +func (p *ReqGetChessRetireReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqGetChessRetireReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqGetChessRetireReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqGetChessRetireReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqGetChessRetireReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqGetChessRetireReward) Equals(other *ReqGetChessRetireReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqGetChessRetireReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqGetChessRetireReward(%+v)", *p) +} + +func (p *ReqGetChessRetireReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqGetChessRetireReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqGetChessRetireReward)(nil) + +func (p *ReqGetChessRetireReward) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqGetDailyTaskReward struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqGetDailyTaskReward() *ReqGetDailyTaskReward { + return &ReqGetDailyTaskReward{} +} + +func (p *ReqGetDailyTaskReward) GetId() int32 { + return p.Id +} + +func (p *ReqGetDailyTaskReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqGetDailyTaskReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqGetDailyTaskReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqGetDailyTaskReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqGetDailyTaskReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqGetDailyTaskReward) Equals(other *ReqGetDailyTaskReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqGetDailyTaskReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqGetDailyTaskReward(%+v)", *p) +} + +func (p *ReqGetDailyTaskReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqGetDailyTaskReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqGetDailyTaskReward)(nil) + +func (p *ReqGetDailyTaskReward) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqGetDailyWeekReward struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqGetDailyWeekReward() *ReqGetDailyWeekReward { + return &ReqGetDailyWeekReward{} +} + +func (p *ReqGetDailyWeekReward) GetId() int32 { + return p.Id +} + +func (p *ReqGetDailyWeekReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqGetDailyWeekReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqGetDailyWeekReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqGetDailyWeekReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqGetDailyWeekReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqGetDailyWeekReward) Equals(other *ReqGetDailyWeekReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqGetDailyWeekReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqGetDailyWeekReward(%+v)", *p) +} + +func (p *ReqGetDailyWeekReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqGetDailyWeekReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqGetDailyWeekReward)(nil) + +func (p *ReqGetDailyWeekReward) Validate() error { + return nil +} + +type ReqGetEnergyByAD struct { +} + +func NewReqGetEnergyByAD() *ReqGetEnergyByAD { + return &ReqGetEnergyByAD{} +} + +func (p *ReqGetEnergyByAD) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqGetEnergyByAD) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqGetEnergyByAD"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqGetEnergyByAD) Equals(other *ReqGetEnergyByAD) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqGetEnergyByAD) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqGetEnergyByAD(%+v)", *p) +} + +func (p *ReqGetEnergyByAD) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqGetEnergyByAD", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqGetEnergyByAD)(nil) + +func (p *ReqGetEnergyByAD) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqGetFriendCard struct { + Id string `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqGetFriendCard() *ReqGetFriendCard { + return &ReqGetFriendCard{} +} + +func (p *ReqGetFriendCard) GetId() string { + return p.Id +} + +func (p *ReqGetFriendCard) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqGetFriendCard) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqGetFriendCard) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqGetFriendCard"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqGetFriendCard) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqGetFriendCard) Equals(other *ReqGetFriendCard) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqGetFriendCard) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqGetFriendCard(%+v)", *p) +} + +func (p *ReqGetFriendCard) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqGetFriendCard", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqGetFriendCard)(nil) + +func (p *ReqGetFriendCard) Validate() error { + return nil +} + +type ReqGetGoldCard struct { +} + +func NewReqGetGoldCard() *ReqGetGoldCard { + return &ReqGetGoldCard{} +} + +func (p *ReqGetGoldCard) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqGetGoldCard) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqGetGoldCard"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqGetGoldCard) Equals(other *ReqGetGoldCard) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqGetGoldCard) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqGetGoldCard(%+v)", *p) +} + +func (p *ReqGetGoldCard) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqGetGoldCard", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqGetGoldCard)(nil) + +func (p *ReqGetGoldCard) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqGetGuideActiveReward struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqGetGuideActiveReward() *ReqGetGuideActiveReward { + return &ReqGetGuideActiveReward{} +} + +func (p *ReqGetGuideActiveReward) GetId() int32 { + return p.Id +} + +func (p *ReqGetGuideActiveReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqGetGuideActiveReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqGetGuideActiveReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqGetGuideActiveReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqGetGuideActiveReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqGetGuideActiveReward) Equals(other *ReqGetGuideActiveReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqGetGuideActiveReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqGetGuideActiveReward(%+v)", *p) +} + +func (p *ReqGetGuideActiveReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqGetGuideActiveReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqGetGuideActiveReward)(nil) + +func (p *ReqGetGuideActiveReward) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqGetGuideTaskReward struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqGetGuideTaskReward() *ReqGetGuideTaskReward { + return &ReqGetGuideTaskReward{} +} + +func (p *ReqGetGuideTaskReward) GetId() int32 { + return p.Id +} + +func (p *ReqGetGuideTaskReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqGetGuideTaskReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqGetGuideTaskReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqGetGuideTaskReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqGetGuideTaskReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqGetGuideTaskReward) Equals(other *ReqGetGuideTaskReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqGetGuideTaskReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqGetGuideTaskReward(%+v)", *p) +} + +func (p *ReqGetGuideTaskReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqGetGuideTaskReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqGetGuideTaskReward)(nil) + +func (p *ReqGetGuideTaskReward) Validate() error { + return nil +} + +// Attributes: +// - ChessId +// +type ReqGetHandbookReward struct { + ChessId int32 `thrift:"ChessId,1" db:"ChessId" json:"ChessId"` +} + +func NewReqGetHandbookReward() *ReqGetHandbookReward { + return &ReqGetHandbookReward{} +} + +func (p *ReqGetHandbookReward) GetChessId() int32 { + return p.ChessId +} + +func (p *ReqGetHandbookReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqGetHandbookReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.ChessId = v + } + return nil +} + +func (p *ReqGetHandbookReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqGetHandbookReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqGetHandbookReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChessId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ChessId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ChessId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ChessId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ChessId: ", p), err) + } + return err +} + +func (p *ReqGetHandbookReward) Equals(other *ReqGetHandbookReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ChessId != other.ChessId { + return false + } + return true +} + +func (p *ReqGetHandbookReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqGetHandbookReward(%+v)", *p) +} + +func (p *ReqGetHandbookReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqGetHandbookReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqGetHandbookReward)(nil) + +func (p *ReqGetHandbookReward) Validate() error { + return nil +} + +// Attributes: +// - GetIndex +// +type ReqGetInviteReward struct { + GetIndex int32 `thrift:"GetIndex,1" db:"GetIndex" json:"GetIndex"` +} + +func NewReqGetInviteReward() *ReqGetInviteReward { + return &ReqGetInviteReward{} +} + +func (p *ReqGetInviteReward) GetGetIndex() int32 { + return p.GetIndex +} + +func (p *ReqGetInviteReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqGetInviteReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.GetIndex = v + } + return nil +} + +func (p *ReqGetInviteReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqGetInviteReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqGetInviteReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "GetIndex", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:GetIndex: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.GetIndex)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.GetIndex (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:GetIndex: ", p), err) + } + return err +} + +func (p *ReqGetInviteReward) Equals(other *ReqGetInviteReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.GetIndex != other.GetIndex { + return false + } + return true +} + +func (p *ReqGetInviteReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqGetInviteReward(%+v)", *p) +} + +func (p *ReqGetInviteReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqGetInviteReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqGetInviteReward)(nil) + +func (p *ReqGetInviteReward) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqGetMailReward struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqGetMailReward() *ReqGetMailReward { + return &ReqGetMailReward{} +} + +func (p *ReqGetMailReward) GetId() int32 { + return p.Id +} + +func (p *ReqGetMailReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqGetMailReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqGetMailReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqGetMailReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqGetMailReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqGetMailReward) Equals(other *ReqGetMailReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqGetMailReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqGetMailReward(%+v)", *p) +} + +func (p *ReqGetMailReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqGetMailReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqGetMailReward)(nil) + +func (p *ReqGetMailReward) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqGetMonthLoginReward struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqGetMonthLoginReward() *ReqGetMonthLoginReward { + return &ReqGetMonthLoginReward{} +} + +func (p *ReqGetMonthLoginReward) GetId() int32 { + return p.Id +} + +func (p *ReqGetMonthLoginReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqGetMonthLoginReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqGetMonthLoginReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqGetMonthLoginReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqGetMonthLoginReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqGetMonthLoginReward) Equals(other *ReqGetMonthLoginReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqGetMonthLoginReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqGetMonthLoginReward(%+v)", *p) +} + +func (p *ReqGetMonthLoginReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqGetMonthLoginReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqGetMonthLoginReward)(nil) + +func (p *ReqGetMonthLoginReward) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqGetSevenLoginReward struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqGetSevenLoginReward() *ReqGetSevenLoginReward { + return &ReqGetSevenLoginReward{} +} + +func (p *ReqGetSevenLoginReward) GetId() int32 { + return p.Id +} + +func (p *ReqGetSevenLoginReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqGetSevenLoginReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqGetSevenLoginReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqGetSevenLoginReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqGetSevenLoginReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqGetSevenLoginReward) Equals(other *ReqGetSevenLoginReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqGetSevenLoginReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqGetSevenLoginReward(%+v)", *p) +} + +func (p *ReqGetSevenLoginReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqGetSevenLoginReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqGetSevenLoginReward)(nil) + +func (p *ReqGetSevenLoginReward) Validate() error { + return nil +} + +type ReqGetWish struct { +} + +func NewReqGetWish() *ReqGetWish { + return &ReqGetWish{} +} + +func (p *ReqGetWish) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqGetWish) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqGetWish"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqGetWish) Equals(other *ReqGetWish) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqGetWish) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqGetWish(%+v)", *p) +} + +func (p *ReqGetWish) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqGetWish", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqGetWish)(nil) + +func (p *ReqGetWish) Validate() error { + return nil +} + +// Attributes: +// - Command +// - Args_ +// +type ReqGmCommand struct { + Command string `thrift:"Command,1" db:"Command" json:"Command"` + Args_ string `thrift:"args,2" db:"args" json:"args"` +} + +func NewReqGmCommand() *ReqGmCommand { + return &ReqGmCommand{} +} + +func (p *ReqGmCommand) GetCommand() string { + return p.Command +} + +func (p *ReqGmCommand) GetArgs_() string { + return p.Args_ +} + +func (p *ReqGmCommand) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqGmCommand) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Command = v + } + return nil +} + +func (p *ReqGmCommand) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Args_ = v + } + return nil +} + +func (p *ReqGmCommand) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqGmCommand"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqGmCommand) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Command", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Command: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Command)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Command (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Command: ", p), err) + } + return err +} + +func (p *ReqGmCommand) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "args", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:args: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Args_)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.args (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:args: ", p), err) + } + return err +} + +func (p *ReqGmCommand) Equals(other *ReqGmCommand) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Command != other.Command { + return false + } + if p.Args_ != other.Args_ { + return false + } + return true +} + +func (p *ReqGmCommand) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqGmCommand(%+v)", *p) +} + +func (p *ReqGmCommand) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqGmCommand", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqGmCommand)(nil) + +func (p *ReqGmCommand) Validate() error { + return nil +} + +type ReqGuessColor struct { +} + +func NewReqGuessColor() *ReqGuessColor { + return &ReqGuessColor{} +} + +func (p *ReqGuessColor) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqGuessColor) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqGuessColor"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqGuessColor) Equals(other *ReqGuessColor) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqGuessColor) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqGuessColor(%+v)", *p) +} + +func (p *ReqGuessColor) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqGuessColor", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqGuessColor)(nil) + +func (p *ReqGuessColor) Validate() error { + return nil +} + +type ReqGuessColorReward struct { +} + +func NewReqGuessColorReward() *ReqGuessColorReward { + return &ReqGuessColorReward{} +} + +func (p *ReqGuessColorReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqGuessColorReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqGuessColorReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqGuessColorReward) Equals(other *ReqGuessColorReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqGuessColorReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqGuessColorReward(%+v)", *p) +} + +func (p *ReqGuessColorReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqGuessColorReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqGuessColorReward)(nil) + +func (p *ReqGuessColorReward) Validate() error { + return nil +} + +// Attributes: +// - Map +// - OMap +// +type ReqGuessColorTake struct { + Map *GuessColorInfo `thrift:"Map,1" db:"Map" json:"Map"` + OMap map[int32]int32 `thrift:"OMap,2" db:"OMap" json:"OMap"` +} + +func NewReqGuessColorTake() *ReqGuessColorTake { + return &ReqGuessColorTake{} +} + +var ReqGuessColorTake_Map_DEFAULT *GuessColorInfo + +func (p *ReqGuessColorTake) GetMap() *GuessColorInfo { + if !p.IsSetMap() { + return ReqGuessColorTake_Map_DEFAULT + } + return p.Map +} + +func (p *ReqGuessColorTake) GetOMap() map[int32]int32 { + return p.OMap +} + +func (p *ReqGuessColorTake) IsSetMap() bool { + return p.Map != nil +} + +func (p *ReqGuessColorTake) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.MAP { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqGuessColorTake) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + p.Map = &GuessColorInfo{} + if err := p.Map.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.Map), err) + } + return nil +} + +func (p *ReqGuessColorTake) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.OMap = tMap + for i := 0; i < size; i++ { + var _key105 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key105 = v + } + var _val106 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val106 = v + } + p.OMap[_key105] = _val106 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ReqGuessColorTake) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqGuessColorTake"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqGuessColorTake) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Map", thrift.STRUCT, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Map: ", p), err) + } + if err := p.Map.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.Map), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Map: ", p), err) + } + return err +} + +func (p *ReqGuessColorTake) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "OMap", thrift.MAP, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:OMap: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.OMap)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.OMap { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:OMap: ", p), err) + } + return err +} + +func (p *ReqGuessColorTake) Equals(other *ReqGuessColorTake) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if !p.Map.Equals(other.Map) { + return false + } + if len(p.OMap) != len(other.OMap) { + return false + } + for k, _tgt := range p.OMap { + _src107 := other.OMap[k] + if _tgt != _src107 { + return false + } + } + return true +} + +func (p *ReqGuessColorTake) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqGuessColorTake(%+v)", *p) +} + +func (p *ReqGuessColorTake) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqGuessColorTake", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqGuessColorTake)(nil) + +func (p *ReqGuessColorTake) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqGuidePlayroom struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqGuidePlayroom() *ReqGuidePlayroom { + return &ReqGuidePlayroom{} +} + +func (p *ReqGuidePlayroom) GetId() int32 { + return p.Id +} + +func (p *ReqGuidePlayroom) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqGuidePlayroom) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqGuidePlayroom) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqGuidePlayroom"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqGuidePlayroom) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqGuidePlayroom) Equals(other *ReqGuidePlayroom) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqGuidePlayroom) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqGuidePlayroom(%+v)", *p) +} + +func (p *ReqGuidePlayroom) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqGuidePlayroom", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqGuidePlayroom)(nil) + +func (p *ReqGuidePlayroom) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqGuideReward struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqGuideReward() *ReqGuideReward { + return &ReqGuideReward{} +} + +func (p *ReqGuideReward) GetId() int32 { + return p.Id +} + +func (p *ReqGuideReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqGuideReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqGuideReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqGuideReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqGuideReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqGuideReward) Equals(other *ReqGuideReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqGuideReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqGuideReward(%+v)", *p) +} + +func (p *ReqGuideReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqGuideReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqGuideReward)(nil) + +func (p *ReqGuideReward) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Name +// +type ReqId2Verify struct { + Id string `thrift:"Id,1" db:"Id" json:"Id"` + Name string `thrift:"Name,2" db:"Name" json:"Name"` +} + +func NewReqId2Verify() *ReqId2Verify { + return &ReqId2Verify{} +} + +func (p *ReqId2Verify) GetId() string { + return p.Id +} + +func (p *ReqId2Verify) GetName() string { + return p.Name +} + +func (p *ReqId2Verify) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqId2Verify) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqId2Verify) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Name = v + } + return nil +} + +func (p *ReqId2Verify) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqId2Verify"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqId2Verify) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqId2Verify) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Name", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Name: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Name)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Name (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Name: ", p), err) + } + return err +} + +func (p *ReqId2Verify) Equals(other *ReqId2Verify) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Name != other.Name { + return false + } + return true +} + +func (p *ReqId2Verify) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqId2Verify(%+v)", *p) +} + +func (p *ReqId2Verify) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqId2Verify", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqId2Verify)(nil) + +func (p *ReqId2Verify) Validate() error { + return nil +} + +// Attributes: +// - DwUin +// +type ReqInviteFriendData struct { + DwUin int64 `thrift:"dwUin,1" db:"dwUin" json:"dwUin"` +} + +func NewReqInviteFriendData() *ReqInviteFriendData { + return &ReqInviteFriendData{} +} + +func (p *ReqInviteFriendData) GetDwUin() int64 { + return p.DwUin +} + +func (p *ReqInviteFriendData) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqInviteFriendData) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.DwUin = v + } + return nil +} + +func (p *ReqInviteFriendData) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqInviteFriendData"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqInviteFriendData) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "dwUin", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:dwUin: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.DwUin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.dwUin (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:dwUin: ", p), err) + } + return err +} + +func (p *ReqInviteFriendData) Equals(other *ReqInviteFriendData) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.DwUin != other.DwUin { + return false + } + return true +} + +func (p *ReqInviteFriendData) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqInviteFriendData(%+v)", *p) +} + +func (p *ReqInviteFriendData) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqInviteFriendData", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqInviteFriendData)(nil) + +func (p *ReqInviteFriendData) Validate() error { + return nil +} + +// Attributes: +// - Event +// - Data +// +type ReqKafkaLog struct { + Event string `thrift:"Event,1" db:"Event" json:"Event"` + Data string `thrift:"Data,2" db:"Data" json:"Data"` +} + +func NewReqKafkaLog() *ReqKafkaLog { + return &ReqKafkaLog{} +} + +func (p *ReqKafkaLog) GetEvent() string { + return p.Event +} + +func (p *ReqKafkaLog) GetData() string { + return p.Data +} + +func (p *ReqKafkaLog) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqKafkaLog) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Event = v + } + return nil +} + +func (p *ReqKafkaLog) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Data = v + } + return nil +} + +func (p *ReqKafkaLog) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqKafkaLog"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqKafkaLog) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Event", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Event: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Event)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Event (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Event: ", p), err) + } + return err +} + +func (p *ReqKafkaLog) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Data", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Data: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Data)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Data (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Data: ", p), err) + } + return err +} + +func (p *ReqKafkaLog) Equals(other *ReqKafkaLog) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Event != other.Event { + return false + } + if p.Data != other.Data { + return false + } + return true +} + +func (p *ReqKafkaLog) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqKafkaLog(%+v)", *p) +} + +func (p *ReqKafkaLog) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqKafkaLog", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqKafkaLog)(nil) + +func (p *ReqKafkaLog) Validate() error { + return nil +} + +// Attributes: +// - Key +// - Value +// +type ReqKv struct { + Key int32 `thrift:"key,1" db:"key" json:"key"` + Value string `thrift:"value,2" db:"value" json:"value"` +} + +func NewReqKv() *ReqKv { + return &ReqKv{} +} + +func (p *ReqKv) GetKey() int32 { + return p.Key +} + +func (p *ReqKv) GetValue() string { + return p.Value +} + +func (p *ReqKv) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqKv) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Key = v + } + return nil +} + +func (p *ReqKv) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Value = v + } + return nil +} + +func (p *ReqKv) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqKv"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqKv) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "key", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:key: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Key)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.key (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:key: ", p), err) + } + return err +} + +func (p *ReqKv) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "value", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:value: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Value)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.value (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:value: ", p), err) + } + return err +} + +func (p *ReqKv) Equals(other *ReqKv) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Key != other.Key { + return false + } + if p.Value != other.Value { + return false + } + return true +} + +func (p *ReqKv) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqKv(%+v)", *p) +} + +func (p *ReqKv) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqKv", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqKv)(nil) + +func (p *ReqKv) Validate() error { + return nil +} + +// Attributes: +// - Lang +// +type ReqLang struct { + Lang LANG_TYPE `thrift:"Lang,1" db:"Lang" json:"Lang"` +} + +func NewReqLang() *ReqLang { + return &ReqLang{} +} + +func (p *ReqLang) GetLang() LANG_TYPE { + return p.Lang +} + +func (p *ReqLang) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqLang) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := LANG_TYPE(v) + p.Lang = temp + } + return nil +} + +func (p *ReqLang) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqLang"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqLang) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Lang", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Lang: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Lang)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Lang (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Lang: ", p), err) + } + return err +} + +func (p *ReqLang) Equals(other *ReqLang) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Lang != other.Lang { + return false + } + return true +} + +func (p *ReqLang) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqLang(%+v)", *p) +} + +func (p *ReqLang) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqLang", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqLang)(nil) + +func (p *ReqLang) Validate() error { + return nil +} + +type ReqLimitEvent struct { +} + +func NewReqLimitEvent() *ReqLimitEvent { + return &ReqLimitEvent{} +} + +func (p *ReqLimitEvent) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqLimitEvent) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqLimitEvent"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqLimitEvent) Equals(other *ReqLimitEvent) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqLimitEvent) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqLimitEvent(%+v)", *p) +} + +func (p *ReqLimitEvent) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqLimitEvent", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqLimitEvent)(nil) + +func (p *ReqLimitEvent) Validate() error { + return nil +} + +// Attributes: +// - ChessId +// - MChessData +// +type ReqLimitEventLuckyCat struct { + ChessId int32 `thrift:"ChessId,1" db:"ChessId" json:"ChessId"` + MChessData map[string]int32 `thrift:"MChessData,2" db:"MChessData" json:"MChessData"` +} + +func NewReqLimitEventLuckyCat() *ReqLimitEventLuckyCat { + return &ReqLimitEventLuckyCat{} +} + +func (p *ReqLimitEventLuckyCat) GetChessId() int32 { + return p.ChessId +} + +func (p *ReqLimitEventLuckyCat) GetMChessData() map[string]int32 { + return p.MChessData +} + +func (p *ReqLimitEventLuckyCat) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.MAP { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqLimitEventLuckyCat) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.ChessId = v + } + return nil +} + +func (p *ReqLimitEventLuckyCat) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[string]int32, size) + p.MChessData = tMap + for i := 0; i < size; i++ { + var _key108 string + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key108 = v + } + var _val109 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val109 = v + } + p.MChessData[_key108] = _val109 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ReqLimitEventLuckyCat) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqLimitEventLuckyCat"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqLimitEventLuckyCat) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChessId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ChessId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ChessId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ChessId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ChessId: ", p), err) + } + return err +} + +func (p *ReqLimitEventLuckyCat) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MChessData", thrift.MAP, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:MChessData: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.STRING, thrift.I32, len(p.MChessData)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.MChessData { + if err := oprot.WriteString(ctx, string(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:MChessData: ", p), err) + } + return err +} + +func (p *ReqLimitEventLuckyCat) Equals(other *ReqLimitEventLuckyCat) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ChessId != other.ChessId { + return false + } + if len(p.MChessData) != len(other.MChessData) { + return false + } + for k, _tgt := range p.MChessData { + _src110 := other.MChessData[k] + if _tgt != _src110 { + return false + } + } + return true +} + +func (p *ReqLimitEventLuckyCat) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqLimitEventLuckyCat(%+v)", *p) +} + +func (p *ReqLimitEventLuckyCat) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqLimitEventLuckyCat", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqLimitEventLuckyCat)(nil) + +func (p *ReqLimitEventLuckyCat) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqLimitEventReward struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqLimitEventReward() *ReqLimitEventReward { + return &ReqLimitEventReward{} +} + +func (p *ReqLimitEventReward) GetId() int32 { + return p.Id +} + +func (p *ReqLimitEventReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqLimitEventReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqLimitEventReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqLimitEventReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqLimitEventReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqLimitEventReward) Equals(other *ReqLimitEventReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqLimitEventReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqLimitEventReward(%+v)", *p) +} + +func (p *ReqLimitEventReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqLimitEventReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqLimitEventReward)(nil) + +func (p *ReqLimitEventReward) Validate() error { + return nil +} + +type ReqLimitSenceReward struct { +} + +func NewReqLimitSenceReward() *ReqLimitSenceReward { + return &ReqLimitSenceReward{} +} + +func (p *ReqLimitSenceReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqLimitSenceReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqLimitSenceReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqLimitSenceReward) Equals(other *ReqLimitSenceReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqLimitSenceReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqLimitSenceReward(%+v)", *p) +} + +func (p *ReqLimitSenceReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqLimitSenceReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqLimitSenceReward)(nil) + +func (p *ReqLimitSenceReward) Validate() error { + return nil +} + +// Attributes: +// - UserName +// - UserPwd +// - Code +// - Device +// - Type +// +type ReqLogin struct { + UserName string `thrift:"UserName,1" db:"UserName" json:"UserName"` + UserPwd string `thrift:"UserPwd,2" db:"UserPwd" json:"UserPwd"` + Code string `thrift:"Code,3" db:"Code" json:"Code"` + Device string `thrift:"Device,4" db:"Device" json:"Device"` + Type LOGIN_TYPE `thrift:"type,5" db:"type" json:"type"` +} + +func NewReqLogin() *ReqLogin { + return &ReqLogin{} +} + +func (p *ReqLogin) GetUserName() string { + return p.UserName +} + +func (p *ReqLogin) GetUserPwd() string { + return p.UserPwd +} + +func (p *ReqLogin) GetCode() string { + return p.Code +} + +func (p *ReqLogin) GetDevice() string { + return p.Device +} + +func (p *ReqLogin) GetType() LOGIN_TYPE { + return p.Type +} + +func (p *ReqLogin) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.STRING { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.STRING { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqLogin) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.UserName = v + } + return nil +} + +func (p *ReqLogin) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.UserPwd = v + } + return nil +} + +func (p *ReqLogin) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Code = v + } + return nil +} + +func (p *ReqLogin) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Device = v + } + return nil +} + +func (p *ReqLogin) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + temp := LOGIN_TYPE(v) + p.Type = temp + } + return nil +} + +func (p *ReqLogin) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqLogin"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqLogin) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "UserName", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:UserName: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.UserName)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.UserName (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:UserName: ", p), err) + } + return err +} + +func (p *ReqLogin) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "UserPwd", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:UserPwd: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.UserPwd)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.UserPwd (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:UserPwd: ", p), err) + } + return err +} + +func (p *ReqLogin) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.STRING, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Code: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Code: ", p), err) + } + return err +} + +func (p *ReqLogin) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Device", thrift.STRING, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Device: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Device)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Device (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Device: ", p), err) + } + return err +} + +func (p *ReqLogin) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "type", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.type (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:type: ", p), err) + } + return err +} + +func (p *ReqLogin) Equals(other *ReqLogin) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.UserName != other.UserName { + return false + } + if p.UserPwd != other.UserPwd { + return false + } + if p.Code != other.Code { + return false + } + if p.Device != other.Device { + return false + } + if p.Type != other.Type { + return false + } + return true +} + +func (p *ReqLogin) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqLogin(%+v)", *p) +} + +func (p *ReqLogin) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqLogin", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqLogin)(nil) + +func (p *ReqLogin) Validate() error { + return nil +} + +// Attributes: +// - TelPhone +// +type ReqLoginCode struct { + TelPhone string `thrift:"TelPhone,1" db:"TelPhone" json:"TelPhone"` +} + +func NewReqLoginCode() *ReqLoginCode { + return &ReqLoginCode{} +} + +func (p *ReqLoginCode) GetTelPhone() string { + return p.TelPhone +} + +func (p *ReqLoginCode) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqLoginCode) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.TelPhone = v + } + return nil +} + +func (p *ReqLoginCode) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqLoginCode"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqLoginCode) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "TelPhone", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:TelPhone: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.TelPhone)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.TelPhone (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:TelPhone: ", p), err) + } + return err +} + +func (p *ReqLoginCode) Equals(other *ReqLoginCode) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.TelPhone != other.TelPhone { + return false + } + return true +} + +func (p *ReqLoginCode) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqLoginCode(%+v)", *p) +} + +func (p *ReqLoginCode) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqLoginCode", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqLoginCode)(nil) + +func (p *ReqLoginCode) Validate() error { + return nil +} + +type ReqMailList struct { +} + +func NewReqMailList() *ReqMailList { + return &ReqMailList{} +} + +func (p *ReqMailList) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqMailList) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqMailList"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqMailList) Equals(other *ReqMailList) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqMailList) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqMailList(%+v)", *p) +} + +func (p *ReqMailList) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqMailList", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqMailList)(nil) + +func (p *ReqMailList) Validate() error { + return nil +} + +// Attributes: +// - Id +// - CardId +// +type ReqMasterCard struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + CardId int32 `thrift:"CardId,2" db:"CardId" json:"CardId"` +} + +func NewReqMasterCard() *ReqMasterCard { + return &ReqMasterCard{} +} + +func (p *ReqMasterCard) GetId() int32 { + return p.Id +} + +func (p *ReqMasterCard) GetCardId() int32 { + return p.CardId +} + +func (p *ReqMasterCard) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqMasterCard) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqMasterCard) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.CardId = v + } + return nil +} + +func (p *ReqMasterCard) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqMasterCard"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqMasterCard) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqMasterCard) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "CardId", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:CardId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.CardId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.CardId (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:CardId: ", p), err) + } + return err +} + +func (p *ReqMasterCard) Equals(other *ReqMasterCard) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.CardId != other.CardId { + return false + } + return true +} + +func (p *ReqMasterCard) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqMasterCard(%+v)", *p) +} + +func (p *ReqMasterCard) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqMasterCard", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqMasterCard)(nil) + +func (p *ReqMasterCard) Validate() error { + return nil +} + +type ReqMining struct { +} + +func NewReqMining() *ReqMining { + return &ReqMining{} +} + +func (p *ReqMining) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqMining) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqMining"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqMining) Equals(other *ReqMining) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqMining) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqMining(%+v)", *p) +} + +func (p *ReqMining) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqMining", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqMining)(nil) + +func (p *ReqMining) Validate() error { + return nil +} + +type ReqMiningReward struct { +} + +func NewReqMiningReward() *ReqMiningReward { + return &ReqMiningReward{} +} + +func (p *ReqMiningReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqMiningReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqMiningReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqMiningReward) Equals(other *ReqMiningReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqMiningReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqMiningReward(%+v)", *p) +} + +func (p *ReqMiningReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqMiningReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqMiningReward)(nil) + +func (p *ReqMiningReward) Validate() error { + return nil +} + +// Attributes: +// - Map +// - Gem +// +type ReqMiningTake struct { + Map map[int32]string `thrift:"Map,1" db:"Map" json:"Map"` + Gem int32 `thrift:"Gem,2" db:"Gem" json:"Gem"` +} + +func NewReqMiningTake() *ReqMiningTake { + return &ReqMiningTake{} +} + +func (p *ReqMiningTake) GetMap() map[int32]string { + return p.Map +} + +func (p *ReqMiningTake) GetGem() int32 { + return p.Gem +} + +func (p *ReqMiningTake) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.MAP { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqMiningTake) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]string, size) + p.Map = tMap + for i := 0; i < size; i++ { + var _key111 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key111 = v + } + var _val112 string + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val112 = v + } + p.Map[_key111] = _val112 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ReqMiningTake) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Gem = v + } + return nil +} + +func (p *ReqMiningTake) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqMiningTake"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqMiningTake) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Map", thrift.MAP, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Map: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.STRING, len(p.Map)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Map { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteString(ctx, string(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Map: ", p), err) + } + return err +} + +func (p *ReqMiningTake) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Gem", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Gem: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Gem)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Gem (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Gem: ", p), err) + } + return err +} + +func (p *ReqMiningTake) Equals(other *ReqMiningTake) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.Map) != len(other.Map) { + return false + } + for k, _tgt := range p.Map { + _src113 := other.Map[k] + if _tgt != _src113 { + return false + } + } + if p.Gem != other.Gem { + return false + } + return true +} + +func (p *ReqMiningTake) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqMiningTake(%+v)", *p) +} + +func (p *ReqMiningTake) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqMiningTake", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqMiningTake)(nil) + +func (p *ReqMiningTake) Validate() error { + return nil +} + +// Attributes: +// - DwUin +// +type ReqOfflineReconnect struct { + DwUin int64 `thrift:"dwUin,1" db:"dwUin" json:"dwUin"` +} + +func NewReqOfflineReconnect() *ReqOfflineReconnect { + return &ReqOfflineReconnect{} +} + +func (p *ReqOfflineReconnect) GetDwUin() int64 { + return p.DwUin +} + +func (p *ReqOfflineReconnect) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqOfflineReconnect) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.DwUin = v + } + return nil +} + +func (p *ReqOfflineReconnect) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqOfflineReconnect"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqOfflineReconnect) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "dwUin", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:dwUin: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.DwUin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.dwUin (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:dwUin: ", p), err) + } + return err +} + +func (p *ReqOfflineReconnect) Equals(other *ReqOfflineReconnect) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.DwUin != other.DwUin { + return false + } + return true +} + +func (p *ReqOfflineReconnect) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqOfflineReconnect(%+v)", *p) +} + +func (p *ReqOfflineReconnect) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqOfflineReconnect", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqOfflineReconnect)(nil) + +func (p *ReqOfflineReconnect) Validate() error { + return nil +} + +// Attributes: +// - DwUin +// - BindAccountId +// +type ReqOnlyBindFacebook struct { + DwUin int64 `thrift:"dwUin,1" db:"dwUin" json:"dwUin"` + BindAccountId string `thrift:"BindAccountId,2" db:"BindAccountId" json:"BindAccountId"` +} + +func NewReqOnlyBindFacebook() *ReqOnlyBindFacebook { + return &ReqOnlyBindFacebook{} +} + +func (p *ReqOnlyBindFacebook) GetDwUin() int64 { + return p.DwUin +} + +func (p *ReqOnlyBindFacebook) GetBindAccountId() string { + return p.BindAccountId +} + +func (p *ReqOnlyBindFacebook) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqOnlyBindFacebook) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.DwUin = v + } + return nil +} + +func (p *ReqOnlyBindFacebook) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.BindAccountId = v + } + return nil +} + +func (p *ReqOnlyBindFacebook) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqOnlyBindFacebook"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqOnlyBindFacebook) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "dwUin", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:dwUin: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.DwUin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.dwUin (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:dwUin: ", p), err) + } + return err +} + +func (p *ReqOnlyBindFacebook) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "BindAccountId", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:BindAccountId: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.BindAccountId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.BindAccountId (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:BindAccountId: ", p), err) + } + return err +} + +func (p *ReqOnlyBindFacebook) Equals(other *ReqOnlyBindFacebook) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.DwUin != other.DwUin { + return false + } + if p.BindAccountId != other.BindAccountId { + return false + } + return true +} + +func (p *ReqOnlyBindFacebook) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqOnlyBindFacebook(%+v)", *p) +} + +func (p *ReqOnlyBindFacebook) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqOnlyBindFacebook", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqOnlyBindFacebook)(nil) + +func (p *ReqOnlyBindFacebook) Validate() error { + return nil +} + +// Attributes: +// - OrderSn +// - Status +// - ChannelOrderSn +// +type ReqOrderShipping struct { + OrderSn string `thrift:"OrderSn,1" db:"OrderSn" json:"OrderSn"` + Status int32 `thrift:"Status,2" db:"Status" json:"Status"` + ChannelOrderSn string `thrift:"ChannelOrderSn,3" db:"ChannelOrderSn" json:"ChannelOrderSn"` +} + +func NewReqOrderShipping() *ReqOrderShipping { + return &ReqOrderShipping{} +} + +func (p *ReqOrderShipping) GetOrderSn() string { + return p.OrderSn +} + +func (p *ReqOrderShipping) GetStatus() int32 { + return p.Status +} + +func (p *ReqOrderShipping) GetChannelOrderSn() string { + return p.ChannelOrderSn +} + +func (p *ReqOrderShipping) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.STRING { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqOrderShipping) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.OrderSn = v + } + return nil +} + +func (p *ReqOrderShipping) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Status = v + } + return nil +} + +func (p *ReqOrderShipping) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.ChannelOrderSn = v + } + return nil +} + +func (p *ReqOrderShipping) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqOrderShipping"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqOrderShipping) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "OrderSn", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:OrderSn: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.OrderSn)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.OrderSn (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:OrderSn: ", p), err) + } + return err +} + +func (p *ReqOrderShipping) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Status", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Status: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Status)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Status (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Status: ", p), err) + } + return err +} + +func (p *ReqOrderShipping) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChannelOrderSn", thrift.STRING, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:ChannelOrderSn: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.ChannelOrderSn)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ChannelOrderSn (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:ChannelOrderSn: ", p), err) + } + return err +} + +func (p *ReqOrderShipping) Equals(other *ReqOrderShipping) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.OrderSn != other.OrderSn { + return false + } + if p.Status != other.Status { + return false + } + if p.ChannelOrderSn != other.ChannelOrderSn { + return false + } + return true +} + +func (p *ReqOrderShipping) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqOrderShipping(%+v)", *p) +} + +func (p *ReqOrderShipping) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqOrderShipping", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqOrderShipping)(nil) + +func (p *ReqOrderShipping) Validate() error { + return nil +} + +type ReqPetFur struct { +} + +func NewReqPetFur() *ReqPetFur { + return &ReqPetFur{} +} + +func (p *ReqPetFur) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPetFur) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPetFur"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPetFur) Equals(other *ReqPetFur) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqPetFur) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPetFur(%+v)", *p) +} + +func (p *ReqPetFur) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPetFur", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPetFur)(nil) + +func (p *ReqPetFur) Validate() error { + return nil +} + +// Attributes: +// - FurId +// +type ReqPetFurBuy struct { + FurId int32 `thrift:"FurId,1" db:"FurId" json:"FurId"` +} + +func NewReqPetFurBuy() *ReqPetFurBuy { + return &ReqPetFurBuy{} +} + +func (p *ReqPetFurBuy) GetFurId() int32 { + return p.FurId +} + +func (p *ReqPetFurBuy) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPetFurBuy) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.FurId = v + } + return nil +} + +func (p *ReqPetFurBuy) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPetFurBuy"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPetFurBuy) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "FurId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:FurId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.FurId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.FurId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:FurId: ", p), err) + } + return err +} + +func (p *ReqPetFurBuy) Equals(other *ReqPetFurBuy) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.FurId != other.FurId { + return false + } + return true +} + +func (p *ReqPetFurBuy) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPetFurBuy(%+v)", *p) +} + +func (p *ReqPetFurBuy) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPetFurBuy", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPetFurBuy)(nil) + +func (p *ReqPetFurBuy) Validate() error { + return nil +} + +type ReqPiggyBankReward struct { +} + +func NewReqPiggyBankReward() *ReqPiggyBankReward { + return &ReqPiggyBankReward{} +} + +func (p *ReqPiggyBankReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPiggyBankReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPiggyBankReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPiggyBankReward) Equals(other *ReqPiggyBankReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqPiggyBankReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPiggyBankReward(%+v)", *p) +} + +func (p *ReqPiggyBankReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPiggyBankReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPiggyBankReward)(nil) + +func (p *ReqPiggyBankReward) Validate() error { + return nil +} + +type ReqPlayerAsset struct { +} + +func NewReqPlayerAsset() *ReqPlayerAsset { + return &ReqPlayerAsset{} +} + +func (p *ReqPlayerAsset) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayerAsset) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayerAsset"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayerAsset) Equals(other *ReqPlayerAsset) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqPlayerAsset) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayerAsset(%+v)", *p) +} + +func (p *ReqPlayerAsset) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayerAsset", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayerAsset)(nil) + +func (p *ReqPlayerAsset) Validate() error { + return nil +} + +// Attributes: +// - DwUin +// +type ReqPlayerBaseInfo struct { + DwUin int64 `thrift:"dwUin,1" db:"dwUin" json:"dwUin"` +} + +func NewReqPlayerBaseInfo() *ReqPlayerBaseInfo { + return &ReqPlayerBaseInfo{} +} + +func (p *ReqPlayerBaseInfo) GetDwUin() int64 { + return p.DwUin +} + +func (p *ReqPlayerBaseInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayerBaseInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.DwUin = v + } + return nil +} + +func (p *ReqPlayerBaseInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayerBaseInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayerBaseInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "dwUin", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:dwUin: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.DwUin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.dwUin (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:dwUin: ", p), err) + } + return err +} + +func (p *ReqPlayerBaseInfo) Equals(other *ReqPlayerBaseInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.DwUin != other.DwUin { + return false + } + return true +} + +func (p *ReqPlayerBaseInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayerBaseInfo(%+v)", *p) +} + +func (p *ReqPlayerBaseInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayerBaseInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayerBaseInfo)(nil) + +func (p *ReqPlayerBaseInfo) Validate() error { + return nil +} + +// Attributes: +// - DwUin +// +type ReqPlayerBriefProfileData struct { + DwUin int64 `thrift:"dwUin,1" db:"dwUin" json:"dwUin"` +} + +func NewReqPlayerBriefProfileData() *ReqPlayerBriefProfileData { + return &ReqPlayerBriefProfileData{} +} + +func (p *ReqPlayerBriefProfileData) GetDwUin() int64 { + return p.DwUin +} + +func (p *ReqPlayerBriefProfileData) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayerBriefProfileData) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.DwUin = v + } + return nil +} + +func (p *ReqPlayerBriefProfileData) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayerBriefProfileData"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayerBriefProfileData) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "dwUin", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:dwUin: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.DwUin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.dwUin (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:dwUin: ", p), err) + } + return err +} + +func (p *ReqPlayerBriefProfileData) Equals(other *ReqPlayerBriefProfileData) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.DwUin != other.DwUin { + return false + } + return true +} + +func (p *ReqPlayerBriefProfileData) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayerBriefProfileData(%+v)", *p) +} + +func (p *ReqPlayerBriefProfileData) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayerBriefProfileData", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayerBriefProfileData)(nil) + +func (p *ReqPlayerBriefProfileData) Validate() error { + return nil +} + +// Attributes: +// - DwUin +// +type ReqPlayerChessData struct { + DwUin int64 `thrift:"dwUin,1" db:"dwUin" json:"dwUin"` +} + +func NewReqPlayerChessData() *ReqPlayerChessData { + return &ReqPlayerChessData{} +} + +func (p *ReqPlayerChessData) GetDwUin() int64 { + return p.DwUin +} + +func (p *ReqPlayerChessData) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayerChessData) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.DwUin = v + } + return nil +} + +func (p *ReqPlayerChessData) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayerChessData"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayerChessData) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "dwUin", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:dwUin: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.DwUin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.dwUin (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:dwUin: ", p), err) + } + return err +} + +func (p *ReqPlayerChessData) Equals(other *ReqPlayerChessData) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.DwUin != other.DwUin { + return false + } + return true +} + +func (p *ReqPlayerChessData) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayerChessData(%+v)", *p) +} + +func (p *ReqPlayerChessData) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayerChessData", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayerChessData)(nil) + +func (p *ReqPlayerChessData) Validate() error { + return nil +} + +// Attributes: +// - DwUin +// +type ReqPlayerProfileData struct { + DwUin int64 `thrift:"dwUin,1" db:"dwUin" json:"dwUin"` +} + +func NewReqPlayerProfileData() *ReqPlayerProfileData { + return &ReqPlayerProfileData{} +} + +func (p *ReqPlayerProfileData) GetDwUin() int64 { + return p.DwUin +} + +func (p *ReqPlayerProfileData) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayerProfileData) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.DwUin = v + } + return nil +} + +func (p *ReqPlayerProfileData) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayerProfileData"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayerProfileData) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "dwUin", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:dwUin: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.DwUin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.dwUin (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:dwUin: ", p), err) + } + return err +} + +func (p *ReqPlayerProfileData) Equals(other *ReqPlayerProfileData) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.DwUin != other.DwUin { + return false + } + return true +} + +func (p *ReqPlayerProfileData) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayerProfileData(%+v)", *p) +} + +func (p *ReqPlayerProfileData) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayerProfileData", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayerProfileData)(nil) + +func (p *ReqPlayerProfileData) Validate() error { + return nil +} + +type ReqPlayroom struct { +} + +func NewReqPlayroom() *ReqPlayroom { + return &ReqPlayroom{} +} + +func (p *ReqPlayroom) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayroom) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayroom"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayroom) Equals(other *ReqPlayroom) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqPlayroom) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayroom(%+v)", *p) +} + +func (p *ReqPlayroom) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayroom", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayroom)(nil) + +func (p *ReqPlayroom) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqPlayroomBuyItem struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqPlayroomBuyItem() *ReqPlayroomBuyItem { + return &ReqPlayroomBuyItem{} +} + +func (p *ReqPlayroomBuyItem) GetId() int32 { + return p.Id +} + +func (p *ReqPlayroomBuyItem) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayroomBuyItem) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqPlayroomBuyItem) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayroomBuyItem"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayroomBuyItem) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqPlayroomBuyItem) Equals(other *ReqPlayroomBuyItem) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqPlayroomBuyItem) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayroomBuyItem(%+v)", *p) +} + +func (p *ReqPlayroomBuyItem) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayroomBuyItem", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayroomBuyItem)(nil) + +func (p *ReqPlayroomBuyItem) Validate() error { + return nil +} + +// Attributes: +// - Uid +// +type ReqPlayroomChip struct { + Uid []int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` +} + +func NewReqPlayroomChip() *ReqPlayroomChip { + return &ReqPlayroomChip{} +} + +func (p *ReqPlayroomChip) GetUid() []int64 { + return p.Uid +} + +func (p *ReqPlayroomChip) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayroomChip) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int64, 0, size) + p.Uid = tSlice + for i := 0; i < size; i++ { + var _elem114 int64 + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem114 = v + } + p.Uid = append(p.Uid, _elem114) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ReqPlayroomChip) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayroomChip"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayroomChip) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I64, len(p.Uid)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Uid { + if err := oprot.WriteI64(ctx, int64(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *ReqPlayroomChip) Equals(other *ReqPlayroomChip) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.Uid) != len(other.Uid) { + return false + } + for i, _tgt := range p.Uid { + _src115 := other.Uid[i] + if _tgt != _src115 { + return false + } + } + return true +} + +func (p *ReqPlayroomChip) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayroomChip(%+v)", *p) +} + +func (p *ReqPlayroomChip) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayroomChip", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayroomChip)(nil) + +func (p *ReqPlayroomChip) Validate() error { + return nil +} + +type ReqPlayroomDraw struct { +} + +func NewReqPlayroomDraw() *ReqPlayroomDraw { + return &ReqPlayroomDraw{} +} + +func (p *ReqPlayroomDraw) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayroomDraw) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayroomDraw"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayroomDraw) Equals(other *ReqPlayroomDraw) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqPlayroomDraw) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayroomDraw(%+v)", *p) +} + +func (p *ReqPlayroomDraw) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayroomDraw", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayroomDraw)(nil) + +func (p *ReqPlayroomDraw) Validate() error { + return nil +} + +// Attributes: +// - DressSet +// +type ReqPlayroomDressSet struct { + DressSet map[int32]int32 `thrift:"DressSet,1" db:"DressSet" json:"DressSet"` +} + +func NewReqPlayroomDressSet() *ReqPlayroomDressSet { + return &ReqPlayroomDressSet{} +} + +func (p *ReqPlayroomDressSet) GetDressSet() map[int32]int32 { + return p.DressSet +} + +func (p *ReqPlayroomDressSet) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.MAP { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayroomDressSet) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.DressSet = tMap + for i := 0; i < size; i++ { + var _key116 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key116 = v + } + var _val117 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val117 = v + } + p.DressSet[_key116] = _val117 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ReqPlayroomDressSet) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayroomDressSet"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayroomDressSet) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "DressSet", thrift.MAP, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:DressSet: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.DressSet)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.DressSet { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:DressSet: ", p), err) + } + return err +} + +func (p *ReqPlayroomDressSet) Equals(other *ReqPlayroomDressSet) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.DressSet) != len(other.DressSet) { + return false + } + for k, _tgt := range p.DressSet { + _src118 := other.DressSet[k] + if _tgt != _src118 { + return false + } + } + return true +} + +func (p *ReqPlayroomDressSet) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayroomDressSet(%+v)", *p) +} + +func (p *ReqPlayroomDressSet) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayroomDressSet", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayroomDressSet)(nil) + +func (p *ReqPlayroomDressSet) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqPlayroomFlip struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqPlayroomFlip() *ReqPlayroomFlip { + return &ReqPlayroomFlip{} +} + +func (p *ReqPlayroomFlip) GetId() int32 { + return p.Id +} + +func (p *ReqPlayroomFlip) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayroomFlip) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqPlayroomFlip) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayroomFlip"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayroomFlip) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqPlayroomFlip) Equals(other *ReqPlayroomFlip) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqPlayroomFlip) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayroomFlip(%+v)", *p) +} + +func (p *ReqPlayroomFlip) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayroomFlip", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayroomFlip)(nil) + +func (p *ReqPlayroomFlip) Validate() error { + return nil +} + +// Attributes: +// - EmojiId +// +type ReqPlayroomFlipReward struct { + EmojiId int32 `thrift:"EmojiId,1" db:"EmojiId" json:"EmojiId"` +} + +func NewReqPlayroomFlipReward() *ReqPlayroomFlipReward { + return &ReqPlayroomFlipReward{} +} + +func (p *ReqPlayroomFlipReward) GetEmojiId() int32 { + return p.EmojiId +} + +func (p *ReqPlayroomFlipReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayroomFlipReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.EmojiId = v + } + return nil +} + +func (p *ReqPlayroomFlipReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayroomFlipReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayroomFlipReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EmojiId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:EmojiId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.EmojiId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EmojiId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:EmojiId: ", p), err) + } + return err +} + +func (p *ReqPlayroomFlipReward) Equals(other *ReqPlayroomFlipReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.EmojiId != other.EmojiId { + return false + } + return true +} + +func (p *ReqPlayroomFlipReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayroomFlipReward(%+v)", *p) +} + +func (p *ReqPlayroomFlipReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayroomFlipReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayroomFlipReward)(nil) + +func (p *ReqPlayroomFlipReward) Validate() error { + return nil +} + +// Attributes: +// - Type +// - EmojiId +// +type ReqPlayroomGame struct { + Type int32 `thrift:"Type,1" db:"Type" json:"Type"` + EmojiId int32 `thrift:"EmojiId,2" db:"EmojiId" json:"EmojiId"` +} + +func NewReqPlayroomGame() *ReqPlayroomGame { + return &ReqPlayroomGame{} +} + +func (p *ReqPlayroomGame) GetType() int32 { + return p.Type +} + +func (p *ReqPlayroomGame) GetEmojiId() int32 { + return p.EmojiId +} + +func (p *ReqPlayroomGame) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayroomGame) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ReqPlayroomGame) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.EmojiId = v + } + return nil +} + +func (p *ReqPlayroomGame) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayroomGame"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayroomGame) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Type: ", p), err) + } + return err +} + +func (p *ReqPlayroomGame) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EmojiId", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:EmojiId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.EmojiId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EmojiId (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:EmojiId: ", p), err) + } + return err +} + +func (p *ReqPlayroomGame) Equals(other *ReqPlayroomGame) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Type != other.Type { + return false + } + if p.EmojiId != other.EmojiId { + return false + } + return true +} + +func (p *ReqPlayroomGame) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayroomGame(%+v)", *p) +} + +func (p *ReqPlayroomGame) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayroomGame", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayroomGame)(nil) + +func (p *ReqPlayroomGame) Validate() error { + return nil +} + +// Attributes: +// - Type +// - SelectId +// +type ReqPlayroomGameShowReward struct { + Type int32 `thrift:"Type,1" db:"Type" json:"Type"` + SelectId int32 `thrift:"SelectId,2" db:"SelectId" json:"SelectId"` +} + +func NewReqPlayroomGameShowReward() *ReqPlayroomGameShowReward { + return &ReqPlayroomGameShowReward{} +} + +func (p *ReqPlayroomGameShowReward) GetType() int32 { + return p.Type +} + +func (p *ReqPlayroomGameShowReward) GetSelectId() int32 { + return p.SelectId +} + +func (p *ReqPlayroomGameShowReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayroomGameShowReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ReqPlayroomGameShowReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.SelectId = v + } + return nil +} + +func (p *ReqPlayroomGameShowReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayroomGameShowReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayroomGameShowReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Type: ", p), err) + } + return err +} + +func (p *ReqPlayroomGameShowReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "SelectId", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:SelectId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.SelectId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.SelectId (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:SelectId: ", p), err) + } + return err +} + +func (p *ReqPlayroomGameShowReward) Equals(other *ReqPlayroomGameShowReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Type != other.Type { + return false + } + if p.SelectId != other.SelectId { + return false + } + return true +} + +func (p *ReqPlayroomGameShowReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayroomGameShowReward(%+v)", *p) +} + +func (p *ReqPlayroomGameShowReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayroomGameShowReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayroomGameShowReward)(nil) + +func (p *ReqPlayroomGameShowReward) Validate() error { + return nil +} + +// Attributes: +// - Type +// +type ReqPlayroomGuide struct { + Type int32 `thrift:"Type,1" db:"Type" json:"Type"` +} + +func NewReqPlayroomGuide() *ReqPlayroomGuide { + return &ReqPlayroomGuide{} +} + +func (p *ReqPlayroomGuide) GetType() int32 { + return p.Type +} + +func (p *ReqPlayroomGuide) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayroomGuide) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ReqPlayroomGuide) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayroomGuide"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayroomGuide) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Type: ", p), err) + } + return err +} + +func (p *ReqPlayroomGuide) Equals(other *ReqPlayroomGuide) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Type != other.Type { + return false + } + return true +} + +func (p *ReqPlayroomGuide) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayroomGuide(%+v)", *p) +} + +func (p *ReqPlayroomGuide) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayroomGuide", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayroomGuide)(nil) + +func (p *ReqPlayroomGuide) Validate() error { + return nil +} + +// Attributes: +// - Uid +// +type ReqPlayroomInfo struct { + Uid int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` +} + +func NewReqPlayroomInfo() *ReqPlayroomInfo { + return &ReqPlayroomInfo{} +} + +func (p *ReqPlayroomInfo) GetUid() int64 { + return p.Uid +} + +func (p *ReqPlayroomInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayroomInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ReqPlayroomInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayroomInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayroomInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *ReqPlayroomInfo) Equals(other *ReqPlayroomInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Uid != other.Uid { + return false + } + return true +} + +func (p *ReqPlayroomInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayroomInfo(%+v)", *p) +} + +func (p *ReqPlayroomInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayroomInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayroomInfo)(nil) + +func (p *ReqPlayroomInfo) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Type +// +type ReqPlayroomInteract struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Type int32 `thrift:"Type,2" db:"Type" json:"Type"` +} + +func NewReqPlayroomInteract() *ReqPlayroomInteract { + return &ReqPlayroomInteract{} +} + +func (p *ReqPlayroomInteract) GetId() int32 { + return p.Id +} + +func (p *ReqPlayroomInteract) GetType() int32 { + return p.Type +} + +func (p *ReqPlayroomInteract) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayroomInteract) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqPlayroomInteract) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ReqPlayroomInteract) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayroomInteract"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayroomInteract) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqPlayroomInteract) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Type: ", p), err) + } + return err +} + +func (p *ReqPlayroomInteract) Equals(other *ReqPlayroomInteract) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Type != other.Type { + return false + } + return true +} + +func (p *ReqPlayroomInteract) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayroomInteract(%+v)", *p) +} + +func (p *ReqPlayroomInteract) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayroomInteract", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayroomInteract)(nil) + +func (p *ReqPlayroomInteract) Validate() error { + return nil +} + +type ReqPlayroomLose struct { +} + +func NewReqPlayroomLose() *ReqPlayroomLose { + return &ReqPlayroomLose{} +} + +func (p *ReqPlayroomLose) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayroomLose) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayroomLose"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayroomLose) Equals(other *ReqPlayroomLose) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqPlayroomLose) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayroomLose(%+v)", *p) +} + +func (p *ReqPlayroomLose) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayroomLose", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayroomLose)(nil) + +func (p *ReqPlayroomLose) Validate() error { + return nil +} + +// Attributes: +// - OldChessId +// - NewChessId_ +// - CostDia +// - Type +// - MChessData +// +type ReqPlayroomOutline struct { + OldChessId int32 `thrift:"OldChessId,1" db:"OldChessId" json:"OldChessId"` + NewChessId_ int32 `thrift:"NewChessId,2" db:"NewChessId" json:"NewChessId"` + CostDia int32 `thrift:"CostDia,3" db:"CostDia" json:"CostDia"` + Type int32 `thrift:"Type,4" db:"Type" json:"Type"` + MChessData map[string]int32 `thrift:"MChessData,5" db:"MChessData" json:"MChessData"` +} + +func NewReqPlayroomOutline() *ReqPlayroomOutline { + return &ReqPlayroomOutline{} +} + +func (p *ReqPlayroomOutline) GetOldChessId() int32 { + return p.OldChessId +} + +func (p *ReqPlayroomOutline) GetNewChessId_() int32 { + return p.NewChessId_ +} + +func (p *ReqPlayroomOutline) GetCostDia() int32 { + return p.CostDia +} + +func (p *ReqPlayroomOutline) GetType() int32 { + return p.Type +} + +func (p *ReqPlayroomOutline) GetMChessData() map[string]int32 { + return p.MChessData +} + +func (p *ReqPlayroomOutline) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.MAP { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayroomOutline) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.OldChessId = v + } + return nil +} + +func (p *ReqPlayroomOutline) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.NewChessId_ = v + } + return nil +} + +func (p *ReqPlayroomOutline) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.CostDia = v + } + return nil +} + +func (p *ReqPlayroomOutline) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ReqPlayroomOutline) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[string]int32, size) + p.MChessData = tMap + for i := 0; i < size; i++ { + var _key119 string + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key119 = v + } + var _val120 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val120 = v + } + p.MChessData[_key119] = _val120 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ReqPlayroomOutline) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayroomOutline"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayroomOutline) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "OldChessId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:OldChessId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.OldChessId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.OldChessId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:OldChessId: ", p), err) + } + return err +} + +func (p *ReqPlayroomOutline) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "NewChessId", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:NewChessId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.NewChessId_)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.NewChessId (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:NewChessId: ", p), err) + } + return err +} + +func (p *ReqPlayroomOutline) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "CostDia", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:CostDia: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.CostDia)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.CostDia (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:CostDia: ", p), err) + } + return err +} + +func (p *ReqPlayroomOutline) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Type: ", p), err) + } + return err +} + +func (p *ReqPlayroomOutline) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MChessData", thrift.MAP, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:MChessData: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.STRING, thrift.I32, len(p.MChessData)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.MChessData { + if err := oprot.WriteString(ctx, string(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:MChessData: ", p), err) + } + return err +} + +func (p *ReqPlayroomOutline) Equals(other *ReqPlayroomOutline) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.OldChessId != other.OldChessId { + return false + } + if p.NewChessId_ != other.NewChessId_ { + return false + } + if p.CostDia != other.CostDia { + return false + } + if p.Type != other.Type { + return false + } + if len(p.MChessData) != len(other.MChessData) { + return false + } + for k, _tgt := range p.MChessData { + _src121 := other.MChessData[k] + if _tgt != _src121 { + return false + } + } + return true +} + +func (p *ReqPlayroomOutline) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayroomOutline(%+v)", *p) +} + +func (p *ReqPlayroomOutline) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayroomOutline", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayroomOutline)(nil) + +func (p *ReqPlayroomOutline) Validate() error { + return nil +} + +// Attributes: +// - PetAirSet +// +type ReqPlayroomPetAirSet struct { + PetAirSet int32 `thrift:"PetAirSet,1" db:"PetAirSet" json:"PetAirSet"` +} + +func NewReqPlayroomPetAirSet() *ReqPlayroomPetAirSet { + return &ReqPlayroomPetAirSet{} +} + +func (p *ReqPlayroomPetAirSet) GetPetAirSet() int32 { + return p.PetAirSet +} + +func (p *ReqPlayroomPetAirSet) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayroomPetAirSet) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.PetAirSet = v + } + return nil +} + +func (p *ReqPlayroomPetAirSet) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayroomPetAirSet"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayroomPetAirSet) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "PetAirSet", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:PetAirSet: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.PetAirSet)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.PetAirSet (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:PetAirSet: ", p), err) + } + return err +} + +func (p *ReqPlayroomPetAirSet) Equals(other *ReqPlayroomPetAirSet) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.PetAirSet != other.PetAirSet { + return false + } + return true +} + +func (p *ReqPlayroomPetAirSet) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayroomPetAirSet(%+v)", *p) +} + +func (p *ReqPlayroomPetAirSet) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayroomPetAirSet", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayroomPetAirSet)(nil) + +func (p *ReqPlayroomPetAirSet) Validate() error { + return nil +} + +type ReqPlayroomRest struct { +} + +func NewReqPlayroomRest() *ReqPlayroomRest { + return &ReqPlayroomRest{} +} + +func (p *ReqPlayroomRest) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayroomRest) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayroomRest"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayroomRest) Equals(other *ReqPlayroomRest) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqPlayroomRest) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayroomRest(%+v)", *p) +} + +func (p *ReqPlayroomRest) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayroomRest", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayroomRest)(nil) + +func (p *ReqPlayroomRest) Validate() error { + return nil +} + +// Attributes: +// - Id +// - EmojiId +// +type ReqPlayroomSelectReward struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + EmojiId int32 `thrift:"EmojiId,2" db:"EmojiId" json:"EmojiId"` +} + +func NewReqPlayroomSelectReward() *ReqPlayroomSelectReward { + return &ReqPlayroomSelectReward{} +} + +func (p *ReqPlayroomSelectReward) GetId() int32 { + return p.Id +} + +func (p *ReqPlayroomSelectReward) GetEmojiId() int32 { + return p.EmojiId +} + +func (p *ReqPlayroomSelectReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayroomSelectReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqPlayroomSelectReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.EmojiId = v + } + return nil +} + +func (p *ReqPlayroomSelectReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayroomSelectReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayroomSelectReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqPlayroomSelectReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EmojiId", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:EmojiId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.EmojiId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EmojiId (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:EmojiId: ", p), err) + } + return err +} + +func (p *ReqPlayroomSelectReward) Equals(other *ReqPlayroomSelectReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.EmojiId != other.EmojiId { + return false + } + return true +} + +func (p *ReqPlayroomSelectReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayroomSelectReward(%+v)", *p) +} + +func (p *ReqPlayroomSelectReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayroomSelectReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayroomSelectReward)(nil) + +func (p *ReqPlayroomSelectReward) Validate() error { + return nil +} + +// Attributes: +// - Playroom +// +type ReqPlayroomSetRoom struct { + Playroom map[int32]int32 `thrift:"Playroom,1" db:"Playroom" json:"Playroom"` +} + +func NewReqPlayroomSetRoom() *ReqPlayroomSetRoom { + return &ReqPlayroomSetRoom{} +} + +func (p *ReqPlayroomSetRoom) GetPlayroom() map[int32]int32 { + return p.Playroom +} + +func (p *ReqPlayroomSetRoom) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.MAP { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayroomSetRoom) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.Playroom = tMap + for i := 0; i < size; i++ { + var _key122 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key122 = v + } + var _val123 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val123 = v + } + p.Playroom[_key122] = _val123 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ReqPlayroomSetRoom) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayroomSetRoom"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayroomSetRoom) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Playroom", thrift.MAP, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Playroom: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.Playroom)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Playroom { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Playroom: ", p), err) + } + return err +} + +func (p *ReqPlayroomSetRoom) Equals(other *ReqPlayroomSetRoom) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.Playroom) != len(other.Playroom) { + return false + } + for k, _tgt := range p.Playroom { + _src124 := other.Playroom[k] + if _tgt != _src124 { + return false + } + } + return true +} + +func (p *ReqPlayroomSetRoom) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayroomSetRoom(%+v)", *p) +} + +func (p *ReqPlayroomSetRoom) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayroomSetRoom", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayroomSetRoom)(nil) + +func (p *ReqPlayroomSetRoom) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Num +// +type ReqPlayroomShop struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Num int32 `thrift:"Num,2" db:"Num" json:"Num"` +} + +func NewReqPlayroomShop() *ReqPlayroomShop { + return &ReqPlayroomShop{} +} + +func (p *ReqPlayroomShop) GetId() int32 { + return p.Id +} + +func (p *ReqPlayroomShop) GetNum() int32 { + return p.Num +} + +func (p *ReqPlayroomShop) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayroomShop) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqPlayroomShop) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Num = v + } + return nil +} + +func (p *ReqPlayroomShop) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayroomShop"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayroomShop) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqPlayroomShop) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Num", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Num: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Num)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Num (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Num: ", p), err) + } + return err +} + +func (p *ReqPlayroomShop) Equals(other *ReqPlayroomShop) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Num != other.Num { + return false + } + return true +} + +func (p *ReqPlayroomShop) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayroomShop(%+v)", *p) +} + +func (p *ReqPlayroomShop) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayroomShop", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayroomShop)(nil) + +func (p *ReqPlayroomShop) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqPlayroomTask struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqPlayroomTask() *ReqPlayroomTask { + return &ReqPlayroomTask{} +} + +func (p *ReqPlayroomTask) GetId() int32 { + return p.Id +} + +func (p *ReqPlayroomTask) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayroomTask) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqPlayroomTask) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayroomTask"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayroomTask) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqPlayroomTask) Equals(other *ReqPlayroomTask) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqPlayroomTask) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayroomTask(%+v)", *p) +} + +func (p *ReqPlayroomTask) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayroomTask", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayroomTask)(nil) + +func (p *ReqPlayroomTask) Validate() error { + return nil +} + +// Attributes: +// - Type +// +type ReqPlayroomTaskReward struct { + Type int32 `thrift:"Type,1" db:"Type" json:"Type"` +} + +func NewReqPlayroomTaskReward() *ReqPlayroomTaskReward { + return &ReqPlayroomTaskReward{} +} + +func (p *ReqPlayroomTaskReward) GetType() int32 { + return p.Type +} + +func (p *ReqPlayroomTaskReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayroomTaskReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ReqPlayroomTaskReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayroomTaskReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayroomTaskReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Type: ", p), err) + } + return err +} + +func (p *ReqPlayroomTaskReward) Equals(other *ReqPlayroomTaskReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Type != other.Type { + return false + } + return true +} + +func (p *ReqPlayroomTaskReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayroomTaskReward(%+v)", *p) +} + +func (p *ReqPlayroomTaskReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayroomTaskReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayroomTaskReward)(nil) + +func (p *ReqPlayroomTaskReward) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqPlayroomUnlock struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqPlayroomUnlock() *ReqPlayroomUnlock { + return &ReqPlayroomUnlock{} +} + +func (p *ReqPlayroomUnlock) GetId() int32 { + return p.Id +} + +func (p *ReqPlayroomUnlock) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayroomUnlock) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqPlayroomUnlock) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayroomUnlock"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayroomUnlock) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqPlayroomUnlock) Equals(other *ReqPlayroomUnlock) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqPlayroomUnlock) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayroomUnlock(%+v)", *p) +} + +func (p *ReqPlayroomUnlock) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayroomUnlock", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayroomUnlock)(nil) + +func (p *ReqPlayroomUnlock) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqPlayroomUpvote struct { + Id int64 `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqPlayroomUpvote() *ReqPlayroomUpvote { + return &ReqPlayroomUpvote{} +} + +func (p *ReqPlayroomUpvote) GetId() int64 { + return p.Id +} + +func (p *ReqPlayroomUpvote) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayroomUpvote) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqPlayroomUpvote) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayroomUpvote"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayroomUpvote) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqPlayroomUpvote) Equals(other *ReqPlayroomUpvote) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqPlayroomUpvote) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayroomUpvote(%+v)", *p) +} + +func (p *ReqPlayroomUpvote) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayroomUpvote", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayroomUpvote)(nil) + +func (p *ReqPlayroomUpvote) Validate() error { + return nil +} + +type ReqPlayroomWork struct { +} + +func NewReqPlayroomWork() *ReqPlayroomWork { + return &ReqPlayroomWork{} +} + +func (p *ReqPlayroomWork) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayroomWork) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayroomWork"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayroomWork) Equals(other *ReqPlayroomWork) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqPlayroomWork) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayroomWork(%+v)", *p) +} + +func (p *ReqPlayroomWork) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayroomWork", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayroomWork)(nil) + +func (p *ReqPlayroomWork) Validate() error { + return nil +} + +type ReqPlayroomWorkOutline struct { +} + +func NewReqPlayroomWorkOutline() *ReqPlayroomWorkOutline { + return &ReqPlayroomWorkOutline{} +} + +func (p *ReqPlayroomWorkOutline) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPlayroomWorkOutline) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPlayroomWorkOutline"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPlayroomWorkOutline) Equals(other *ReqPlayroomWorkOutline) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqPlayroomWorkOutline) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPlayroomWorkOutline(%+v)", *p) +} + +func (p *ReqPlayroomWorkOutline) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPlayroomWorkOutline", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPlayroomWorkOutline)(nil) + +func (p *ReqPlayroomWorkOutline) Validate() error { + return nil +} + +// Attributes: +// - ChessId +// - BagId +// - EmitId +// - MChessData +// +type ReqPutChessInBag struct { + ChessId int32 `thrift:"ChessId,1" db:"ChessId" json:"ChessId"` + BagId int32 `thrift:"BagId,2" db:"BagId" json:"BagId"` + EmitId int32 `thrift:"EmitId,3" db:"EmitId" json:"EmitId"` + MChessData map[string]int32 `thrift:"MChessData,4" db:"MChessData" json:"MChessData"` +} + +func NewReqPutChessInBag() *ReqPutChessInBag { + return &ReqPutChessInBag{} +} + +func (p *ReqPutChessInBag) GetChessId() int32 { + return p.ChessId +} + +func (p *ReqPutChessInBag) GetBagId() int32 { + return p.BagId +} + +func (p *ReqPutChessInBag) GetEmitId() int32 { + return p.EmitId +} + +func (p *ReqPutChessInBag) GetMChessData() map[string]int32 { + return p.MChessData +} + +func (p *ReqPutChessInBag) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.MAP { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPutChessInBag) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.ChessId = v + } + return nil +} + +func (p *ReqPutChessInBag) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.BagId = v + } + return nil +} + +func (p *ReqPutChessInBag) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.EmitId = v + } + return nil +} + +func (p *ReqPutChessInBag) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[string]int32, size) + p.MChessData = tMap + for i := 0; i < size; i++ { + var _key125 string + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key125 = v + } + var _val126 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val126 = v + } + p.MChessData[_key125] = _val126 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ReqPutChessInBag) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPutChessInBag"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPutChessInBag) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChessId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ChessId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ChessId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ChessId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ChessId: ", p), err) + } + return err +} + +func (p *ReqPutChessInBag) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "BagId", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:BagId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.BagId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.BagId (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:BagId: ", p), err) + } + return err +} + +func (p *ReqPutChessInBag) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EmitId", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:EmitId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.EmitId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EmitId (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:EmitId: ", p), err) + } + return err +} + +func (p *ReqPutChessInBag) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MChessData", thrift.MAP, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:MChessData: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.STRING, thrift.I32, len(p.MChessData)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.MChessData { + if err := oprot.WriteString(ctx, string(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:MChessData: ", p), err) + } + return err +} + +func (p *ReqPutChessInBag) Equals(other *ReqPutChessInBag) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ChessId != other.ChessId { + return false + } + if p.BagId != other.BagId { + return false + } + if p.EmitId != other.EmitId { + return false + } + if len(p.MChessData) != len(other.MChessData) { + return false + } + for k, _tgt := range p.MChessData { + _src127 := other.MChessData[k] + if _tgt != _src127 { + return false + } + } + return true +} + +func (p *ReqPutChessInBag) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPutChessInBag(%+v)", *p) +} + +func (p *ReqPutChessInBag) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPutChessInBag", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPutChessInBag)(nil) + +func (p *ReqPutChessInBag) Validate() error { + return nil +} + +// Attributes: +// - ChessId +// - MChessData +// +type ReqPutPartInBag struct { + ChessId int32 `thrift:"ChessId,1" db:"ChessId" json:"ChessId"` + MChessData map[string]int32 `thrift:"MChessData,2" db:"MChessData" json:"MChessData"` +} + +func NewReqPutPartInBag() *ReqPutPartInBag { + return &ReqPutPartInBag{} +} + +func (p *ReqPutPartInBag) GetChessId() int32 { + return p.ChessId +} + +func (p *ReqPutPartInBag) GetMChessData() map[string]int32 { + return p.MChessData +} + +func (p *ReqPutPartInBag) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.MAP { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqPutPartInBag) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.ChessId = v + } + return nil +} + +func (p *ReqPutPartInBag) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[string]int32, size) + p.MChessData = tMap + for i := 0; i < size; i++ { + var _key128 string + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key128 = v + } + var _val129 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val129 = v + } + p.MChessData[_key128] = _val129 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ReqPutPartInBag) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqPutPartInBag"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqPutPartInBag) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChessId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ChessId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ChessId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ChessId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ChessId: ", p), err) + } + return err +} + +func (p *ReqPutPartInBag) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MChessData", thrift.MAP, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:MChessData: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.STRING, thrift.I32, len(p.MChessData)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.MChessData { + if err := oprot.WriteString(ctx, string(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:MChessData: ", p), err) + } + return err +} + +func (p *ReqPutPartInBag) Equals(other *ReqPutPartInBag) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ChessId != other.ChessId { + return false + } + if len(p.MChessData) != len(other.MChessData) { + return false + } + for k, _tgt := range p.MChessData { + _src130 := other.MChessData[k] + if _tgt != _src130 { + return false + } + } + return true +} + +func (p *ReqPutPartInBag) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqPutPartInBag(%+v)", *p) +} + +func (p *ReqPutPartInBag) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqPutPartInBag", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqPutPartInBag)(nil) + +func (p *ReqPutPartInBag) Validate() error { + return nil +} + +type ReqRace struct { +} + +func NewReqRace() *ReqRace { + return &ReqRace{} +} + +func (p *ReqRace) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqRace) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqRace"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqRace) Equals(other *ReqRace) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqRace) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqRace(%+v)", *p) +} + +func (p *ReqRace) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqRace", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqRace)(nil) + +func (p *ReqRace) Validate() error { + return nil +} + +type ReqRaceReward struct { +} + +func NewReqRaceReward() *ReqRaceReward { + return &ReqRaceReward{} +} + +func (p *ReqRaceReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqRaceReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqRaceReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqRaceReward) Equals(other *ReqRaceReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqRaceReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqRaceReward(%+v)", *p) +} + +func (p *ReqRaceReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqRaceReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqRaceReward)(nil) + +func (p *ReqRaceReward) Validate() error { + return nil +} + +type ReqRaceStart struct { +} + +func NewReqRaceStart() *ReqRaceStart { + return &ReqRaceStart{} +} + +func (p *ReqRaceStart) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqRaceStart) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqRaceStart"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqRaceStart) Equals(other *ReqRaceStart) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqRaceStart) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqRaceStart(%+v)", *p) +} + +func (p *ReqRaceStart) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqRaceStart", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqRaceStart)(nil) + +func (p *ReqRaceStart) Validate() error { + return nil +} + +// Attributes: +// - Type +// +type ReqRank struct { + Type int32 `thrift:"Type,1" db:"Type" json:"Type"` +} + +func NewReqRank() *ReqRank { + return &ReqRank{} +} + +func (p *ReqRank) GetType() int32 { + return p.Type +} + +func (p *ReqRank) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqRank) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ReqRank) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqRank"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqRank) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Type: ", p), err) + } + return err +} + +func (p *ReqRank) Equals(other *ReqRank) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Type != other.Type { + return false + } + return true +} + +func (p *ReqRank) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqRank(%+v)", *p) +} + +func (p *ReqRank) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqRank", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqRank)(nil) + +func (p *ReqRank) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqReadMail struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqReadMail() *ReqReadMail { + return &ReqReadMail{} +} + +func (p *ReqReadMail) GetId() int32 { + return p.Id +} + +func (p *ReqReadMail) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqReadMail) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqReadMail) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqReadMail"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqReadMail) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqReadMail) Equals(other *ReqReadMail) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqReadMail) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqReadMail(%+v)", *p) +} + +func (p *ReqReadMail) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqReadMail", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqReadMail)(nil) + +func (p *ReqReadMail) Validate() error { + return nil +} + +type ReqRefreshChessShop struct { +} + +func NewReqRefreshChessShop() *ReqRefreshChessShop { + return &ReqRefreshChessShop{} +} + +func (p *ReqRefreshChessShop) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqRefreshChessShop) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqRefreshChessShop"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqRefreshChessShop) Equals(other *ReqRefreshChessShop) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqRefreshChessShop) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqRefreshChessShop(%+v)", *p) +} + +func (p *ReqRefreshChessShop) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqRefreshChessShop", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqRefreshChessShop)(nil) + +func (p *ReqRefreshChessShop) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqRefuseCardExchange struct { + Id string `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqRefuseCardExchange() *ReqRefuseCardExchange { + return &ReqRefuseCardExchange{} +} + +func (p *ReqRefuseCardExchange) GetId() string { + return p.Id +} + +func (p *ReqRefuseCardExchange) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqRefuseCardExchange) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqRefuseCardExchange) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqRefuseCardExchange"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqRefuseCardExchange) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqRefuseCardExchange) Equals(other *ReqRefuseCardExchange) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqRefuseCardExchange) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqRefuseCardExchange(%+v)", *p) +} + +func (p *ReqRefuseCardExchange) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqRefuseCardExchange", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqRefuseCardExchange)(nil) + +func (p *ReqRefuseCardExchange) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqRefuseCardGive struct { + Id string `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqRefuseCardGive() *ReqRefuseCardGive { + return &ReqRefuseCardGive{} +} + +func (p *ReqRefuseCardGive) GetId() string { + return p.Id +} + +func (p *ReqRefuseCardGive) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqRefuseCardGive) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqRefuseCardGive) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqRefuseCardGive"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqRefuseCardGive) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqRefuseCardGive) Equals(other *ReqRefuseCardGive) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqRefuseCardGive) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqRefuseCardGive(%+v)", *p) +} + +func (p *ReqRefuseCardGive) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqRefuseCardGive", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqRefuseCardGive)(nil) + +func (p *ReqRefuseCardGive) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqRefuseCardSelect struct { + Id string `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqRefuseCardSelect() *ReqRefuseCardSelect { + return &ReqRefuseCardSelect{} +} + +func (p *ReqRefuseCardSelect) GetId() string { + return p.Id +} + +func (p *ReqRefuseCardSelect) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqRefuseCardSelect) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqRefuseCardSelect) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqRefuseCardSelect"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqRefuseCardSelect) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqRefuseCardSelect) Equals(other *ReqRefuseCardSelect) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqRefuseCardSelect) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqRefuseCardSelect(%+v)", *p) +} + +func (p *ReqRefuseCardSelect) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqRefuseCardSelect", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqRefuseCardSelect)(nil) + +func (p *ReqRefuseCardSelect) Validate() error { + return nil +} + +// Attributes: +// - Uid +// +type ReqRefuseFriend struct { + Uid int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` +} + +func NewReqRefuseFriend() *ReqRefuseFriend { + return &ReqRefuseFriend{} +} + +func (p *ReqRefuseFriend) GetUid() int64 { + return p.Uid +} + +func (p *ReqRefuseFriend) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqRefuseFriend) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ReqRefuseFriend) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqRefuseFriend"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqRefuseFriend) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *ReqRefuseFriend) Equals(other *ReqRefuseFriend) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Uid != other.Uid { + return false + } + return true +} + +func (p *ReqRefuseFriend) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqRefuseFriend(%+v)", *p) +} + +func (p *ReqRefuseFriend) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqRefuseFriend", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqRefuseFriend)(nil) + +func (p *ReqRefuseFriend) Validate() error { + return nil +} + +// Attributes: +// - UserName +// - UserPwd +// - DwUin +// - Device +// +type ReqRegisterAccount struct { + UserName string `thrift:"UserName,1" db:"UserName" json:"UserName"` + UserPwd string `thrift:"UserPwd,2" db:"UserPwd" json:"UserPwd"` + DwUin int32 `thrift:"dwUin,3" db:"dwUin" json:"dwUin"` + Device string `thrift:"Device,4" db:"Device" json:"Device"` +} + +func NewReqRegisterAccount() *ReqRegisterAccount { + return &ReqRegisterAccount{} +} + +func (p *ReqRegisterAccount) GetUserName() string { + return p.UserName +} + +func (p *ReqRegisterAccount) GetUserPwd() string { + return p.UserPwd +} + +func (p *ReqRegisterAccount) GetDwUin() int32 { + return p.DwUin +} + +func (p *ReqRegisterAccount) GetDevice() string { + return p.Device +} + +func (p *ReqRegisterAccount) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.STRING { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqRegisterAccount) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.UserName = v + } + return nil +} + +func (p *ReqRegisterAccount) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.UserPwd = v + } + return nil +} + +func (p *ReqRegisterAccount) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.DwUin = v + } + return nil +} + +func (p *ReqRegisterAccount) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Device = v + } + return nil +} + +func (p *ReqRegisterAccount) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqRegisterAccount"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqRegisterAccount) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "UserName", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:UserName: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.UserName)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.UserName (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:UserName: ", p), err) + } + return err +} + +func (p *ReqRegisterAccount) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "UserPwd", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:UserPwd: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.UserPwd)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.UserPwd (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:UserPwd: ", p), err) + } + return err +} + +func (p *ReqRegisterAccount) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "dwUin", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:dwUin: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.DwUin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.dwUin (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:dwUin: ", p), err) + } + return err +} + +func (p *ReqRegisterAccount) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Device", thrift.STRING, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Device: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Device)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Device (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Device: ", p), err) + } + return err +} + +func (p *ReqRegisterAccount) Equals(other *ReqRegisterAccount) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.UserName != other.UserName { + return false + } + if p.UserPwd != other.UserPwd { + return false + } + if p.DwUin != other.DwUin { + return false + } + if p.Device != other.Device { + return false + } + return true +} + +func (p *ReqRegisterAccount) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqRegisterAccount(%+v)", *p) +} + +func (p *ReqRegisterAccount) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqRegisterAccount", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqRegisterAccount)(nil) + +func (p *ReqRegisterAccount) Validate() error { + return nil +} + +type ReqReload struct { +} + +func NewReqReload() *ReqReload { + return &ReqReload{} +} + +func (p *ReqReload) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqReload) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqReload"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqReload) Equals(other *ReqReload) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqReload) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqReload(%+v)", *p) +} + +func (p *ReqReload) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqReload", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqReload)(nil) + +func (p *ReqReload) Validate() error { + return nil +} + +type ReqReloadServerMail struct { +} + +func NewReqReloadServerMail() *ReqReloadServerMail { + return &ReqReloadServerMail{} +} + +func (p *ReqReloadServerMail) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqReloadServerMail) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqReloadServerMail"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqReloadServerMail) Equals(other *ReqReloadServerMail) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqReloadServerMail) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqReloadServerMail(%+v)", *p) +} + +func (p *ReqReloadServerMail) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqReloadServerMail", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqReloadServerMail)(nil) + +func (p *ReqReloadServerMail) Validate() error { + return nil +} + +// Attributes: +// - DwUin +// +type ReqRemoveAd struct { + DwUin int64 `thrift:"dwUin,1" db:"dwUin" json:"dwUin"` +} + +func NewReqRemoveAd() *ReqRemoveAd { + return &ReqRemoveAd{} +} + +func (p *ReqRemoveAd) GetDwUin() int64 { + return p.DwUin +} + +func (p *ReqRemoveAd) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqRemoveAd) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.DwUin = v + } + return nil +} + +func (p *ReqRemoveAd) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqRemoveAd"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqRemoveAd) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "dwUin", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:dwUin: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.DwUin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.dwUin (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:dwUin: ", p), err) + } + return err +} + +func (p *ReqRemoveAd) Equals(other *ReqRemoveAd) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.DwUin != other.DwUin { + return false + } + return true +} + +func (p *ReqRemoveAd) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqRemoveAd(%+v)", *p) +} + +func (p *ReqRemoveAd) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqRemoveAd", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqRemoveAd)(nil) + +func (p *ReqRemoveAd) Validate() error { + return nil +} + +// Attributes: +// - OrderId +// - MChessData +// - ActType +// +type ReqRewardOrder struct { + OrderId int32 `thrift:"OrderId,1" db:"OrderId" json:"OrderId"` + MChessData map[string]int32 `thrift:"MChessData,2" db:"MChessData" json:"MChessData"` + ActType []int32 `thrift:"ActType,3" db:"ActType" json:"ActType"` +} + +func NewReqRewardOrder() *ReqRewardOrder { + return &ReqRewardOrder{} +} + +func (p *ReqRewardOrder) GetOrderId() int32 { + return p.OrderId +} + +func (p *ReqRewardOrder) GetMChessData() map[string]int32 { + return p.MChessData +} + +func (p *ReqRewardOrder) GetActType() []int32 { + return p.ActType +} + +func (p *ReqRewardOrder) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.MAP { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.LIST { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqRewardOrder) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.OrderId = v + } + return nil +} + +func (p *ReqRewardOrder) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[string]int32, size) + p.MChessData = tMap + for i := 0; i < size; i++ { + var _key131 string + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key131 = v + } + var _val132 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val132 = v + } + p.MChessData[_key131] = _val132 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ReqRewardOrder) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.ActType = tSlice + for i := 0; i < size; i++ { + var _elem133 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem133 = v + } + p.ActType = append(p.ActType, _elem133) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ReqRewardOrder) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqRewardOrder"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqRewardOrder) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "OrderId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:OrderId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.OrderId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.OrderId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:OrderId: ", p), err) + } + return err +} + +func (p *ReqRewardOrder) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MChessData", thrift.MAP, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:MChessData: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.STRING, thrift.I32, len(p.MChessData)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.MChessData { + if err := oprot.WriteString(ctx, string(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:MChessData: ", p), err) + } + return err +} + +func (p *ReqRewardOrder) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ActType", thrift.LIST, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:ActType: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.ActType)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.ActType { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:ActType: ", p), err) + } + return err +} + +func (p *ReqRewardOrder) Equals(other *ReqRewardOrder) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.OrderId != other.OrderId { + return false + } + if len(p.MChessData) != len(other.MChessData) { + return false + } + for k, _tgt := range p.MChessData { + _src134 := other.MChessData[k] + if _tgt != _src134 { + return false + } + } + if len(p.ActType) != len(other.ActType) { + return false + } + for i, _tgt := range p.ActType { + _src135 := other.ActType[i] + if _tgt != _src135 { + return false + } + } + return true +} + +func (p *ReqRewardOrder) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqRewardOrder(%+v)", *p) +} + +func (p *ReqRewardOrder) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqRewardOrder", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqRewardOrder)(nil) + +func (p *ReqRewardOrder) Validate() error { + return nil +} + +// Attributes: +// - Uid +// +type ReqSearchPlayer struct { + Uid string `thrift:"Uid,1" db:"Uid" json:"Uid"` +} + +func NewReqSearchPlayer() *ReqSearchPlayer { + return &ReqSearchPlayer{} +} + +func (p *ReqSearchPlayer) GetUid() string { + return p.Uid +} + +func (p *ReqSearchPlayer) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqSearchPlayer) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ReqSearchPlayer) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqSearchPlayer"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqSearchPlayer) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *ReqSearchPlayer) Equals(other *ReqSearchPlayer) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Uid != other.Uid { + return false + } + return true +} + +func (p *ReqSearchPlayer) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqSearchPlayer(%+v)", *p) +} + +func (p *ReqSearchPlayer) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqSearchPlayer", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqSearchPlayer)(nil) + +func (p *ReqSearchPlayer) Validate() error { + return nil +} + +// Attributes: +// - Id +// - CardId +// +type ReqSelectCardExchange struct { + Id string `thrift:"Id,1" db:"Id" json:"Id"` + CardId int32 `thrift:"CardId,2" db:"CardId" json:"CardId"` +} + +func NewReqSelectCardExchange() *ReqSelectCardExchange { + return &ReqSelectCardExchange{} +} + +func (p *ReqSelectCardExchange) GetId() string { + return p.Id +} + +func (p *ReqSelectCardExchange) GetCardId() int32 { + return p.CardId +} + +func (p *ReqSelectCardExchange) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqSelectCardExchange) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqSelectCardExchange) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.CardId = v + } + return nil +} + +func (p *ReqSelectCardExchange) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqSelectCardExchange"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqSelectCardExchange) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqSelectCardExchange) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "CardId", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:CardId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.CardId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.CardId (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:CardId: ", p), err) + } + return err +} + +func (p *ReqSelectCardExchange) Equals(other *ReqSelectCardExchange) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.CardId != other.CardId { + return false + } + return true +} + +func (p *ReqSelectCardExchange) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqSelectCardExchange(%+v)", *p) +} + +func (p *ReqSelectCardExchange) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqSelectCardExchange", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqSelectCardExchange)(nil) + +func (p *ReqSelectCardExchange) Validate() error { + return nil +} + +// Attributes: +// - Id +// +type ReqSelectLimitEvent struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` +} + +func NewReqSelectLimitEvent() *ReqSelectLimitEvent { + return &ReqSelectLimitEvent{} +} + +func (p *ReqSelectLimitEvent) GetId() int32 { + return p.Id +} + +func (p *ReqSelectLimitEvent) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqSelectLimitEvent) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqSelectLimitEvent) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqSelectLimitEvent"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqSelectLimitEvent) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqSelectLimitEvent) Equals(other *ReqSelectLimitEvent) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ReqSelectLimitEvent) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqSelectLimitEvent(%+v)", *p) +} + +func (p *ReqSelectLimitEvent) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqSelectLimitEvent", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqSelectLimitEvent)(nil) + +func (p *ReqSelectLimitEvent) Validate() error { + return nil +} + +// Attributes: +// - InviterId +// +type ReqSelfInvited struct { + InviterId int64 `thrift:"InviterId,1" db:"InviterId" json:"InviterId"` +} + +func NewReqSelfInvited() *ReqSelfInvited { + return &ReqSelfInvited{} +} + +func (p *ReqSelfInvited) GetInviterId() int64 { + return p.InviterId +} + +func (p *ReqSelfInvited) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqSelfInvited) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.InviterId = v + } + return nil +} + +func (p *ReqSelfInvited) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqSelfInvited"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqSelfInvited) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "InviterId", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:InviterId: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.InviterId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.InviterId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:InviterId: ", p), err) + } + return err +} + +func (p *ReqSelfInvited) Equals(other *ReqSelfInvited) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.InviterId != other.InviterId { + return false + } + return true +} + +func (p *ReqSelfInvited) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqSelfInvited(%+v)", *p) +} + +func (p *ReqSelfInvited) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqSelfInvited", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqSelfInvited)(nil) + +func (p *ReqSelfInvited) Validate() error { + return nil +} + +// Attributes: +// - ChessId +// +type ReqSellChessNum struct { + ChessId int32 `thrift:"ChessId,1" db:"ChessId" json:"ChessId"` +} + +func NewReqSellChessNum() *ReqSellChessNum { + return &ReqSellChessNum{} +} + +func (p *ReqSellChessNum) GetChessId() int32 { + return p.ChessId +} + +func (p *ReqSellChessNum) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqSellChessNum) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.ChessId = v + } + return nil +} + +func (p *ReqSellChessNum) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqSellChessNum"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqSellChessNum) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChessId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ChessId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ChessId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ChessId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ChessId: ", p), err) + } + return err +} + +func (p *ReqSellChessNum) Equals(other *ReqSellChessNum) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ChessId != other.ChessId { + return false + } + return true +} + +func (p *ReqSellChessNum) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqSellChessNum(%+v)", *p) +} + +func (p *ReqSellChessNum) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqSellChessNum", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqSellChessNum)(nil) + +func (p *ReqSellChessNum) Validate() error { + return nil +} + +// Attributes: +// - Uid +// +type ReqSendWishBeg struct { + Uid []int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` +} + +func NewReqSendWishBeg() *ReqSendWishBeg { + return &ReqSendWishBeg{} +} + +func (p *ReqSendWishBeg) GetUid() []int64 { + return p.Uid +} + +func (p *ReqSendWishBeg) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqSendWishBeg) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int64, 0, size) + p.Uid = tSlice + for i := 0; i < size; i++ { + var _elem136 int64 + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem136 = v + } + p.Uid = append(p.Uid, _elem136) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ReqSendWishBeg) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqSendWishBeg"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqSendWishBeg) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I64, len(p.Uid)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Uid { + if err := oprot.WriteI64(ctx, int64(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *ReqSendWishBeg) Equals(other *ReqSendWishBeg) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.Uid) != len(other.Uid) { + return false + } + for i, _tgt := range p.Uid { + _src137 := other.Uid[i] + if _tgt != _src137 { + return false + } + } + return true +} + +func (p *ReqSendWishBeg) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqSendWishBeg(%+v)", *p) +} + +func (p *ReqSendWishBeg) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqSendWishBeg", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqSendWishBeg)(nil) + +func (p *ReqSendWishBeg) Validate() error { + return nil +} + +// Attributes: +// - ChessId +// - MChessData +// +type ReqSeparateChess struct { + ChessId int32 `thrift:"ChessId,1" db:"ChessId" json:"ChessId"` + MChessData map[string]int32 `thrift:"MChessData,2" db:"MChessData" json:"MChessData"` +} + +func NewReqSeparateChess() *ReqSeparateChess { + return &ReqSeparateChess{} +} + +func (p *ReqSeparateChess) GetChessId() int32 { + return p.ChessId +} + +func (p *ReqSeparateChess) GetMChessData() map[string]int32 { + return p.MChessData +} + +func (p *ReqSeparateChess) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.MAP { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqSeparateChess) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.ChessId = v + } + return nil +} + +func (p *ReqSeparateChess) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[string]int32, size) + p.MChessData = tMap + for i := 0; i < size; i++ { + var _key138 string + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key138 = v + } + var _val139 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val139 = v + } + p.MChessData[_key138] = _val139 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ReqSeparateChess) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqSeparateChess"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqSeparateChess) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChessId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ChessId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ChessId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ChessId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ChessId: ", p), err) + } + return err +} + +func (p *ReqSeparateChess) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MChessData", thrift.MAP, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:MChessData: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.STRING, thrift.I32, len(p.MChessData)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.MChessData { + if err := oprot.WriteString(ctx, string(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:MChessData: ", p), err) + } + return err +} + +func (p *ReqSeparateChess) Equals(other *ReqSeparateChess) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ChessId != other.ChessId { + return false + } + if len(p.MChessData) != len(other.MChessData) { + return false + } + for k, _tgt := range p.MChessData { + _src140 := other.MChessData[k] + if _tgt != _src140 { + return false + } + } + return true +} + +func (p *ReqSeparateChess) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqSeparateChess(%+v)", *p) +} + +func (p *ReqSeparateChess) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqSeparateChess", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqSeparateChess)(nil) + +func (p *ReqSeparateChess) Validate() error { + return nil +} + +type ReqServerInfo struct { +} + +func NewReqServerInfo() *ReqServerInfo { + return &ReqServerInfo{} +} + +func (p *ReqServerInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqServerInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqServerInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqServerInfo) Equals(other *ReqServerInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqServerInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqServerInfo(%+v)", *p) +} + +func (p *ReqServerInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqServerInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqServerInfo)(nil) + +func (p *ReqServerInfo) Validate() error { + return nil +} + +// Attributes: +// - DwUin +// +type ReqServerTime struct { + DwUin int64 `thrift:"dwUin,1" db:"dwUin" json:"dwUin"` +} + +func NewReqServerTime() *ReqServerTime { + return &ReqServerTime{} +} + +func (p *ReqServerTime) GetDwUin() int64 { + return p.DwUin +} + +func (p *ReqServerTime) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqServerTime) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.DwUin = v + } + return nil +} + +func (p *ReqServerTime) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqServerTime"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqServerTime) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "dwUin", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:dwUin: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.DwUin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.dwUin (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:dwUin: ", p), err) + } + return err +} + +func (p *ReqServerTime) Equals(other *ReqServerTime) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.DwUin != other.DwUin { + return false + } + return true +} + +func (p *ReqServerTime) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqServerTime(%+v)", *p) +} + +func (p *ReqServerTime) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqServerTime", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqServerTime)(nil) + +func (p *ReqServerTime) Validate() error { + return nil +} + +// Attributes: +// - Avatar +// +type ReqSetAvatar struct { + Avatar int32 `thrift:"Avatar,1" db:"Avatar" json:"Avatar"` +} + +func NewReqSetAvatar() *ReqSetAvatar { + return &ReqSetAvatar{} +} + +func (p *ReqSetAvatar) GetAvatar() int32 { + return p.Avatar +} + +func (p *ReqSetAvatar) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqSetAvatar) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Avatar = v + } + return nil +} + +func (p *ReqSetAvatar) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqSetAvatar"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqSetAvatar) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Avatar", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Avatar: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Avatar)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Avatar (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Avatar: ", p), err) + } + return err +} + +func (p *ReqSetAvatar) Equals(other *ReqSetAvatar) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Avatar != other.Avatar { + return false + } + return true +} + +func (p *ReqSetAvatar) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqSetAvatar(%+v)", *p) +} + +func (p *ReqSetAvatar) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqSetAvatar", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqSetAvatar)(nil) + +func (p *ReqSetAvatar) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Type +// +type ReqSetEmoji struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Type int32 `thrift:"Type,2" db:"Type" json:"Type"` +} + +func NewReqSetEmoji() *ReqSetEmoji { + return &ReqSetEmoji{} +} + +func (p *ReqSetEmoji) GetId() int32 { + return p.Id +} + +func (p *ReqSetEmoji) GetType() int32 { + return p.Type +} + +func (p *ReqSetEmoji) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqSetEmoji) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ReqSetEmoji) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ReqSetEmoji) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqSetEmoji"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqSetEmoji) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ReqSetEmoji) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Type: ", p), err) + } + return err +} + +func (p *ReqSetEmoji) Equals(other *ReqSetEmoji) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Type != other.Type { + return false + } + return true +} + +func (p *ReqSetEmoji) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqSetEmoji(%+v)", *p) +} + +func (p *ReqSetEmoji) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqSetEmoji", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqSetEmoji)(nil) + +func (p *ReqSetEmoji) Validate() error { + return nil +} + +// Attributes: +// - EnergyMul +// +type ReqSetEnergyMul struct { + EnergyMul int32 `thrift:"EnergyMul,1" db:"EnergyMul" json:"EnergyMul"` +} + +func NewReqSetEnergyMul() *ReqSetEnergyMul { + return &ReqSetEnergyMul{} +} + +func (p *ReqSetEnergyMul) GetEnergyMul() int32 { + return p.EnergyMul +} + +func (p *ReqSetEnergyMul) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqSetEnergyMul) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.EnergyMul = v + } + return nil +} + +func (p *ReqSetEnergyMul) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqSetEnergyMul"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqSetEnergyMul) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EnergyMul", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:EnergyMul: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.EnergyMul)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EnergyMul (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:EnergyMul: ", p), err) + } + return err +} + +func (p *ReqSetEnergyMul) Equals(other *ReqSetEnergyMul) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.EnergyMul != other.EnergyMul { + return false + } + return true +} + +func (p *ReqSetEnergyMul) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqSetEnergyMul(%+v)", *p) +} + +func (p *ReqSetEnergyMul) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqSetEnergyMul", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqSetEnergyMul)(nil) + +func (p *ReqSetEnergyMul) Validate() error { + return nil +} + +// Attributes: +// - Face +// +type ReqSetFace struct { + Face int32 `thrift:"Face,1" db:"Face" json:"Face"` +} + +func NewReqSetFace() *ReqSetFace { + return &ReqSetFace{} +} + +func (p *ReqSetFace) GetFace() int32 { + return p.Face +} + +func (p *ReqSetFace) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqSetFace) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Face = v + } + return nil +} + +func (p *ReqSetFace) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqSetFace"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqSetFace) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Face", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Face: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Face)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Face (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Face: ", p), err) + } + return err +} + +func (p *ReqSetFace) Equals(other *ReqSetFace) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Face != other.Face { + return false + } + return true +} + +func (p *ReqSetFace) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqSetFace(%+v)", *p) +} + +func (p *ReqSetFace) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqSetFace", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqSetFace)(nil) + +func (p *ReqSetFace) Validate() error { + return nil +} + +// Attributes: +// - Url +// +type ReqSetFacebookUrl struct { + Url string `thrift:"Url,1" db:"Url" json:"Url"` +} + +func NewReqSetFacebookUrl() *ReqSetFacebookUrl { + return &ReqSetFacebookUrl{} +} + +func (p *ReqSetFacebookUrl) GetUrl() string { + return p.Url +} + +func (p *ReqSetFacebookUrl) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqSetFacebookUrl) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Url = v + } + return nil +} + +func (p *ReqSetFacebookUrl) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqSetFacebookUrl"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqSetFacebookUrl) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Url", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Url: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Url)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Url (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Url: ", p), err) + } + return err +} + +func (p *ReqSetFacebookUrl) Equals(other *ReqSetFacebookUrl) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Url != other.Url { + return false + } + return true +} + +func (p *ReqSetFacebookUrl) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqSetFacebookUrl(%+v)", *p) +} + +func (p *ReqSetFacebookUrl) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqSetFacebookUrl", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqSetFacebookUrl)(nil) + +func (p *ReqSetFacebookUrl) Validate() error { + return nil +} + +// Attributes: +// - Name +// +type ReqSetName struct { + Name string `thrift:"Name,1" db:"Name" json:"Name"` +} + +func NewReqSetName() *ReqSetName { + return &ReqSetName{} +} + +func (p *ReqSetName) GetName() string { + return p.Name +} + +func (p *ReqSetName) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqSetName) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Name = v + } + return nil +} + +func (p *ReqSetName) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqSetName"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqSetName) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Name", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Name: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Name)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Name (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Name: ", p), err) + } + return err +} + +func (p *ReqSetName) Equals(other *ReqSetName) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Name != other.Name { + return false + } + return true +} + +func (p *ReqSetName) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqSetName(%+v)", *p) +} + +func (p *ReqSetName) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqSetName", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqSetName)(nil) + +func (p *ReqSetName) Validate() error { + return nil +} + +// Attributes: +// - Name +// +type ReqSetPetName struct { + Name string `thrift:"Name,1" db:"Name" json:"Name"` +} + +func NewReqSetPetName() *ReqSetPetName { + return &ReqSetPetName{} +} + +func (p *ReqSetPetName) GetName() string { + return p.Name +} + +func (p *ReqSetPetName) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqSetPetName) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Name = v + } + return nil +} + +func (p *ReqSetPetName) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqSetPetName"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqSetPetName) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Name", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Name: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Name)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Name (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Name: ", p), err) + } + return err +} + +func (p *ReqSetPetName) Equals(other *ReqSetPetName) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Name != other.Name { + return false + } + return true +} + +func (p *ReqSetPetName) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqSetPetName(%+v)", *p) +} + +func (p *ReqSetPetName) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqSetPetName", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqSetPetName)(nil) + +func (p *ReqSetPetName) Validate() error { + return nil +} + +// Attributes: +// - OrderSn +// - ProduceId +// - Token +// - Status +// +type ReqShippingOrder struct { + OrderSn string `thrift:"OrderSn,1" db:"OrderSn" json:"OrderSn"` + ProduceId string `thrift:"ProduceId,2" db:"ProduceId" json:"ProduceId"` + Token string `thrift:"Token,3" db:"Token" json:"Token"` + Status int32 `thrift:"Status,4" db:"Status" json:"Status"` +} + +func NewReqShippingOrder() *ReqShippingOrder { + return &ReqShippingOrder{} +} + +func (p *ReqShippingOrder) GetOrderSn() string { + return p.OrderSn +} + +func (p *ReqShippingOrder) GetProduceId() string { + return p.ProduceId +} + +func (p *ReqShippingOrder) GetToken() string { + return p.Token +} + +func (p *ReqShippingOrder) GetStatus() int32 { + return p.Status +} + +func (p *ReqShippingOrder) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.STRING { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqShippingOrder) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.OrderSn = v + } + return nil +} + +func (p *ReqShippingOrder) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.ProduceId = v + } + return nil +} + +func (p *ReqShippingOrder) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Token = v + } + return nil +} + +func (p *ReqShippingOrder) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Status = v + } + return nil +} + +func (p *ReqShippingOrder) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqShippingOrder"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqShippingOrder) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "OrderSn", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:OrderSn: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.OrderSn)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.OrderSn (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:OrderSn: ", p), err) + } + return err +} + +func (p *ReqShippingOrder) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ProduceId", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:ProduceId: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.ProduceId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ProduceId (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:ProduceId: ", p), err) + } + return err +} + +func (p *ReqShippingOrder) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Token", thrift.STRING, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Token: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Token)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Token (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Token: ", p), err) + } + return err +} + +func (p *ReqShippingOrder) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Status", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Status: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Status)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Status (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Status: ", p), err) + } + return err +} + +func (p *ReqShippingOrder) Equals(other *ReqShippingOrder) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.OrderSn != other.OrderSn { + return false + } + if p.ProduceId != other.ProduceId { + return false + } + if p.Token != other.Token { + return false + } + if p.Status != other.Status { + return false + } + return true +} + +func (p *ReqShippingOrder) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqShippingOrder(%+v)", *p) +} + +func (p *ReqShippingOrder) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqShippingOrder", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqShippingOrder)(nil) + +func (p *ReqShippingOrder) Validate() error { + return nil +} + +// Attributes: +// - ChestId +// - MChessData +// +type ReqSourceChest struct { + ChestId int32 `thrift:"ChestId,1" db:"ChestId" json:"ChestId"` + MChessData map[string]int32 `thrift:"MChessData,2" db:"MChessData" json:"MChessData"` +} + +func NewReqSourceChest() *ReqSourceChest { + return &ReqSourceChest{} +} + +func (p *ReqSourceChest) GetChestId() int32 { + return p.ChestId +} + +func (p *ReqSourceChest) GetMChessData() map[string]int32 { + return p.MChessData +} + +func (p *ReqSourceChest) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.MAP { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqSourceChest) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.ChestId = v + } + return nil +} + +func (p *ReqSourceChest) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[string]int32, size) + p.MChessData = tMap + for i := 0; i < size; i++ { + var _key141 string + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key141 = v + } + var _val142 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val142 = v + } + p.MChessData[_key141] = _val142 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ReqSourceChest) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqSourceChest"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqSourceChest) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChestId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ChestId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ChestId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ChestId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ChestId: ", p), err) + } + return err +} + +func (p *ReqSourceChest) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MChessData", thrift.MAP, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:MChessData: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.STRING, thrift.I32, len(p.MChessData)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.MChessData { + if err := oprot.WriteString(ctx, string(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:MChessData: ", p), err) + } + return err +} + +func (p *ReqSourceChest) Equals(other *ReqSourceChest) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ChestId != other.ChestId { + return false + } + if len(p.MChessData) != len(other.MChessData) { + return false + } + for k, _tgt := range p.MChessData { + _src143 := other.MChessData[k] + if _tgt != _src143 { + return false + } + } + return true +} + +func (p *ReqSourceChest) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqSourceChest(%+v)", *p) +} + +func (p *ReqSourceChest) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqSourceChest", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqSourceChest)(nil) + +func (p *ReqSourceChest) Validate() error { + return nil +} + +// Attributes: +// - DwUin +// - NewFBId_ +// +type ReqSynGameData struct { + DwUin int64 `thrift:"dwUin,1" db:"dwUin" json:"dwUin"` + NewFBId_ string `thrift:"NewFBId,2" db:"NewFBId" json:"NewFBId"` +} + +func NewReqSynGameData() *ReqSynGameData { + return &ReqSynGameData{} +} + +func (p *ReqSynGameData) GetDwUin() int64 { + return p.DwUin +} + +func (p *ReqSynGameData) GetNewFBId_() string { + return p.NewFBId_ +} + +func (p *ReqSynGameData) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqSynGameData) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.DwUin = v + } + return nil +} + +func (p *ReqSynGameData) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.NewFBId_ = v + } + return nil +} + +func (p *ReqSynGameData) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqSynGameData"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqSynGameData) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "dwUin", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:dwUin: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.DwUin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.dwUin (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:dwUin: ", p), err) + } + return err +} + +func (p *ReqSynGameData) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "NewFBId", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:NewFBId: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.NewFBId_)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.NewFBId (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:NewFBId: ", p), err) + } + return err +} + +func (p *ReqSynGameData) Equals(other *ReqSynGameData) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.DwUin != other.DwUin { + return false + } + if p.NewFBId_ != other.NewFBId_ { + return false + } + return true +} + +func (p *ReqSynGameData) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqSynGameData(%+v)", *p) +} + +func (p *ReqSynGameData) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqSynGameData", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqSynGameData)(nil) + +func (p *ReqSynGameData) Validate() error { + return nil +} + +// Attributes: +// - BagId +// - MChessData +// +type ReqTakeChessOutBag struct { + BagId int32 `thrift:"BagId,1" db:"BagId" json:"BagId"` + MChessData map[string]int32 `thrift:"MChessData,2" db:"MChessData" json:"MChessData"` +} + +func NewReqTakeChessOutBag() *ReqTakeChessOutBag { + return &ReqTakeChessOutBag{} +} + +func (p *ReqTakeChessOutBag) GetBagId() int32 { + return p.BagId +} + +func (p *ReqTakeChessOutBag) GetMChessData() map[string]int32 { + return p.MChessData +} + +func (p *ReqTakeChessOutBag) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.MAP { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqTakeChessOutBag) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.BagId = v + } + return nil +} + +func (p *ReqTakeChessOutBag) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[string]int32, size) + p.MChessData = tMap + for i := 0; i < size; i++ { + var _key144 string + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key144 = v + } + var _val145 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val145 = v + } + p.MChessData[_key144] = _val145 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ReqTakeChessOutBag) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqTakeChessOutBag"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqTakeChessOutBag) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "BagId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:BagId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.BagId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.BagId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:BagId: ", p), err) + } + return err +} + +func (p *ReqTakeChessOutBag) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MChessData", thrift.MAP, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:MChessData: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.STRING, thrift.I32, len(p.MChessData)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.MChessData { + if err := oprot.WriteString(ctx, string(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:MChessData: ", p), err) + } + return err +} + +func (p *ReqTakeChessOutBag) Equals(other *ReqTakeChessOutBag) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.BagId != other.BagId { + return false + } + if len(p.MChessData) != len(other.MChessData) { + return false + } + for k, _tgt := range p.MChessData { + _src146 := other.MChessData[k] + if _tgt != _src146 { + return false + } + } + return true +} + +func (p *ReqTakeChessOutBag) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqTakeChessOutBag(%+v)", *p) +} + +func (p *ReqTakeChessOutBag) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqTakeChessOutBag", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqTakeChessOutBag)(nil) + +func (p *ReqTakeChessOutBag) Validate() error { + return nil +} + +// Attributes: +// - BagId +// +type ReqTakeChessOutBagToHonor struct { + BagId int32 `thrift:"BagId,1" db:"BagId" json:"BagId"` +} + +func NewReqTakeChessOutBagToHonor() *ReqTakeChessOutBagToHonor { + return &ReqTakeChessOutBagToHonor{} +} + +func (p *ReqTakeChessOutBagToHonor) GetBagId() int32 { + return p.BagId +} + +func (p *ReqTakeChessOutBagToHonor) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqTakeChessOutBagToHonor) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.BagId = v + } + return nil +} + +func (p *ReqTakeChessOutBagToHonor) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqTakeChessOutBagToHonor"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqTakeChessOutBagToHonor) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "BagId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:BagId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.BagId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.BagId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:BagId: ", p), err) + } + return err +} + +func (p *ReqTakeChessOutBagToHonor) Equals(other *ReqTakeChessOutBagToHonor) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.BagId != other.BagId { + return false + } + return true +} + +func (p *ReqTakeChessOutBagToHonor) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqTakeChessOutBagToHonor(%+v)", *p) +} + +func (p *ReqTakeChessOutBagToHonor) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqTakeChessOutBagToHonor", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqTakeChessOutBagToHonor)(nil) + +func (p *ReqTakeChessOutBagToHonor) Validate() error { + return nil +} + +// Attributes: +// - DwUin +// - BindAccountId +// +type ReqUnBindFacebook struct { + DwUin int64 `thrift:"dwUin,1" db:"dwUin" json:"dwUin"` + BindAccountId string `thrift:"BindAccountId,2" db:"BindAccountId" json:"BindAccountId"` +} + +func NewReqUnBindFacebook() *ReqUnBindFacebook { + return &ReqUnBindFacebook{} +} + +func (p *ReqUnBindFacebook) GetDwUin() int64 { + return p.DwUin +} + +func (p *ReqUnBindFacebook) GetBindAccountId() string { + return p.BindAccountId +} + +func (p *ReqUnBindFacebook) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqUnBindFacebook) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.DwUin = v + } + return nil +} + +func (p *ReqUnBindFacebook) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.BindAccountId = v + } + return nil +} + +func (p *ReqUnBindFacebook) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqUnBindFacebook"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqUnBindFacebook) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "dwUin", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:dwUin: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.DwUin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.dwUin (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:dwUin: ", p), err) + } + return err +} + +func (p *ReqUnBindFacebook) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "BindAccountId", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:BindAccountId: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.BindAccountId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.BindAccountId (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:BindAccountId: ", p), err) + } + return err +} + +func (p *ReqUnBindFacebook) Equals(other *ReqUnBindFacebook) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.DwUin != other.DwUin { + return false + } + if p.BindAccountId != other.BindAccountId { + return false + } + return true +} + +func (p *ReqUnBindFacebook) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqUnBindFacebook(%+v)", *p) +} + +func (p *ReqUnBindFacebook) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqUnBindFacebook", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqUnBindFacebook)(nil) + +func (p *ReqUnBindFacebook) Validate() error { + return nil +} + +// Attributes: +// - ChessId +// - MChessData +// +type ReqUpgradeChess struct { + ChessId int32 `thrift:"ChessId,1" db:"ChessId" json:"ChessId"` + MChessData map[string]int32 `thrift:"MChessData,2" db:"MChessData" json:"MChessData"` +} + +func NewReqUpgradeChess() *ReqUpgradeChess { + return &ReqUpgradeChess{} +} + +func (p *ReqUpgradeChess) GetChessId() int32 { + return p.ChessId +} + +func (p *ReqUpgradeChess) GetMChessData() map[string]int32 { + return p.MChessData +} + +func (p *ReqUpgradeChess) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.MAP { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqUpgradeChess) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.ChessId = v + } + return nil +} + +func (p *ReqUpgradeChess) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[string]int32, size) + p.MChessData = tMap + for i := 0; i < size; i++ { + var _key147 string + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key147 = v + } + var _val148 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val148 = v + } + p.MChessData[_key147] = _val148 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ReqUpgradeChess) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqUpgradeChess"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqUpgradeChess) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChessId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ChessId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ChessId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ChessId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ChessId: ", p), err) + } + return err +} + +func (p *ReqUpgradeChess) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MChessData", thrift.MAP, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:MChessData: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.STRING, thrift.I32, len(p.MChessData)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.MChessData { + if err := oprot.WriteString(ctx, string(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:MChessData: ", p), err) + } + return err +} + +func (p *ReqUpgradeChess) Equals(other *ReqUpgradeChess) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ChessId != other.ChessId { + return false + } + if len(p.MChessData) != len(other.MChessData) { + return false + } + for k, _tgt := range p.MChessData { + _src149 := other.MChessData[k] + if _tgt != _src149 { + return false + } + } + return true +} + +func (p *ReqUpgradeChess) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqUpgradeChess(%+v)", *p) +} + +func (p *ReqUpgradeChess) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqUpgradeChess", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqUpgradeChess)(nil) + +func (p *ReqUpgradeChess) Validate() error { + return nil +} + +type ReqUserInfo struct { +} + +func NewReqUserInfo() *ReqUserInfo { + return &ReqUserInfo{} +} + +func (p *ReqUserInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqUserInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqUserInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqUserInfo) Equals(other *ReqUserInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqUserInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqUserInfo(%+v)", *p) +} + +func (p *ReqUserInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqUserInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqUserInfo)(nil) + +func (p *ReqUserInfo) Validate() error { + return nil +} + +// Attributes: +// - Uid +// +type ReqWishApply struct { + Uid int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` +} + +func NewReqWishApply() *ReqWishApply { + return &ReqWishApply{} +} + +func (p *ReqWishApply) GetUid() int64 { + return p.Uid +} + +func (p *ReqWishApply) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqWishApply) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ReqWishApply) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqWishApply"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqWishApply) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *ReqWishApply) Equals(other *ReqWishApply) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Uid != other.Uid { + return false + } + return true +} + +func (p *ReqWishApply) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqWishApply(%+v)", *p) +} + +func (p *ReqWishApply) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqWishApply", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqWishApply)(nil) + +func (p *ReqWishApply) Validate() error { + return nil +} + +type ReqWishApplyList struct { +} + +func NewReqWishApplyList() *ReqWishApplyList { + return &ReqWishApplyList{} +} + +func (p *ReqWishApplyList) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ReqWishApplyList) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ReqWishApplyList"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ReqWishApplyList) Equals(other *ReqWishApplyList) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + return true +} + +func (p *ReqWishApplyList) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ReqWishApplyList(%+v)", *p) +} + +func (p *ReqWishApplyList) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ReqWishApplyList", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ReqWishApplyList)(nil) + +func (p *ReqWishApplyList) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Status +// - EndTime +// - Template +// - Score +// - Reward +// - LowPass +// - HighPass +// +type ResActPass struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Status int32 `thrift:"Status,2" db:"Status" json:"Status"` + EndTime int32 `thrift:"EndTime,3" db:"EndTime" json:"EndTime"` + Template int32 `thrift:"Template,4" db:"Template" json:"Template"` + // unused field # 5 + Score int32 `thrift:"Score,6" db:"Score" json:"Score"` + Reward []int32 `thrift:"Reward,7" db:"Reward" json:"Reward"` + LowPass bool `thrift:"LowPass,8" db:"LowPass" json:"LowPass"` + HighPass bool `thrift:"HighPass,9" db:"HighPass" json:"HighPass"` +} + +func NewResActPass() *ResActPass { + return &ResActPass{} +} + +func (p *ResActPass) GetId() int32 { + return p.Id +} + +func (p *ResActPass) GetStatus() int32 { + return p.Status +} + +func (p *ResActPass) GetEndTime() int32 { + return p.EndTime +} + +func (p *ResActPass) GetTemplate() int32 { + return p.Template +} + +func (p *ResActPass) GetScore() int32 { + return p.Score +} + +func (p *ResActPass) GetReward() []int32 { + return p.Reward +} + +func (p *ResActPass) GetLowPass() bool { + return p.LowPass +} + +func (p *ResActPass) GetHighPass() bool { + return p.HighPass +} + +func (p *ResActPass) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.I32 { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.LIST { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 8: + if fieldTypeId == thrift.BOOL { + if err := p.ReadField8(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 9: + if fieldTypeId == thrift.BOOL { + if err := p.ReadField9(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResActPass) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResActPass) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Status = v + } + return nil +} + +func (p *ResActPass) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.EndTime = v + } + return nil +} + +func (p *ResActPass) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Template = v + } + return nil +} + +func (p *ResActPass) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 6: ", err) + } else { + p.Score = v + } + return nil +} + +func (p *ResActPass) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.Reward = tSlice + for i := 0; i < size; i++ { + var _elem150 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem150 = v + } + p.Reward = append(p.Reward, _elem150) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResActPass) ReadField8(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadBool(ctx); err != nil { + return thrift.PrependError("error reading field 8: ", err) + } else { + p.LowPass = v + } + return nil +} + +func (p *ResActPass) ReadField9(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadBool(ctx); err != nil { + return thrift.PrependError("error reading field 9: ", err) + } else { + p.HighPass = v + } + return nil +} + +func (p *ResActPass) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResActPass"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + if err := p.writeField8(ctx, oprot); err != nil { + return err + } + if err := p.writeField9(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResActPass) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ResActPass) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Status", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Status: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Status)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Status (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Status: ", p), err) + } + return err +} + +func (p *ResActPass) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EndTime", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:EndTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.EndTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EndTime (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:EndTime: ", p), err) + } + return err +} + +func (p *ResActPass) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Template", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Template: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Template)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Template (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Template: ", p), err) + } + return err +} + +func (p *ResActPass) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Score", thrift.I32, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:Score: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Score)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Score (6) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:Score: ", p), err) + } + return err +} + +func (p *ResActPass) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Reward", thrift.LIST, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:Reward: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.Reward)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Reward { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:Reward: ", p), err) + } + return err +} + +func (p *ResActPass) writeField8(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "LowPass", thrift.BOOL, 8); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 8:LowPass: ", p), err) + } + if err := oprot.WriteBool(ctx, bool(p.LowPass)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.LowPass (8) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 8:LowPass: ", p), err) + } + return err +} + +func (p *ResActPass) writeField9(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "HighPass", thrift.BOOL, 9); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 9:HighPass: ", p), err) + } + if err := oprot.WriteBool(ctx, bool(p.HighPass)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.HighPass (9) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 9:HighPass: ", p), err) + } + return err +} + +func (p *ResActPass) Equals(other *ResActPass) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Status != other.Status { + return false + } + if p.EndTime != other.EndTime { + return false + } + if p.Template != other.Template { + return false + } + if p.Score != other.Score { + return false + } + if len(p.Reward) != len(other.Reward) { + return false + } + for i, _tgt := range p.Reward { + _src151 := other.Reward[i] + if _tgt != _src151 { + return false + } + } + if p.LowPass != other.LowPass { + return false + } + if p.HighPass != other.HighPass { + return false + } + return true +} + +func (p *ResActPass) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResActPass(%+v)", *p) +} + +func (p *ResActPass) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResActPass", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResActPass)(nil) + +func (p *ResActPass) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - RewardLevel +// +type ResActPassReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + RewardLevel []int32 `thrift:"RewardLevel,3" db:"RewardLevel" json:"RewardLevel"` +} + +func NewResActPassReward() *ResActPassReward { + return &ResActPassReward{} +} + +func (p *ResActPassReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResActPassReward) GetMsg() string { + return p.Msg +} + +func (p *ResActPassReward) GetRewardLevel() []int32 { + return p.RewardLevel +} + +func (p *ResActPassReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.LIST { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResActPassReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResActPassReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResActPassReward) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.RewardLevel = tSlice + for i := 0; i < size; i++ { + var _elem152 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem152 = v + } + p.RewardLevel = append(p.RewardLevel, _elem152) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResActPassReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResActPassReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResActPassReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResActPassReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResActPassReward) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "RewardLevel", thrift.LIST, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:RewardLevel: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.RewardLevel)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.RewardLevel { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:RewardLevel: ", p), err) + } + return err +} + +func (p *ResActPassReward) Equals(other *ResActPassReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if len(p.RewardLevel) != len(other.RewardLevel) { + return false + } + for i, _tgt := range p.RewardLevel { + _src153 := other.RewardLevel[i] + if _tgt != _src153 { + return false + } + } + return true +} + +func (p *ResActPassReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResActPassReward(%+v)", *p) +} + +func (p *ResActPassReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResActPassReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResActPassReward)(nil) + +func (p *ResActPassReward) Validate() error { + return nil +} + +// Attributes: +// - Red +// +type ResActRed struct { + Red map[int32]int32 `thrift:"Red,1" db:"Red" json:"Red"` +} + +func NewResActRed() *ResActRed { + return &ResActRed{} +} + +func (p *ResActRed) GetRed() map[int32]int32 { + return p.Red +} + +func (p *ResActRed) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.MAP { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResActRed) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.Red = tMap + for i := 0; i < size; i++ { + var _key154 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key154 = v + } + var _val155 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val155 = v + } + p.Red[_key154] = _val155 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResActRed) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResActRed"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResActRed) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Red", thrift.MAP, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Red: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.Red)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Red { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Red: ", p), err) + } + return err +} + +func (p *ResActRed) Equals(other *ResActRed) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.Red) != len(other.Red) { + return false + } + for k, _tgt := range p.Red { + _src156 := other.Red[k] + if _tgt != _src156 { + return false + } + } + return true +} + +func (p *ResActRed) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResActRed(%+v)", *p) +} + +func (p *ResActRed) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResActRed", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResActRed)(nil) + +func (p *ResActRed) Validate() error { + return nil +} + +// Attributes: +// - ActiveList +// - AddEnd +// - AddReward +// +type ResActivity struct { + ActiveList []*ActivityInfo `thrift:"ActiveList,1" db:"ActiveList" json:"ActiveList"` + AddEnd int64 `thrift:"AddEnd,2" db:"AddEnd" json:"AddEnd"` + AddReward bool `thrift:"AddReward,3" db:"AddReward" json:"AddReward"` +} + +func NewResActivity() *ResActivity { + return &ResActivity{} +} + +func (p *ResActivity) GetActiveList() []*ActivityInfo { + return p.ActiveList +} + +func (p *ResActivity) GetAddEnd() int64 { + return p.AddEnd +} + +func (p *ResActivity) GetAddReward() bool { + return p.AddReward +} + +func (p *ResActivity) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I64 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.BOOL { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResActivity) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ActivityInfo, 0, size) + p.ActiveList = tSlice + for i := 0; i < size; i++ { + _elem157 := &ActivityInfo{} + if err := _elem157.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem157), err) + } + p.ActiveList = append(p.ActiveList, _elem157) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResActivity) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.AddEnd = v + } + return nil +} + +func (p *ResActivity) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadBool(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.AddReward = v + } + return nil +} + +func (p *ResActivity) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResActivity"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResActivity) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ActiveList", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ActiveList: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.ActiveList)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.ActiveList { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ActiveList: ", p), err) + } + return err +} + +func (p *ResActivity) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "AddEnd", thrift.I64, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:AddEnd: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.AddEnd)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.AddEnd (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:AddEnd: ", p), err) + } + return err +} + +func (p *ResActivity) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "AddReward", thrift.BOOL, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:AddReward: ", p), err) + } + if err := oprot.WriteBool(ctx, bool(p.AddReward)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.AddReward (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:AddReward: ", p), err) + } + return err +} + +func (p *ResActivity) Equals(other *ResActivity) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.ActiveList) != len(other.ActiveList) { + return false + } + for i, _tgt := range p.ActiveList { + _src158 := other.ActiveList[i] + if !_tgt.Equals(_src158) { + return false + } + } + if p.AddEnd != other.AddEnd { + return false + } + if p.AddReward != other.AddReward { + return false + } + return true +} + +func (p *ResActivity) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResActivity(%+v)", *p) +} + +func (p *ResActivity) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResActivity", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResActivity)(nil) + +func (p *ResActivity) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResActivityCfgReload struct { + Code int32 `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResActivityCfgReload() *ResActivityCfgReload { + return &ResActivityCfgReload{} +} + +func (p *ResActivityCfgReload) GetCode() int32 { + return p.Code +} + +func (p *ResActivityCfgReload) GetMsg() string { + return p.Msg +} + +func (p *ResActivityCfgReload) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResActivityCfgReload) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Code = v + } + return nil +} + +func (p *ResActivityCfgReload) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResActivityCfgReload) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResActivityCfgReload"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResActivityCfgReload) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResActivityCfgReload) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResActivityCfgReload) Equals(other *ResActivityCfgReload) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResActivityCfgReload) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResActivityCfgReload(%+v)", *p) +} + +func (p *ResActivityCfgReload) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResActivityCfgReload", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResActivityCfgReload)(nil) + +func (p *ResActivityCfgReload) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResActivityReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResActivityReward() *ResActivityReward { + return &ResActivityReward{} +} + +func (p *ResActivityReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResActivityReward) GetMsg() string { + return p.Msg +} + +func (p *ResActivityReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResActivityReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResActivityReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResActivityReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResActivityReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResActivityReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResActivityReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResActivityReward) Equals(other *ResActivityReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResActivityReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResActivityReward(%+v)", *p) +} + +func (p *ResActivityReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResActivityReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResActivityReward)(nil) + +func (p *ResActivityReward) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResAdWatch struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResAdWatch() *ResAdWatch { + return &ResAdWatch{} +} + +func (p *ResAdWatch) GetCode() RES_CODE { + return p.Code +} + +func (p *ResAdWatch) GetMsg() string { + return p.Msg +} + +func (p *ResAdWatch) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResAdWatch) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResAdWatch) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResAdWatch) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResAdWatch"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResAdWatch) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResAdWatch) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResAdWatch) Equals(other *ResAdWatch) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResAdWatch) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResAdWatch(%+v)", *p) +} + +func (p *ResAdWatch) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResAdWatch", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResAdWatch)(nil) + +func (p *ResAdWatch) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResAddGiftReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResAddGiftReward() *ResAddGiftReward { + return &ResAddGiftReward{} +} + +func (p *ResAddGiftReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResAddGiftReward) GetMsg() string { + return p.Msg +} + +func (p *ResAddGiftReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResAddGiftReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResAddGiftReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResAddGiftReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResAddGiftReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResAddGiftReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResAddGiftReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResAddGiftReward) Equals(other *ResAddGiftReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResAddGiftReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResAddGiftReward(%+v)", *p) +} + +func (p *ResAddGiftReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResAddGiftReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResAddGiftReward)(nil) + +func (p *ResAddGiftReward) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - NpcId +// +type ResAddNpc struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + NpcId int32 `thrift:"NpcId,3" db:"NpcId" json:"NpcId"` +} + +func NewResAddNpc() *ResAddNpc { + return &ResAddNpc{} +} + +func (p *ResAddNpc) GetCode() RES_CODE { + return p.Code +} + +func (p *ResAddNpc) GetMsg() string { + return p.Msg +} + +func (p *ResAddNpc) GetNpcId() int32 { + return p.NpcId +} + +func (p *ResAddNpc) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResAddNpc) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResAddNpc) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResAddNpc) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.NpcId = v + } + return nil +} + +func (p *ResAddNpc) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResAddNpc"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResAddNpc) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResAddNpc) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResAddNpc) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "NpcId", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:NpcId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.NpcId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.NpcId (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:NpcId: ", p), err) + } + return err +} + +func (p *ResAddNpc) Equals(other *ResAddNpc) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.NpcId != other.NpcId { + return false + } + return true +} + +func (p *ResAddNpc) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResAddNpc(%+v)", *p) +} + +func (p *ResAddNpc) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResAddNpc", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResAddNpc)(nil) + +func (p *ResAddNpc) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResAddWish struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResAddWish() *ResAddWish { + return &ResAddWish{} +} + +func (p *ResAddWish) GetCode() RES_CODE { + return p.Code +} + +func (p *ResAddWish) GetMsg() string { + return p.Msg +} + +func (p *ResAddWish) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResAddWish) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResAddWish) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResAddWish) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResAddWish"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResAddWish) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResAddWish) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResAddWish) Equals(other *ResAddWish) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResAddWish) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResAddWish(%+v)", *p) +} + +func (p *ResAddWish) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResAddWish", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResAddWish)(nil) + +func (p *ResAddWish) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Id +// - Emoji +// +type ResAgreeCardExchange struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Id string `thrift:"Id,3" db:"Id" json:"Id"` + Emoji int32 `thrift:"Emoji,4" db:"Emoji" json:"Emoji"` +} + +func NewResAgreeCardExchange() *ResAgreeCardExchange { + return &ResAgreeCardExchange{} +} + +func (p *ResAgreeCardExchange) GetCode() RES_CODE { + return p.Code +} + +func (p *ResAgreeCardExchange) GetMsg() string { + return p.Msg +} + +func (p *ResAgreeCardExchange) GetId() string { + return p.Id +} + +func (p *ResAgreeCardExchange) GetEmoji() int32 { + return p.Emoji +} + +func (p *ResAgreeCardExchange) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.STRING { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResAgreeCardExchange) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResAgreeCardExchange) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResAgreeCardExchange) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResAgreeCardExchange) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Emoji = v + } + return nil +} + +func (p *ResAgreeCardExchange) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResAgreeCardExchange"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResAgreeCardExchange) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResAgreeCardExchange) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResAgreeCardExchange) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.STRING, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Id: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Id: ", p), err) + } + return err +} + +func (p *ResAgreeCardExchange) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Emoji", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Emoji: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Emoji)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Emoji (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Emoji: ", p), err) + } + return err +} + +func (p *ResAgreeCardExchange) Equals(other *ResAgreeCardExchange) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Id != other.Id { + return false + } + if p.Emoji != other.Emoji { + return false + } + return true +} + +func (p *ResAgreeCardExchange) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResAgreeCardExchange(%+v)", *p) +} + +func (p *ResAgreeCardExchange) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResAgreeCardExchange", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResAgreeCardExchange)(nil) + +func (p *ResAgreeCardExchange) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Id +// +type ResAgreeCardGive struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Id string `thrift:"Id,3" db:"Id" json:"Id"` +} + +func NewResAgreeCardGive() *ResAgreeCardGive { + return &ResAgreeCardGive{} +} + +func (p *ResAgreeCardGive) GetCode() RES_CODE { + return p.Code +} + +func (p *ResAgreeCardGive) GetMsg() string { + return p.Msg +} + +func (p *ResAgreeCardGive) GetId() string { + return p.Id +} + +func (p *ResAgreeCardGive) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.STRING { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResAgreeCardGive) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResAgreeCardGive) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResAgreeCardGive) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResAgreeCardGive) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResAgreeCardGive"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResAgreeCardGive) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResAgreeCardGive) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResAgreeCardGive) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.STRING, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Id: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Id: ", p), err) + } + return err +} + +func (p *ResAgreeCardGive) Equals(other *ResAgreeCardGive) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ResAgreeCardGive) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResAgreeCardGive(%+v)", *p) +} + +func (p *ResAgreeCardGive) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResAgreeCardGive", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResAgreeCardGive)(nil) + +func (p *ResAgreeCardGive) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Uid +// - Player +// +type ResAgreeFriend struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Uid int64 `thrift:"Uid,3" db:"Uid" json:"Uid"` + Player *ResPlayerSimple `thrift:"Player,4" db:"Player" json:"Player"` +} + +func NewResAgreeFriend() *ResAgreeFriend { + return &ResAgreeFriend{} +} + +func (p *ResAgreeFriend) GetCode() RES_CODE { + return p.Code +} + +func (p *ResAgreeFriend) GetMsg() string { + return p.Msg +} + +func (p *ResAgreeFriend) GetUid() int64 { + return p.Uid +} + +var ResAgreeFriend_Player_DEFAULT *ResPlayerSimple + +func (p *ResAgreeFriend) GetPlayer() *ResPlayerSimple { + if !p.IsSetPlayer() { + return ResAgreeFriend_Player_DEFAULT + } + return p.Player +} + +func (p *ResAgreeFriend) IsSetPlayer() bool { + return p.Player != nil +} + +func (p *ResAgreeFriend) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I64 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResAgreeFriend) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResAgreeFriend) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResAgreeFriend) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ResAgreeFriend) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + p.Player = &ResPlayerSimple{} + if err := p.Player.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.Player), err) + } + return nil +} + +func (p *ResAgreeFriend) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResAgreeFriend"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResAgreeFriend) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResAgreeFriend) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResAgreeFriend) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Uid: ", p), err) + } + return err +} + +func (p *ResAgreeFriend) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Player", thrift.STRUCT, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Player: ", p), err) + } + if err := p.Player.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.Player), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Player: ", p), err) + } + return err +} + +func (p *ResAgreeFriend) Equals(other *ResAgreeFriend) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Uid != other.Uid { + return false + } + if !p.Player.Equals(other.Player) { + return false + } + return true +} + +func (p *ResAgreeFriend) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResAgreeFriend(%+v)", *p) +} + +func (p *ResAgreeFriend) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResAgreeFriend", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResAgreeFriend)(nil) + +func (p *ResAgreeFriend) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResAllCollectReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResAllCollectReward() *ResAllCollectReward { + return &ResAllCollectReward{} +} + +func (p *ResAllCollectReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResAllCollectReward) GetMsg() string { + return p.Msg +} + +func (p *ResAllCollectReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResAllCollectReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResAllCollectReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResAllCollectReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResAllCollectReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResAllCollectReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResAllCollectReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResAllCollectReward) Equals(other *ResAllCollectReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResAllCollectReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResAllCollectReward(%+v)", *p) +} + +func (p *ResAllCollectReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResAllCollectReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResAllCollectReward)(nil) + +func (p *ResAllCollectReward) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Uid +// +type ResApplyFriend struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Uid int64 `thrift:"Uid,3" db:"Uid" json:"Uid"` +} + +func NewResApplyFriend() *ResApplyFriend { + return &ResApplyFriend{} +} + +func (p *ResApplyFriend) GetCode() RES_CODE { + return p.Code +} + +func (p *ResApplyFriend) GetMsg() string { + return p.Msg +} + +func (p *ResApplyFriend) GetUid() int64 { + return p.Uid +} + +func (p *ResApplyFriend) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I64 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResApplyFriend) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResApplyFriend) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResApplyFriend) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ResApplyFriend) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResApplyFriend"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResApplyFriend) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResApplyFriend) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResApplyFriend) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Uid: ", p), err) + } + return err +} + +func (p *ResApplyFriend) Equals(other *ResApplyFriend) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Uid != other.Uid { + return false + } + return true +} + +func (p *ResApplyFriend) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResApplyFriend(%+v)", *p) +} + +func (p *ResApplyFriend) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResApplyFriend", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResApplyFriend)(nil) + +func (p *ResApplyFriend) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResAreaReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResAreaReward() *ResAreaReward { + return &ResAreaReward{} +} + +func (p *ResAreaReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResAreaReward) GetMsg() string { + return p.Msg +} + +func (p *ResAreaReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResAreaReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResAreaReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResAreaReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResAreaReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResAreaReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResAreaReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResAreaReward) Equals(other *ResAreaReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResAreaReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResAreaReward(%+v)", *p) +} + +func (p *ResAreaReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResAreaReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResAreaReward)(nil) + +func (p *ResAreaReward) Validate() error { + return nil +} + +// Attributes: +// - ResultCode +// +type ResAutoAddInviteFriend struct { + ResultCode int32 `thrift:"ResultCode,1" db:"ResultCode" json:"ResultCode"` +} + +func NewResAutoAddInviteFriend() *ResAutoAddInviteFriend { + return &ResAutoAddInviteFriend{} +} + +func (p *ResAutoAddInviteFriend) GetResultCode() int32 { + return p.ResultCode +} + +func (p *ResAutoAddInviteFriend) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResAutoAddInviteFriend) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.ResultCode = v + } + return nil +} + +func (p *ResAutoAddInviteFriend) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResAutoAddInviteFriend"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResAutoAddInviteFriend) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ResultCode", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ResultCode: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ResultCode)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ResultCode (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ResultCode: ", p), err) + } + return err +} + +func (p *ResAutoAddInviteFriend) Equals(other *ResAutoAddInviteFriend) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ResultCode != other.ResultCode { + return false + } + return true +} + +func (p *ResAutoAddInviteFriend) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResAutoAddInviteFriend(%+v)", *p) +} + +func (p *ResAutoAddInviteFriend) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResAutoAddInviteFriend", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResAutoAddInviteFriend)(nil) + +func (p *ResAutoAddInviteFriend) Validate() error { + return nil +} + +// Attributes: +// - ResultCode +// +type ResAutoAddInviteFriend2 struct { + ResultCode int32 `thrift:"ResultCode,1" db:"ResultCode" json:"ResultCode"` +} + +func NewResAutoAddInviteFriend2() *ResAutoAddInviteFriend2 { + return &ResAutoAddInviteFriend2{} +} + +func (p *ResAutoAddInviteFriend2) GetResultCode() int32 { + return p.ResultCode +} + +func (p *ResAutoAddInviteFriend2) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResAutoAddInviteFriend2) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.ResultCode = v + } + return nil +} + +func (p *ResAutoAddInviteFriend2) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResAutoAddInviteFriend2"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResAutoAddInviteFriend2) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ResultCode", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ResultCode: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ResultCode)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ResultCode (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ResultCode: ", p), err) + } + return err +} + +func (p *ResAutoAddInviteFriend2) Equals(other *ResAutoAddInviteFriend2) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ResultCode != other.ResultCode { + return false + } + return true +} + +func (p *ResAutoAddInviteFriend2) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResAutoAddInviteFriend2(%+v)", *p) +} + +func (p *ResAutoAddInviteFriend2) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResAutoAddInviteFriend2", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResAutoAddInviteFriend2)(nil) + +func (p *ResAutoAddInviteFriend2) Validate() error { + return nil +} + +// Attributes: +// - AvatarList +// - SetId +// +type ResAvatarInfo struct { + AvatarList []*AvatarInfo `thrift:"AvatarList,1" db:"AvatarList" json:"AvatarList"` + SetId int32 `thrift:"SetId,2" db:"SetId" json:"SetId"` +} + +func NewResAvatarInfo() *ResAvatarInfo { + return &ResAvatarInfo{} +} + +func (p *ResAvatarInfo) GetAvatarList() []*AvatarInfo { + return p.AvatarList +} + +func (p *ResAvatarInfo) GetSetId() int32 { + return p.SetId +} + +func (p *ResAvatarInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResAvatarInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*AvatarInfo, 0, size) + p.AvatarList = tSlice + for i := 0; i < size; i++ { + _elem159 := &AvatarInfo{} + if err := _elem159.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem159), err) + } + p.AvatarList = append(p.AvatarList, _elem159) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResAvatarInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.SetId = v + } + return nil +} + +func (p *ResAvatarInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResAvatarInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResAvatarInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "AvatarList", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:AvatarList: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.AvatarList)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.AvatarList { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:AvatarList: ", p), err) + } + return err +} + +func (p *ResAvatarInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "SetId", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:SetId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.SetId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.SetId (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:SetId: ", p), err) + } + return err +} + +func (p *ResAvatarInfo) Equals(other *ResAvatarInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.AvatarList) != len(other.AvatarList) { + return false + } + for i, _tgt := range p.AvatarList { + _src160 := other.AvatarList[i] + if !_tgt.Equals(_src160) { + return false + } + } + if p.SetId != other.SetId { + return false + } + return true +} + +func (p *ResAvatarInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResAvatarInfo(%+v)", *p) +} + +func (p *ResAvatarInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResAvatarInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResAvatarInfo)(nil) + +func (p *ResAvatarInfo) Validate() error { + return nil +} + +// Attributes: +// - DwUin +// - BindAccountId +// - ResultCode +// +type ResBindFacebookAccount struct { + DwUin int64 `thrift:"dwUin,1" db:"dwUin" json:"dwUin"` + BindAccountId string `thrift:"BindAccountId,2" db:"BindAccountId" json:"BindAccountId"` + ResultCode int32 `thrift:"ResultCode,3" db:"ResultCode" json:"ResultCode"` +} + +func NewResBindFacebookAccount() *ResBindFacebookAccount { + return &ResBindFacebookAccount{} +} + +func (p *ResBindFacebookAccount) GetDwUin() int64 { + return p.DwUin +} + +func (p *ResBindFacebookAccount) GetBindAccountId() string { + return p.BindAccountId +} + +func (p *ResBindFacebookAccount) GetResultCode() int32 { + return p.ResultCode +} + +func (p *ResBindFacebookAccount) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResBindFacebookAccount) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.DwUin = v + } + return nil +} + +func (p *ResBindFacebookAccount) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.BindAccountId = v + } + return nil +} + +func (p *ResBindFacebookAccount) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.ResultCode = v + } + return nil +} + +func (p *ResBindFacebookAccount) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResBindFacebookAccount"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResBindFacebookAccount) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "dwUin", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:dwUin: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.DwUin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.dwUin (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:dwUin: ", p), err) + } + return err +} + +func (p *ResBindFacebookAccount) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "BindAccountId", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:BindAccountId: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.BindAccountId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.BindAccountId (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:BindAccountId: ", p), err) + } + return err +} + +func (p *ResBindFacebookAccount) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ResultCode", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:ResultCode: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ResultCode)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ResultCode (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:ResultCode: ", p), err) + } + return err +} + +func (p *ResBindFacebookAccount) Equals(other *ResBindFacebookAccount) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.DwUin != other.DwUin { + return false + } + if p.BindAccountId != other.BindAccountId { + return false + } + if p.ResultCode != other.ResultCode { + return false + } + return true +} + +func (p *ResBindFacebookAccount) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResBindFacebookAccount(%+v)", *p) +} + +func (p *ResBindFacebookAccount) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResBindFacebookAccount", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResBindFacebookAccount)(nil) + +func (p *ResBindFacebookAccount) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResBuyChessBagGrid struct { + Code RES_CODE `thrift:"code,1" db:"code" json:"code"` + Msg string `thrift:"msg,2" db:"msg" json:"msg"` +} + +func NewResBuyChessBagGrid() *ResBuyChessBagGrid { + return &ResBuyChessBagGrid{} +} + +func (p *ResBuyChessBagGrid) GetCode() RES_CODE { + return p.Code +} + +func (p *ResBuyChessBagGrid) GetMsg() string { + return p.Msg +} + +func (p *ResBuyChessBagGrid) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResBuyChessBagGrid) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResBuyChessBagGrid) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResBuyChessBagGrid) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResBuyChessBagGrid"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResBuyChessBagGrid) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:code: ", p), err) + } + return err +} + +func (p *ResBuyChessBagGrid) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:msg: ", p), err) + } + return err +} + +func (p *ResBuyChessBagGrid) Equals(other *ResBuyChessBagGrid) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResBuyChessBagGrid) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResBuyChessBagGrid(%+v)", *p) +} + +func (p *ResBuyChessBagGrid) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResBuyChessBagGrid", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResBuyChessBagGrid)(nil) + +func (p *ResBuyChessBagGrid) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResBuyChessShop struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResBuyChessShop() *ResBuyChessShop { + return &ResBuyChessShop{} +} + +func (p *ResBuyChessShop) GetCode() RES_CODE { + return p.Code +} + +func (p *ResBuyChessShop) GetMsg() string { + return p.Msg +} + +func (p *ResBuyChessShop) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResBuyChessShop) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResBuyChessShop) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResBuyChessShop) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResBuyChessShop"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResBuyChessShop) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResBuyChessShop) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResBuyChessShop) Equals(other *ResBuyChessShop) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResBuyChessShop) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResBuyChessShop(%+v)", *p) +} + +func (p *ResBuyChessShop) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResBuyChessShop", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResBuyChessShop)(nil) + +func (p *ResBuyChessShop) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResBuyChessShop2 struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResBuyChessShop2() *ResBuyChessShop2 { + return &ResBuyChessShop2{} +} + +func (p *ResBuyChessShop2) GetCode() RES_CODE { + return p.Code +} + +func (p *ResBuyChessShop2) GetMsg() string { + return p.Msg +} + +func (p *ResBuyChessShop2) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResBuyChessShop2) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResBuyChessShop2) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResBuyChessShop2) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResBuyChessShop2"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResBuyChessShop2) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResBuyChessShop2) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResBuyChessShop2) Equals(other *ResBuyChessShop2) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResBuyChessShop2) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResBuyChessShop2(%+v)", *p) +} + +func (p *ResBuyChessShop2) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResBuyChessShop2", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResBuyChessShop2)(nil) + +func (p *ResBuyChessShop2) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResBuyEnergy struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResBuyEnergy() *ResBuyEnergy { + return &ResBuyEnergy{} +} + +func (p *ResBuyEnergy) GetCode() RES_CODE { + return p.Code +} + +func (p *ResBuyEnergy) GetMsg() string { + return p.Msg +} + +func (p *ResBuyEnergy) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResBuyEnergy) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResBuyEnergy) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResBuyEnergy) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResBuyEnergy"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResBuyEnergy) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResBuyEnergy) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResBuyEnergy) Equals(other *ResBuyEnergy) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResBuyEnergy) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResBuyEnergy(%+v)", *p) +} + +func (p *ResBuyEnergy) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResBuyEnergy", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResBuyEnergy)(nil) + +func (p *ResBuyEnergy) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResCardCollectReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResCardCollectReward() *ResCardCollectReward { + return &ResCardCollectReward{} +} + +func (p *ResCardCollectReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResCardCollectReward) GetMsg() string { + return p.Msg +} + +func (p *ResCardCollectReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResCardCollectReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResCardCollectReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResCardCollectReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResCardCollectReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResCardCollectReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResCardCollectReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResCardCollectReward) Equals(other *ResCardCollectReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResCardCollectReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResCardCollectReward(%+v)", *p) +} + +func (p *ResCardCollectReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResCardCollectReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResCardCollectReward)(nil) + +func (p *ResCardCollectReward) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResCardExchange struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResCardExchange() *ResCardExchange { + return &ResCardExchange{} +} + +func (p *ResCardExchange) GetCode() RES_CODE { + return p.Code +} + +func (p *ResCardExchange) GetMsg() string { + return p.Msg +} + +func (p *ResCardExchange) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResCardExchange) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResCardExchange) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResCardExchange) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResCardExchange"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResCardExchange) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResCardExchange) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResCardExchange) Equals(other *ResCardExchange) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResCardExchange) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResCardExchange(%+v)", *p) +} + +func (p *ResCardExchange) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResCardExchange", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResCardExchange)(nil) + +func (p *ResCardExchange) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResCardGive struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResCardGive() *ResCardGive { + return &ResCardGive{} +} + +func (p *ResCardGive) GetCode() RES_CODE { + return p.Code +} + +func (p *ResCardGive) GetMsg() string { + return p.Msg +} + +func (p *ResCardGive) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResCardGive) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResCardGive) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResCardGive) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResCardGive"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResCardGive) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResCardGive) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResCardGive) Equals(other *ResCardGive) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResCardGive) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResCardGive(%+v)", *p) +} + +func (p *ResCardGive) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResCardGive", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResCardGive)(nil) + +func (p *ResCardGive) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - CardId +// +type ResCardHandbookReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + CardId int32 `thrift:"CardId,3" db:"CardId" json:"CardId"` +} + +func NewResCardHandbookReward() *ResCardHandbookReward { + return &ResCardHandbookReward{} +} + +func (p *ResCardHandbookReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResCardHandbookReward) GetMsg() string { + return p.Msg +} + +func (p *ResCardHandbookReward) GetCardId() int32 { + return p.CardId +} + +func (p *ResCardHandbookReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResCardHandbookReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResCardHandbookReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResCardHandbookReward) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.CardId = v + } + return nil +} + +func (p *ResCardHandbookReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResCardHandbookReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResCardHandbookReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResCardHandbookReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResCardHandbookReward) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "CardId", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:CardId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.CardId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.CardId (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:CardId: ", p), err) + } + return err +} + +func (p *ResCardHandbookReward) Equals(other *ResCardHandbookReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.CardId != other.CardId { + return false + } + return true +} + +func (p *ResCardHandbookReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResCardHandbookReward(%+v)", *p) +} + +func (p *ResCardHandbookReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResCardHandbookReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResCardHandbookReward)(nil) + +func (p *ResCardHandbookReward) Validate() error { + return nil +} + +// Attributes: +// - CardList +// - ExStar +// - Status +// - CollectId +// - ExTimes +// - ReqTimes +// - AllCard +// - EndTime +// - ReqUid +// - ExUid +// - GoldTimes +// - Round +// - Handbook +// - SeasonFirst +// +type ResCardInfo struct { + CardList []*Card `thrift:"CardList,1" db:"CardList" json:"CardList"` + ExStar int32 `thrift:"ExStar,2" db:"ExStar" json:"ExStar"` + Status int32 `thrift:"Status,3" db:"Status" json:"Status"` + CollectId []int32 `thrift:"CollectId,4" db:"CollectId" json:"CollectId"` + ExTimes int32 `thrift:"ExTimes,5" db:"ExTimes" json:"ExTimes"` + ReqTimes int32 `thrift:"ReqTimes,6" db:"ReqTimes" json:"ReqTimes"` + AllCard map[int32]int32 `thrift:"AllCard,7" db:"AllCard" json:"AllCard"` + EndTime int32 `thrift:"EndTime,8" db:"EndTime" json:"EndTime"` + ReqUid []int64 `thrift:"ReqUid,9" db:"ReqUid" json:"ReqUid"` + ExUid []int64 `thrift:"ExUid,10" db:"ExUid" json:"ExUid"` + GoldTimes int32 `thrift:"GoldTimes,11" db:"GoldTimes" json:"GoldTimes"` + Round int32 `thrift:"Round,12" db:"Round" json:"Round"` + Handbook map[int32]int32 `thrift:"Handbook,13" db:"Handbook" json:"Handbook"` + SeasonFirst bool `thrift:"SeasonFirst,14" db:"SeasonFirst" json:"SeasonFirst"` +} + +func NewResCardInfo() *ResCardInfo { + return &ResCardInfo{} +} + +func (p *ResCardInfo) GetCardList() []*Card { + return p.CardList +} + +func (p *ResCardInfo) GetExStar() int32 { + return p.ExStar +} + +func (p *ResCardInfo) GetStatus() int32 { + return p.Status +} + +func (p *ResCardInfo) GetCollectId() []int32 { + return p.CollectId +} + +func (p *ResCardInfo) GetExTimes() int32 { + return p.ExTimes +} + +func (p *ResCardInfo) GetReqTimes() int32 { + return p.ReqTimes +} + +func (p *ResCardInfo) GetAllCard() map[int32]int32 { + return p.AllCard +} + +func (p *ResCardInfo) GetEndTime() int32 { + return p.EndTime +} + +func (p *ResCardInfo) GetReqUid() []int64 { + return p.ReqUid +} + +func (p *ResCardInfo) GetExUid() []int64 { + return p.ExUid +} + +func (p *ResCardInfo) GetGoldTimes() int32 { + return p.GoldTimes +} + +func (p *ResCardInfo) GetRound() int32 { + return p.Round +} + +func (p *ResCardInfo) GetHandbook() map[int32]int32 { + return p.Handbook +} + +func (p *ResCardInfo) GetSeasonFirst() bool { + return p.SeasonFirst +} + +func (p *ResCardInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.LIST { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.I32 { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.MAP { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 8: + if fieldTypeId == thrift.I32 { + if err := p.ReadField8(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 9: + if fieldTypeId == thrift.LIST { + if err := p.ReadField9(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 10: + if fieldTypeId == thrift.LIST { + if err := p.ReadField10(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 11: + if fieldTypeId == thrift.I32 { + if err := p.ReadField11(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 12: + if fieldTypeId == thrift.I32 { + if err := p.ReadField12(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 13: + if fieldTypeId == thrift.MAP { + if err := p.ReadField13(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 14: + if fieldTypeId == thrift.BOOL { + if err := p.ReadField14(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResCardInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*Card, 0, size) + p.CardList = tSlice + for i := 0; i < size; i++ { + _elem161 := &Card{} + if err := _elem161.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem161), err) + } + p.CardList = append(p.CardList, _elem161) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResCardInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.ExStar = v + } + return nil +} + +func (p *ResCardInfo) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Status = v + } + return nil +} + +func (p *ResCardInfo) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.CollectId = tSlice + for i := 0; i < size; i++ { + var _elem162 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem162 = v + } + p.CollectId = append(p.CollectId, _elem162) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResCardInfo) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.ExTimes = v + } + return nil +} + +func (p *ResCardInfo) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 6: ", err) + } else { + p.ReqTimes = v + } + return nil +} + +func (p *ResCardInfo) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.AllCard = tMap + for i := 0; i < size; i++ { + var _key163 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key163 = v + } + var _val164 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val164 = v + } + p.AllCard[_key163] = _val164 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResCardInfo) ReadField8(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 8: ", err) + } else { + p.EndTime = v + } + return nil +} + +func (p *ResCardInfo) ReadField9(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int64, 0, size) + p.ReqUid = tSlice + for i := 0; i < size; i++ { + var _elem165 int64 + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem165 = v + } + p.ReqUid = append(p.ReqUid, _elem165) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResCardInfo) ReadField10(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int64, 0, size) + p.ExUid = tSlice + for i := 0; i < size; i++ { + var _elem166 int64 + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem166 = v + } + p.ExUid = append(p.ExUid, _elem166) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResCardInfo) ReadField11(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 11: ", err) + } else { + p.GoldTimes = v + } + return nil +} + +func (p *ResCardInfo) ReadField12(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 12: ", err) + } else { + p.Round = v + } + return nil +} + +func (p *ResCardInfo) ReadField13(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.Handbook = tMap + for i := 0; i < size; i++ { + var _key167 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key167 = v + } + var _val168 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val168 = v + } + p.Handbook[_key167] = _val168 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResCardInfo) ReadField14(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadBool(ctx); err != nil { + return thrift.PrependError("error reading field 14: ", err) + } else { + p.SeasonFirst = v + } + return nil +} + +func (p *ResCardInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResCardInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + if err := p.writeField8(ctx, oprot); err != nil { + return err + } + if err := p.writeField9(ctx, oprot); err != nil { + return err + } + if err := p.writeField10(ctx, oprot); err != nil { + return err + } + if err := p.writeField11(ctx, oprot); err != nil { + return err + } + if err := p.writeField12(ctx, oprot); err != nil { + return err + } + if err := p.writeField13(ctx, oprot); err != nil { + return err + } + if err := p.writeField14(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResCardInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "CardList", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:CardList: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.CardList)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.CardList { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:CardList: ", p), err) + } + return err +} + +func (p *ResCardInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ExStar", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:ExStar: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ExStar)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ExStar (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:ExStar: ", p), err) + } + return err +} + +func (p *ResCardInfo) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Status", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Status: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Status)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Status (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Status: ", p), err) + } + return err +} + +func (p *ResCardInfo) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "CollectId", thrift.LIST, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:CollectId: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.CollectId)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.CollectId { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:CollectId: ", p), err) + } + return err +} + +func (p *ResCardInfo) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ExTimes", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:ExTimes: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ExTimes)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ExTimes (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:ExTimes: ", p), err) + } + return err +} + +func (p *ResCardInfo) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ReqTimes", thrift.I32, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:ReqTimes: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ReqTimes)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ReqTimes (6) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:ReqTimes: ", p), err) + } + return err +} + +func (p *ResCardInfo) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "AllCard", thrift.MAP, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:AllCard: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.AllCard)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.AllCard { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:AllCard: ", p), err) + } + return err +} + +func (p *ResCardInfo) writeField8(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EndTime", thrift.I32, 8); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 8:EndTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.EndTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EndTime (8) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 8:EndTime: ", p), err) + } + return err +} + +func (p *ResCardInfo) writeField9(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ReqUid", thrift.LIST, 9); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 9:ReqUid: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I64, len(p.ReqUid)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.ReqUid { + if err := oprot.WriteI64(ctx, int64(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 9:ReqUid: ", p), err) + } + return err +} + +func (p *ResCardInfo) writeField10(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ExUid", thrift.LIST, 10); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 10:ExUid: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I64, len(p.ExUid)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.ExUid { + if err := oprot.WriteI64(ctx, int64(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 10:ExUid: ", p), err) + } + return err +} + +func (p *ResCardInfo) writeField11(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "GoldTimes", thrift.I32, 11); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 11:GoldTimes: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.GoldTimes)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.GoldTimes (11) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 11:GoldTimes: ", p), err) + } + return err +} + +func (p *ResCardInfo) writeField12(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Round", thrift.I32, 12); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 12:Round: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Round)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Round (12) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 12:Round: ", p), err) + } + return err +} + +func (p *ResCardInfo) writeField13(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Handbook", thrift.MAP, 13); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 13:Handbook: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.Handbook)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Handbook { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 13:Handbook: ", p), err) + } + return err +} + +func (p *ResCardInfo) writeField14(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "SeasonFirst", thrift.BOOL, 14); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 14:SeasonFirst: ", p), err) + } + if err := oprot.WriteBool(ctx, bool(p.SeasonFirst)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.SeasonFirst (14) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 14:SeasonFirst: ", p), err) + } + return err +} + +func (p *ResCardInfo) Equals(other *ResCardInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.CardList) != len(other.CardList) { + return false + } + for i, _tgt := range p.CardList { + _src169 := other.CardList[i] + if !_tgt.Equals(_src169) { + return false + } + } + if p.ExStar != other.ExStar { + return false + } + if p.Status != other.Status { + return false + } + if len(p.CollectId) != len(other.CollectId) { + return false + } + for i, _tgt := range p.CollectId { + _src170 := other.CollectId[i] + if _tgt != _src170 { + return false + } + } + if p.ExTimes != other.ExTimes { + return false + } + if p.ReqTimes != other.ReqTimes { + return false + } + if len(p.AllCard) != len(other.AllCard) { + return false + } + for k, _tgt := range p.AllCard { + _src171 := other.AllCard[k] + if _tgt != _src171 { + return false + } + } + if p.EndTime != other.EndTime { + return false + } + if len(p.ReqUid) != len(other.ReqUid) { + return false + } + for i, _tgt := range p.ReqUid { + _src172 := other.ReqUid[i] + if _tgt != _src172 { + return false + } + } + if len(p.ExUid) != len(other.ExUid) { + return false + } + for i, _tgt := range p.ExUid { + _src173 := other.ExUid[i] + if _tgt != _src173 { + return false + } + } + if p.GoldTimes != other.GoldTimes { + return false + } + if p.Round != other.Round { + return false + } + if len(p.Handbook) != len(other.Handbook) { + return false + } + for k, _tgt := range p.Handbook { + _src174 := other.Handbook[k] + if _tgt != _src174 { + return false + } + } + if p.SeasonFirst != other.SeasonFirst { + return false + } + return true +} + +func (p *ResCardInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResCardInfo(%+v)", *p) +} + +func (p *ResCardInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResCardInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResCardInfo)(nil) + +func (p *ResCardInfo) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResCardSeasonFirstReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResCardSeasonFirstReward() *ResCardSeasonFirstReward { + return &ResCardSeasonFirstReward{} +} + +func (p *ResCardSeasonFirstReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResCardSeasonFirstReward) GetMsg() string { + return p.Msg +} + +func (p *ResCardSeasonFirstReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResCardSeasonFirstReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResCardSeasonFirstReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResCardSeasonFirstReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResCardSeasonFirstReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResCardSeasonFirstReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResCardSeasonFirstReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResCardSeasonFirstReward) Equals(other *ResCardSeasonFirstReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResCardSeasonFirstReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResCardSeasonFirstReward(%+v)", *p) +} + +func (p *ResCardSeasonFirstReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResCardSeasonFirstReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResCardSeasonFirstReward)(nil) + +func (p *ResCardSeasonFirstReward) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResCardSend struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResCardSend() *ResCardSend { + return &ResCardSend{} +} + +func (p *ResCardSend) GetCode() RES_CODE { + return p.Code +} + +func (p *ResCardSend) GetMsg() string { + return p.Msg +} + +func (p *ResCardSend) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResCardSend) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResCardSend) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResCardSend) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResCardSend"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResCardSend) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResCardSend) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResCardSend) Equals(other *ResCardSend) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResCardSend) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResCardSend(%+v)", *p) +} + +func (p *ResCardSend) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResCardSend", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResCardSend)(nil) + +func (p *ResCardSend) Validate() error { + return nil +} + +// Attributes: +// - Id +// - StartTime +// - EndTime +// - Score +// - Reward +// - Cfg +// +type ResCatReturnGift struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + StartTime int64 `thrift:"StartTime,2" db:"StartTime" json:"StartTime"` + EndTime int64 `thrift:"EndTime,3" db:"EndTime" json:"EndTime"` + Score int32 `thrift:"Score,4" db:"Score" json:"Score"` + Reward int32 `thrift:"Reward,5" db:"Reward" json:"Reward"` + Cfg *CatReturnGiftCfg `thrift:"Cfg,6" db:"Cfg" json:"Cfg"` +} + +func NewResCatReturnGift() *ResCatReturnGift { + return &ResCatReturnGift{} +} + +func (p *ResCatReturnGift) GetId() int32 { + return p.Id +} + +func (p *ResCatReturnGift) GetStartTime() int64 { + return p.StartTime +} + +func (p *ResCatReturnGift) GetEndTime() int64 { + return p.EndTime +} + +func (p *ResCatReturnGift) GetScore() int32 { + return p.Score +} + +func (p *ResCatReturnGift) GetReward() int32 { + return p.Reward +} + +var ResCatReturnGift_Cfg_DEFAULT *CatReturnGiftCfg + +func (p *ResCatReturnGift) GetCfg() *CatReturnGiftCfg { + if !p.IsSetCfg() { + return ResCatReturnGift_Cfg_DEFAULT + } + return p.Cfg +} + +func (p *ResCatReturnGift) IsSetCfg() bool { + return p.Cfg != nil +} + +func (p *ResCatReturnGift) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I64 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I64 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResCatReturnGift) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResCatReturnGift) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.StartTime = v + } + return nil +} + +func (p *ResCatReturnGift) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.EndTime = v + } + return nil +} + +func (p *ResCatReturnGift) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Score = v + } + return nil +} + +func (p *ResCatReturnGift) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.Reward = v + } + return nil +} + +func (p *ResCatReturnGift) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + p.Cfg = &CatReturnGiftCfg{} + if err := p.Cfg.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.Cfg), err) + } + return nil +} + +func (p *ResCatReturnGift) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResCatReturnGift"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResCatReturnGift) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ResCatReturnGift) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "StartTime", thrift.I64, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:StartTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.StartTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.StartTime (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:StartTime: ", p), err) + } + return err +} + +func (p *ResCatReturnGift) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EndTime", thrift.I64, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:EndTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.EndTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EndTime (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:EndTime: ", p), err) + } + return err +} + +func (p *ResCatReturnGift) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Score", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Score: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Score)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Score (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Score: ", p), err) + } + return err +} + +func (p *ResCatReturnGift) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Reward", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Reward: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Reward)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Reward (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Reward: ", p), err) + } + return err +} + +func (p *ResCatReturnGift) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Cfg", thrift.STRUCT, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:Cfg: ", p), err) + } + if err := p.Cfg.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.Cfg), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:Cfg: ", p), err) + } + return err +} + +func (p *ResCatReturnGift) Equals(other *ResCatReturnGift) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.StartTime != other.StartTime { + return false + } + if p.EndTime != other.EndTime { + return false + } + if p.Score != other.Score { + return false + } + if p.Reward != other.Reward { + return false + } + if !p.Cfg.Equals(other.Cfg) { + return false + } + return true +} + +func (p *ResCatReturnGift) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResCatReturnGift(%+v)", *p) +} + +func (p *ResCatReturnGift) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResCatReturnGift", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResCatReturnGift)(nil) + +func (p *ResCatReturnGift) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResCatReturnGiftReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResCatReturnGiftReward() *ResCatReturnGiftReward { + return &ResCatReturnGiftReward{} +} + +func (p *ResCatReturnGiftReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResCatReturnGiftReward) GetMsg() string { + return p.Msg +} + +func (p *ResCatReturnGiftReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResCatReturnGiftReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResCatReturnGiftReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResCatReturnGiftReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResCatReturnGiftReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResCatReturnGiftReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResCatReturnGiftReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResCatReturnGiftReward) Equals(other *ResCatReturnGiftReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResCatReturnGiftReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResCatReturnGiftReward(%+v)", *p) +} + +func (p *ResCatReturnGiftReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResCatReturnGiftReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResCatReturnGiftReward)(nil) + +func (p *ResCatReturnGiftReward) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResCatReturnGiftRewardGift struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResCatReturnGiftRewardGift() *ResCatReturnGiftRewardGift { + return &ResCatReturnGiftRewardGift{} +} + +func (p *ResCatReturnGiftRewardGift) GetCode() RES_CODE { + return p.Code +} + +func (p *ResCatReturnGiftRewardGift) GetMsg() string { + return p.Msg +} + +func (p *ResCatReturnGiftRewardGift) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResCatReturnGiftRewardGift) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResCatReturnGiftRewardGift) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResCatReturnGiftRewardGift) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResCatReturnGiftRewardGift"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResCatReturnGiftRewardGift) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResCatReturnGiftRewardGift) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResCatReturnGiftRewardGift) Equals(other *ResCatReturnGiftRewardGift) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResCatReturnGiftRewardGift) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResCatReturnGiftRewardGift(%+v)", *p) +} + +func (p *ResCatReturnGiftRewardGift) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResCatReturnGiftRewardGift", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResCatReturnGiftRewardGift)(nil) + +func (p *ResCatReturnGiftRewardGift) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResCatReturnGiftScore struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResCatReturnGiftScore() *ResCatReturnGiftScore { + return &ResCatReturnGiftScore{} +} + +func (p *ResCatReturnGiftScore) GetCode() RES_CODE { + return p.Code +} + +func (p *ResCatReturnGiftScore) GetMsg() string { + return p.Msg +} + +func (p *ResCatReturnGiftScore) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResCatReturnGiftScore) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResCatReturnGiftScore) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResCatReturnGiftScore) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResCatReturnGiftScore"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResCatReturnGiftScore) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResCatReturnGiftScore) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResCatReturnGiftScore) Equals(other *ResCatReturnGiftScore) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResCatReturnGiftScore) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResCatReturnGiftScore(%+v)", *p) +} + +func (p *ResCatReturnGiftScore) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResCatReturnGiftScore", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResCatReturnGiftScore)(nil) + +func (p *ResCatReturnGiftScore) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - IsClose +// +type ResCatTrickReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + IsClose bool `thrift:"IsClose,3" db:"IsClose" json:"IsClose"` +} + +func NewResCatTrickReward() *ResCatTrickReward { + return &ResCatTrickReward{} +} + +func (p *ResCatTrickReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResCatTrickReward) GetMsg() string { + return p.Msg +} + +func (p *ResCatTrickReward) GetIsClose() bool { + return p.IsClose +} + +func (p *ResCatTrickReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.BOOL { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResCatTrickReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResCatTrickReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResCatTrickReward) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadBool(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.IsClose = v + } + return nil +} + +func (p *ResCatTrickReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResCatTrickReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResCatTrickReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResCatTrickReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResCatTrickReward) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "IsClose", thrift.BOOL, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:IsClose: ", p), err) + } + if err := oprot.WriteBool(ctx, bool(p.IsClose)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.IsClose (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:IsClose: ", p), err) + } + return err +} + +func (p *ResCatTrickReward) Equals(other *ResCatTrickReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.IsClose != other.IsClose { + return false + } + return true +} + +func (p *ResCatTrickReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResCatTrickReward(%+v)", *p) +} + +func (p *ResCatTrickReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResCatTrickReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResCatTrickReward)(nil) + +func (p *ResCatTrickReward) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Status +// - EndTime +// - Template +// - GameList +// - Multiply +// - FriendList +// +type ResCatnip struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Status int32 `thrift:"Status,2" db:"Status" json:"Status"` + EndTime int32 `thrift:"EndTime,3" db:"EndTime" json:"EndTime"` + Template int32 `thrift:"Template,4" db:"Template" json:"Template"` + GameList []*CatnipGame `thrift:"GameList,5" db:"GameList" json:"GameList"` + Multiply int32 `thrift:"Multiply,6" db:"Multiply" json:"Multiply"` + FriendList []*CatnipInvite `thrift:"FriendList,7" db:"FriendList" json:"FriendList"` +} + +func NewResCatnip() *ResCatnip { + return &ResCatnip{} +} + +func (p *ResCatnip) GetId() int32 { + return p.Id +} + +func (p *ResCatnip) GetStatus() int32 { + return p.Status +} + +func (p *ResCatnip) GetEndTime() int32 { + return p.EndTime +} + +func (p *ResCatnip) GetTemplate() int32 { + return p.Template +} + +func (p *ResCatnip) GetGameList() []*CatnipGame { + return p.GameList +} + +func (p *ResCatnip) GetMultiply() int32 { + return p.Multiply +} + +func (p *ResCatnip) GetFriendList() []*CatnipInvite { + return p.FriendList +} + +func (p *ResCatnip) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.LIST { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.I32 { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.LIST { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResCatnip) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResCatnip) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Status = v + } + return nil +} + +func (p *ResCatnip) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.EndTime = v + } + return nil +} + +func (p *ResCatnip) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Template = v + } + return nil +} + +func (p *ResCatnip) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*CatnipGame, 0, size) + p.GameList = tSlice + for i := 0; i < size; i++ { + _elem175 := &CatnipGame{} + if err := _elem175.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem175), err) + } + p.GameList = append(p.GameList, _elem175) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResCatnip) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 6: ", err) + } else { + p.Multiply = v + } + return nil +} + +func (p *ResCatnip) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*CatnipInvite, 0, size) + p.FriendList = tSlice + for i := 0; i < size; i++ { + _elem176 := &CatnipInvite{} + if err := _elem176.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem176), err) + } + p.FriendList = append(p.FriendList, _elem176) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResCatnip) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResCatnip"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResCatnip) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ResCatnip) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Status", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Status: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Status)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Status (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Status: ", p), err) + } + return err +} + +func (p *ResCatnip) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EndTime", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:EndTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.EndTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EndTime (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:EndTime: ", p), err) + } + return err +} + +func (p *ResCatnip) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Template", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Template: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Template)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Template (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Template: ", p), err) + } + return err +} + +func (p *ResCatnip) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "GameList", thrift.LIST, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:GameList: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.GameList)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.GameList { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:GameList: ", p), err) + } + return err +} + +func (p *ResCatnip) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Multiply", thrift.I32, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:Multiply: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Multiply)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Multiply (6) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:Multiply: ", p), err) + } + return err +} + +func (p *ResCatnip) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "FriendList", thrift.LIST, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:FriendList: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.FriendList)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.FriendList { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:FriendList: ", p), err) + } + return err +} + +func (p *ResCatnip) Equals(other *ResCatnip) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Status != other.Status { + return false + } + if p.EndTime != other.EndTime { + return false + } + if p.Template != other.Template { + return false + } + if len(p.GameList) != len(other.GameList) { + return false + } + for i, _tgt := range p.GameList { + _src177 := other.GameList[i] + if !_tgt.Equals(_src177) { + return false + } + } + if p.Multiply != other.Multiply { + return false + } + if len(p.FriendList) != len(other.FriendList) { + return false + } + for i, _tgt := range p.FriendList { + _src178 := other.FriendList[i] + if !_tgt.Equals(_src178) { + return false + } + } + return true +} + +func (p *ResCatnip) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResCatnip(%+v)", *p) +} + +func (p *ResCatnip) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResCatnip", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResCatnip)(nil) + +func (p *ResCatnip) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Uid +// +type ResCatnipAgree struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Uid int64 `thrift:"Uid,3" db:"Uid" json:"Uid"` +} + +func NewResCatnipAgree() *ResCatnipAgree { + return &ResCatnipAgree{} +} + +func (p *ResCatnipAgree) GetCode() RES_CODE { + return p.Code +} + +func (p *ResCatnipAgree) GetMsg() string { + return p.Msg +} + +func (p *ResCatnipAgree) GetUid() int64 { + return p.Uid +} + +func (p *ResCatnipAgree) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I64 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResCatnipAgree) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResCatnipAgree) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResCatnipAgree) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ResCatnipAgree) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResCatnipAgree"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResCatnipAgree) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResCatnipAgree) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResCatnipAgree) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Uid: ", p), err) + } + return err +} + +func (p *ResCatnipAgree) Equals(other *ResCatnipAgree) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Uid != other.Uid { + return false + } + return true +} + +func (p *ResCatnipAgree) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResCatnipAgree(%+v)", *p) +} + +func (p *ResCatnipAgree) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResCatnipAgree", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResCatnipAgree)(nil) + +func (p *ResCatnipAgree) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - EmojiId +// - Id +// +type ResCatnipEmoji struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + EmojiId int32 `thrift:"EmojiId,3" db:"EmojiId" json:"EmojiId"` + Id int32 `thrift:"Id,4" db:"Id" json:"Id"` +} + +func NewResCatnipEmoji() *ResCatnipEmoji { + return &ResCatnipEmoji{} +} + +func (p *ResCatnipEmoji) GetCode() RES_CODE { + return p.Code +} + +func (p *ResCatnipEmoji) GetMsg() string { + return p.Msg +} + +func (p *ResCatnipEmoji) GetEmojiId() int32 { + return p.EmojiId +} + +func (p *ResCatnipEmoji) GetId() int32 { + return p.Id +} + +func (p *ResCatnipEmoji) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResCatnipEmoji) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResCatnipEmoji) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResCatnipEmoji) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.EmojiId = v + } + return nil +} + +func (p *ResCatnipEmoji) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResCatnipEmoji) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResCatnipEmoji"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResCatnipEmoji) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResCatnipEmoji) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResCatnipEmoji) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EmojiId", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:EmojiId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.EmojiId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EmojiId (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:EmojiId: ", p), err) + } + return err +} + +func (p *ResCatnipEmoji) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Id: ", p), err) + } + return err +} + +func (p *ResCatnipEmoji) Equals(other *ResCatnipEmoji) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.EmojiId != other.EmojiId { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ResCatnipEmoji) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResCatnipEmoji(%+v)", *p) +} + +func (p *ResCatnipEmoji) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResCatnipEmoji", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResCatnipEmoji)(nil) + +func (p *ResCatnipEmoji) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResCatnipGrandReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResCatnipGrandReward() *ResCatnipGrandReward { + return &ResCatnipGrandReward{} +} + +func (p *ResCatnipGrandReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResCatnipGrandReward) GetMsg() string { + return p.Msg +} + +func (p *ResCatnipGrandReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResCatnipGrandReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResCatnipGrandReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResCatnipGrandReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResCatnipGrandReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResCatnipGrandReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResCatnipGrandReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResCatnipGrandReward) Equals(other *ResCatnipGrandReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResCatnipGrandReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResCatnipGrandReward(%+v)", *p) +} + +func (p *ResCatnipGrandReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResCatnipGrandReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResCatnipGrandReward)(nil) + +func (p *ResCatnipGrandReward) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Uid +// +type ResCatnipInvite struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Uid int64 `thrift:"Uid,3" db:"Uid" json:"Uid"` +} + +func NewResCatnipInvite() *ResCatnipInvite { + return &ResCatnipInvite{} +} + +func (p *ResCatnipInvite) GetCode() RES_CODE { + return p.Code +} + +func (p *ResCatnipInvite) GetMsg() string { + return p.Msg +} + +func (p *ResCatnipInvite) GetUid() int64 { + return p.Uid +} + +func (p *ResCatnipInvite) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I64 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResCatnipInvite) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResCatnipInvite) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResCatnipInvite) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ResCatnipInvite) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResCatnipInvite"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResCatnipInvite) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResCatnipInvite) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResCatnipInvite) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Uid: ", p), err) + } + return err +} + +func (p *ResCatnipInvite) Equals(other *ResCatnipInvite) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Uid != other.Uid { + return false + } + return true +} + +func (p *ResCatnipInvite) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResCatnipInvite(%+v)", *p) +} + +func (p *ResCatnipInvite) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResCatnipInvite", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResCatnipInvite)(nil) + +func (p *ResCatnipInvite) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Multiply +// +type ResCatnipMultiply struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Multiply int32 `thrift:"Multiply,3" db:"Multiply" json:"Multiply"` +} + +func NewResCatnipMultiply() *ResCatnipMultiply { + return &ResCatnipMultiply{} +} + +func (p *ResCatnipMultiply) GetCode() RES_CODE { + return p.Code +} + +func (p *ResCatnipMultiply) GetMsg() string { + return p.Msg +} + +func (p *ResCatnipMultiply) GetMultiply() int32 { + return p.Multiply +} + +func (p *ResCatnipMultiply) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResCatnipMultiply) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResCatnipMultiply) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResCatnipMultiply) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Multiply = v + } + return nil +} + +func (p *ResCatnipMultiply) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResCatnipMultiply"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResCatnipMultiply) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResCatnipMultiply) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResCatnipMultiply) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Multiply", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Multiply: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Multiply)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Multiply (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Multiply: ", p), err) + } + return err +} + +func (p *ResCatnipMultiply) Equals(other *ResCatnipMultiply) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Multiply != other.Multiply { + return false + } + return true +} + +func (p *ResCatnipMultiply) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResCatnipMultiply(%+v)", *p) +} + +func (p *ResCatnipMultiply) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResCatnipMultiply", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResCatnipMultiply)(nil) + +func (p *ResCatnipMultiply) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Id +// +type ResCatnipPlay struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Id int32 `thrift:"Id,3" db:"Id" json:"Id"` +} + +func NewResCatnipPlay() *ResCatnipPlay { + return &ResCatnipPlay{} +} + +func (p *ResCatnipPlay) GetCode() RES_CODE { + return p.Code +} + +func (p *ResCatnipPlay) GetMsg() string { + return p.Msg +} + +func (p *ResCatnipPlay) GetId() int32 { + return p.Id +} + +func (p *ResCatnipPlay) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResCatnipPlay) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResCatnipPlay) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResCatnipPlay) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResCatnipPlay) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResCatnipPlay"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResCatnipPlay) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResCatnipPlay) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResCatnipPlay) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Id: ", p), err) + } + return err +} + +func (p *ResCatnipPlay) Equals(other *ResCatnipPlay) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ResCatnipPlay) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResCatnipPlay(%+v)", *p) +} + +func (p *ResCatnipPlay) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResCatnipPlay", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResCatnipPlay)(nil) + +func (p *ResCatnipPlay) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Uid +// +type ResCatnipRefuse struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Uid int64 `thrift:"Uid,3" db:"Uid" json:"Uid"` +} + +func NewResCatnipRefuse() *ResCatnipRefuse { + return &ResCatnipRefuse{} +} + +func (p *ResCatnipRefuse) GetCode() RES_CODE { + return p.Code +} + +func (p *ResCatnipRefuse) GetMsg() string { + return p.Msg +} + +func (p *ResCatnipRefuse) GetUid() int64 { + return p.Uid +} + +func (p *ResCatnipRefuse) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I64 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResCatnipRefuse) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResCatnipRefuse) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResCatnipRefuse) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ResCatnipRefuse) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResCatnipRefuse"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResCatnipRefuse) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResCatnipRefuse) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResCatnipRefuse) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Uid: ", p), err) + } + return err +} + +func (p *ResCatnipRefuse) Equals(other *ResCatnipRefuse) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Uid != other.Uid { + return false + } + return true +} + +func (p *ResCatnipRefuse) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResCatnipRefuse(%+v)", *p) +} + +func (p *ResCatnipRefuse) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResCatnipRefuse", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResCatnipRefuse)(nil) + +func (p *ResCatnipRefuse) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResCatnipReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResCatnipReward() *ResCatnipReward { + return &ResCatnipReward{} +} + +func (p *ResCatnipReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResCatnipReward) GetMsg() string { + return p.Msg +} + +func (p *ResCatnipReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResCatnipReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResCatnipReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResCatnipReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResCatnipReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResCatnipReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResCatnipReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResCatnipReward) Equals(other *ResCatnipReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResCatnipReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResCatnipReward(%+v)", *p) +} + +func (p *ResCatnipReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResCatnipReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResCatnipReward)(nil) + +func (p *ResCatnipReward) Validate() error { + return nil +} + +// Attributes: +// - Score +// - Reward +// - EndTime +// - Period +// - Rank +// - RankReward +// - Status +// - TodayActivityId +// - YesterdayActivityId +// - Cfg +// +type ResChampship struct { + Score int32 `thrift:"Score,1" db:"Score" json:"Score"` + Reward int32 `thrift:"Reward,2" db:"Reward" json:"Reward"` + EndTime int32 `thrift:"EndTime,3" db:"EndTime" json:"EndTime"` + Period int32 `thrift:"Period,4" db:"Period" json:"Period"` + Rank int32 `thrift:"Rank,5" db:"Rank" json:"Rank"` + RankReward int32 `thrift:"RankReward,6" db:"RankReward" json:"RankReward"` + Status int32 `thrift:"Status,7" db:"Status" json:"Status"` + TodayActivityId int32 `thrift:"TodayActivityId,8" db:"TodayActivityId" json:"TodayActivityId"` + YesterdayActivityId int32 `thrift:"YesterdayActivityId,9" db:"YesterdayActivityId" json:"YesterdayActivityId"` + Cfg *ChampionshipCfg `thrift:"Cfg,10" db:"Cfg" json:"Cfg"` +} + +func NewResChampship() *ResChampship { + return &ResChampship{} +} + +func (p *ResChampship) GetScore() int32 { + return p.Score +} + +func (p *ResChampship) GetReward() int32 { + return p.Reward +} + +func (p *ResChampship) GetEndTime() int32 { + return p.EndTime +} + +func (p *ResChampship) GetPeriod() int32 { + return p.Period +} + +func (p *ResChampship) GetRank() int32 { + return p.Rank +} + +func (p *ResChampship) GetRankReward() int32 { + return p.RankReward +} + +func (p *ResChampship) GetStatus() int32 { + return p.Status +} + +func (p *ResChampship) GetTodayActivityId() int32 { + return p.TodayActivityId +} + +func (p *ResChampship) GetYesterdayActivityId() int32 { + return p.YesterdayActivityId +} + +var ResChampship_Cfg_DEFAULT *ChampionshipCfg + +func (p *ResChampship) GetCfg() *ChampionshipCfg { + if !p.IsSetCfg() { + return ResChampship_Cfg_DEFAULT + } + return p.Cfg +} + +func (p *ResChampship) IsSetCfg() bool { + return p.Cfg != nil +} + +func (p *ResChampship) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.I32 { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.I32 { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 8: + if fieldTypeId == thrift.I32 { + if err := p.ReadField8(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 9: + if fieldTypeId == thrift.I32 { + if err := p.ReadField9(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 10: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField10(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResChampship) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Score = v + } + return nil +} + +func (p *ResChampship) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Reward = v + } + return nil +} + +func (p *ResChampship) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.EndTime = v + } + return nil +} + +func (p *ResChampship) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Period = v + } + return nil +} + +func (p *ResChampship) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.Rank = v + } + return nil +} + +func (p *ResChampship) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 6: ", err) + } else { + p.RankReward = v + } + return nil +} + +func (p *ResChampship) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 7: ", err) + } else { + p.Status = v + } + return nil +} + +func (p *ResChampship) ReadField8(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 8: ", err) + } else { + p.TodayActivityId = v + } + return nil +} + +func (p *ResChampship) ReadField9(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 9: ", err) + } else { + p.YesterdayActivityId = v + } + return nil +} + +func (p *ResChampship) ReadField10(ctx context.Context, iprot thrift.TProtocol) error { + p.Cfg = &ChampionshipCfg{} + if err := p.Cfg.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.Cfg), err) + } + return nil +} + +func (p *ResChampship) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResChampship"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + if err := p.writeField8(ctx, oprot); err != nil { + return err + } + if err := p.writeField9(ctx, oprot); err != nil { + return err + } + if err := p.writeField10(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResChampship) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Score", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Score: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Score)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Score (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Score: ", p), err) + } + return err +} + +func (p *ResChampship) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Reward", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Reward: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Reward)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Reward (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Reward: ", p), err) + } + return err +} + +func (p *ResChampship) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EndTime", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:EndTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.EndTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EndTime (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:EndTime: ", p), err) + } + return err +} + +func (p *ResChampship) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Period", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Period: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Period)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Period (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Period: ", p), err) + } + return err +} + +func (p *ResChampship) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Rank", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Rank: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Rank)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Rank (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Rank: ", p), err) + } + return err +} + +func (p *ResChampship) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "RankReward", thrift.I32, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:RankReward: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.RankReward)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.RankReward (6) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:RankReward: ", p), err) + } + return err +} + +func (p *ResChampship) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Status", thrift.I32, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:Status: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Status)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Status (7) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:Status: ", p), err) + } + return err +} + +func (p *ResChampship) writeField8(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "TodayActivityId", thrift.I32, 8); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 8:TodayActivityId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.TodayActivityId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.TodayActivityId (8) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 8:TodayActivityId: ", p), err) + } + return err +} + +func (p *ResChampship) writeField9(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "YesterdayActivityId", thrift.I32, 9); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 9:YesterdayActivityId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.YesterdayActivityId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.YesterdayActivityId (9) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 9:YesterdayActivityId: ", p), err) + } + return err +} + +func (p *ResChampship) writeField10(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Cfg", thrift.STRUCT, 10); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 10:Cfg: ", p), err) + } + if err := p.Cfg.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.Cfg), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 10:Cfg: ", p), err) + } + return err +} + +func (p *ResChampship) Equals(other *ResChampship) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Score != other.Score { + return false + } + if p.Reward != other.Reward { + return false + } + if p.EndTime != other.EndTime { + return false + } + if p.Period != other.Period { + return false + } + if p.Rank != other.Rank { + return false + } + if p.RankReward != other.RankReward { + return false + } + if p.Status != other.Status { + return false + } + if p.TodayActivityId != other.TodayActivityId { + return false + } + if p.YesterdayActivityId != other.YesterdayActivityId { + return false + } + if !p.Cfg.Equals(other.Cfg) { + return false + } + return true +} + +func (p *ResChampship) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResChampship(%+v)", *p) +} + +func (p *ResChampship) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResChampship", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResChampship)(nil) + +func (p *ResChampship) Validate() error { + return nil +} + +// Attributes: +// - RankList +// - MyRank +// - MyScore +// +type ResChampshipPreRank struct { + RankList map[int32]*ResPlayerRank `thrift:"RankList,1" db:"RankList" json:"RankList"` + MyRank int32 `thrift:"MyRank,2" db:"MyRank" json:"MyRank"` + MyScore float64 `thrift:"MyScore,3" db:"MyScore" json:"MyScore"` +} + +func NewResChampshipPreRank() *ResChampshipPreRank { + return &ResChampshipPreRank{} +} + +func (p *ResChampshipPreRank) GetRankList() map[int32]*ResPlayerRank { + return p.RankList +} + +func (p *ResChampshipPreRank) GetMyRank() int32 { + return p.MyRank +} + +func (p *ResChampshipPreRank) GetMyScore() float64 { + return p.MyScore +} + +func (p *ResChampshipPreRank) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.MAP { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.DOUBLE { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResChampshipPreRank) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]*ResPlayerRank, size) + p.RankList = tMap + for i := 0; i < size; i++ { + var _key179 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key179 = v + } + _val180 := &ResPlayerRank{} + if err := _val180.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _val180), err) + } + p.RankList[_key179] = _val180 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResChampshipPreRank) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.MyRank = v + } + return nil +} + +func (p *ResChampshipPreRank) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadDouble(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.MyScore = v + } + return nil +} + +func (p *ResChampshipPreRank) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResChampshipPreRank"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResChampshipPreRank) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "RankList", thrift.MAP, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:RankList: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.STRUCT, len(p.RankList)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.RankList { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:RankList: ", p), err) + } + return err +} + +func (p *ResChampshipPreRank) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MyRank", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:MyRank: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.MyRank)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.MyRank (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:MyRank: ", p), err) + } + return err +} + +func (p *ResChampshipPreRank) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MyScore", thrift.DOUBLE, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:MyScore: ", p), err) + } + if err := oprot.WriteDouble(ctx, float64(p.MyScore)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.MyScore (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:MyScore: ", p), err) + } + return err +} + +func (p *ResChampshipPreRank) Equals(other *ResChampshipPreRank) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.RankList) != len(other.RankList) { + return false + } + for k, _tgt := range p.RankList { + _src181 := other.RankList[k] + if !_tgt.Equals(_src181) { + return false + } + } + if p.MyRank != other.MyRank { + return false + } + if p.MyScore != other.MyScore { + return false + } + return true +} + +func (p *ResChampshipPreRank) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResChampshipPreRank(%+v)", *p) +} + +func (p *ResChampshipPreRank) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResChampshipPreRank", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResChampshipPreRank)(nil) + +func (p *ResChampshipPreRank) Validate() error { + return nil +} + +// Attributes: +// - RankList +// - MyRank +// - MyScore +// +type ResChampshipRank struct { + RankList map[int32]*ResPlayerRank `thrift:"RankList,1" db:"RankList" json:"RankList"` + MyRank int32 `thrift:"MyRank,2" db:"MyRank" json:"MyRank"` + MyScore float64 `thrift:"MyScore,3" db:"MyScore" json:"MyScore"` +} + +func NewResChampshipRank() *ResChampshipRank { + return &ResChampshipRank{} +} + +func (p *ResChampshipRank) GetRankList() map[int32]*ResPlayerRank { + return p.RankList +} + +func (p *ResChampshipRank) GetMyRank() int32 { + return p.MyRank +} + +func (p *ResChampshipRank) GetMyScore() float64 { + return p.MyScore +} + +func (p *ResChampshipRank) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.MAP { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.DOUBLE { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResChampshipRank) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]*ResPlayerRank, size) + p.RankList = tMap + for i := 0; i < size; i++ { + var _key182 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key182 = v + } + _val183 := &ResPlayerRank{} + if err := _val183.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _val183), err) + } + p.RankList[_key182] = _val183 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResChampshipRank) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.MyRank = v + } + return nil +} + +func (p *ResChampshipRank) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadDouble(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.MyScore = v + } + return nil +} + +func (p *ResChampshipRank) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResChampshipRank"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResChampshipRank) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "RankList", thrift.MAP, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:RankList: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.STRUCT, len(p.RankList)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.RankList { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:RankList: ", p), err) + } + return err +} + +func (p *ResChampshipRank) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MyRank", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:MyRank: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.MyRank)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.MyRank (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:MyRank: ", p), err) + } + return err +} + +func (p *ResChampshipRank) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MyScore", thrift.DOUBLE, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:MyScore: ", p), err) + } + if err := oprot.WriteDouble(ctx, float64(p.MyScore)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.MyScore (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:MyScore: ", p), err) + } + return err +} + +func (p *ResChampshipRank) Equals(other *ResChampshipRank) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.RankList) != len(other.RankList) { + return false + } + for k, _tgt := range p.RankList { + _src184 := other.RankList[k] + if !_tgt.Equals(_src184) { + return false + } + } + if p.MyRank != other.MyRank { + return false + } + if p.MyScore != other.MyScore { + return false + } + return true +} + +func (p *ResChampshipRank) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResChampshipRank(%+v)", *p) +} + +func (p *ResChampshipRank) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResChampshipRank", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResChampshipRank)(nil) + +func (p *ResChampshipRank) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResChampshipRankReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResChampshipRankReward() *ResChampshipRankReward { + return &ResChampshipRankReward{} +} + +func (p *ResChampshipRankReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResChampshipRankReward) GetMsg() string { + return p.Msg +} + +func (p *ResChampshipRankReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResChampshipRankReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResChampshipRankReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResChampshipRankReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResChampshipRankReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResChampshipRankReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResChampshipRankReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResChampshipRankReward) Equals(other *ResChampshipRankReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResChampshipRankReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResChampshipRankReward(%+v)", *p) +} + +func (p *ResChampshipRankReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResChampshipRankReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResChampshipRankReward)(nil) + +func (p *ResChampshipRankReward) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResChampshipReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResChampshipReward() *ResChampshipReward { + return &ResChampshipReward{} +} + +func (p *ResChampshipReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResChampshipReward) GetMsg() string { + return p.Msg +} + +func (p *ResChampshipReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResChampshipReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResChampshipReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResChampshipReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResChampshipReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResChampshipReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResChampshipReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResChampshipReward) Equals(other *ResChampshipReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResChampshipReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResChampshipReward(%+v)", *p) +} + +func (p *ResChampshipReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResChampshipReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResChampshipReward)(nil) + +func (p *ResChampshipReward) Validate() error { + return nil +} + +// Attributes: +// - ResultCode +// +type ResChangePassword struct { + ResultCode int32 `thrift:"ResultCode,1" db:"ResultCode" json:"ResultCode"` +} + +func NewResChangePassword() *ResChangePassword { + return &ResChangePassword{} +} + +func (p *ResChangePassword) GetResultCode() int32 { + return p.ResultCode +} + +func (p *ResChangePassword) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResChangePassword) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.ResultCode = v + } + return nil +} + +func (p *ResChangePassword) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResChangePassword"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResChangePassword) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ResultCode", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ResultCode: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ResultCode)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ResultCode (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ResultCode: ", p), err) + } + return err +} + +func (p *ResChangePassword) Equals(other *ResChangePassword) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ResultCode != other.ResultCode { + return false + } + return true +} + +func (p *ResChangePassword) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResChangePassword(%+v)", *p) +} + +func (p *ResChangePassword) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResChangePassword", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResChangePassword)(nil) + +func (p *ResChangePassword) Validate() error { + return nil +} + +// Attributes: +// - Charge +// - Total +// - First +// - SpecialShop +// - FreeShop +// - ChessShop +// - Gift +// - Ad +// - Wish +// - SpecialCharge +// - SpecialChargeWeek +// - TodayCharge +// - MonthCharge +// - AdEndTime +// - WeeklyDiscount +// - PetWorkRemainTime +// - WeeklyEndTime +// +type ResCharge struct { + Charge float64 `thrift:"Charge,1" db:"Charge" json:"Charge"` + Total int32 `thrift:"Total,2" db:"Total" json:"Total"` + First []int32 `thrift:"First,3" db:"First" json:"First"` + SpecialShop map[int32]*ResSpecialShop `thrift:"SpecialShop,4" db:"SpecialShop" json:"SpecialShop"` + FreeShop int32 `thrift:"FreeShop,5" db:"FreeShop" json:"FreeShop"` + ChessShop map[int32]*ResChessShop `thrift:"ChessShop,6" db:"ChessShop" json:"ChessShop"` + Gift map[int32]int32 `thrift:"Gift,7" db:"Gift" json:"Gift"` + Ad bool `thrift:"Ad,8" db:"Ad" json:"Ad"` + Wish *WishList `thrift:"Wish,9" db:"Wish" json:"Wish"` + SpecialCharge float64 `thrift:"SpecialCharge,10" db:"SpecialCharge" json:"SpecialCharge"` + SpecialChargeWeek int32 `thrift:"SpecialChargeWeek,11" db:"SpecialChargeWeek" json:"SpecialChargeWeek"` + TodayCharge float64 `thrift:"TodayCharge,12" db:"TodayCharge" json:"TodayCharge"` + MonthCharge float64 `thrift:"MonthCharge,13" db:"MonthCharge" json:"MonthCharge"` + AdEndTime int64 `thrift:"AdEndTime,14" db:"AdEndTime" json:"AdEndTime"` + WeeklyDiscount map[int32]*WeeklyDiscountInfo `thrift:"WeeklyDiscount,15" db:"WeeklyDiscount" json:"WeeklyDiscount"` + PetWorkRemainTime int64 `thrift:"PetWorkRemainTime,16" db:"PetWorkRemainTime" json:"PetWorkRemainTime"` + WeeklyEndTime int64 `thrift:"WeeklyEndTime,17" db:"WeeklyEndTime" json:"WeeklyEndTime"` +} + +func NewResCharge() *ResCharge { + return &ResCharge{} +} + +func (p *ResCharge) GetCharge() float64 { + return p.Charge +} + +func (p *ResCharge) GetTotal() int32 { + return p.Total +} + +func (p *ResCharge) GetFirst() []int32 { + return p.First +} + +func (p *ResCharge) GetSpecialShop() map[int32]*ResSpecialShop { + return p.SpecialShop +} + +func (p *ResCharge) GetFreeShop() int32 { + return p.FreeShop +} + +func (p *ResCharge) GetChessShop() map[int32]*ResChessShop { + return p.ChessShop +} + +func (p *ResCharge) GetGift() map[int32]int32 { + return p.Gift +} + +func (p *ResCharge) GetAd() bool { + return p.Ad +} + +var ResCharge_Wish_DEFAULT *WishList + +func (p *ResCharge) GetWish() *WishList { + if !p.IsSetWish() { + return ResCharge_Wish_DEFAULT + } + return p.Wish +} + +func (p *ResCharge) GetSpecialCharge() float64 { + return p.SpecialCharge +} + +func (p *ResCharge) GetSpecialChargeWeek() int32 { + return p.SpecialChargeWeek +} + +func (p *ResCharge) GetTodayCharge() float64 { + return p.TodayCharge +} + +func (p *ResCharge) GetMonthCharge() float64 { + return p.MonthCharge +} + +func (p *ResCharge) GetAdEndTime() int64 { + return p.AdEndTime +} + +func (p *ResCharge) GetWeeklyDiscount() map[int32]*WeeklyDiscountInfo { + return p.WeeklyDiscount +} + +func (p *ResCharge) GetPetWorkRemainTime() int64 { + return p.PetWorkRemainTime +} + +func (p *ResCharge) GetWeeklyEndTime() int64 { + return p.WeeklyEndTime +} + +func (p *ResCharge) IsSetWish() bool { + return p.Wish != nil +} + +func (p *ResCharge) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.DOUBLE { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.LIST { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.MAP { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.MAP { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.MAP { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 8: + if fieldTypeId == thrift.BOOL { + if err := p.ReadField8(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 9: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField9(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 10: + if fieldTypeId == thrift.DOUBLE { + if err := p.ReadField10(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 11: + if fieldTypeId == thrift.I32 { + if err := p.ReadField11(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 12: + if fieldTypeId == thrift.DOUBLE { + if err := p.ReadField12(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 13: + if fieldTypeId == thrift.DOUBLE { + if err := p.ReadField13(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 14: + if fieldTypeId == thrift.I64 { + if err := p.ReadField14(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 15: + if fieldTypeId == thrift.MAP { + if err := p.ReadField15(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 16: + if fieldTypeId == thrift.I64 { + if err := p.ReadField16(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 17: + if fieldTypeId == thrift.I64 { + if err := p.ReadField17(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResCharge) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadDouble(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Charge = v + } + return nil +} + +func (p *ResCharge) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Total = v + } + return nil +} + +func (p *ResCharge) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.First = tSlice + for i := 0; i < size; i++ { + var _elem185 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem185 = v + } + p.First = append(p.First, _elem185) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResCharge) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]*ResSpecialShop, size) + p.SpecialShop = tMap + for i := 0; i < size; i++ { + var _key186 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key186 = v + } + _val187 := &ResSpecialShop{} + if err := _val187.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _val187), err) + } + p.SpecialShop[_key186] = _val187 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResCharge) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.FreeShop = v + } + return nil +} + +func (p *ResCharge) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]*ResChessShop, size) + p.ChessShop = tMap + for i := 0; i < size; i++ { + var _key188 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key188 = v + } + _val189 := &ResChessShop{} + if err := _val189.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _val189), err) + } + p.ChessShop[_key188] = _val189 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResCharge) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.Gift = tMap + for i := 0; i < size; i++ { + var _key190 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key190 = v + } + var _val191 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val191 = v + } + p.Gift[_key190] = _val191 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResCharge) ReadField8(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadBool(ctx); err != nil { + return thrift.PrependError("error reading field 8: ", err) + } else { + p.Ad = v + } + return nil +} + +func (p *ResCharge) ReadField9(ctx context.Context, iprot thrift.TProtocol) error { + p.Wish = &WishList{} + if err := p.Wish.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.Wish), err) + } + return nil +} + +func (p *ResCharge) ReadField10(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadDouble(ctx); err != nil { + return thrift.PrependError("error reading field 10: ", err) + } else { + p.SpecialCharge = v + } + return nil +} + +func (p *ResCharge) ReadField11(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 11: ", err) + } else { + p.SpecialChargeWeek = v + } + return nil +} + +func (p *ResCharge) ReadField12(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadDouble(ctx); err != nil { + return thrift.PrependError("error reading field 12: ", err) + } else { + p.TodayCharge = v + } + return nil +} + +func (p *ResCharge) ReadField13(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadDouble(ctx); err != nil { + return thrift.PrependError("error reading field 13: ", err) + } else { + p.MonthCharge = v + } + return nil +} + +func (p *ResCharge) ReadField14(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 14: ", err) + } else { + p.AdEndTime = v + } + return nil +} + +func (p *ResCharge) ReadField15(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]*WeeklyDiscountInfo, size) + p.WeeklyDiscount = tMap + for i := 0; i < size; i++ { + var _key192 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key192 = v + } + _val193 := &WeeklyDiscountInfo{} + if err := _val193.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _val193), err) + } + p.WeeklyDiscount[_key192] = _val193 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResCharge) ReadField16(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 16: ", err) + } else { + p.PetWorkRemainTime = v + } + return nil +} + +func (p *ResCharge) ReadField17(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 17: ", err) + } else { + p.WeeklyEndTime = v + } + return nil +} + +func (p *ResCharge) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResCharge"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + if err := p.writeField8(ctx, oprot); err != nil { + return err + } + if err := p.writeField9(ctx, oprot); err != nil { + return err + } + if err := p.writeField10(ctx, oprot); err != nil { + return err + } + if err := p.writeField11(ctx, oprot); err != nil { + return err + } + if err := p.writeField12(ctx, oprot); err != nil { + return err + } + if err := p.writeField13(ctx, oprot); err != nil { + return err + } + if err := p.writeField14(ctx, oprot); err != nil { + return err + } + if err := p.writeField15(ctx, oprot); err != nil { + return err + } + if err := p.writeField16(ctx, oprot); err != nil { + return err + } + if err := p.writeField17(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResCharge) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Charge", thrift.DOUBLE, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Charge: ", p), err) + } + if err := oprot.WriteDouble(ctx, float64(p.Charge)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Charge (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Charge: ", p), err) + } + return err +} + +func (p *ResCharge) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Total", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Total: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Total)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Total (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Total: ", p), err) + } + return err +} + +func (p *ResCharge) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "First", thrift.LIST, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:First: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.First)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.First { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:First: ", p), err) + } + return err +} + +func (p *ResCharge) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "SpecialShop", thrift.MAP, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:SpecialShop: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.STRUCT, len(p.SpecialShop)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.SpecialShop { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:SpecialShop: ", p), err) + } + return err +} + +func (p *ResCharge) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "FreeShop", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:FreeShop: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.FreeShop)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.FreeShop (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:FreeShop: ", p), err) + } + return err +} + +func (p *ResCharge) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChessShop", thrift.MAP, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:ChessShop: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.STRUCT, len(p.ChessShop)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.ChessShop { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:ChessShop: ", p), err) + } + return err +} + +func (p *ResCharge) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Gift", thrift.MAP, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:Gift: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.Gift)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Gift { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:Gift: ", p), err) + } + return err +} + +func (p *ResCharge) writeField8(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Ad", thrift.BOOL, 8); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 8:Ad: ", p), err) + } + if err := oprot.WriteBool(ctx, bool(p.Ad)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Ad (8) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 8:Ad: ", p), err) + } + return err +} + +func (p *ResCharge) writeField9(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Wish", thrift.STRUCT, 9); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 9:Wish: ", p), err) + } + if err := p.Wish.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.Wish), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 9:Wish: ", p), err) + } + return err +} + +func (p *ResCharge) writeField10(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "SpecialCharge", thrift.DOUBLE, 10); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 10:SpecialCharge: ", p), err) + } + if err := oprot.WriteDouble(ctx, float64(p.SpecialCharge)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.SpecialCharge (10) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 10:SpecialCharge: ", p), err) + } + return err +} + +func (p *ResCharge) writeField11(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "SpecialChargeWeek", thrift.I32, 11); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 11:SpecialChargeWeek: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.SpecialChargeWeek)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.SpecialChargeWeek (11) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 11:SpecialChargeWeek: ", p), err) + } + return err +} + +func (p *ResCharge) writeField12(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "TodayCharge", thrift.DOUBLE, 12); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 12:TodayCharge: ", p), err) + } + if err := oprot.WriteDouble(ctx, float64(p.TodayCharge)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.TodayCharge (12) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 12:TodayCharge: ", p), err) + } + return err +} + +func (p *ResCharge) writeField13(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MonthCharge", thrift.DOUBLE, 13); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 13:MonthCharge: ", p), err) + } + if err := oprot.WriteDouble(ctx, float64(p.MonthCharge)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.MonthCharge (13) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 13:MonthCharge: ", p), err) + } + return err +} + +func (p *ResCharge) writeField14(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "AdEndTime", thrift.I64, 14); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 14:AdEndTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.AdEndTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.AdEndTime (14) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 14:AdEndTime: ", p), err) + } + return err +} + +func (p *ResCharge) writeField15(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "WeeklyDiscount", thrift.MAP, 15); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 15:WeeklyDiscount: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.STRUCT, len(p.WeeklyDiscount)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.WeeklyDiscount { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 15:WeeklyDiscount: ", p), err) + } + return err +} + +func (p *ResCharge) writeField16(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "PetWorkRemainTime", thrift.I64, 16); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 16:PetWorkRemainTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.PetWorkRemainTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.PetWorkRemainTime (16) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 16:PetWorkRemainTime: ", p), err) + } + return err +} + +func (p *ResCharge) writeField17(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "WeeklyEndTime", thrift.I64, 17); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 17:WeeklyEndTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.WeeklyEndTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.WeeklyEndTime (17) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 17:WeeklyEndTime: ", p), err) + } + return err +} + +func (p *ResCharge) Equals(other *ResCharge) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Charge != other.Charge { + return false + } + if p.Total != other.Total { + return false + } + if len(p.First) != len(other.First) { + return false + } + for i, _tgt := range p.First { + _src194 := other.First[i] + if _tgt != _src194 { + return false + } + } + if len(p.SpecialShop) != len(other.SpecialShop) { + return false + } + for k, _tgt := range p.SpecialShop { + _src195 := other.SpecialShop[k] + if !_tgt.Equals(_src195) { + return false + } + } + if p.FreeShop != other.FreeShop { + return false + } + if len(p.ChessShop) != len(other.ChessShop) { + return false + } + for k, _tgt := range p.ChessShop { + _src196 := other.ChessShop[k] + if !_tgt.Equals(_src196) { + return false + } + } + if len(p.Gift) != len(other.Gift) { + return false + } + for k, _tgt := range p.Gift { + _src197 := other.Gift[k] + if _tgt != _src197 { + return false + } + } + if p.Ad != other.Ad { + return false + } + if !p.Wish.Equals(other.Wish) { + return false + } + if p.SpecialCharge != other.SpecialCharge { + return false + } + if p.SpecialChargeWeek != other.SpecialChargeWeek { + return false + } + if p.TodayCharge != other.TodayCharge { + return false + } + if p.MonthCharge != other.MonthCharge { + return false + } + if p.AdEndTime != other.AdEndTime { + return false + } + if len(p.WeeklyDiscount) != len(other.WeeklyDiscount) { + return false + } + for k, _tgt := range p.WeeklyDiscount { + _src198 := other.WeeklyDiscount[k] + if !_tgt.Equals(_src198) { + return false + } + } + if p.PetWorkRemainTime != other.PetWorkRemainTime { + return false + } + if p.WeeklyEndTime != other.WeeklyEndTime { + return false + } + return true +} + +func (p *ResCharge) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResCharge(%+v)", *p) +} + +func (p *ResCharge) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResCharge", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResCharge)(nil) + +func (p *ResCharge) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResChargeReceive struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResChargeReceive() *ResChargeReceive { + return &ResChargeReceive{} +} + +func (p *ResChargeReceive) GetCode() RES_CODE { + return p.Code +} + +func (p *ResChargeReceive) GetMsg() string { + return p.Msg +} + +func (p *ResChargeReceive) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResChargeReceive) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResChargeReceive) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResChargeReceive) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResChargeReceive"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResChargeReceive) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResChargeReceive) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResChargeReceive) Equals(other *ResChargeReceive) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResChargeReceive) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResChargeReceive(%+v)", *p) +} + +func (p *ResChargeReceive) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResChargeReceive", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResChargeReceive)(nil) + +func (p *ResChargeReceive) Validate() error { + return nil +} + +// Attributes: +// - MChessColorData +// +type ResChessColorData struct { + MChessColorData map[string]int32 `thrift:"MChessColorData,1" db:"MChessColorData" json:"MChessColorData"` +} + +func NewResChessColorData() *ResChessColorData { + return &ResChessColorData{} +} + +func (p *ResChessColorData) GetMChessColorData() map[string]int32 { + return p.MChessColorData +} + +func (p *ResChessColorData) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.MAP { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResChessColorData) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[string]int32, size) + p.MChessColorData = tMap + for i := 0; i < size; i++ { + var _key199 string + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key199 = v + } + var _val200 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val200 = v + } + p.MChessColorData[_key199] = _val200 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResChessColorData) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResChessColorData"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResChessColorData) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MChessColorData", thrift.MAP, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:MChessColorData: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.STRING, thrift.I32, len(p.MChessColorData)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.MChessColorData { + if err := oprot.WriteString(ctx, string(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:MChessColorData: ", p), err) + } + return err +} + +func (p *ResChessColorData) Equals(other *ResChessColorData) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.MChessColorData) != len(other.MChessColorData) { + return false + } + for k, _tgt := range p.MChessColorData { + _src201 := other.MChessColorData[k] + if _tgt != _src201 { + return false + } + } + return true +} + +func (p *ResChessColorData) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResChessColorData(%+v)", *p) +} + +func (p *ResChessColorData) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResChessColorData", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResChessColorData)(nil) + +func (p *ResChessColorData) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResChessEx struct { + Code RES_CODE `thrift:"code,1" db:"code" json:"code"` + Msg string `thrift:"msg,2" db:"msg" json:"msg"` +} + +func NewResChessEx() *ResChessEx { + return &ResChessEx{} +} + +func (p *ResChessEx) GetCode() RES_CODE { + return p.Code +} + +func (p *ResChessEx) GetMsg() string { + return p.Msg +} + +func (p *ResChessEx) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResChessEx) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResChessEx) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResChessEx) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResChessEx"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResChessEx) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:code: ", p), err) + } + return err +} + +func (p *ResChessEx) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:msg: ", p), err) + } + return err +} + +func (p *ResChessEx) Equals(other *ResChessEx) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResChessEx) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResChessEx(%+v)", *p) +} + +func (p *ResChessEx) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResChessEx", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResChessEx)(nil) + +func (p *ResChessEx) Validate() error { + return nil +} + +// Attributes: +// - Items +// - Id +// +type ResChessRainReward struct { + Items []*ItemInfo `thrift:"Items,1" db:"Items" json:"Items"` + Id int32 `thrift:"Id,2" db:"Id" json:"Id"` +} + +func NewResChessRainReward() *ResChessRainReward { + return &ResChessRainReward{} +} + +func (p *ResChessRainReward) GetItems() []*ItemInfo { + return p.Items +} + +func (p *ResChessRainReward) GetId() int32 { + return p.Id +} + +func (p *ResChessRainReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResChessRainReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ItemInfo, 0, size) + p.Items = tSlice + for i := 0; i < size; i++ { + _elem202 := &ItemInfo{} + if err := _elem202.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem202), err) + } + p.Items = append(p.Items, _elem202) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResChessRainReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResChessRainReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResChessRainReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResChessRainReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Items", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Items: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Items)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Items { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Items: ", p), err) + } + return err +} + +func (p *ResChessRainReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Id: ", p), err) + } + return err +} + +func (p *ResChessRainReward) Equals(other *ResChessRainReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.Items) != len(other.Items) { + return false + } + for i, _tgt := range p.Items { + _src203 := other.Items[i] + if !_tgt.Equals(_src203) { + return false + } + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ResChessRainReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResChessRainReward(%+v)", *p) +} + +func (p *ResChessRainReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResChessRainReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResChessRainReward)(nil) + +func (p *ResChessRainReward) Validate() error { + return nil +} + +// Attributes: +// - Diamond +// - Count +// - ChessId +// +type ResChessShop struct { + Diamond int32 `thrift:"Diamond,1" db:"Diamond" json:"Diamond"` + Count int32 `thrift:"Count,2" db:"Count" json:"Count"` + ChessId int32 `thrift:"ChessId,3" db:"ChessId" json:"ChessId"` +} + +func NewResChessShop() *ResChessShop { + return &ResChessShop{} +} + +func (p *ResChessShop) GetDiamond() int32 { + return p.Diamond +} + +func (p *ResChessShop) GetCount() int32 { + return p.Count +} + +func (p *ResChessShop) GetChessId() int32 { + return p.ChessId +} + +func (p *ResChessShop) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResChessShop) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Diamond = v + } + return nil +} + +func (p *ResChessShop) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Count = v + } + return nil +} + +func (p *ResChessShop) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.ChessId = v + } + return nil +} + +func (p *ResChessShop) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResChessShop"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResChessShop) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Diamond", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Diamond: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Diamond)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Diamond (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Diamond: ", p), err) + } + return err +} + +func (p *ResChessShop) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Count", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Count: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Count)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Count (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Count: ", p), err) + } + return err +} + +func (p *ResChessShop) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChessId", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:ChessId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ChessId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ChessId (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:ChessId: ", p), err) + } + return err +} + +func (p *ResChessShop) Equals(other *ResChessShop) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Diamond != other.Diamond { + return false + } + if p.Count != other.Count { + return false + } + if p.ChessId != other.ChessId { + return false + } + return true +} + +func (p *ResChessShop) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResChessShop(%+v)", *p) +} + +func (p *ResChessShop) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResChessShop", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResChessShop)(nil) + +func (p *ResChessShop) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResCollect struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResCollect() *ResCollect { + return &ResCollect{} +} + +func (p *ResCollect) GetCode() RES_CODE { + return p.Code +} + +func (p *ResCollect) GetMsg() string { + return p.Msg +} + +func (p *ResCollect) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResCollect) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResCollect) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResCollect) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResCollect"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResCollect) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResCollect) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResCollect) Equals(other *ResCollect) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResCollect) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResCollect(%+v)", *p) +} + +func (p *ResCollect) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResCollect", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResCollect)(nil) + +func (p *ResCollect) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Items +// +type ResCollectInfo struct { + Id []int32 `thrift:"Id,1" db:"Id" json:"Id"` + Items []*CollectItem `thrift:"Items,2" db:"Items" json:"Items"` +} + +func NewResCollectInfo() *ResCollectInfo { + return &ResCollectInfo{} +} + +func (p *ResCollectInfo) GetId() []int32 { + return p.Id +} + +func (p *ResCollectInfo) GetItems() []*CollectItem { + return p.Items +} + +func (p *ResCollectInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.LIST { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResCollectInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.Id = tSlice + for i := 0; i < size; i++ { + var _elem204 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem204 = v + } + p.Id = append(p.Id, _elem204) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResCollectInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*CollectItem, 0, size) + p.Items = tSlice + for i := 0; i < size; i++ { + _elem205 := &CollectItem{} + if err := _elem205.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem205), err) + } + p.Items = append(p.Items, _elem205) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResCollectInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResCollectInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResCollectInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.Id)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Id { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ResCollectInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Items", thrift.LIST, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Items: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Items)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Items { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Items: ", p), err) + } + return err +} + +func (p *ResCollectInfo) Equals(other *ResCollectInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.Id) != len(other.Id) { + return false + } + for i, _tgt := range p.Id { + _src206 := other.Id[i] + if _tgt != _src206 { + return false + } + } + if len(p.Items) != len(other.Items) { + return false + } + for i, _tgt := range p.Items { + _src207 := other.Items[i] + if !_tgt.Equals(_src207) { + return false + } + } + return true +} + +func (p *ResCollectInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResCollectInfo(%+v)", *p) +} + +func (p *ResCollectInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResCollectInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResCollectInfo)(nil) + +func (p *ResCollectInfo) Validate() error { + return nil +} + +// Attributes: +// - OrderSn +// +type ResCreateOrderSn struct { + OrderSn string `thrift:"OrderSn,1" db:"OrderSn" json:"OrderSn"` +} + +func NewResCreateOrderSn() *ResCreateOrderSn { + return &ResCreateOrderSn{} +} + +func (p *ResCreateOrderSn) GetOrderSn() string { + return p.OrderSn +} + +func (p *ResCreateOrderSn) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResCreateOrderSn) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.OrderSn = v + } + return nil +} + +func (p *ResCreateOrderSn) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResCreateOrderSn"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResCreateOrderSn) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "OrderSn", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:OrderSn: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.OrderSn)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.OrderSn (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:OrderSn: ", p), err) + } + return err +} + +func (p *ResCreateOrderSn) Equals(other *ResCreateOrderSn) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.OrderSn != other.OrderSn { + return false + } + return true +} + +func (p *ResCreateOrderSn) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResCreateOrderSn(%+v)", *p) +} + +func (p *ResCreateOrderSn) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResCreateOrderSn", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResCreateOrderSn)(nil) + +func (p *ResCreateOrderSn) Validate() error { + return nil +} + +// Attributes: +// - WeekReward +// - DailyTask +// - Active +// - DayEnd +// - WeekEnd +// +type ResDailyTask struct { + WeekReward map[int32]*DailyWeek `thrift:"WeekReward,1" db:"WeekReward" json:"WeekReward"` + DailyTask map[int32]*DailyTask `thrift:"DailyTask,2" db:"DailyTask" json:"DailyTask"` + Active int32 `thrift:"Active,3" db:"Active" json:"Active"` + DayEnd int32 `thrift:"DayEnd,4" db:"DayEnd" json:"DayEnd"` + WeekEnd int32 `thrift:"WeekEnd,5" db:"WeekEnd" json:"WeekEnd"` +} + +func NewResDailyTask() *ResDailyTask { + return &ResDailyTask{} +} + +func (p *ResDailyTask) GetWeekReward() map[int32]*DailyWeek { + return p.WeekReward +} + +func (p *ResDailyTask) GetDailyTask() map[int32]*DailyTask { + return p.DailyTask +} + +func (p *ResDailyTask) GetActive() int32 { + return p.Active +} + +func (p *ResDailyTask) GetDayEnd() int32 { + return p.DayEnd +} + +func (p *ResDailyTask) GetWeekEnd() int32 { + return p.WeekEnd +} + +func (p *ResDailyTask) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.MAP { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.MAP { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResDailyTask) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]*DailyWeek, size) + p.WeekReward = tMap + for i := 0; i < size; i++ { + var _key208 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key208 = v + } + _val209 := &DailyWeek{} + if err := _val209.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _val209), err) + } + p.WeekReward[_key208] = _val209 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResDailyTask) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]*DailyTask, size) + p.DailyTask = tMap + for i := 0; i < size; i++ { + var _key210 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key210 = v + } + _val211 := &DailyTask{} + if err := _val211.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _val211), err) + } + p.DailyTask[_key210] = _val211 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResDailyTask) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Active = v + } + return nil +} + +func (p *ResDailyTask) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.DayEnd = v + } + return nil +} + +func (p *ResDailyTask) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.WeekEnd = v + } + return nil +} + +func (p *ResDailyTask) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResDailyTask"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResDailyTask) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "WeekReward", thrift.MAP, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:WeekReward: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.STRUCT, len(p.WeekReward)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.WeekReward { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:WeekReward: ", p), err) + } + return err +} + +func (p *ResDailyTask) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "DailyTask", thrift.MAP, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:DailyTask: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.STRUCT, len(p.DailyTask)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.DailyTask { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:DailyTask: ", p), err) + } + return err +} + +func (p *ResDailyTask) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Active", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Active: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Active)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Active (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Active: ", p), err) + } + return err +} + +func (p *ResDailyTask) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "DayEnd", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:DayEnd: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.DayEnd)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.DayEnd (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:DayEnd: ", p), err) + } + return err +} + +func (p *ResDailyTask) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "WeekEnd", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:WeekEnd: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.WeekEnd)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.WeekEnd (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:WeekEnd: ", p), err) + } + return err +} + +func (p *ResDailyTask) Equals(other *ResDailyTask) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.WeekReward) != len(other.WeekReward) { + return false + } + for k, _tgt := range p.WeekReward { + _src212 := other.WeekReward[k] + if !_tgt.Equals(_src212) { + return false + } + } + if len(p.DailyTask) != len(other.DailyTask) { + return false + } + for k, _tgt := range p.DailyTask { + _src213 := other.DailyTask[k] + if !_tgt.Equals(_src213) { + return false + } + } + if p.Active != other.Active { + return false + } + if p.DayEnd != other.DayEnd { + return false + } + if p.WeekEnd != other.WeekEnd { + return false + } + return true +} + +func (p *ResDailyTask) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResDailyTask(%+v)", *p) +} + +func (p *ResDailyTask) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResDailyTask", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResDailyTask)(nil) + +func (p *ResDailyTask) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResDailyUnlock struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResDailyUnlock() *ResDailyUnlock { + return &ResDailyUnlock{} +} + +func (p *ResDailyUnlock) GetCode() RES_CODE { + return p.Code +} + +func (p *ResDailyUnlock) GetMsg() string { + return p.Msg +} + +func (p *ResDailyUnlock) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResDailyUnlock) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResDailyUnlock) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResDailyUnlock) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResDailyUnlock"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResDailyUnlock) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResDailyUnlock) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResDailyUnlock) Equals(other *ResDailyUnlock) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResDailyUnlock) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResDailyUnlock(%+v)", *p) +} + +func (p *ResDailyUnlock) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResDailyUnlock", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResDailyUnlock)(nil) + +func (p *ResDailyUnlock) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResDecorate struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResDecorate() *ResDecorate { + return &ResDecorate{} +} + +func (p *ResDecorate) GetCode() RES_CODE { + return p.Code +} + +func (p *ResDecorate) GetMsg() string { + return p.Msg +} + +func (p *ResDecorate) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResDecorate) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResDecorate) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResDecorate) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResDecorate"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResDecorate) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResDecorate) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResDecorate) Equals(other *ResDecorate) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResDecorate) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResDecorate(%+v)", *p) +} + +func (p *ResDecorate) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResDecorate", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResDecorate)(nil) + +func (p *ResDecorate) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResDecorateAll struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResDecorateAll() *ResDecorateAll { + return &ResDecorateAll{} +} + +func (p *ResDecorateAll) GetCode() RES_CODE { + return p.Code +} + +func (p *ResDecorateAll) GetMsg() string { + return p.Msg +} + +func (p *ResDecorateAll) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResDecorateAll) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResDecorateAll) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResDecorateAll) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResDecorateAll"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResDecorateAll) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResDecorateAll) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResDecorateAll) Equals(other *ResDecorateAll) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResDecorateAll) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResDecorateAll(%+v)", *p) +} + +func (p *ResDecorateAll) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResDecorateAll", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResDecorateAll)(nil) + +func (p *ResDecorateAll) Validate() error { + return nil +} + +// Attributes: +// - AreaId +// - MFinishList +// - RewardArea +// - Parts +// +type ResDecorateInfo struct { + AreaId int32 `thrift:"AreaId,1" db:"AreaId" json:"AreaId"` + MFinishList []int32 `thrift:"mFinishList,2" db:"mFinishList" json:"mFinishList"` + RewardArea []int32 `thrift:"RewardArea,3" db:"RewardArea" json:"RewardArea"` + Parts []*DecoratePart `thrift:"Parts,4" db:"Parts" json:"Parts"` +} + +func NewResDecorateInfo() *ResDecorateInfo { + return &ResDecorateInfo{} +} + +func (p *ResDecorateInfo) GetAreaId() int32 { + return p.AreaId +} + +func (p *ResDecorateInfo) GetMFinishList() []int32 { + return p.MFinishList +} + +func (p *ResDecorateInfo) GetRewardArea() []int32 { + return p.RewardArea +} + +func (p *ResDecorateInfo) GetParts() []*DecoratePart { + return p.Parts +} + +func (p *ResDecorateInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.LIST { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.LIST { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.LIST { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResDecorateInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.AreaId = v + } + return nil +} + +func (p *ResDecorateInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.MFinishList = tSlice + for i := 0; i < size; i++ { + var _elem214 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem214 = v + } + p.MFinishList = append(p.MFinishList, _elem214) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResDecorateInfo) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.RewardArea = tSlice + for i := 0; i < size; i++ { + var _elem215 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem215 = v + } + p.RewardArea = append(p.RewardArea, _elem215) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResDecorateInfo) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*DecoratePart, 0, size) + p.Parts = tSlice + for i := 0; i < size; i++ { + _elem216 := &DecoratePart{} + if err := _elem216.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem216), err) + } + p.Parts = append(p.Parts, _elem216) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResDecorateInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResDecorateInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResDecorateInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "AreaId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:AreaId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.AreaId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.AreaId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:AreaId: ", p), err) + } + return err +} + +func (p *ResDecorateInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "mFinishList", thrift.LIST, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:mFinishList: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.MFinishList)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.MFinishList { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:mFinishList: ", p), err) + } + return err +} + +func (p *ResDecorateInfo) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "RewardArea", thrift.LIST, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:RewardArea: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.RewardArea)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.RewardArea { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:RewardArea: ", p), err) + } + return err +} + +func (p *ResDecorateInfo) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Parts", thrift.LIST, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Parts: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Parts)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Parts { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Parts: ", p), err) + } + return err +} + +func (p *ResDecorateInfo) Equals(other *ResDecorateInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.AreaId != other.AreaId { + return false + } + if len(p.MFinishList) != len(other.MFinishList) { + return false + } + for i, _tgt := range p.MFinishList { + _src217 := other.MFinishList[i] + if _tgt != _src217 { + return false + } + } + if len(p.RewardArea) != len(other.RewardArea) { + return false + } + for i, _tgt := range p.RewardArea { + _src218 := other.RewardArea[i] + if _tgt != _src218 { + return false + } + } + if len(p.Parts) != len(other.Parts) { + return false + } + for i, _tgt := range p.Parts { + _src219 := other.Parts[i] + if !_tgt.Equals(_src219) { + return false + } + } + return true +} + +func (p *ResDecorateInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResDecorateInfo(%+v)", *p) +} + +func (p *ResDecorateInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResDecorateInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResDecorateInfo)(nil) + +func (p *ResDecorateInfo) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Uid +// +type ResDelFriend struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Uid int64 `thrift:"Uid,3" db:"Uid" json:"Uid"` +} + +func NewResDelFriend() *ResDelFriend { + return &ResDelFriend{} +} + +func (p *ResDelFriend) GetCode() RES_CODE { + return p.Code +} + +func (p *ResDelFriend) GetMsg() string { + return p.Msg +} + +func (p *ResDelFriend) GetUid() int64 { + return p.Uid +} + +func (p *ResDelFriend) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I64 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResDelFriend) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResDelFriend) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResDelFriend) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ResDelFriend) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResDelFriend"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResDelFriend) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResDelFriend) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResDelFriend) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Uid: ", p), err) + } + return err +} + +func (p *ResDelFriend) Equals(other *ResDelFriend) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Uid != other.Uid { + return false + } + return true +} + +func (p *ResDelFriend) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResDelFriend(%+v)", *p) +} + +func (p *ResDelFriend) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResDelFriend", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResDelFriend)(nil) + +func (p *ResDelFriend) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResDelOrder struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResDelOrder() *ResDelOrder { + return &ResDelOrder{} +} + +func (p *ResDelOrder) GetCode() RES_CODE { + return p.Code +} + +func (p *ResDelOrder) GetMsg() string { + return p.Msg +} + +func (p *ResDelOrder) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResDelOrder) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResDelOrder) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResDelOrder) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResDelOrder"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResDelOrder) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResDelOrder) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResDelOrder) Equals(other *ResDelOrder) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResDelOrder) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResDelOrder(%+v)", *p) +} + +func (p *ResDelOrder) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResDelOrder", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResDelOrder)(nil) + +func (p *ResDelOrder) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Id +// +type ResDeleteMail struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Id int32 `thrift:"Id,3" db:"Id" json:"Id"` +} + +func NewResDeleteMail() *ResDeleteMail { + return &ResDeleteMail{} +} + +func (p *ResDeleteMail) GetCode() RES_CODE { + return p.Code +} + +func (p *ResDeleteMail) GetMsg() string { + return p.Msg +} + +func (p *ResDeleteMail) GetId() int32 { + return p.Id +} + +func (p *ResDeleteMail) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResDeleteMail) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResDeleteMail) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResDeleteMail) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResDeleteMail) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResDeleteMail"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResDeleteMail) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResDeleteMail) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResDeleteMail) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Id: ", p), err) + } + return err +} + +func (p *ResDeleteMail) Equals(other *ResDeleteMail) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ResDeleteMail) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResDeleteMail(%+v)", *p) +} + +func (p *ResDeleteMail) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResDeleteMail", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResDeleteMail)(nil) + +func (p *ResDeleteMail) Validate() error { + return nil +} + +// Attributes: +// - Id +// - EndlessList +// +type ResEndless struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + EndlessList map[int32]*ResEndlessInfo `thrift:"EndlessList,2" db:"EndlessList" json:"EndlessList"` +} + +func NewResEndless() *ResEndless { + return &ResEndless{} +} + +func (p *ResEndless) GetId() int32 { + return p.Id +} + +func (p *ResEndless) GetEndlessList() map[int32]*ResEndlessInfo { + return p.EndlessList +} + +func (p *ResEndless) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.MAP { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResEndless) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResEndless) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]*ResEndlessInfo, size) + p.EndlessList = tMap + for i := 0; i < size; i++ { + var _key220 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key220 = v + } + _val221 := &ResEndlessInfo{} + if err := _val221.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _val221), err) + } + p.EndlessList[_key220] = _val221 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResEndless) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResEndless"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResEndless) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ResEndless) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EndlessList", thrift.MAP, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:EndlessList: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.STRUCT, len(p.EndlessList)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.EndlessList { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:EndlessList: ", p), err) + } + return err +} + +func (p *ResEndless) Equals(other *ResEndless) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if len(p.EndlessList) != len(other.EndlessList) { + return false + } + for k, _tgt := range p.EndlessList { + _src222 := other.EndlessList[k] + if !_tgt.Equals(_src222) { + return false + } + } + return true +} + +func (p *ResEndless) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResEndless(%+v)", *p) +} + +func (p *ResEndless) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResEndless", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResEndless)(nil) + +func (p *ResEndless) Validate() error { + return nil +} + +// Attributes: +// - ChargeId +// - Type +// - Items +// +type ResEndlessInfo struct { + ChargeId int32 `thrift:"ChargeId,1" db:"ChargeId" json:"ChargeId"` + Type int32 `thrift:"Type,2" db:"Type" json:"Type"` + Items []*ItemInfo `thrift:"Items,3" db:"Items" json:"Items"` +} + +func NewResEndlessInfo() *ResEndlessInfo { + return &ResEndlessInfo{} +} + +func (p *ResEndlessInfo) GetChargeId() int32 { + return p.ChargeId +} + +func (p *ResEndlessInfo) GetType() int32 { + return p.Type +} + +func (p *ResEndlessInfo) GetItems() []*ItemInfo { + return p.Items +} + +func (p *ResEndlessInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.LIST { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResEndlessInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.ChargeId = v + } + return nil +} + +func (p *ResEndlessInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ResEndlessInfo) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ItemInfo, 0, size) + p.Items = tSlice + for i := 0; i < size; i++ { + _elem223 := &ItemInfo{} + if err := _elem223.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem223), err) + } + p.Items = append(p.Items, _elem223) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResEndlessInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResEndlessInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResEndlessInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChargeId", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ChargeId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ChargeId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ChargeId (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ChargeId: ", p), err) + } + return err +} + +func (p *ResEndlessInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Type: ", p), err) + } + return err +} + +func (p *ResEndlessInfo) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Items", thrift.LIST, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Items: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Items)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Items { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Items: ", p), err) + } + return err +} + +func (p *ResEndlessInfo) Equals(other *ResEndlessInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ChargeId != other.ChargeId { + return false + } + if p.Type != other.Type { + return false + } + if len(p.Items) != len(other.Items) { + return false + } + for i, _tgt := range p.Items { + _src224 := other.Items[i] + if !_tgt.Equals(_src224) { + return false + } + } + return true +} + +func (p *ResEndlessInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResEndlessInfo(%+v)", *p) +} + +func (p *ResEndlessInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResEndlessInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResEndlessInfo)(nil) + +func (p *ResEndlessInfo) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResEndlessReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResEndlessReward() *ResEndlessReward { + return &ResEndlessReward{} +} + +func (p *ResEndlessReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResEndlessReward) GetMsg() string { + return p.Msg +} + +func (p *ResEndlessReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResEndlessReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResEndlessReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResEndlessReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResEndlessReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResEndlessReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResEndlessReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResEndlessReward) Equals(other *ResEndlessReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResEndlessReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResEndlessReward(%+v)", *p) +} + +func (p *ResEndlessReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResEndlessReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResEndlessReward)(nil) + +func (p *ResEndlessReward) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResExStarReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResExStarReward() *ResExStarReward { + return &ResExStarReward{} +} + +func (p *ResExStarReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResExStarReward) GetMsg() string { + return p.Msg +} + +func (p *ResExStarReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResExStarReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResExStarReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResExStarReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResExStarReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResExStarReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResExStarReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResExStarReward) Equals(other *ResExStarReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResExStarReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResExStarReward(%+v)", *p) +} + +func (p *ResExStarReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResExStarReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResExStarReward)(nil) + +func (p *ResExStarReward) Validate() error { + return nil +} + +// Attributes: +// - FaceList +// - SetId +// +type ResFaceInfo struct { + FaceList []*FaceInfo `thrift:"FaceList,1" db:"FaceList" json:"FaceList"` + SetId int32 `thrift:"SetId,2" db:"SetId" json:"SetId"` +} + +func NewResFaceInfo() *ResFaceInfo { + return &ResFaceInfo{} +} + +func (p *ResFaceInfo) GetFaceList() []*FaceInfo { + return p.FaceList +} + +func (p *ResFaceInfo) GetSetId() int32 { + return p.SetId +} + +func (p *ResFaceInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFaceInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*FaceInfo, 0, size) + p.FaceList = tSlice + for i := 0; i < size; i++ { + _elem225 := &FaceInfo{} + if err := _elem225.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem225), err) + } + p.FaceList = append(p.FaceList, _elem225) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResFaceInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.SetId = v + } + return nil +} + +func (p *ResFaceInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFaceInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFaceInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "FaceList", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:FaceList: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.FaceList)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.FaceList { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:FaceList: ", p), err) + } + return err +} + +func (p *ResFaceInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "SetId", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:SetId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.SetId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.SetId (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:SetId: ", p), err) + } + return err +} + +func (p *ResFaceInfo) Equals(other *ResFaceInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.FaceList) != len(other.FaceList) { + return false + } + for i, _tgt := range p.FaceList { + _src226 := other.FaceList[i] + if !_tgt.Equals(_src226) { + return false + } + } + if p.SetId != other.SetId { + return false + } + return true +} + +func (p *ResFaceInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFaceInfo(%+v)", *p) +} + +func (p *ResFaceInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFaceInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFaceInfo)(nil) + +func (p *ResFaceInfo) Validate() error { + return nil +} + +// Attributes: +// - Energy +// - Num +// - EndTime +// +type ResFastProduceInfo struct { + Energy int32 `thrift:"Energy,1" db:"Energy" json:"Energy"` + Num int32 `thrift:"Num,2" db:"Num" json:"Num"` + EndTime int64 `thrift:"EndTime,3" db:"EndTime" json:"EndTime"` +} + +func NewResFastProduceInfo() *ResFastProduceInfo { + return &ResFastProduceInfo{} +} + +func (p *ResFastProduceInfo) GetEnergy() int32 { + return p.Energy +} + +func (p *ResFastProduceInfo) GetNum() int32 { + return p.Num +} + +func (p *ResFastProduceInfo) GetEndTime() int64 { + return p.EndTime +} + +func (p *ResFastProduceInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I64 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFastProduceInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Energy = v + } + return nil +} + +func (p *ResFastProduceInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Num = v + } + return nil +} + +func (p *ResFastProduceInfo) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.EndTime = v + } + return nil +} + +func (p *ResFastProduceInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFastProduceInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFastProduceInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Energy", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Energy: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Energy)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Energy (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Energy: ", p), err) + } + return err +} + +func (p *ResFastProduceInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Num", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Num: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Num)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Num (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Num: ", p), err) + } + return err +} + +func (p *ResFastProduceInfo) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EndTime", thrift.I64, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:EndTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.EndTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EndTime (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:EndTime: ", p), err) + } + return err +} + +func (p *ResFastProduceInfo) Equals(other *ResFastProduceInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Energy != other.Energy { + return false + } + if p.Num != other.Num { + return false + } + if p.EndTime != other.EndTime { + return false + } + return true +} + +func (p *ResFastProduceInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFastProduceInfo(%+v)", *p) +} + +func (p *ResFastProduceInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFastProduceInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFastProduceInfo)(nil) + +func (p *ResFastProduceInfo) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - EndTime +// - Num +// +type ResFastProduceReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + EndTime int64 `thrift:"EndTime,3" db:"EndTime" json:"EndTime"` + Num int32 `thrift:"Num,4" db:"Num" json:"Num"` +} + +func NewResFastProduceReward() *ResFastProduceReward { + return &ResFastProduceReward{} +} + +func (p *ResFastProduceReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResFastProduceReward) GetMsg() string { + return p.Msg +} + +func (p *ResFastProduceReward) GetEndTime() int64 { + return p.EndTime +} + +func (p *ResFastProduceReward) GetNum() int32 { + return p.Num +} + +func (p *ResFastProduceReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I64 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFastProduceReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResFastProduceReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResFastProduceReward) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.EndTime = v + } + return nil +} + +func (p *ResFastProduceReward) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Num = v + } + return nil +} + +func (p *ResFastProduceReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFastProduceReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFastProduceReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResFastProduceReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResFastProduceReward) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EndTime", thrift.I64, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:EndTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.EndTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EndTime (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:EndTime: ", p), err) + } + return err +} + +func (p *ResFastProduceReward) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Num", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Num: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Num)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Num (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Num: ", p), err) + } + return err +} + +func (p *ResFastProduceReward) Equals(other *ResFastProduceReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.EndTime != other.EndTime { + return false + } + if p.Num != other.Num { + return false + } + return true +} + +func (p *ResFastProduceReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFastProduceReward(%+v)", *p) +} + +func (p *ResFastProduceReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFastProduceReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFastProduceReward)(nil) + +func (p *ResFastProduceReward) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResFreeShop struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResFreeShop() *ResFreeShop { + return &ResFreeShop{} +} + +func (p *ResFreeShop) GetCode() RES_CODE { + return p.Code +} + +func (p *ResFreeShop) GetMsg() string { + return p.Msg +} + +func (p *ResFreeShop) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFreeShop) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResFreeShop) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResFreeShop) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFreeShop"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFreeShop) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResFreeShop) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResFreeShop) Equals(other *ResFreeShop) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResFreeShop) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFreeShop(%+v)", *p) +} + +func (p *ResFreeShop) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFreeShop", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFreeShop)(nil) + +func (p *ResFreeShop) Validate() error { + return nil +} + +// Attributes: +// - ApplyList +// +type ResFriendApply struct { + ApplyList []*ResFriendApplyInfo `thrift:"ApplyList,1" db:"ApplyList" json:"ApplyList"` +} + +func NewResFriendApply() *ResFriendApply { + return &ResFriendApply{} +} + +func (p *ResFriendApply) GetApplyList() []*ResFriendApplyInfo { + return p.ApplyList +} + +func (p *ResFriendApply) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFriendApply) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ResFriendApplyInfo, 0, size) + p.ApplyList = tSlice + for i := 0; i < size; i++ { + _elem227 := &ResFriendApplyInfo{} + if err := _elem227.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem227), err) + } + p.ApplyList = append(p.ApplyList, _elem227) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResFriendApply) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFriendApply"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFriendApply) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ApplyList", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ApplyList: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.ApplyList)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.ApplyList { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ApplyList: ", p), err) + } + return err +} + +func (p *ResFriendApply) Equals(other *ResFriendApply) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.ApplyList) != len(other.ApplyList) { + return false + } + for i, _tgt := range p.ApplyList { + _src228 := other.ApplyList[i] + if !_tgt.Equals(_src228) { + return false + } + } + return true +} + +func (p *ResFriendApply) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFriendApply(%+v)", *p) +} + +func (p *ResFriendApply) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFriendApply", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFriendApply)(nil) + +func (p *ResFriendApply) Validate() error { + return nil +} + +// Attributes: +// - Player +// - Time +// +type ResFriendApplyInfo struct { + Player *ResPlayerSimple `thrift:"Player,1" db:"Player" json:"Player"` + Time int32 `thrift:"Time,2" db:"Time" json:"Time"` +} + +func NewResFriendApplyInfo() *ResFriendApplyInfo { + return &ResFriendApplyInfo{} +} + +var ResFriendApplyInfo_Player_DEFAULT *ResPlayerSimple + +func (p *ResFriendApplyInfo) GetPlayer() *ResPlayerSimple { + if !p.IsSetPlayer() { + return ResFriendApplyInfo_Player_DEFAULT + } + return p.Player +} + +func (p *ResFriendApplyInfo) GetTime() int32 { + return p.Time +} + +func (p *ResFriendApplyInfo) IsSetPlayer() bool { + return p.Player != nil +} + +func (p *ResFriendApplyInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFriendApplyInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + p.Player = &ResPlayerSimple{} + if err := p.Player.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.Player), err) + } + return nil +} + +func (p *ResFriendApplyInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Time = v + } + return nil +} + +func (p *ResFriendApplyInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFriendApplyInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFriendApplyInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Player", thrift.STRUCT, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Player: ", p), err) + } + if err := p.Player.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.Player), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Player: ", p), err) + } + return err +} + +func (p *ResFriendApplyInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Time", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Time: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Time)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Time (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Time: ", p), err) + } + return err +} + +func (p *ResFriendApplyInfo) Equals(other *ResFriendApplyInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if !p.Player.Equals(other.Player) { + return false + } + if p.Time != other.Time { + return false + } + return true +} + +func (p *ResFriendApplyInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFriendApplyInfo(%+v)", *p) +} + +func (p *ResFriendApplyInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFriendApplyInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFriendApplyInfo)(nil) + +func (p *ResFriendApplyInfo) Validate() error { + return nil +} + +// Attributes: +// - Player +// - Type +// - Time +// +type ResFriendApplyNotify struct { + Player *ResPlayerSimple `thrift:"Player,1" db:"Player" json:"Player"` + Type int32 `thrift:"Type,2" db:"Type" json:"Type"` + Time int32 `thrift:"Time,3" db:"Time" json:"Time"` +} + +func NewResFriendApplyNotify() *ResFriendApplyNotify { + return &ResFriendApplyNotify{} +} + +var ResFriendApplyNotify_Player_DEFAULT *ResPlayerSimple + +func (p *ResFriendApplyNotify) GetPlayer() *ResPlayerSimple { + if !p.IsSetPlayer() { + return ResFriendApplyNotify_Player_DEFAULT + } + return p.Player +} + +func (p *ResFriendApplyNotify) GetType() int32 { + return p.Type +} + +func (p *ResFriendApplyNotify) GetTime() int32 { + return p.Time +} + +func (p *ResFriendApplyNotify) IsSetPlayer() bool { + return p.Player != nil +} + +func (p *ResFriendApplyNotify) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFriendApplyNotify) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + p.Player = &ResPlayerSimple{} + if err := p.Player.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.Player), err) + } + return nil +} + +func (p *ResFriendApplyNotify) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ResFriendApplyNotify) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Time = v + } + return nil +} + +func (p *ResFriendApplyNotify) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFriendApplyNotify"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFriendApplyNotify) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Player", thrift.STRUCT, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Player: ", p), err) + } + if err := p.Player.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.Player), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Player: ", p), err) + } + return err +} + +func (p *ResFriendApplyNotify) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Type: ", p), err) + } + return err +} + +func (p *ResFriendApplyNotify) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Time", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Time: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Time)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Time (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Time: ", p), err) + } + return err +} + +func (p *ResFriendApplyNotify) Equals(other *ResFriendApplyNotify) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if !p.Player.Equals(other.Player) { + return false + } + if p.Type != other.Type { + return false + } + if p.Time != other.Time { + return false + } + return true +} + +func (p *ResFriendApplyNotify) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFriendApplyNotify(%+v)", *p) +} + +func (p *ResFriendApplyNotify) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFriendApplyNotify", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFriendApplyNotify)(nil) + +func (p *ResFriendApplyNotify) Validate() error { + return nil +} + +// Attributes: +// - Bubble +// +type ResFriendBubble struct { + Bubble []*FriendBubbleInfo `thrift:"Bubble,1" db:"Bubble" json:"Bubble"` +} + +func NewResFriendBubble() *ResFriendBubble { + return &ResFriendBubble{} +} + +func (p *ResFriendBubble) GetBubble() []*FriendBubbleInfo { + return p.Bubble +} + +func (p *ResFriendBubble) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFriendBubble) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*FriendBubbleInfo, 0, size) + p.Bubble = tSlice + for i := 0; i < size; i++ { + _elem229 := &FriendBubbleInfo{} + if err := _elem229.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem229), err) + } + p.Bubble = append(p.Bubble, _elem229) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResFriendBubble) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFriendBubble"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFriendBubble) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Bubble", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Bubble: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Bubble)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Bubble { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Bubble: ", p), err) + } + return err +} + +func (p *ResFriendBubble) Equals(other *ResFriendBubble) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.Bubble) != len(other.Bubble) { + return false + } + for i, _tgt := range p.Bubble { + _src230 := other.Bubble[i] + if !_tgt.Equals(_src230) { + return false + } + } + return true +} + +func (p *ResFriendBubble) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFriendBubble(%+v)", *p) +} + +func (p *ResFriendBubble) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFriendBubble", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFriendBubble)(nil) + +func (p *ResFriendBubble) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Player +// +type ResFriendByCode struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Player *ResPlayerSimple `thrift:"Player,3" db:"Player" json:"Player"` +} + +func NewResFriendByCode() *ResFriendByCode { + return &ResFriendByCode{} +} + +func (p *ResFriendByCode) GetCode() RES_CODE { + return p.Code +} + +func (p *ResFriendByCode) GetMsg() string { + return p.Msg +} + +var ResFriendByCode_Player_DEFAULT *ResPlayerSimple + +func (p *ResFriendByCode) GetPlayer() *ResPlayerSimple { + if !p.IsSetPlayer() { + return ResFriendByCode_Player_DEFAULT + } + return p.Player +} + +func (p *ResFriendByCode) IsSetPlayer() bool { + return p.Player != nil +} + +func (p *ResFriendByCode) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFriendByCode) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResFriendByCode) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResFriendByCode) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + p.Player = &ResPlayerSimple{} + if err := p.Player.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.Player), err) + } + return nil +} + +func (p *ResFriendByCode) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFriendByCode"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFriendByCode) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResFriendByCode) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResFriendByCode) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Player", thrift.STRUCT, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Player: ", p), err) + } + if err := p.Player.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.Player), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Player: ", p), err) + } + return err +} + +func (p *ResFriendByCode) Equals(other *ResFriendByCode) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if !p.Player.Equals(other.Player) { + return false + } + return true +} + +func (p *ResFriendByCode) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFriendByCode(%+v)", *p) +} + +func (p *ResFriendByCode) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFriendByCode", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFriendByCode)(nil) + +func (p *ResFriendByCode) Validate() error { + return nil +} + +// Attributes: +// - Uid +// - Name +// - Face +// - Avatar +// - Level +// - Type +// - Time +// - CardId +// - ExCardId +// - Status +// - Id +// - Emoji +// +type ResFriendCard struct { + Uid int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` + Name string `thrift:"Name,2" db:"Name" json:"Name"` + Face int32 `thrift:"Face,3" db:"Face" json:"Face"` + Avatar int32 `thrift:"Avatar,4" db:"Avatar" json:"Avatar"` + Level int32 `thrift:"Level,5" db:"Level" json:"Level"` + Type int32 `thrift:"Type,6" db:"Type" json:"Type"` + Time int32 `thrift:"Time,7" db:"Time" json:"Time"` + CardId int32 `thrift:"CardId,8" db:"CardId" json:"CardId"` + ExCardId int32 `thrift:"ExCardId,9" db:"ExCardId" json:"ExCardId"` + Status int32 `thrift:"Status,10" db:"Status" json:"Status"` + Id string `thrift:"Id,11" db:"Id" json:"Id"` + Emoji int32 `thrift:"Emoji,12" db:"Emoji" json:"Emoji"` +} + +func NewResFriendCard() *ResFriendCard { + return &ResFriendCard{} +} + +func (p *ResFriendCard) GetUid() int64 { + return p.Uid +} + +func (p *ResFriendCard) GetName() string { + return p.Name +} + +func (p *ResFriendCard) GetFace() int32 { + return p.Face +} + +func (p *ResFriendCard) GetAvatar() int32 { + return p.Avatar +} + +func (p *ResFriendCard) GetLevel() int32 { + return p.Level +} + +func (p *ResFriendCard) GetType() int32 { + return p.Type +} + +func (p *ResFriendCard) GetTime() int32 { + return p.Time +} + +func (p *ResFriendCard) GetCardId() int32 { + return p.CardId +} + +func (p *ResFriendCard) GetExCardId() int32 { + return p.ExCardId +} + +func (p *ResFriendCard) GetStatus() int32 { + return p.Status +} + +func (p *ResFriendCard) GetId() string { + return p.Id +} + +func (p *ResFriendCard) GetEmoji() int32 { + return p.Emoji +} + +func (p *ResFriendCard) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.I32 { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.I32 { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 8: + if fieldTypeId == thrift.I32 { + if err := p.ReadField8(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 9: + if fieldTypeId == thrift.I32 { + if err := p.ReadField9(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 10: + if fieldTypeId == thrift.I32 { + if err := p.ReadField10(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 11: + if fieldTypeId == thrift.STRING { + if err := p.ReadField11(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 12: + if fieldTypeId == thrift.I32 { + if err := p.ReadField12(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFriendCard) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ResFriendCard) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Name = v + } + return nil +} + +func (p *ResFriendCard) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Face = v + } + return nil +} + +func (p *ResFriendCard) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Avatar = v + } + return nil +} + +func (p *ResFriendCard) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.Level = v + } + return nil +} + +func (p *ResFriendCard) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 6: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ResFriendCard) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 7: ", err) + } else { + p.Time = v + } + return nil +} + +func (p *ResFriendCard) ReadField8(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 8: ", err) + } else { + p.CardId = v + } + return nil +} + +func (p *ResFriendCard) ReadField9(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 9: ", err) + } else { + p.ExCardId = v + } + return nil +} + +func (p *ResFriendCard) ReadField10(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 10: ", err) + } else { + p.Status = v + } + return nil +} + +func (p *ResFriendCard) ReadField11(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 11: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResFriendCard) ReadField12(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 12: ", err) + } else { + p.Emoji = v + } + return nil +} + +func (p *ResFriendCard) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFriendCard"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + if err := p.writeField8(ctx, oprot); err != nil { + return err + } + if err := p.writeField9(ctx, oprot); err != nil { + return err + } + if err := p.writeField10(ctx, oprot); err != nil { + return err + } + if err := p.writeField11(ctx, oprot); err != nil { + return err + } + if err := p.writeField12(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFriendCard) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *ResFriendCard) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Name", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Name: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Name)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Name (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Name: ", p), err) + } + return err +} + +func (p *ResFriendCard) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Face", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Face: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Face)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Face (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Face: ", p), err) + } + return err +} + +func (p *ResFriendCard) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Avatar", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Avatar: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Avatar)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Avatar (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Avatar: ", p), err) + } + return err +} + +func (p *ResFriendCard) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Level", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Level: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Level)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Level (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Level: ", p), err) + } + return err +} + +func (p *ResFriendCard) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (6) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:Type: ", p), err) + } + return err +} + +func (p *ResFriendCard) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Time", thrift.I32, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:Time: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Time)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Time (7) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:Time: ", p), err) + } + return err +} + +func (p *ResFriendCard) writeField8(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "CardId", thrift.I32, 8); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 8:CardId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.CardId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.CardId (8) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 8:CardId: ", p), err) + } + return err +} + +func (p *ResFriendCard) writeField9(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ExCardId", thrift.I32, 9); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 9:ExCardId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ExCardId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ExCardId (9) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 9:ExCardId: ", p), err) + } + return err +} + +func (p *ResFriendCard) writeField10(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Status", thrift.I32, 10); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 10:Status: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Status)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Status (10) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 10:Status: ", p), err) + } + return err +} + +func (p *ResFriendCard) writeField11(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.STRING, 11); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 11:Id: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (11) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 11:Id: ", p), err) + } + return err +} + +func (p *ResFriendCard) writeField12(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Emoji", thrift.I32, 12); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 12:Emoji: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Emoji)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Emoji (12) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 12:Emoji: ", p), err) + } + return err +} + +func (p *ResFriendCard) Equals(other *ResFriendCard) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Uid != other.Uid { + return false + } + if p.Name != other.Name { + return false + } + if p.Face != other.Face { + return false + } + if p.Avatar != other.Avatar { + return false + } + if p.Level != other.Level { + return false + } + if p.Type != other.Type { + return false + } + if p.Time != other.Time { + return false + } + if p.CardId != other.CardId { + return false + } + if p.ExCardId != other.ExCardId { + return false + } + if p.Status != other.Status { + return false + } + if p.Id != other.Id { + return false + } + if p.Emoji != other.Emoji { + return false + } + return true +} + +func (p *ResFriendCard) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFriendCard(%+v)", *p) +} + +func (p *ResFriendCard) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFriendCard", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFriendCard)(nil) + +func (p *ResFriendCard) Validate() error { + return nil +} + +// Attributes: +// - MsgList +// +type ResFriendCardMsg struct { + MsgList []*ResFriendCard `thrift:"MsgList,1" db:"MsgList" json:"MsgList"` +} + +func NewResFriendCardMsg() *ResFriendCardMsg { + return &ResFriendCardMsg{} +} + +func (p *ResFriendCardMsg) GetMsgList() []*ResFriendCard { + return p.MsgList +} + +func (p *ResFriendCardMsg) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFriendCardMsg) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ResFriendCard, 0, size) + p.MsgList = tSlice + for i := 0; i < size; i++ { + _elem231 := &ResFriendCard{} + if err := _elem231.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem231), err) + } + p.MsgList = append(p.MsgList, _elem231) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResFriendCardMsg) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFriendCardMsg"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFriendCardMsg) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MsgList", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:MsgList: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.MsgList)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.MsgList { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:MsgList: ", p), err) + } + return err +} + +func (p *ResFriendCardMsg) Equals(other *ResFriendCardMsg) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.MsgList) != len(other.MsgList) { + return false + } + for i, _tgt := range p.MsgList { + _src232 := other.MsgList[i] + if !_tgt.Equals(_src232) { + return false + } + } + return true +} + +func (p *ResFriendCardMsg) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFriendCardMsg(%+v)", *p) +} + +func (p *ResFriendCardMsg) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFriendCardMsg", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFriendCardMsg)(nil) + +func (p *ResFriendCardMsg) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResFriendIgnore struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResFriendIgnore() *ResFriendIgnore { + return &ResFriendIgnore{} +} + +func (p *ResFriendIgnore) GetCode() RES_CODE { + return p.Code +} + +func (p *ResFriendIgnore) GetMsg() string { + return p.Msg +} + +func (p *ResFriendIgnore) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFriendIgnore) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResFriendIgnore) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResFriendIgnore) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFriendIgnore"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFriendIgnore) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResFriendIgnore) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResFriendIgnore) Equals(other *ResFriendIgnore) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResFriendIgnore) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFriendIgnore(%+v)", *p) +} + +func (p *ResFriendIgnore) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFriendIgnore", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFriendIgnore)(nil) + +func (p *ResFriendIgnore) Validate() error { + return nil +} + +// Attributes: +// - FriendList +// - ReqApplyList +// - Npc +// - Sponsor +// +type ResFriendList struct { + FriendList []*ResPlayerSimple `thrift:"FriendList,1" db:"FriendList" json:"FriendList"` + Npc []int32 `thrift:"Npc,2" db:"Npc" json:"Npc"` + ReqApplyList []int64 `thrift:"ReqApplyList,3" db:"ReqApplyList" json:"ReqApplyList"` + Sponsor int32 `thrift:"Sponsor,4" db:"Sponsor" json:"Sponsor"` +} + +func NewResFriendList() *ResFriendList { + return &ResFriendList{} +} + +func (p *ResFriendList) GetFriendList() []*ResPlayerSimple { + return p.FriendList +} + +func (p *ResFriendList) GetReqApplyList() []int64 { + return p.ReqApplyList +} + +func (p *ResFriendList) GetNpc() []int32 { + return p.Npc +} + +func (p *ResFriendList) GetSponsor() int32 { + return p.Sponsor +} + +func (p *ResFriendList) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.LIST { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.LIST { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFriendList) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ResPlayerSimple, 0, size) + p.FriendList = tSlice + for i := 0; i < size; i++ { + _elem233 := &ResPlayerSimple{} + if err := _elem233.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem233), err) + } + p.FriendList = append(p.FriendList, _elem233) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResFriendList) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int64, 0, size) + p.ReqApplyList = tSlice + for i := 0; i < size; i++ { + var _elem234 int64 + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem234 = v + } + p.ReqApplyList = append(p.ReqApplyList, _elem234) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResFriendList) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.Npc = tSlice + for i := 0; i < size; i++ { + var _elem235 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem235 = v + } + p.Npc = append(p.Npc, _elem235) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResFriendList) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Sponsor = v + } + return nil +} + +func (p *ResFriendList) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFriendList"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFriendList) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "FriendList", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:FriendList: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.FriendList)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.FriendList { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:FriendList: ", p), err) + } + return err +} + +func (p *ResFriendList) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Npc", thrift.LIST, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Npc: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.Npc)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Npc { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Npc: ", p), err) + } + return err +} + +func (p *ResFriendList) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ReqApplyList", thrift.LIST, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:ReqApplyList: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I64, len(p.ReqApplyList)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.ReqApplyList { + if err := oprot.WriteI64(ctx, int64(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:ReqApplyList: ", p), err) + } + return err +} + +func (p *ResFriendList) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Sponsor", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Sponsor: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Sponsor)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Sponsor (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Sponsor: ", p), err) + } + return err +} + +func (p *ResFriendList) Equals(other *ResFriendList) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.FriendList) != len(other.FriendList) { + return false + } + for i, _tgt := range p.FriendList { + _src236 := other.FriendList[i] + if !_tgt.Equals(_src236) { + return false + } + } + if len(p.Npc) != len(other.Npc) { + return false + } + for i, _tgt := range p.Npc { + _src237 := other.Npc[i] + if _tgt != _src237 { + return false + } + } + if len(p.ReqApplyList) != len(other.ReqApplyList) { + return false + } + for i, _tgt := range p.ReqApplyList { + _src238 := other.ReqApplyList[i] + if _tgt != _src238 { + return false + } + } + if p.Sponsor != other.Sponsor { + return false + } + return true +} + +func (p *ResFriendList) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFriendList(%+v)", *p) +} + +func (p *ResFriendList) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFriendList", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFriendList)(nil) + +func (p *ResFriendList) Validate() error { + return nil +} + +// Attributes: +// - Player +// - Type +// - Time +// - Param +// - Id +// - Upvote +// +type ResFriendLog struct { + Player *ResPlayerSimple `thrift:"Player,1" db:"Player" json:"Player"` + Type int32 `thrift:"Type,2" db:"Type" json:"Type"` + Time int32 `thrift:"Time,3" db:"Time" json:"Time"` + Param string `thrift:"Param,4" db:"Param" json:"Param"` + Id int32 `thrift:"Id,5" db:"Id" json:"Id"` + Upvote bool `thrift:"Upvote,6" db:"Upvote" json:"Upvote"` +} + +func NewResFriendLog() *ResFriendLog { + return &ResFriendLog{} +} + +var ResFriendLog_Player_DEFAULT *ResPlayerSimple + +func (p *ResFriendLog) GetPlayer() *ResPlayerSimple { + if !p.IsSetPlayer() { + return ResFriendLog_Player_DEFAULT + } + return p.Player +} + +func (p *ResFriendLog) GetType() int32 { + return p.Type +} + +func (p *ResFriendLog) GetTime() int32 { + return p.Time +} + +func (p *ResFriendLog) GetParam() string { + return p.Param +} + +func (p *ResFriendLog) GetId() int32 { + return p.Id +} + +func (p *ResFriendLog) GetUpvote() bool { + return p.Upvote +} + +func (p *ResFriendLog) IsSetPlayer() bool { + return p.Player != nil +} + +func (p *ResFriendLog) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.STRING { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.BOOL { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFriendLog) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + p.Player = &ResPlayerSimple{} + if err := p.Player.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.Player), err) + } + return nil +} + +func (p *ResFriendLog) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ResFriendLog) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Time = v + } + return nil +} + +func (p *ResFriendLog) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Param = v + } + return nil +} + +func (p *ResFriendLog) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResFriendLog) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadBool(ctx); err != nil { + return thrift.PrependError("error reading field 6: ", err) + } else { + p.Upvote = v + } + return nil +} + +func (p *ResFriendLog) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFriendLog"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFriendLog) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Player", thrift.STRUCT, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Player: ", p), err) + } + if err := p.Player.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.Player), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Player: ", p), err) + } + return err +} + +func (p *ResFriendLog) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Type: ", p), err) + } + return err +} + +func (p *ResFriendLog) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Time", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Time: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Time)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Time (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Time: ", p), err) + } + return err +} + +func (p *ResFriendLog) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Param", thrift.STRING, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Param: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Param)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Param (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Param: ", p), err) + } + return err +} + +func (p *ResFriendLog) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Id: ", p), err) + } + return err +} + +func (p *ResFriendLog) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Upvote", thrift.BOOL, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:Upvote: ", p), err) + } + if err := oprot.WriteBool(ctx, bool(p.Upvote)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Upvote (6) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:Upvote: ", p), err) + } + return err +} + +func (p *ResFriendLog) Equals(other *ResFriendLog) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if !p.Player.Equals(other.Player) { + return false + } + if p.Type != other.Type { + return false + } + if p.Time != other.Time { + return false + } + if p.Param != other.Param { + return false + } + if p.Id != other.Id { + return false + } + if p.Upvote != other.Upvote { + return false + } + return true +} + +func (p *ResFriendLog) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFriendLog(%+v)", *p) +} + +func (p *ResFriendLog) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFriendLog", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFriendLog)(nil) + +func (p *ResFriendLog) Validate() error { + return nil +} + +// Attributes: +// - Uid +// - Name +// - Face +// - Avatar +// - Level +// - Decorate +// - Login +// - Loginout +// - Facebook +// - Emoji +// - AddTime +// - Interact +// - Playroom +// - DressSet +// - Friend +// - Last +// - Physiology +// - PetName +// - PetFur +// +type ResFriendPlayerSimple struct { + Uid int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` + Name string `thrift:"Name,2" db:"Name" json:"Name"` + Face int32 `thrift:"Face,3" db:"Face" json:"Face"` + Avatar int32 `thrift:"Avatar,4" db:"Avatar" json:"Avatar"` + Level int32 `thrift:"Level,5" db:"Level" json:"Level"` + Decorate int32 `thrift:"Decorate,6" db:"Decorate" json:"Decorate"` + Login int32 `thrift:"login,7" db:"login" json:"login"` + Loginout int32 `thrift:"loginout,8" db:"loginout" json:"loginout"` + Facebook string `thrift:"Facebook,9" db:"Facebook" json:"Facebook"` + Emoji map[int32]int32 `thrift:"Emoji,10" db:"Emoji" json:"Emoji"` + AddTime int64 `thrift:"AddTime,11" db:"AddTime" json:"AddTime"` + Interact int64 `thrift:"Interact,12" db:"Interact" json:"Interact"` + Playroom map[int32]int32 `thrift:"Playroom,13" db:"Playroom" json:"Playroom"` + DressSet map[int32]int32 `thrift:"DressSet,14" db:"DressSet" json:"DressSet"` + Friend []int32 `thrift:"Friend,15" db:"Friend" json:"Friend"` + Last *ActLog `thrift:"Last,16" db:"Last" json:"Last"` + Physiology map[int32]int32 `thrift:"Physiology,17" db:"Physiology" json:"Physiology"` + PetName string `thrift:"PetName,18" db:"PetName" json:"PetName"` + PetFur int32 `thrift:"PetFur,19" db:"PetFur" json:"PetFur"` +} + +func NewResFriendPlayerSimple() *ResFriendPlayerSimple { + return &ResFriendPlayerSimple{} +} + +func (p *ResFriendPlayerSimple) GetUid() int64 { + return p.Uid +} + +func (p *ResFriendPlayerSimple) GetName() string { + return p.Name +} + +func (p *ResFriendPlayerSimple) GetFace() int32 { + return p.Face +} + +func (p *ResFriendPlayerSimple) GetAvatar() int32 { + return p.Avatar +} + +func (p *ResFriendPlayerSimple) GetLevel() int32 { + return p.Level +} + +func (p *ResFriendPlayerSimple) GetDecorate() int32 { + return p.Decorate +} + +func (p *ResFriendPlayerSimple) GetLogin() int32 { + return p.Login +} + +func (p *ResFriendPlayerSimple) GetLoginout() int32 { + return p.Loginout +} + +func (p *ResFriendPlayerSimple) GetFacebook() string { + return p.Facebook +} + +func (p *ResFriendPlayerSimple) GetEmoji() map[int32]int32 { + return p.Emoji +} + +func (p *ResFriendPlayerSimple) GetAddTime() int64 { + return p.AddTime +} + +func (p *ResFriendPlayerSimple) GetInteract() int64 { + return p.Interact +} + +func (p *ResFriendPlayerSimple) GetPlayroom() map[int32]int32 { + return p.Playroom +} + +func (p *ResFriendPlayerSimple) GetDressSet() map[int32]int32 { + return p.DressSet +} + +func (p *ResFriendPlayerSimple) GetFriend() []int32 { + return p.Friend +} + +var ResFriendPlayerSimple_Last_DEFAULT *ActLog + +func (p *ResFriendPlayerSimple) GetLast() *ActLog { + if !p.IsSetLast() { + return ResFriendPlayerSimple_Last_DEFAULT + } + return p.Last +} + +func (p *ResFriendPlayerSimple) GetPhysiology() map[int32]int32 { + return p.Physiology +} + +func (p *ResFriendPlayerSimple) GetPetName() string { + return p.PetName +} + +func (p *ResFriendPlayerSimple) GetPetFur() int32 { + return p.PetFur +} + +func (p *ResFriendPlayerSimple) IsSetLast() bool { + return p.Last != nil +} + +func (p *ResFriendPlayerSimple) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.I32 { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.I32 { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 8: + if fieldTypeId == thrift.I32 { + if err := p.ReadField8(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 9: + if fieldTypeId == thrift.STRING { + if err := p.ReadField9(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 10: + if fieldTypeId == thrift.MAP { + if err := p.ReadField10(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 11: + if fieldTypeId == thrift.I64 { + if err := p.ReadField11(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 12: + if fieldTypeId == thrift.I64 { + if err := p.ReadField12(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 13: + if fieldTypeId == thrift.MAP { + if err := p.ReadField13(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 14: + if fieldTypeId == thrift.MAP { + if err := p.ReadField14(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 15: + if fieldTypeId == thrift.LIST { + if err := p.ReadField15(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 16: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField16(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 17: + if fieldTypeId == thrift.MAP { + if err := p.ReadField17(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 18: + if fieldTypeId == thrift.STRING { + if err := p.ReadField18(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 19: + if fieldTypeId == thrift.I32 { + if err := p.ReadField19(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFriendPlayerSimple) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ResFriendPlayerSimple) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Name = v + } + return nil +} + +func (p *ResFriendPlayerSimple) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Face = v + } + return nil +} + +func (p *ResFriendPlayerSimple) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Avatar = v + } + return nil +} + +func (p *ResFriendPlayerSimple) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.Level = v + } + return nil +} + +func (p *ResFriendPlayerSimple) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 6: ", err) + } else { + p.Decorate = v + } + return nil +} + +func (p *ResFriendPlayerSimple) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 7: ", err) + } else { + p.Login = v + } + return nil +} + +func (p *ResFriendPlayerSimple) ReadField8(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 8: ", err) + } else { + p.Loginout = v + } + return nil +} + +func (p *ResFriendPlayerSimple) ReadField9(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 9: ", err) + } else { + p.Facebook = v + } + return nil +} + +func (p *ResFriendPlayerSimple) ReadField10(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.Emoji = tMap + for i := 0; i < size; i++ { + var _key239 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key239 = v + } + var _val240 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val240 = v + } + p.Emoji[_key239] = _val240 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResFriendPlayerSimple) ReadField11(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 11: ", err) + } else { + p.AddTime = v + } + return nil +} + +func (p *ResFriendPlayerSimple) ReadField12(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 12: ", err) + } else { + p.Interact = v + } + return nil +} + +func (p *ResFriendPlayerSimple) ReadField13(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.Playroom = tMap + for i := 0; i < size; i++ { + var _key241 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key241 = v + } + var _val242 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val242 = v + } + p.Playroom[_key241] = _val242 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResFriendPlayerSimple) ReadField14(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.DressSet = tMap + for i := 0; i < size; i++ { + var _key243 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key243 = v + } + var _val244 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val244 = v + } + p.DressSet[_key243] = _val244 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResFriendPlayerSimple) ReadField15(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.Friend = tSlice + for i := 0; i < size; i++ { + var _elem245 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem245 = v + } + p.Friend = append(p.Friend, _elem245) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResFriendPlayerSimple) ReadField16(ctx context.Context, iprot thrift.TProtocol) error { + p.Last = &ActLog{} + if err := p.Last.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.Last), err) + } + return nil +} + +func (p *ResFriendPlayerSimple) ReadField17(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.Physiology = tMap + for i := 0; i < size; i++ { + var _key246 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key246 = v + } + var _val247 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val247 = v + } + p.Physiology[_key246] = _val247 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResFriendPlayerSimple) ReadField18(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 18: ", err) + } else { + p.PetName = v + } + return nil +} + +func (p *ResFriendPlayerSimple) ReadField19(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 19: ", err) + } else { + p.PetFur = v + } + return nil +} + +func (p *ResFriendPlayerSimple) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFriendPlayerSimple"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + if err := p.writeField8(ctx, oprot); err != nil { + return err + } + if err := p.writeField9(ctx, oprot); err != nil { + return err + } + if err := p.writeField10(ctx, oprot); err != nil { + return err + } + if err := p.writeField11(ctx, oprot); err != nil { + return err + } + if err := p.writeField12(ctx, oprot); err != nil { + return err + } + if err := p.writeField13(ctx, oprot); err != nil { + return err + } + if err := p.writeField14(ctx, oprot); err != nil { + return err + } + if err := p.writeField15(ctx, oprot); err != nil { + return err + } + if err := p.writeField16(ctx, oprot); err != nil { + return err + } + if err := p.writeField17(ctx, oprot); err != nil { + return err + } + if err := p.writeField18(ctx, oprot); err != nil { + return err + } + if err := p.writeField19(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFriendPlayerSimple) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *ResFriendPlayerSimple) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Name", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Name: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Name)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Name (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Name: ", p), err) + } + return err +} + +func (p *ResFriendPlayerSimple) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Face", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Face: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Face)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Face (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Face: ", p), err) + } + return err +} + +func (p *ResFriendPlayerSimple) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Avatar", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Avatar: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Avatar)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Avatar (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Avatar: ", p), err) + } + return err +} + +func (p *ResFriendPlayerSimple) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Level", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Level: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Level)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Level (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Level: ", p), err) + } + return err +} + +func (p *ResFriendPlayerSimple) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Decorate", thrift.I32, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:Decorate: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Decorate)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Decorate (6) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:Decorate: ", p), err) + } + return err +} + +func (p *ResFriendPlayerSimple) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "login", thrift.I32, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:login: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Login)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.login (7) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:login: ", p), err) + } + return err +} + +func (p *ResFriendPlayerSimple) writeField8(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "loginout", thrift.I32, 8); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 8:loginout: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Loginout)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.loginout (8) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 8:loginout: ", p), err) + } + return err +} + +func (p *ResFriendPlayerSimple) writeField9(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Facebook", thrift.STRING, 9); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 9:Facebook: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Facebook)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Facebook (9) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 9:Facebook: ", p), err) + } + return err +} + +func (p *ResFriendPlayerSimple) writeField10(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Emoji", thrift.MAP, 10); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 10:Emoji: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.Emoji)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Emoji { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 10:Emoji: ", p), err) + } + return err +} + +func (p *ResFriendPlayerSimple) writeField11(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "AddTime", thrift.I64, 11); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 11:AddTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.AddTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.AddTime (11) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 11:AddTime: ", p), err) + } + return err +} + +func (p *ResFriendPlayerSimple) writeField12(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Interact", thrift.I64, 12); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 12:Interact: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Interact)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Interact (12) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 12:Interact: ", p), err) + } + return err +} + +func (p *ResFriendPlayerSimple) writeField13(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Playroom", thrift.MAP, 13); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 13:Playroom: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.Playroom)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Playroom { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 13:Playroom: ", p), err) + } + return err +} + +func (p *ResFriendPlayerSimple) writeField14(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "DressSet", thrift.MAP, 14); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 14:DressSet: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.DressSet)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.DressSet { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 14:DressSet: ", p), err) + } + return err +} + +func (p *ResFriendPlayerSimple) writeField15(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Friend", thrift.LIST, 15); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 15:Friend: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.Friend)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Friend { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 15:Friend: ", p), err) + } + return err +} + +func (p *ResFriendPlayerSimple) writeField16(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Last", thrift.STRUCT, 16); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 16:Last: ", p), err) + } + if err := p.Last.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.Last), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 16:Last: ", p), err) + } + return err +} + +func (p *ResFriendPlayerSimple) writeField17(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Physiology", thrift.MAP, 17); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 17:Physiology: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.Physiology)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Physiology { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 17:Physiology: ", p), err) + } + return err +} + +func (p *ResFriendPlayerSimple) writeField18(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "PetName", thrift.STRING, 18); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 18:PetName: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.PetName)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.PetName (18) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 18:PetName: ", p), err) + } + return err +} + +func (p *ResFriendPlayerSimple) writeField19(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "PetFur", thrift.I32, 19); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 19:PetFur: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.PetFur)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.PetFur (19) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 19:PetFur: ", p), err) + } + return err +} + +func (p *ResFriendPlayerSimple) Equals(other *ResFriendPlayerSimple) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Uid != other.Uid { + return false + } + if p.Name != other.Name { + return false + } + if p.Face != other.Face { + return false + } + if p.Avatar != other.Avatar { + return false + } + if p.Level != other.Level { + return false + } + if p.Decorate != other.Decorate { + return false + } + if p.Login != other.Login { + return false + } + if p.Loginout != other.Loginout { + return false + } + if p.Facebook != other.Facebook { + return false + } + if len(p.Emoji) != len(other.Emoji) { + return false + } + for k, _tgt := range p.Emoji { + _src248 := other.Emoji[k] + if _tgt != _src248 { + return false + } + } + if p.AddTime != other.AddTime { + return false + } + if p.Interact != other.Interact { + return false + } + if len(p.Playroom) != len(other.Playroom) { + return false + } + for k, _tgt := range p.Playroom { + _src249 := other.Playroom[k] + if _tgt != _src249 { + return false + } + } + if len(p.DressSet) != len(other.DressSet) { + return false + } + for k, _tgt := range p.DressSet { + _src250 := other.DressSet[k] + if _tgt != _src250 { + return false + } + } + if len(p.Friend) != len(other.Friend) { + return false + } + for i, _tgt := range p.Friend { + _src251 := other.Friend[i] + if _tgt != _src251 { + return false + } + } + if !p.Last.Equals(other.Last) { + return false + } + if len(p.Physiology) != len(other.Physiology) { + return false + } + for k, _tgt := range p.Physiology { + _src252 := other.Physiology[k] + if _tgt != _src252 { + return false + } + } + if p.PetName != other.PetName { + return false + } + if p.PetFur != other.PetFur { + return false + } + return true +} + +func (p *ResFriendPlayerSimple) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFriendPlayerSimple(%+v)", *p) +} + +func (p *ResFriendPlayerSimple) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFriendPlayerSimple", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFriendPlayerSimple)(nil) + +func (p *ResFriendPlayerSimple) Validate() error { + return nil +} + +// Attributes: +// - List +// +type ResFriendRecommend struct { + List []*ResPlayerSimple `thrift:"List,1" db:"List" json:"List"` +} + +func NewResFriendRecommend() *ResFriendRecommend { + return &ResFriendRecommend{} +} + +func (p *ResFriendRecommend) GetList() []*ResPlayerSimple { + return p.List +} + +func (p *ResFriendRecommend) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFriendRecommend) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ResPlayerSimple, 0, size) + p.List = tSlice + for i := 0; i < size; i++ { + _elem253 := &ResPlayerSimple{} + if err := _elem253.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem253), err) + } + p.List = append(p.List, _elem253) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResFriendRecommend) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFriendRecommend"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFriendRecommend) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "List", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:List: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.List)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.List { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:List: ", p), err) + } + return err +} + +func (p *ResFriendRecommend) Equals(other *ResFriendRecommend) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.List) != len(other.List) { + return false + } + for i, _tgt := range p.List { + _src254 := other.List[i] + if !_tgt.Equals(_src254) { + return false + } + } + return true +} + +func (p *ResFriendRecommend) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFriendRecommend(%+v)", *p) +} + +func (p *ResFriendRecommend) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFriendRecommend", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFriendRecommend)(nil) + +func (p *ResFriendRecommend) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Type +// - Param +// - Status +// - AddTime +// - EndTime +// - Player +// - Items +// +type ResFriendReply struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Type int32 `thrift:"Type,2" db:"Type" json:"Type"` + Param string `thrift:"Param,3" db:"Param" json:"Param"` + Status int32 `thrift:"Status,4" db:"Status" json:"Status"` + AddTime int64 `thrift:"AddTime,5" db:"AddTime" json:"AddTime"` + EndTime int64 `thrift:"EndTime,6" db:"EndTime" json:"EndTime"` + Player *ResPlayerSimple `thrift:"Player,7" db:"Player" json:"Player"` + Items []*ItemInfo `thrift:"Items,8" db:"Items" json:"Items"` +} + +func NewResFriendReply() *ResFriendReply { + return &ResFriendReply{} +} + +func (p *ResFriendReply) GetId() int32 { + return p.Id +} + +func (p *ResFriendReply) GetType() int32 { + return p.Type +} + +func (p *ResFriendReply) GetParam() string { + return p.Param +} + +func (p *ResFriendReply) GetStatus() int32 { + return p.Status +} + +func (p *ResFriendReply) GetAddTime() int64 { + return p.AddTime +} + +func (p *ResFriendReply) GetEndTime() int64 { + return p.EndTime +} + +var ResFriendReply_Player_DEFAULT *ResPlayerSimple + +func (p *ResFriendReply) GetPlayer() *ResPlayerSimple { + if !p.IsSetPlayer() { + return ResFriendReply_Player_DEFAULT + } + return p.Player +} + +func (p *ResFriendReply) GetItems() []*ItemInfo { + return p.Items +} + +func (p *ResFriendReply) IsSetPlayer() bool { + return p.Player != nil +} + +func (p *ResFriendReply) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.STRING { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I64 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.I64 { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 8: + if fieldTypeId == thrift.LIST { + if err := p.ReadField8(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFriendReply) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResFriendReply) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ResFriendReply) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Param = v + } + return nil +} + +func (p *ResFriendReply) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Status = v + } + return nil +} + +func (p *ResFriendReply) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.AddTime = v + } + return nil +} + +func (p *ResFriendReply) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 6: ", err) + } else { + p.EndTime = v + } + return nil +} + +func (p *ResFriendReply) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + p.Player = &ResPlayerSimple{} + if err := p.Player.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.Player), err) + } + return nil +} + +func (p *ResFriendReply) ReadField8(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ItemInfo, 0, size) + p.Items = tSlice + for i := 0; i < size; i++ { + _elem255 := &ItemInfo{} + if err := _elem255.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem255), err) + } + p.Items = append(p.Items, _elem255) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResFriendReply) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFriendReply"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + if err := p.writeField8(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFriendReply) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ResFriendReply) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Type: ", p), err) + } + return err +} + +func (p *ResFriendReply) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Param", thrift.STRING, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Param: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Param)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Param (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Param: ", p), err) + } + return err +} + +func (p *ResFriendReply) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Status", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Status: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Status)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Status (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Status: ", p), err) + } + return err +} + +func (p *ResFriendReply) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "AddTime", thrift.I64, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:AddTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.AddTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.AddTime (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:AddTime: ", p), err) + } + return err +} + +func (p *ResFriendReply) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EndTime", thrift.I64, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:EndTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.EndTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EndTime (6) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:EndTime: ", p), err) + } + return err +} + +func (p *ResFriendReply) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Player", thrift.STRUCT, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:Player: ", p), err) + } + if err := p.Player.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.Player), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:Player: ", p), err) + } + return err +} + +func (p *ResFriendReply) writeField8(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Items", thrift.LIST, 8); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 8:Items: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Items)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Items { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 8:Items: ", p), err) + } + return err +} + +func (p *ResFriendReply) Equals(other *ResFriendReply) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Type != other.Type { + return false + } + if p.Param != other.Param { + return false + } + if p.Status != other.Status { + return false + } + if p.AddTime != other.AddTime { + return false + } + if p.EndTime != other.EndTime { + return false + } + if !p.Player.Equals(other.Player) { + return false + } + if len(p.Items) != len(other.Items) { + return false + } + for i, _tgt := range p.Items { + _src256 := other.Items[i] + if !_tgt.Equals(_src256) { + return false + } + } + return true +} + +func (p *ResFriendReply) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFriendReply(%+v)", *p) +} + +func (p *ResFriendReply) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFriendReply", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFriendReply)(nil) + +func (p *ResFriendReply) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - LogId +// - Type +// - ErrType +// +type ResFriendReplyHandle struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + LogId int32 `thrift:"LogId,3" db:"LogId" json:"LogId"` + Type int32 `thrift:"Type,4" db:"Type" json:"Type"` + ErrType FRIEND_REPLY_HANDLE_ERR_TYPE `thrift:"ErrType,5" db:"ErrType" json:"ErrType"` +} + +func NewResFriendReplyHandle() *ResFriendReplyHandle { + return &ResFriendReplyHandle{} +} + +func (p *ResFriendReplyHandle) GetCode() RES_CODE { + return p.Code +} + +func (p *ResFriendReplyHandle) GetMsg() string { + return p.Msg +} + +func (p *ResFriendReplyHandle) GetLogId() int32 { + return p.LogId +} + +func (p *ResFriendReplyHandle) GetType() int32 { + return p.Type +} + +func (p *ResFriendReplyHandle) GetErrType() FRIEND_REPLY_HANDLE_ERR_TYPE { + return p.ErrType +} + +func (p *ResFriendReplyHandle) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFriendReplyHandle) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResFriendReplyHandle) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResFriendReplyHandle) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.LogId = v + } + return nil +} + +func (p *ResFriendReplyHandle) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ResFriendReplyHandle) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + temp := FRIEND_REPLY_HANDLE_ERR_TYPE(v) + p.ErrType = temp + } + return nil +} + +func (p *ResFriendReplyHandle) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFriendReplyHandle"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFriendReplyHandle) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResFriendReplyHandle) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResFriendReplyHandle) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "LogId", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:LogId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.LogId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.LogId (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:LogId: ", p), err) + } + return err +} + +func (p *ResFriendReplyHandle) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Type: ", p), err) + } + return err +} + +func (p *ResFriendReplyHandle) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ErrType", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:ErrType: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ErrType)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ErrType (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:ErrType: ", p), err) + } + return err +} + +func (p *ResFriendReplyHandle) Equals(other *ResFriendReplyHandle) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.LogId != other.LogId { + return false + } + if p.Type != other.Type { + return false + } + if p.ErrType != other.ErrType { + return false + } + return true +} + +func (p *ResFriendReplyHandle) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFriendReplyHandle(%+v)", *p) +} + +func (p *ResFriendReplyHandle) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFriendReplyHandle", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFriendReplyHandle)(nil) + +func (p *ResFriendReplyHandle) Validate() error { + return nil +} + +// Attributes: +// - Info +// - Type +// - Time +// +type ResFriendReplyNotify struct { + Info *ResFriendReply `thrift:"info,1" db:"info" json:"info"` + Type int32 `thrift:"Type,2" db:"Type" json:"Type"` + Time int32 `thrift:"Time,3" db:"Time" json:"Time"` +} + +func NewResFriendReplyNotify() *ResFriendReplyNotify { + return &ResFriendReplyNotify{} +} + +var ResFriendReplyNotify_Info_DEFAULT *ResFriendReply + +func (p *ResFriendReplyNotify) GetInfo() *ResFriendReply { + if !p.IsSetInfo() { + return ResFriendReplyNotify_Info_DEFAULT + } + return p.Info +} + +func (p *ResFriendReplyNotify) GetType() int32 { + return p.Type +} + +func (p *ResFriendReplyNotify) GetTime() int32 { + return p.Time +} + +func (p *ResFriendReplyNotify) IsSetInfo() bool { + return p.Info != nil +} + +func (p *ResFriendReplyNotify) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFriendReplyNotify) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + p.Info = &ResFriendReply{} + if err := p.Info.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.Info), err) + } + return nil +} + +func (p *ResFriendReplyNotify) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ResFriendReplyNotify) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Time = v + } + return nil +} + +func (p *ResFriendReplyNotify) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFriendReplyNotify"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFriendReplyNotify) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "info", thrift.STRUCT, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:info: ", p), err) + } + if err := p.Info.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.Info), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:info: ", p), err) + } + return err +} + +func (p *ResFriendReplyNotify) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Type: ", p), err) + } + return err +} + +func (p *ResFriendReplyNotify) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Time", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Time: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Time)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Time (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Time: ", p), err) + } + return err +} + +func (p *ResFriendReplyNotify) Equals(other *ResFriendReplyNotify) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if !p.Info.Equals(other.Info) { + return false + } + if p.Type != other.Type { + return false + } + if p.Time != other.Time { + return false + } + return true +} + +func (p *ResFriendReplyNotify) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFriendReplyNotify(%+v)", *p) +} + +func (p *ResFriendReplyNotify) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFriendReplyNotify", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFriendReplyNotify)(nil) + +func (p *ResFriendReplyNotify) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Id +// +type ResFriendTLUpvote struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Id int32 `thrift:"Id,3" db:"Id" json:"Id"` +} + +func NewResFriendTLUpvote() *ResFriendTLUpvote { + return &ResFriendTLUpvote{} +} + +func (p *ResFriendTLUpvote) GetCode() RES_CODE { + return p.Code +} + +func (p *ResFriendTLUpvote) GetMsg() string { + return p.Msg +} + +func (p *ResFriendTLUpvote) GetId() int32 { + return p.Id +} + +func (p *ResFriendTLUpvote) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFriendTLUpvote) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResFriendTLUpvote) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResFriendTLUpvote) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResFriendTLUpvote) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFriendTLUpvote"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFriendTLUpvote) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResFriendTLUpvote) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResFriendTLUpvote) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Id: ", p), err) + } + return err +} + +func (p *ResFriendTLUpvote) Equals(other *ResFriendTLUpvote) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ResFriendTLUpvote) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFriendTLUpvote(%+v)", *p) +} + +func (p *ResFriendTLUpvote) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFriendTLUpvote", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFriendTLUpvote)(nil) + +func (p *ResFriendTLUpvote) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Id +// +type ResFriendTReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Id int32 `thrift:"Id,3" db:"Id" json:"Id"` +} + +func NewResFriendTReward() *ResFriendTReward { + return &ResFriendTReward{} +} + +func (p *ResFriendTReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResFriendTReward) GetMsg() string { + return p.Msg +} + +func (p *ResFriendTReward) GetId() int32 { + return p.Id +} + +func (p *ResFriendTReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFriendTReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResFriendTReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResFriendTReward) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResFriendTReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFriendTReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFriendTReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResFriendTReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResFriendTReward) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Id: ", p), err) + } + return err +} + +func (p *ResFriendTReward) Equals(other *ResFriendTReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ResFriendTReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFriendTReward(%+v)", *p) +} + +func (p *ResFriendTReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFriendTReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFriendTReward)(nil) + +func (p *ResFriendTReward) Validate() error { + return nil +} + +// Attributes: +// - Log +// - Reply +// +type ResFriendTimeLine struct { + Log []*ResFriendLog `thrift:"Log,1" db:"Log" json:"Log"` + Reply []*ResFriendReply `thrift:"Reply,2" db:"Reply" json:"Reply"` +} + +func NewResFriendTimeLine() *ResFriendTimeLine { + return &ResFriendTimeLine{} +} + +func (p *ResFriendTimeLine) GetLog() []*ResFriendLog { + return p.Log +} + +func (p *ResFriendTimeLine) GetReply() []*ResFriendReply { + return p.Reply +} + +func (p *ResFriendTimeLine) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.LIST { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFriendTimeLine) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ResFriendLog, 0, size) + p.Log = tSlice + for i := 0; i < size; i++ { + _elem257 := &ResFriendLog{} + if err := _elem257.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem257), err) + } + p.Log = append(p.Log, _elem257) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResFriendTimeLine) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ResFriendReply, 0, size) + p.Reply = tSlice + for i := 0; i < size; i++ { + _elem258 := &ResFriendReply{} + if err := _elem258.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem258), err) + } + p.Reply = append(p.Reply, _elem258) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResFriendTimeLine) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFriendTimeLine"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFriendTimeLine) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Log", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Log: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Log)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Log { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Log: ", p), err) + } + return err +} + +func (p *ResFriendTimeLine) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Reply", thrift.LIST, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Reply: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Reply)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Reply { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Reply: ", p), err) + } + return err +} + +func (p *ResFriendTimeLine) Equals(other *ResFriendTimeLine) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.Log) != len(other.Log) { + return false + } + for i, _tgt := range p.Log { + _src259 := other.Log[i] + if !_tgt.Equals(_src259) { + return false + } + } + if len(p.Reply) != len(other.Reply) { + return false + } + for i, _tgt := range p.Reply { + _src260 := other.Reply[i] + if !_tgt.Equals(_src260) { + return false + } + } + return true +} + +func (p *ResFriendTimeLine) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFriendTimeLine(%+v)", *p) +} + +func (p *ResFriendTimeLine) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFriendTimeLine", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFriendTimeLine)(nil) + +func (p *ResFriendTimeLine) Validate() error { + return nil +} + +// Attributes: +// - Status +// - Star +// - Shift +// - List +// - List2 +// - Uids +// +type ResFriendTreasure struct { + Status int32 `thrift:"Status,1" db:"Status" json:"Status"` + Star int32 `thrift:"Star,2" db:"Star" json:"Star"` + Shift int32 `thrift:"Shift,3" db:"Shift" json:"Shift"` + List []*TreasureInfo `thrift:"List,4" db:"List" json:"List"` + List2 []int32 `thrift:"List2,5" db:"List2" json:"List2"` + Uids []int64 `thrift:"Uids,6" db:"Uids" json:"Uids"` +} + +func NewResFriendTreasure() *ResFriendTreasure { + return &ResFriendTreasure{} +} + +func (p *ResFriendTreasure) GetStatus() int32 { + return p.Status +} + +func (p *ResFriendTreasure) GetStar() int32 { + return p.Star +} + +func (p *ResFriendTreasure) GetShift() int32 { + return p.Shift +} + +func (p *ResFriendTreasure) GetList() []*TreasureInfo { + return p.List +} + +func (p *ResFriendTreasure) GetList2() []int32 { + return p.List2 +} + +func (p *ResFriendTreasure) GetUids() []int64 { + return p.Uids +} + +func (p *ResFriendTreasure) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.LIST { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.LIST { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.LIST { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFriendTreasure) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Status = v + } + return nil +} + +func (p *ResFriendTreasure) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Star = v + } + return nil +} + +func (p *ResFriendTreasure) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Shift = v + } + return nil +} + +func (p *ResFriendTreasure) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*TreasureInfo, 0, size) + p.List = tSlice + for i := 0; i < size; i++ { + _elem261 := &TreasureInfo{} + if err := _elem261.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem261), err) + } + p.List = append(p.List, _elem261) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResFriendTreasure) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.List2 = tSlice + for i := 0; i < size; i++ { + var _elem262 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem262 = v + } + p.List2 = append(p.List2, _elem262) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResFriendTreasure) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int64, 0, size) + p.Uids = tSlice + for i := 0; i < size; i++ { + var _elem263 int64 + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem263 = v + } + p.Uids = append(p.Uids, _elem263) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResFriendTreasure) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFriendTreasure"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFriendTreasure) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Status", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Status: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Status)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Status (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Status: ", p), err) + } + return err +} + +func (p *ResFriendTreasure) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Star", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Star: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Star)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Star (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Star: ", p), err) + } + return err +} + +func (p *ResFriendTreasure) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Shift", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Shift: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Shift)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Shift (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Shift: ", p), err) + } + return err +} + +func (p *ResFriendTreasure) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "List", thrift.LIST, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:List: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.List)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.List { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:List: ", p), err) + } + return err +} + +func (p *ResFriendTreasure) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "List2", thrift.LIST, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:List2: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.List2)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.List2 { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:List2: ", p), err) + } + return err +} + +func (p *ResFriendTreasure) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uids", thrift.LIST, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:Uids: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I64, len(p.Uids)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Uids { + if err := oprot.WriteI64(ctx, int64(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:Uids: ", p), err) + } + return err +} + +func (p *ResFriendTreasure) Equals(other *ResFriendTreasure) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Status != other.Status { + return false + } + if p.Star != other.Star { + return false + } + if p.Shift != other.Shift { + return false + } + if len(p.List) != len(other.List) { + return false + } + for i, _tgt := range p.List { + _src264 := other.List[i] + if !_tgt.Equals(_src264) { + return false + } + } + if len(p.List2) != len(other.List2) { + return false + } + for i, _tgt := range p.List2 { + _src265 := other.List2[i] + if _tgt != _src265 { + return false + } + } + if len(p.Uids) != len(other.Uids) { + return false + } + for i, _tgt := range p.Uids { + _src266 := other.Uids[i] + if _tgt != _src266 { + return false + } + } + return true +} + +func (p *ResFriendTreasure) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFriendTreasure(%+v)", *p) +} + +func (p *ResFriendTreasure) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFriendTreasure", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFriendTreasure)(nil) + +func (p *ResFriendTreasure) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResFriendTreasureEnd struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResFriendTreasureEnd() *ResFriendTreasureEnd { + return &ResFriendTreasureEnd{} +} + +func (p *ResFriendTreasureEnd) GetCode() RES_CODE { + return p.Code +} + +func (p *ResFriendTreasureEnd) GetMsg() string { + return p.Msg +} + +func (p *ResFriendTreasureEnd) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFriendTreasureEnd) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResFriendTreasureEnd) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResFriendTreasureEnd) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFriendTreasureEnd"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFriendTreasureEnd) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResFriendTreasureEnd) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResFriendTreasureEnd) Equals(other *ResFriendTreasureEnd) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResFriendTreasureEnd) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFriendTreasureEnd(%+v)", *p) +} + +func (p *ResFriendTreasureEnd) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFriendTreasureEnd", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFriendTreasureEnd)(nil) + +func (p *ResFriendTreasureEnd) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResFriendTreasureFilp struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResFriendTreasureFilp() *ResFriendTreasureFilp { + return &ResFriendTreasureFilp{} +} + +func (p *ResFriendTreasureFilp) GetCode() RES_CODE { + return p.Code +} + +func (p *ResFriendTreasureFilp) GetMsg() string { + return p.Msg +} + +func (p *ResFriendTreasureFilp) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFriendTreasureFilp) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResFriendTreasureFilp) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResFriendTreasureFilp) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFriendTreasureFilp"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFriendTreasureFilp) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResFriendTreasureFilp) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResFriendTreasureFilp) Equals(other *ResFriendTreasureFilp) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResFriendTreasureFilp) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFriendTreasureFilp(%+v)", *p) +} + +func (p *ResFriendTreasureFilp) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFriendTreasureFilp", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFriendTreasureFilp)(nil) + +func (p *ResFriendTreasureFilp) Validate() error { + return nil +} + +// Attributes: +// - Star +// +type ResFriendTreasureStar struct { + Star int32 `thrift:"Star,1" db:"Star" json:"Star"` +} + +func NewResFriendTreasureStar() *ResFriendTreasureStar { + return &ResFriendTreasureStar{} +} + +func (p *ResFriendTreasureStar) GetStar() int32 { + return p.Star +} + +func (p *ResFriendTreasureStar) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFriendTreasureStar) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Star = v + } + return nil +} + +func (p *ResFriendTreasureStar) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFriendTreasureStar"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFriendTreasureStar) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Star", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Star: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Star)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Star (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Star: ", p), err) + } + return err +} + +func (p *ResFriendTreasureStar) Equals(other *ResFriendTreasureStar) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Star != other.Star { + return false + } + return true +} + +func (p *ResFriendTreasureStar) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFriendTreasureStar(%+v)", *p) +} + +func (p *ResFriendTreasureStar) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFriendTreasureStar", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFriendTreasureStar)(nil) + +func (p *ResFriendTreasureStar) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResFriendTreasureStart struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResFriendTreasureStart() *ResFriendTreasureStart { + return &ResFriendTreasureStart{} +} + +func (p *ResFriendTreasureStart) GetCode() RES_CODE { + return p.Code +} + +func (p *ResFriendTreasureStart) GetMsg() string { + return p.Msg +} + +func (p *ResFriendTreasureStart) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFriendTreasureStart) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResFriendTreasureStart) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResFriendTreasureStart) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFriendTreasureStart"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFriendTreasureStart) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResFriendTreasureStart) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResFriendTreasureStart) Equals(other *ResFriendTreasureStart) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResFriendTreasureStart) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFriendTreasureStart(%+v)", *p) +} + +func (p *ResFriendTreasureStart) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFriendTreasureStart", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFriendTreasureStart)(nil) + +func (p *ResFriendTreasureStart) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResFurSet struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResFurSet() *ResFurSet { + return &ResFurSet{} +} + +func (p *ResFurSet) GetCode() RES_CODE { + return p.Code +} + +func (p *ResFurSet) GetMsg() string { + return p.Msg +} + +func (p *ResFurSet) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResFurSet) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResFurSet) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResFurSet) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResFurSet"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResFurSet) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResFurSet) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResFurSet) Equals(other *ResFurSet) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResFurSet) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResFurSet(%+v)", *p) +} + +func (p *ResFurSet) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResFurSet", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResFurSet)(nil) + +func (p *ResFurSet) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResGetChessFromBuff struct { + Code RES_CODE `thrift:"code,1" db:"code" json:"code"` + Msg string `thrift:"msg,2" db:"msg" json:"msg"` +} + +func NewResGetChessFromBuff() *ResGetChessFromBuff { + return &ResGetChessFromBuff{} +} + +func (p *ResGetChessFromBuff) GetCode() RES_CODE { + return p.Code +} + +func (p *ResGetChessFromBuff) GetMsg() string { + return p.Msg +} + +func (p *ResGetChessFromBuff) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResGetChessFromBuff) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResGetChessFromBuff) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResGetChessFromBuff) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResGetChessFromBuff"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResGetChessFromBuff) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:code: ", p), err) + } + return err +} + +func (p *ResGetChessFromBuff) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:msg: ", p), err) + } + return err +} + +func (p *ResGetChessFromBuff) Equals(other *ResGetChessFromBuff) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResGetChessFromBuff) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResGetChessFromBuff(%+v)", *p) +} + +func (p *ResGetChessFromBuff) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResGetChessFromBuff", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResGetChessFromBuff)(nil) + +func (p *ResGetChessFromBuff) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Id +// +type ResGetChessRetireReward struct { + Code RES_CODE `thrift:"code,1" db:"code" json:"code"` + Msg string `thrift:"msg,2" db:"msg" json:"msg"` + Id string `thrift:"Id,3" db:"Id" json:"Id"` +} + +func NewResGetChessRetireReward() *ResGetChessRetireReward { + return &ResGetChessRetireReward{} +} + +func (p *ResGetChessRetireReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResGetChessRetireReward) GetMsg() string { + return p.Msg +} + +func (p *ResGetChessRetireReward) GetId() string { + return p.Id +} + +func (p *ResGetChessRetireReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.STRING { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResGetChessRetireReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResGetChessRetireReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResGetChessRetireReward) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResGetChessRetireReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResGetChessRetireReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResGetChessRetireReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:code: ", p), err) + } + return err +} + +func (p *ResGetChessRetireReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:msg: ", p), err) + } + return err +} + +func (p *ResGetChessRetireReward) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.STRING, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Id: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Id: ", p), err) + } + return err +} + +func (p *ResGetChessRetireReward) Equals(other *ResGetChessRetireReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ResGetChessRetireReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResGetChessRetireReward(%+v)", *p) +} + +func (p *ResGetChessRetireReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResGetChessRetireReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResGetChessRetireReward)(nil) + +func (p *ResGetChessRetireReward) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResGetDailyTaskReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResGetDailyTaskReward() *ResGetDailyTaskReward { + return &ResGetDailyTaskReward{} +} + +func (p *ResGetDailyTaskReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResGetDailyTaskReward) GetMsg() string { + return p.Msg +} + +func (p *ResGetDailyTaskReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResGetDailyTaskReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResGetDailyTaskReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResGetDailyTaskReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResGetDailyTaskReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResGetDailyTaskReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResGetDailyTaskReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResGetDailyTaskReward) Equals(other *ResGetDailyTaskReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResGetDailyTaskReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResGetDailyTaskReward(%+v)", *p) +} + +func (p *ResGetDailyTaskReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResGetDailyTaskReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResGetDailyTaskReward)(nil) + +func (p *ResGetDailyTaskReward) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResGetDailyWeekReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResGetDailyWeekReward() *ResGetDailyWeekReward { + return &ResGetDailyWeekReward{} +} + +func (p *ResGetDailyWeekReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResGetDailyWeekReward) GetMsg() string { + return p.Msg +} + +func (p *ResGetDailyWeekReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResGetDailyWeekReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResGetDailyWeekReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResGetDailyWeekReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResGetDailyWeekReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResGetDailyWeekReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResGetDailyWeekReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResGetDailyWeekReward) Equals(other *ResGetDailyWeekReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResGetDailyWeekReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResGetDailyWeekReward(%+v)", *p) +} + +func (p *ResGetDailyWeekReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResGetDailyWeekReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResGetDailyWeekReward)(nil) + +func (p *ResGetDailyWeekReward) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResGetEnergyByAD struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResGetEnergyByAD() *ResGetEnergyByAD { + return &ResGetEnergyByAD{} +} + +func (p *ResGetEnergyByAD) GetCode() RES_CODE { + return p.Code +} + +func (p *ResGetEnergyByAD) GetMsg() string { + return p.Msg +} + +func (p *ResGetEnergyByAD) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResGetEnergyByAD) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResGetEnergyByAD) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResGetEnergyByAD) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResGetEnergyByAD"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResGetEnergyByAD) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResGetEnergyByAD) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResGetEnergyByAD) Equals(other *ResGetEnergyByAD) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResGetEnergyByAD) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResGetEnergyByAD(%+v)", *p) +} + +func (p *ResGetEnergyByAD) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResGetEnergyByAD", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResGetEnergyByAD)(nil) + +func (p *ResGetEnergyByAD) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Id +// - CardId +// - Emoji +// +type ResGetFriendCard struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Id string `thrift:"Id,3" db:"Id" json:"Id"` + CardId int32 `thrift:"CardId,4" db:"CardId" json:"CardId"` + Emoji int32 `thrift:"Emoji,5" db:"Emoji" json:"Emoji"` +} + +func NewResGetFriendCard() *ResGetFriendCard { + return &ResGetFriendCard{} +} + +func (p *ResGetFriendCard) GetCode() RES_CODE { + return p.Code +} + +func (p *ResGetFriendCard) GetMsg() string { + return p.Msg +} + +func (p *ResGetFriendCard) GetId() string { + return p.Id +} + +func (p *ResGetFriendCard) GetCardId() int32 { + return p.CardId +} + +func (p *ResGetFriendCard) GetEmoji() int32 { + return p.Emoji +} + +func (p *ResGetFriendCard) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.STRING { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResGetFriendCard) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResGetFriendCard) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResGetFriendCard) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResGetFriendCard) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.CardId = v + } + return nil +} + +func (p *ResGetFriendCard) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.Emoji = v + } + return nil +} + +func (p *ResGetFriendCard) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResGetFriendCard"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResGetFriendCard) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResGetFriendCard) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResGetFriendCard) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.STRING, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Id: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Id: ", p), err) + } + return err +} + +func (p *ResGetFriendCard) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "CardId", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:CardId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.CardId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.CardId (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:CardId: ", p), err) + } + return err +} + +func (p *ResGetFriendCard) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Emoji", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Emoji: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Emoji)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Emoji (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Emoji: ", p), err) + } + return err +} + +func (p *ResGetFriendCard) Equals(other *ResGetFriendCard) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Id != other.Id { + return false + } + if p.CardId != other.CardId { + return false + } + if p.Emoji != other.Emoji { + return false + } + return true +} + +func (p *ResGetFriendCard) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResGetFriendCard(%+v)", *p) +} + +func (p *ResGetFriendCard) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResGetFriendCard", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResGetFriendCard)(nil) + +func (p *ResGetFriendCard) Validate() error { + return nil +} + +// Attributes: +// - Four +// - Five +// +type ResGetGoldCard struct { + Four int32 `thrift:"Four,1" db:"Four" json:"Four"` + Five int32 `thrift:"Five,2" db:"Five" json:"Five"` +} + +func NewResGetGoldCard() *ResGetGoldCard { + return &ResGetGoldCard{} +} + +func (p *ResGetGoldCard) GetFour() int32 { + return p.Four +} + +func (p *ResGetGoldCard) GetFive() int32 { + return p.Five +} + +func (p *ResGetGoldCard) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResGetGoldCard) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Four = v + } + return nil +} + +func (p *ResGetGoldCard) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Five = v + } + return nil +} + +func (p *ResGetGoldCard) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResGetGoldCard"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResGetGoldCard) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Four", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Four: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Four)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Four (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Four: ", p), err) + } + return err +} + +func (p *ResGetGoldCard) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Five", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Five: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Five)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Five (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Five: ", p), err) + } + return err +} + +func (p *ResGetGoldCard) Equals(other *ResGetGoldCard) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Four != other.Four { + return false + } + if p.Five != other.Five { + return false + } + return true +} + +func (p *ResGetGoldCard) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResGetGoldCard(%+v)", *p) +} + +func (p *ResGetGoldCard) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResGetGoldCard", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResGetGoldCard)(nil) + +func (p *ResGetGoldCard) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Id +// +type ResGetGuideActiveReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Id int32 `thrift:"Id,3" db:"Id" json:"Id"` +} + +func NewResGetGuideActiveReward() *ResGetGuideActiveReward { + return &ResGetGuideActiveReward{} +} + +func (p *ResGetGuideActiveReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResGetGuideActiveReward) GetMsg() string { + return p.Msg +} + +func (p *ResGetGuideActiveReward) GetId() int32 { + return p.Id +} + +func (p *ResGetGuideActiveReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResGetGuideActiveReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResGetGuideActiveReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResGetGuideActiveReward) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResGetGuideActiveReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResGetGuideActiveReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResGetGuideActiveReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResGetGuideActiveReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResGetGuideActiveReward) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Id: ", p), err) + } + return err +} + +func (p *ResGetGuideActiveReward) Equals(other *ResGetGuideActiveReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ResGetGuideActiveReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResGetGuideActiveReward(%+v)", *p) +} + +func (p *ResGetGuideActiveReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResGetGuideActiveReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResGetGuideActiveReward)(nil) + +func (p *ResGetGuideActiveReward) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Id +// +type ResGetGuideTaskReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Id int32 `thrift:"Id,3" db:"Id" json:"Id"` +} + +func NewResGetGuideTaskReward() *ResGetGuideTaskReward { + return &ResGetGuideTaskReward{} +} + +func (p *ResGetGuideTaskReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResGetGuideTaskReward) GetMsg() string { + return p.Msg +} + +func (p *ResGetGuideTaskReward) GetId() int32 { + return p.Id +} + +func (p *ResGetGuideTaskReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResGetGuideTaskReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResGetGuideTaskReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResGetGuideTaskReward) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResGetGuideTaskReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResGetGuideTaskReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResGetGuideTaskReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResGetGuideTaskReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResGetGuideTaskReward) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Id: ", p), err) + } + return err +} + +func (p *ResGetGuideTaskReward) Equals(other *ResGetGuideTaskReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ResGetGuideTaskReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResGetGuideTaskReward(%+v)", *p) +} + +func (p *ResGetGuideTaskReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResGetGuideTaskReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResGetGuideTaskReward)(nil) + +func (p *ResGetGuideTaskReward) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResGetHandbookReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResGetHandbookReward() *ResGetHandbookReward { + return &ResGetHandbookReward{} +} + +func (p *ResGetHandbookReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResGetHandbookReward) GetMsg() string { + return p.Msg +} + +func (p *ResGetHandbookReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResGetHandbookReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResGetHandbookReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResGetHandbookReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResGetHandbookReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResGetHandbookReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResGetHandbookReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResGetHandbookReward) Equals(other *ResGetHandbookReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResGetHandbookReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResGetHandbookReward(%+v)", *p) +} + +func (p *ResGetHandbookReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResGetHandbookReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResGetHandbookReward)(nil) + +func (p *ResGetHandbookReward) Validate() error { + return nil +} + +// Attributes: +// - ResultCode +// +type ResGetInviteReward struct { + ResultCode int32 `thrift:"ResultCode,1" db:"ResultCode" json:"ResultCode"` +} + +func NewResGetInviteReward() *ResGetInviteReward { + return &ResGetInviteReward{} +} + +func (p *ResGetInviteReward) GetResultCode() int32 { + return p.ResultCode +} + +func (p *ResGetInviteReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResGetInviteReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.ResultCode = v + } + return nil +} + +func (p *ResGetInviteReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResGetInviteReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResGetInviteReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ResultCode", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ResultCode: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ResultCode)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ResultCode (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ResultCode: ", p), err) + } + return err +} + +func (p *ResGetInviteReward) Equals(other *ResGetInviteReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ResultCode != other.ResultCode { + return false + } + return true +} + +func (p *ResGetInviteReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResGetInviteReward(%+v)", *p) +} + +func (p *ResGetInviteReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResGetInviteReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResGetInviteReward)(nil) + +func (p *ResGetInviteReward) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Id +// +type ResGetMailReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Id int32 `thrift:"Id,3" db:"Id" json:"Id"` +} + +func NewResGetMailReward() *ResGetMailReward { + return &ResGetMailReward{} +} + +func (p *ResGetMailReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResGetMailReward) GetMsg() string { + return p.Msg +} + +func (p *ResGetMailReward) GetId() int32 { + return p.Id +} + +func (p *ResGetMailReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResGetMailReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResGetMailReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResGetMailReward) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResGetMailReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResGetMailReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResGetMailReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResGetMailReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResGetMailReward) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Id: ", p), err) + } + return err +} + +func (p *ResGetMailReward) Equals(other *ResGetMailReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ResGetMailReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResGetMailReward(%+v)", *p) +} + +func (p *ResGetMailReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResGetMailReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResGetMailReward)(nil) + +func (p *ResGetMailReward) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResGetMonthLoginReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResGetMonthLoginReward() *ResGetMonthLoginReward { + return &ResGetMonthLoginReward{} +} + +func (p *ResGetMonthLoginReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResGetMonthLoginReward) GetMsg() string { + return p.Msg +} + +func (p *ResGetMonthLoginReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResGetMonthLoginReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResGetMonthLoginReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResGetMonthLoginReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResGetMonthLoginReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResGetMonthLoginReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResGetMonthLoginReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResGetMonthLoginReward) Equals(other *ResGetMonthLoginReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResGetMonthLoginReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResGetMonthLoginReward(%+v)", *p) +} + +func (p *ResGetMonthLoginReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResGetMonthLoginReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResGetMonthLoginReward)(nil) + +func (p *ResGetMonthLoginReward) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResGetSevenLoginReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResGetSevenLoginReward() *ResGetSevenLoginReward { + return &ResGetSevenLoginReward{} +} + +func (p *ResGetSevenLoginReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResGetSevenLoginReward) GetMsg() string { + return p.Msg +} + +func (p *ResGetSevenLoginReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResGetSevenLoginReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResGetSevenLoginReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResGetSevenLoginReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResGetSevenLoginReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResGetSevenLoginReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResGetSevenLoginReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResGetSevenLoginReward) Equals(other *ResGetSevenLoginReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResGetSevenLoginReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResGetSevenLoginReward(%+v)", *p) +} + +func (p *ResGetSevenLoginReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResGetSevenLoginReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResGetSevenLoginReward)(nil) + +func (p *ResGetSevenLoginReward) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResGetWish struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResGetWish() *ResGetWish { + return &ResGetWish{} +} + +func (p *ResGetWish) GetCode() RES_CODE { + return p.Code +} + +func (p *ResGetWish) GetMsg() string { + return p.Msg +} + +func (p *ResGetWish) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResGetWish) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResGetWish) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResGetWish) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResGetWish"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResGetWish) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResGetWish) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResGetWish) Equals(other *ResGetWish) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResGetWish) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResGetWish(%+v)", *p) +} + +func (p *ResGetWish) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResGetWish", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResGetWish)(nil) + +func (p *ResGetWish) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Status +// - EndTime +// - Template +// - Pass +// - MapList +// - OMap +// - WinTime +// - Opponent +// +type ResGuessColor struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Status int32 `thrift:"Status,2" db:"Status" json:"Status"` + EndTime int32 `thrift:"EndTime,3" db:"EndTime" json:"EndTime"` + Template int32 `thrift:"Template,4" db:"Template" json:"Template"` + Pass int32 `thrift:"Pass,5" db:"Pass" json:"Pass"` + MapList []*GuessColorInfo `thrift:"MapList,6" db:"MapList" json:"MapList"` + OMap map[int32]int32 `thrift:"OMap,7" db:"OMap" json:"OMap"` + WinTime int32 `thrift:"WinTime,8" db:"WinTime" json:"WinTime"` + Opponent *Opponent `thrift:"Opponent,9" db:"Opponent" json:"Opponent"` +} + +func NewResGuessColor() *ResGuessColor { + return &ResGuessColor{} +} + +func (p *ResGuessColor) GetId() int32 { + return p.Id +} + +func (p *ResGuessColor) GetStatus() int32 { + return p.Status +} + +func (p *ResGuessColor) GetEndTime() int32 { + return p.EndTime +} + +func (p *ResGuessColor) GetTemplate() int32 { + return p.Template +} + +func (p *ResGuessColor) GetPass() int32 { + return p.Pass +} + +func (p *ResGuessColor) GetMapList() []*GuessColorInfo { + return p.MapList +} + +func (p *ResGuessColor) GetOMap() map[int32]int32 { + return p.OMap +} + +func (p *ResGuessColor) GetWinTime() int32 { + return p.WinTime +} + +var ResGuessColor_Opponent_DEFAULT *Opponent + +func (p *ResGuessColor) GetOpponent() *Opponent { + if !p.IsSetOpponent() { + return ResGuessColor_Opponent_DEFAULT + } + return p.Opponent +} + +func (p *ResGuessColor) IsSetOpponent() bool { + return p.Opponent != nil +} + +func (p *ResGuessColor) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.LIST { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.MAP { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 8: + if fieldTypeId == thrift.I32 { + if err := p.ReadField8(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 9: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField9(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResGuessColor) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResGuessColor) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Status = v + } + return nil +} + +func (p *ResGuessColor) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.EndTime = v + } + return nil +} + +func (p *ResGuessColor) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Template = v + } + return nil +} + +func (p *ResGuessColor) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.Pass = v + } + return nil +} + +func (p *ResGuessColor) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*GuessColorInfo, 0, size) + p.MapList = tSlice + for i := 0; i < size; i++ { + _elem267 := &GuessColorInfo{} + if err := _elem267.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem267), err) + } + p.MapList = append(p.MapList, _elem267) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResGuessColor) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.OMap = tMap + for i := 0; i < size; i++ { + var _key268 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key268 = v + } + var _val269 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val269 = v + } + p.OMap[_key268] = _val269 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResGuessColor) ReadField8(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 8: ", err) + } else { + p.WinTime = v + } + return nil +} + +func (p *ResGuessColor) ReadField9(ctx context.Context, iprot thrift.TProtocol) error { + p.Opponent = &Opponent{} + if err := p.Opponent.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.Opponent), err) + } + return nil +} + +func (p *ResGuessColor) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResGuessColor"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + if err := p.writeField8(ctx, oprot); err != nil { + return err + } + if err := p.writeField9(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResGuessColor) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ResGuessColor) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Status", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Status: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Status)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Status (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Status: ", p), err) + } + return err +} + +func (p *ResGuessColor) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EndTime", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:EndTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.EndTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EndTime (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:EndTime: ", p), err) + } + return err +} + +func (p *ResGuessColor) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Template", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Template: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Template)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Template (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Template: ", p), err) + } + return err +} + +func (p *ResGuessColor) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Pass", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Pass: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Pass)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Pass (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Pass: ", p), err) + } + return err +} + +func (p *ResGuessColor) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MapList", thrift.LIST, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:MapList: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.MapList)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.MapList { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:MapList: ", p), err) + } + return err +} + +func (p *ResGuessColor) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "OMap", thrift.MAP, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:OMap: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.OMap)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.OMap { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:OMap: ", p), err) + } + return err +} + +func (p *ResGuessColor) writeField8(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "WinTime", thrift.I32, 8); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 8:WinTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.WinTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.WinTime (8) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 8:WinTime: ", p), err) + } + return err +} + +func (p *ResGuessColor) writeField9(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Opponent", thrift.STRUCT, 9); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 9:Opponent: ", p), err) + } + if err := p.Opponent.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.Opponent), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 9:Opponent: ", p), err) + } + return err +} + +func (p *ResGuessColor) Equals(other *ResGuessColor) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Status != other.Status { + return false + } + if p.EndTime != other.EndTime { + return false + } + if p.Template != other.Template { + return false + } + if p.Pass != other.Pass { + return false + } + if len(p.MapList) != len(other.MapList) { + return false + } + for i, _tgt := range p.MapList { + _src270 := other.MapList[i] + if !_tgt.Equals(_src270) { + return false + } + } + if len(p.OMap) != len(other.OMap) { + return false + } + for k, _tgt := range p.OMap { + _src271 := other.OMap[k] + if _tgt != _src271 { + return false + } + } + if p.WinTime != other.WinTime { + return false + } + if !p.Opponent.Equals(other.Opponent) { + return false + } + return true +} + +func (p *ResGuessColor) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResGuessColor(%+v)", *p) +} + +func (p *ResGuessColor) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResGuessColor", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResGuessColor)(nil) + +func (p *ResGuessColor) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResGuessColorReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResGuessColorReward() *ResGuessColorReward { + return &ResGuessColorReward{} +} + +func (p *ResGuessColorReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResGuessColorReward) GetMsg() string { + return p.Msg +} + +func (p *ResGuessColorReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResGuessColorReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResGuessColorReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResGuessColorReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResGuessColorReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResGuessColorReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResGuessColorReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResGuessColorReward) Equals(other *ResGuessColorReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResGuessColorReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResGuessColorReward(%+v)", *p) +} + +func (p *ResGuessColorReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResGuessColorReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResGuessColorReward)(nil) + +func (p *ResGuessColorReward) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResGuessColorTake struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResGuessColorTake() *ResGuessColorTake { + return &ResGuessColorTake{} +} + +func (p *ResGuessColorTake) GetCode() RES_CODE { + return p.Code +} + +func (p *ResGuessColorTake) GetMsg() string { + return p.Msg +} + +func (p *ResGuessColorTake) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResGuessColorTake) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResGuessColorTake) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResGuessColorTake) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResGuessColorTake"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResGuessColorTake) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResGuessColorTake) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResGuessColorTake) Equals(other *ResGuessColorTake) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResGuessColorTake) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResGuessColorTake(%+v)", *p) +} + +func (p *ResGuessColorTake) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResGuessColorTake", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResGuessColorTake)(nil) + +func (p *ResGuessColorTake) Validate() error { + return nil +} + +// Attributes: +// - Reward +// +type ResGuideInfo struct { + Reward map[int32]int32 `thrift:"Reward,1" db:"Reward" json:"Reward"` +} + +func NewResGuideInfo() *ResGuideInfo { + return &ResGuideInfo{} +} + +func (p *ResGuideInfo) GetReward() map[int32]int32 { + return p.Reward +} + +func (p *ResGuideInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.MAP { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResGuideInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.Reward = tMap + for i := 0; i < size; i++ { + var _key272 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key272 = v + } + var _val273 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val273 = v + } + p.Reward[_key272] = _val273 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResGuideInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResGuideInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResGuideInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Reward", thrift.MAP, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Reward: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.Reward)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Reward { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Reward: ", p), err) + } + return err +} + +func (p *ResGuideInfo) Equals(other *ResGuideInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.Reward) != len(other.Reward) { + return false + } + for k, _tgt := range p.Reward { + _src274 := other.Reward[k] + if _tgt != _src274 { + return false + } + } + return true +} + +func (p *ResGuideInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResGuideInfo(%+v)", *p) +} + +func (p *ResGuideInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResGuideInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResGuideInfo)(nil) + +func (p *ResGuideInfo) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResGuidePlayroom struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResGuidePlayroom() *ResGuidePlayroom { + return &ResGuidePlayroom{} +} + +func (p *ResGuidePlayroom) GetCode() RES_CODE { + return p.Code +} + +func (p *ResGuidePlayroom) GetMsg() string { + return p.Msg +} + +func (p *ResGuidePlayroom) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResGuidePlayroom) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResGuidePlayroom) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResGuidePlayroom) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResGuidePlayroom"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResGuidePlayroom) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResGuidePlayroom) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResGuidePlayroom) Equals(other *ResGuidePlayroom) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResGuidePlayroom) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResGuidePlayroom(%+v)", *p) +} + +func (p *ResGuidePlayroom) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResGuidePlayroom", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResGuidePlayroom)(nil) + +func (p *ResGuidePlayroom) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResGuideReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResGuideReward() *ResGuideReward { + return &ResGuideReward{} +} + +func (p *ResGuideReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResGuideReward) GetMsg() string { + return p.Msg +} + +func (p *ResGuideReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResGuideReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResGuideReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResGuideReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResGuideReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResGuideReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResGuideReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResGuideReward) Equals(other *ResGuideReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResGuideReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResGuideReward(%+v)", *p) +} + +func (p *ResGuideReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResGuideReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResGuideReward)(nil) + +func (p *ResGuideReward) Validate() error { + return nil +} + +// Attributes: +// - ActiveReward +// - Task +// - Active +// - UnlockTime +// +type ResGuideTask struct { + ActiveReward []int32 `thrift:"ActiveReward,1" db:"ActiveReward" json:"ActiveReward"` + Task map[int32]*GuideTask `thrift:"Task,2" db:"Task" json:"Task"` + Active int32 `thrift:"Active,3" db:"Active" json:"Active"` + UnlockTime int32 `thrift:"UnlockTime,4" db:"UnlockTime" json:"UnlockTime"` +} + +func NewResGuideTask() *ResGuideTask { + return &ResGuideTask{} +} + +func (p *ResGuideTask) GetActiveReward() []int32 { + return p.ActiveReward +} + +func (p *ResGuideTask) GetTask() map[int32]*GuideTask { + return p.Task +} + +func (p *ResGuideTask) GetActive() int32 { + return p.Active +} + +func (p *ResGuideTask) GetUnlockTime() int32 { + return p.UnlockTime +} + +func (p *ResGuideTask) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.MAP { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResGuideTask) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.ActiveReward = tSlice + for i := 0; i < size; i++ { + var _elem275 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem275 = v + } + p.ActiveReward = append(p.ActiveReward, _elem275) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResGuideTask) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]*GuideTask, size) + p.Task = tMap + for i := 0; i < size; i++ { + var _key276 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key276 = v + } + _val277 := &GuideTask{} + if err := _val277.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _val277), err) + } + p.Task[_key276] = _val277 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResGuideTask) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Active = v + } + return nil +} + +func (p *ResGuideTask) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.UnlockTime = v + } + return nil +} + +func (p *ResGuideTask) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResGuideTask"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResGuideTask) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ActiveReward", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ActiveReward: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.ActiveReward)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.ActiveReward { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ActiveReward: ", p), err) + } + return err +} + +func (p *ResGuideTask) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Task", thrift.MAP, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Task: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.STRUCT, len(p.Task)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Task { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Task: ", p), err) + } + return err +} + +func (p *ResGuideTask) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Active", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Active: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Active)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Active (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Active: ", p), err) + } + return err +} + +func (p *ResGuideTask) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "UnlockTime", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:UnlockTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.UnlockTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.UnlockTime (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:UnlockTime: ", p), err) + } + return err +} + +func (p *ResGuideTask) Equals(other *ResGuideTask) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.ActiveReward) != len(other.ActiveReward) { + return false + } + for i, _tgt := range p.ActiveReward { + _src278 := other.ActiveReward[i] + if _tgt != _src278 { + return false + } + } + if len(p.Task) != len(other.Task) { + return false + } + for k, _tgt := range p.Task { + _src279 := other.Task[k] + if !_tgt.Equals(_src279) { + return false + } + } + if p.Active != other.Active { + return false + } + if p.UnlockTime != other.UnlockTime { + return false + } + return true +} + +func (p *ResGuideTask) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResGuideTask(%+v)", *p) +} + +func (p *ResGuideTask) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResGuideTask", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResGuideTask)(nil) + +func (p *ResGuideTask) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResHandbookAllReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResHandbookAllReward() *ResHandbookAllReward { + return &ResHandbookAllReward{} +} + +func (p *ResHandbookAllReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResHandbookAllReward) GetMsg() string { + return p.Msg +} + +func (p *ResHandbookAllReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResHandbookAllReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResHandbookAllReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResHandbookAllReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResHandbookAllReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResHandbookAllReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResHandbookAllReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResHandbookAllReward) Equals(other *ResHandbookAllReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResHandbookAllReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResHandbookAllReward(%+v)", *p) +} + +func (p *ResHandbookAllReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResHandbookAllReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResHandbookAllReward)(nil) + +func (p *ResHandbookAllReward) Validate() error { + return nil +} + +// Attributes: +// - ResultCode +// - Msg +// +type ResId2Verify struct { + ResultCode RES_CODE `thrift:"ResultCode,1" db:"ResultCode" json:"ResultCode"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResId2Verify() *ResId2Verify { + return &ResId2Verify{} +} + +func (p *ResId2Verify) GetResultCode() RES_CODE { + return p.ResultCode +} + +func (p *ResId2Verify) GetMsg() string { + return p.Msg +} + +func (p *ResId2Verify) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResId2Verify) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.ResultCode = temp + } + return nil +} + +func (p *ResId2Verify) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResId2Verify) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResId2Verify"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResId2Verify) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ResultCode", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ResultCode: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ResultCode)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ResultCode (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ResultCode: ", p), err) + } + return err +} + +func (p *ResId2Verify) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResId2Verify) Equals(other *ResId2Verify) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ResultCode != other.ResultCode { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResId2Verify) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResId2Verify(%+v)", *p) +} + +func (p *ResId2Verify) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResId2Verify", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResId2Verify)(nil) + +func (p *ResId2Verify) Validate() error { + return nil +} + +// Attributes: +// - IdLists +// - GetIndex +// +type ResInviteFriendData struct { + IdLists []int32 `thrift:"IdLists,1" db:"IdLists" json:"IdLists"` + GetIndex int32 `thrift:"GetIndex,2" db:"GetIndex" json:"GetIndex"` +} + +func NewResInviteFriendData() *ResInviteFriendData { + return &ResInviteFriendData{} +} + +func (p *ResInviteFriendData) GetIdLists() []int32 { + return p.IdLists +} + +func (p *ResInviteFriendData) GetGetIndex() int32 { + return p.GetIndex +} + +func (p *ResInviteFriendData) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResInviteFriendData) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.IdLists = tSlice + for i := 0; i < size; i++ { + var _elem280 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem280 = v + } + p.IdLists = append(p.IdLists, _elem280) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResInviteFriendData) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.GetIndex = v + } + return nil +} + +func (p *ResInviteFriendData) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResInviteFriendData"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResInviteFriendData) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "IdLists", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:IdLists: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.IdLists)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.IdLists { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:IdLists: ", p), err) + } + return err +} + +func (p *ResInviteFriendData) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "GetIndex", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:GetIndex: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.GetIndex)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.GetIndex (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:GetIndex: ", p), err) + } + return err +} + +func (p *ResInviteFriendData) Equals(other *ResInviteFriendData) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.IdLists) != len(other.IdLists) { + return false + } + for i, _tgt := range p.IdLists { + _src281 := other.IdLists[i] + if _tgt != _src281 { + return false + } + } + if p.GetIndex != other.GetIndex { + return false + } + return true +} + +func (p *ResInviteFriendData) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResInviteFriendData(%+v)", *p) +} + +func (p *ResInviteFriendData) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResInviteFriendData", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResInviteFriendData)(nil) + +func (p *ResInviteFriendData) Validate() error { + return nil +} + +// Attributes: +// - Item +// +type ResItem struct { + Item map[int32]int32 `thrift:"Item,1" db:"Item" json:"Item"` +} + +func NewResItem() *ResItem { + return &ResItem{} +} + +func (p *ResItem) GetItem() map[int32]int32 { + return p.Item +} + +func (p *ResItem) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.MAP { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResItem) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.Item = tMap + for i := 0; i < size; i++ { + var _key282 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key282 = v + } + var _val283 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val283 = v + } + p.Item[_key282] = _val283 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResItem) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResItem"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResItem) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Item", thrift.MAP, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Item: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.Item)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Item { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Item: ", p), err) + } + return err +} + +func (p *ResItem) Equals(other *ResItem) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.Item) != len(other.Item) { + return false + } + for k, _tgt := range p.Item { + _src284 := other.Item[k] + if _tgt != _src284 { + return false + } + } + return true +} + +func (p *ResItem) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResItem(%+v)", *p) +} + +func (p *ResItem) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResItem", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResItem)(nil) + +func (p *ResItem) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Items +// - CardPacks +// - Lable +// +type ResItemPop struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Items []*ItemInfo `thrift:"Items,2" db:"Items" json:"Items"` + CardPacks []*CardPack `thrift:"CardPacks,3" db:"CardPacks" json:"CardPacks"` + Lable string `thrift:"Lable,4" db:"Lable" json:"Lable"` +} + +func NewResItemPop() *ResItemPop { + return &ResItemPop{} +} + +func (p *ResItemPop) GetId() int32 { + return p.Id +} + +func (p *ResItemPop) GetItems() []*ItemInfo { + return p.Items +} + +func (p *ResItemPop) GetCardPacks() []*CardPack { + return p.CardPacks +} + +func (p *ResItemPop) GetLable() string { + return p.Lable +} + +func (p *ResItemPop) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.LIST { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.LIST { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.STRING { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResItemPop) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResItemPop) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ItemInfo, 0, size) + p.Items = tSlice + for i := 0; i < size; i++ { + _elem285 := &ItemInfo{} + if err := _elem285.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem285), err) + } + p.Items = append(p.Items, _elem285) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResItemPop) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*CardPack, 0, size) + p.CardPacks = tSlice + for i := 0; i < size; i++ { + _elem286 := &CardPack{} + if err := _elem286.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem286), err) + } + p.CardPacks = append(p.CardPacks, _elem286) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResItemPop) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Lable = v + } + return nil +} + +func (p *ResItemPop) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResItemPop"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResItemPop) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ResItemPop) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Items", thrift.LIST, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Items: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Items)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Items { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Items: ", p), err) + } + return err +} + +func (p *ResItemPop) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "CardPacks", thrift.LIST, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:CardPacks: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.CardPacks)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.CardPacks { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:CardPacks: ", p), err) + } + return err +} + +func (p *ResItemPop) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Lable", thrift.STRING, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Lable: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Lable)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Lable (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Lable: ", p), err) + } + return err +} + +func (p *ResItemPop) Equals(other *ResItemPop) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if len(p.Items) != len(other.Items) { + return false + } + for i, _tgt := range p.Items { + _src287 := other.Items[i] + if !_tgt.Equals(_src287) { + return false + } + } + if len(p.CardPacks) != len(other.CardPacks) { + return false + } + for i, _tgt := range p.CardPacks { + _src288 := other.CardPacks[i] + if !_tgt.Equals(_src288) { + return false + } + } + if p.Lable != other.Lable { + return false + } + return true +} + +func (p *ResItemPop) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResItemPop(%+v)", *p) +} + +func (p *ResItemPop) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResItemPop", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResItemPop)(nil) + +func (p *ResItemPop) Validate() error { + return nil +} + +// Attributes: +// - Kv +// +type ResKv struct { + Kv map[int32]string `thrift:"Kv,1" db:"Kv" json:"Kv"` +} + +func NewResKv() *ResKv { + return &ResKv{} +} + +func (p *ResKv) GetKv() map[int32]string { + return p.Kv +} + +func (p *ResKv) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.MAP { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResKv) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]string, size) + p.Kv = tMap + for i := 0; i < size; i++ { + var _key289 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key289 = v + } + var _val290 string + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val290 = v + } + p.Kv[_key289] = _val290 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResKv) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResKv"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResKv) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Kv", thrift.MAP, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Kv: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.STRING, len(p.Kv)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Kv { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteString(ctx, string(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Kv: ", p), err) + } + return err +} + +func (p *ResKv) Equals(other *ResKv) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.Kv) != len(other.Kv) { + return false + } + for k, _tgt := range p.Kv { + _src291 := other.Kv[k] + if _tgt != _src291 { + return false + } + } + return true +} + +func (p *ResKv) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResKv(%+v)", *p) +} + +func (p *ResKv) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResKv", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResKv)(nil) + +func (p *ResKv) Validate() error { + return nil +} + +// Attributes: +// - ResultCode +// - Msg +// +type ResLang struct { + ResultCode RES_CODE `thrift:"ResultCode,1" db:"ResultCode" json:"ResultCode"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResLang() *ResLang { + return &ResLang{} +} + +func (p *ResLang) GetResultCode() RES_CODE { + return p.ResultCode +} + +func (p *ResLang) GetMsg() string { + return p.Msg +} + +func (p *ResLang) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResLang) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.ResultCode = temp + } + return nil +} + +func (p *ResLang) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResLang) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResLang"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResLang) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ResultCode", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ResultCode: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ResultCode)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ResultCode (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ResultCode: ", p), err) + } + return err +} + +func (p *ResLang) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResLang) Equals(other *ResLang) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ResultCode != other.ResultCode { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResLang) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResLang(%+v)", *p) +} + +func (p *ResLang) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResLang", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResLang)(nil) + +func (p *ResLang) Validate() error { + return nil +} + +// Attributes: +// - LimitEventList +// +type ResLimitEvent struct { + LimitEventList map[int32]*LimitEvent `thrift:"LimitEventList,1" db:"LimitEventList" json:"LimitEventList"` +} + +func NewResLimitEvent() *ResLimitEvent { + return &ResLimitEvent{} +} + +func (p *ResLimitEvent) GetLimitEventList() map[int32]*LimitEvent { + return p.LimitEventList +} + +func (p *ResLimitEvent) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.MAP { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResLimitEvent) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]*LimitEvent, size) + p.LimitEventList = tMap + for i := 0; i < size; i++ { + var _key292 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key292 = v + } + _val293 := &LimitEvent{} + if err := _val293.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _val293), err) + } + p.LimitEventList[_key292] = _val293 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResLimitEvent) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResLimitEvent"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResLimitEvent) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "LimitEventList", thrift.MAP, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:LimitEventList: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.STRUCT, len(p.LimitEventList)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.LimitEventList { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:LimitEventList: ", p), err) + } + return err +} + +func (p *ResLimitEvent) Equals(other *ResLimitEvent) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.LimitEventList) != len(other.LimitEventList) { + return false + } + for k, _tgt := range p.LimitEventList { + _src294 := other.LimitEventList[k] + if !_tgt.Equals(_src294) { + return false + } + } + return true +} + +func (p *ResLimitEvent) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResLimitEvent(%+v)", *p) +} + +func (p *ResLimitEvent) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResLimitEvent", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResLimitEvent)(nil) + +func (p *ResLimitEvent) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResLimitEventLuckyCat struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResLimitEventLuckyCat() *ResLimitEventLuckyCat { + return &ResLimitEventLuckyCat{} +} + +func (p *ResLimitEventLuckyCat) GetCode() RES_CODE { + return p.Code +} + +func (p *ResLimitEventLuckyCat) GetMsg() string { + return p.Msg +} + +func (p *ResLimitEventLuckyCat) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResLimitEventLuckyCat) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResLimitEventLuckyCat) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResLimitEventLuckyCat) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResLimitEventLuckyCat"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResLimitEventLuckyCat) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResLimitEventLuckyCat) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResLimitEventLuckyCat) Equals(other *ResLimitEventLuckyCat) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResLimitEventLuckyCat) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResLimitEventLuckyCat(%+v)", *p) +} + +func (p *ResLimitEventLuckyCat) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResLimitEventLuckyCat", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResLimitEventLuckyCat)(nil) + +func (p *ResLimitEventLuckyCat) Validate() error { + return nil +} + +// Attributes: +// - ProgressMax +// - Progress +// - ProgressReward +// +type ResLimitEventProgress struct { + ProgressMax int32 `thrift:"ProgressMax,1" db:"ProgressMax" json:"ProgressMax"` + Progress int32 `thrift:"Progress,2" db:"Progress" json:"Progress"` + ProgressReward map[int32]int32 `thrift:"ProgressReward,3" db:"ProgressReward" json:"ProgressReward"` +} + +func NewResLimitEventProgress() *ResLimitEventProgress { + return &ResLimitEventProgress{} +} + +func (p *ResLimitEventProgress) GetProgressMax() int32 { + return p.ProgressMax +} + +func (p *ResLimitEventProgress) GetProgress() int32 { + return p.Progress +} + +func (p *ResLimitEventProgress) GetProgressReward() map[int32]int32 { + return p.ProgressReward +} + +func (p *ResLimitEventProgress) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.MAP { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResLimitEventProgress) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.ProgressMax = v + } + return nil +} + +func (p *ResLimitEventProgress) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Progress = v + } + return nil +} + +func (p *ResLimitEventProgress) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.ProgressReward = tMap + for i := 0; i < size; i++ { + var _key295 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key295 = v + } + var _val296 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val296 = v + } + p.ProgressReward[_key295] = _val296 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResLimitEventProgress) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResLimitEventProgress"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResLimitEventProgress) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ProgressMax", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ProgressMax: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ProgressMax)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ProgressMax (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ProgressMax: ", p), err) + } + return err +} + +func (p *ResLimitEventProgress) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Progress", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Progress: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Progress)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Progress (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Progress: ", p), err) + } + return err +} + +func (p *ResLimitEventProgress) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ProgressReward", thrift.MAP, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:ProgressReward: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.ProgressReward)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.ProgressReward { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:ProgressReward: ", p), err) + } + return err +} + +func (p *ResLimitEventProgress) Equals(other *ResLimitEventProgress) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ProgressMax != other.ProgressMax { + return false + } + if p.Progress != other.Progress { + return false + } + if len(p.ProgressReward) != len(other.ProgressReward) { + return false + } + for k, _tgt := range p.ProgressReward { + _src297 := other.ProgressReward[k] + if _tgt != _src297 { + return false + } + } + return true +} + +func (p *ResLimitEventProgress) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResLimitEventProgress(%+v)", *p) +} + +func (p *ResLimitEventProgress) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResLimitEventProgress", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResLimitEventProgress)(nil) + +func (p *ResLimitEventProgress) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResLimitEventReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResLimitEventReward() *ResLimitEventReward { + return &ResLimitEventReward{} +} + +func (p *ResLimitEventReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResLimitEventReward) GetMsg() string { + return p.Msg +} + +func (p *ResLimitEventReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResLimitEventReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResLimitEventReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResLimitEventReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResLimitEventReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResLimitEventReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResLimitEventReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResLimitEventReward) Equals(other *ResLimitEventReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResLimitEventReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResLimitEventReward(%+v)", *p) +} + +func (p *ResLimitEventReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResLimitEventReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResLimitEventReward)(nil) + +func (p *ResLimitEventReward) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResLimitSenceReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResLimitSenceReward() *ResLimitSenceReward { + return &ResLimitSenceReward{} +} + +func (p *ResLimitSenceReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResLimitSenceReward) GetMsg() string { + return p.Msg +} + +func (p *ResLimitSenceReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResLimitSenceReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResLimitSenceReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResLimitSenceReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResLimitSenceReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResLimitSenceReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResLimitSenceReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResLimitSenceReward) Equals(other *ResLimitSenceReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResLimitSenceReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResLimitSenceReward(%+v)", *p) +} + +func (p *ResLimitSenceReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResLimitSenceReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResLimitSenceReward)(nil) + +func (p *ResLimitSenceReward) Validate() error { + return nil +} + +// Attributes: +// - ResultCode +// - DwUin +// - UserName +// - FaceBookId +// - Msg +// +type ResLogin struct { + ResultCode int32 `thrift:"ResultCode,1" db:"ResultCode" json:"ResultCode"` + DwUin int64 `thrift:"dwUin,2" db:"dwUin" json:"dwUin"` + UserName string `thrift:"UserName,3" db:"UserName" json:"UserName"` + FaceBookId string `thrift:"FaceBookId,4" db:"FaceBookId" json:"FaceBookId"` + Msg string `thrift:"Msg,5" db:"Msg" json:"Msg"` +} + +func NewResLogin() *ResLogin { + return &ResLogin{} +} + +func (p *ResLogin) GetResultCode() int32 { + return p.ResultCode +} + +func (p *ResLogin) GetDwUin() int64 { + return p.DwUin +} + +func (p *ResLogin) GetUserName() string { + return p.UserName +} + +func (p *ResLogin) GetFaceBookId() string { + return p.FaceBookId +} + +func (p *ResLogin) GetMsg() string { + return p.Msg +} + +func (p *ResLogin) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I64 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.STRING { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.STRING { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.STRING { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResLogin) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.ResultCode = v + } + return nil +} + +func (p *ResLogin) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.DwUin = v + } + return nil +} + +func (p *ResLogin) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.UserName = v + } + return nil +} + +func (p *ResLogin) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.FaceBookId = v + } + return nil +} + +func (p *ResLogin) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResLogin) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResLogin"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResLogin) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ResultCode", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ResultCode: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ResultCode)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ResultCode (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ResultCode: ", p), err) + } + return err +} + +func (p *ResLogin) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "dwUin", thrift.I64, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:dwUin: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.DwUin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.dwUin (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:dwUin: ", p), err) + } + return err +} + +func (p *ResLogin) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "UserName", thrift.STRING, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:UserName: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.UserName)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.UserName (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:UserName: ", p), err) + } + return err +} + +func (p *ResLogin) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "FaceBookId", thrift.STRING, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:FaceBookId: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.FaceBookId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.FaceBookId (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:FaceBookId: ", p), err) + } + return err +} + +func (p *ResLogin) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Msg: ", p), err) + } + return err +} + +func (p *ResLogin) Equals(other *ResLogin) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ResultCode != other.ResultCode { + return false + } + if p.DwUin != other.DwUin { + return false + } + if p.UserName != other.UserName { + return false + } + if p.FaceBookId != other.FaceBookId { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResLogin) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResLogin(%+v)", *p) +} + +func (p *ResLogin) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResLogin", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResLogin)(nil) + +func (p *ResLogin) Validate() error { + return nil +} + +// Attributes: +// - ResultCode +// - Msg +// - Code +// +type ResLoginCode struct { + ResultCode int32 `thrift:"ResultCode,1" db:"ResultCode" json:"ResultCode"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Code string `thrift:"Code,3" db:"Code" json:"Code"` +} + +func NewResLoginCode() *ResLoginCode { + return &ResLoginCode{} +} + +func (p *ResLoginCode) GetResultCode() int32 { + return p.ResultCode +} + +func (p *ResLoginCode) GetMsg() string { + return p.Msg +} + +func (p *ResLoginCode) GetCode() string { + return p.Code +} + +func (p *ResLoginCode) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.STRING { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResLoginCode) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.ResultCode = v + } + return nil +} + +func (p *ResLoginCode) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResLoginCode) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Code = v + } + return nil +} + +func (p *ResLoginCode) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResLoginCode"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResLoginCode) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ResultCode", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ResultCode: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ResultCode)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ResultCode (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ResultCode: ", p), err) + } + return err +} + +func (p *ResLoginCode) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResLoginCode) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.STRING, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Code: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Code: ", p), err) + } + return err +} + +func (p *ResLoginCode) Equals(other *ResLoginCode) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ResultCode != other.ResultCode { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Code != other.Code { + return false + } + return true +} + +func (p *ResLoginCode) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResLoginCode(%+v)", *p) +} + +func (p *ResLoginCode) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResLoginCode", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResLoginCode)(nil) + +func (p *ResLoginCode) Validate() error { + return nil +} + +// Attributes: +// - MailList +// +type ResMailList struct { + MailList map[int32]*MailInfo `thrift:"MailList,1" db:"MailList" json:"MailList"` +} + +func NewResMailList() *ResMailList { + return &ResMailList{} +} + +func (p *ResMailList) GetMailList() map[int32]*MailInfo { + return p.MailList +} + +func (p *ResMailList) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.MAP { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResMailList) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]*MailInfo, size) + p.MailList = tMap + for i := 0; i < size; i++ { + var _key298 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key298 = v + } + _val299 := &MailInfo{} + if err := _val299.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _val299), err) + } + p.MailList[_key298] = _val299 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResMailList) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResMailList"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResMailList) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MailList", thrift.MAP, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:MailList: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.STRUCT, len(p.MailList)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.MailList { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:MailList: ", p), err) + } + return err +} + +func (p *ResMailList) Equals(other *ResMailList) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.MailList) != len(other.MailList) { + return false + } + for k, _tgt := range p.MailList { + _src300 := other.MailList[k] + if !_tgt.Equals(_src300) { + return false + } + } + return true +} + +func (p *ResMailList) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResMailList(%+v)", *p) +} + +func (p *ResMailList) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResMailList", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResMailList)(nil) + +func (p *ResMailList) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - MasterId +// - CardId +// +type ResMasterCard struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + MasterId int32 `thrift:"MasterId,3" db:"MasterId" json:"MasterId"` + CardId int32 `thrift:"CardId,4" db:"CardId" json:"CardId"` +} + +func NewResMasterCard() *ResMasterCard { + return &ResMasterCard{} +} + +func (p *ResMasterCard) GetCode() RES_CODE { + return p.Code +} + +func (p *ResMasterCard) GetMsg() string { + return p.Msg +} + +func (p *ResMasterCard) GetMasterId() int32 { + return p.MasterId +} + +func (p *ResMasterCard) GetCardId() int32 { + return p.CardId +} + +func (p *ResMasterCard) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResMasterCard) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResMasterCard) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResMasterCard) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.MasterId = v + } + return nil +} + +func (p *ResMasterCard) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.CardId = v + } + return nil +} + +func (p *ResMasterCard) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResMasterCard"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResMasterCard) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResMasterCard) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResMasterCard) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MasterId", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:MasterId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.MasterId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.MasterId (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:MasterId: ", p), err) + } + return err +} + +func (p *ResMasterCard) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "CardId", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:CardId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.CardId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.CardId (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:CardId: ", p), err) + } + return err +} + +func (p *ResMasterCard) Equals(other *ResMasterCard) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.MasterId != other.MasterId { + return false + } + if p.CardId != other.CardId { + return false + } + return true +} + +func (p *ResMasterCard) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResMasterCard(%+v)", *p) +} + +func (p *ResMasterCard) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResMasterCard", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResMasterCard)(nil) + +func (p *ResMasterCard) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Status +// - EndTime +// - Template +// - Pass +// - Gem +// - Map +// - Mining +// - PassReward +// +type ResMining struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Status int32 `thrift:"Status,2" db:"Status" json:"Status"` + EndTime int32 `thrift:"EndTime,3" db:"EndTime" json:"EndTime"` + Template int32 `thrift:"Template,4" db:"Template" json:"Template"` + Pass int32 `thrift:"Pass,5" db:"Pass" json:"Pass"` + Gem []int32 `thrift:"Gem,6" db:"Gem" json:"Gem"` + Map map[int32]string `thrift:"Map,7" db:"Map" json:"Map"` + Mining int32 `thrift:"Mining,8" db:"Mining" json:"Mining"` + PassReward map[int32]*ItemList `thrift:"PassReward,9" db:"PassReward" json:"PassReward"` +} + +func NewResMining() *ResMining { + return &ResMining{} +} + +func (p *ResMining) GetId() int32 { + return p.Id +} + +func (p *ResMining) GetStatus() int32 { + return p.Status +} + +func (p *ResMining) GetEndTime() int32 { + return p.EndTime +} + +func (p *ResMining) GetTemplate() int32 { + return p.Template +} + +func (p *ResMining) GetPass() int32 { + return p.Pass +} + +func (p *ResMining) GetGem() []int32 { + return p.Gem +} + +func (p *ResMining) GetMap() map[int32]string { + return p.Map +} + +func (p *ResMining) GetMining() int32 { + return p.Mining +} + +func (p *ResMining) GetPassReward() map[int32]*ItemList { + return p.PassReward +} + +func (p *ResMining) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.LIST { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.MAP { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 8: + if fieldTypeId == thrift.I32 { + if err := p.ReadField8(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 9: + if fieldTypeId == thrift.MAP { + if err := p.ReadField9(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResMining) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResMining) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Status = v + } + return nil +} + +func (p *ResMining) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.EndTime = v + } + return nil +} + +func (p *ResMining) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Template = v + } + return nil +} + +func (p *ResMining) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.Pass = v + } + return nil +} + +func (p *ResMining) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.Gem = tSlice + for i := 0; i < size; i++ { + var _elem301 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem301 = v + } + p.Gem = append(p.Gem, _elem301) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResMining) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]string, size) + p.Map = tMap + for i := 0; i < size; i++ { + var _key302 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key302 = v + } + var _val303 string + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val303 = v + } + p.Map[_key302] = _val303 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResMining) ReadField8(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 8: ", err) + } else { + p.Mining = v + } + return nil +} + +func (p *ResMining) ReadField9(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]*ItemList, size) + p.PassReward = tMap + for i := 0; i < size; i++ { + var _key304 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key304 = v + } + _val305 := &ItemList{} + if err := _val305.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _val305), err) + } + p.PassReward[_key304] = _val305 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResMining) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResMining"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + if err := p.writeField8(ctx, oprot); err != nil { + return err + } + if err := p.writeField9(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResMining) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ResMining) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Status", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Status: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Status)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Status (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Status: ", p), err) + } + return err +} + +func (p *ResMining) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EndTime", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:EndTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.EndTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EndTime (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:EndTime: ", p), err) + } + return err +} + +func (p *ResMining) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Template", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Template: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Template)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Template (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Template: ", p), err) + } + return err +} + +func (p *ResMining) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Pass", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Pass: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Pass)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Pass (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Pass: ", p), err) + } + return err +} + +func (p *ResMining) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Gem", thrift.LIST, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:Gem: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.Gem)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Gem { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:Gem: ", p), err) + } + return err +} + +func (p *ResMining) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Map", thrift.MAP, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:Map: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.STRING, len(p.Map)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Map { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteString(ctx, string(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:Map: ", p), err) + } + return err +} + +func (p *ResMining) writeField8(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Mining", thrift.I32, 8); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 8:Mining: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Mining)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Mining (8) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 8:Mining: ", p), err) + } + return err +} + +func (p *ResMining) writeField9(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "PassReward", thrift.MAP, 9); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 9:PassReward: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.STRUCT, len(p.PassReward)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.PassReward { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 9:PassReward: ", p), err) + } + return err +} + +func (p *ResMining) Equals(other *ResMining) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Status != other.Status { + return false + } + if p.EndTime != other.EndTime { + return false + } + if p.Template != other.Template { + return false + } + if p.Pass != other.Pass { + return false + } + if len(p.Gem) != len(other.Gem) { + return false + } + for i, _tgt := range p.Gem { + _src306 := other.Gem[i] + if _tgt != _src306 { + return false + } + } + if len(p.Map) != len(other.Map) { + return false + } + for k, _tgt := range p.Map { + _src307 := other.Map[k] + if _tgt != _src307 { + return false + } + } + if p.Mining != other.Mining { + return false + } + if len(p.PassReward) != len(other.PassReward) { + return false + } + for k, _tgt := range p.PassReward { + _src308 := other.PassReward[k] + if !_tgt.Equals(_src308) { + return false + } + } + return true +} + +func (p *ResMining) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResMining(%+v)", *p) +} + +func (p *ResMining) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResMining", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResMining)(nil) + +func (p *ResMining) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResMiningReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResMiningReward() *ResMiningReward { + return &ResMiningReward{} +} + +func (p *ResMiningReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResMiningReward) GetMsg() string { + return p.Msg +} + +func (p *ResMiningReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResMiningReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResMiningReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResMiningReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResMiningReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResMiningReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResMiningReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResMiningReward) Equals(other *ResMiningReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResMiningReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResMiningReward(%+v)", *p) +} + +func (p *ResMiningReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResMiningReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResMiningReward)(nil) + +func (p *ResMiningReward) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResMiningTake struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResMiningTake() *ResMiningTake { + return &ResMiningTake{} +} + +func (p *ResMiningTake) GetCode() RES_CODE { + return p.Code +} + +func (p *ResMiningTake) GetMsg() string { + return p.Msg +} + +func (p *ResMiningTake) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResMiningTake) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResMiningTake) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResMiningTake) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResMiningTake"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResMiningTake) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResMiningTake) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResMiningTake) Equals(other *ResMiningTake) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResMiningTake) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResMiningTake(%+v)", *p) +} + +func (p *ResMiningTake) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResMiningTake", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResMiningTake)(nil) + +func (p *ResMiningTake) Validate() error { + return nil +} + +// Attributes: +// - Card +// - Master +// - ExStar +// - Handbook +// +type ResNotifyCard struct { + Card map[int32]int32 `thrift:"Card,1" db:"Card" json:"Card"` + Master map[int32]int32 `thrift:"Master,2" db:"Master" json:"Master"` + ExStar int32 `thrift:"ExStar,3" db:"ExStar" json:"ExStar"` + Handbook map[int32]int32 `thrift:"Handbook,4" db:"Handbook" json:"Handbook"` +} + +func NewResNotifyCard() *ResNotifyCard { + return &ResNotifyCard{} +} + +func (p *ResNotifyCard) GetCard() map[int32]int32 { + return p.Card +} + +func (p *ResNotifyCard) GetMaster() map[int32]int32 { + return p.Master +} + +func (p *ResNotifyCard) GetExStar() int32 { + return p.ExStar +} + +func (p *ResNotifyCard) GetHandbook() map[int32]int32 { + return p.Handbook +} + +func (p *ResNotifyCard) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.MAP { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.MAP { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.MAP { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResNotifyCard) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.Card = tMap + for i := 0; i < size; i++ { + var _key309 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key309 = v + } + var _val310 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val310 = v + } + p.Card[_key309] = _val310 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResNotifyCard) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.Master = tMap + for i := 0; i < size; i++ { + var _key311 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key311 = v + } + var _val312 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val312 = v + } + p.Master[_key311] = _val312 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResNotifyCard) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.ExStar = v + } + return nil +} + +func (p *ResNotifyCard) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.Handbook = tMap + for i := 0; i < size; i++ { + var _key313 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key313 = v + } + var _val314 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val314 = v + } + p.Handbook[_key313] = _val314 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResNotifyCard) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResNotifyCard"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResNotifyCard) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Card", thrift.MAP, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Card: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.Card)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Card { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Card: ", p), err) + } + return err +} + +func (p *ResNotifyCard) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Master", thrift.MAP, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Master: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.Master)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Master { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Master: ", p), err) + } + return err +} + +func (p *ResNotifyCard) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ExStar", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:ExStar: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ExStar)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ExStar (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:ExStar: ", p), err) + } + return err +} + +func (p *ResNotifyCard) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Handbook", thrift.MAP, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Handbook: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.Handbook)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Handbook { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Handbook: ", p), err) + } + return err +} + +func (p *ResNotifyCard) Equals(other *ResNotifyCard) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.Card) != len(other.Card) { + return false + } + for k, _tgt := range p.Card { + _src315 := other.Card[k] + if _tgt != _src315 { + return false + } + } + if len(p.Master) != len(other.Master) { + return false + } + for k, _tgt := range p.Master { + _src316 := other.Master[k] + if _tgt != _src316 { + return false + } + } + if p.ExStar != other.ExStar { + return false + } + if len(p.Handbook) != len(other.Handbook) { + return false + } + for k, _tgt := range p.Handbook { + _src317 := other.Handbook[k] + if _tgt != _src317 { + return false + } + } + return true +} + +func (p *ResNotifyCard) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResNotifyCard(%+v)", *p) +} + +func (p *ResNotifyCard) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResNotifyCard", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResNotifyCard)(nil) + +func (p *ResNotifyCard) Validate() error { + return nil +} + +// Attributes: +// - ExTimes +// - ReqTimes +// - ReqUid +// - ExUid +// - GoldTimes +// +type ResNotifyCardTimes struct { + ExTimes int32 `thrift:"ExTimes,1" db:"ExTimes" json:"ExTimes"` + ReqTimes int32 `thrift:"ReqTimes,2" db:"ReqTimes" json:"ReqTimes"` + ReqUid []int64 `thrift:"ReqUid,3" db:"ReqUid" json:"ReqUid"` + ExUid []int64 `thrift:"ExUid,4" db:"ExUid" json:"ExUid"` + GoldTimes int32 `thrift:"GoldTimes,5" db:"GoldTimes" json:"GoldTimes"` +} + +func NewResNotifyCardTimes() *ResNotifyCardTimes { + return &ResNotifyCardTimes{} +} + +func (p *ResNotifyCardTimes) GetExTimes() int32 { + return p.ExTimes +} + +func (p *ResNotifyCardTimes) GetReqTimes() int32 { + return p.ReqTimes +} + +func (p *ResNotifyCardTimes) GetReqUid() []int64 { + return p.ReqUid +} + +func (p *ResNotifyCardTimes) GetExUid() []int64 { + return p.ExUid +} + +func (p *ResNotifyCardTimes) GetGoldTimes() int32 { + return p.GoldTimes +} + +func (p *ResNotifyCardTimes) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.LIST { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.LIST { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResNotifyCardTimes) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.ExTimes = v + } + return nil +} + +func (p *ResNotifyCardTimes) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.ReqTimes = v + } + return nil +} + +func (p *ResNotifyCardTimes) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int64, 0, size) + p.ReqUid = tSlice + for i := 0; i < size; i++ { + var _elem318 int64 + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem318 = v + } + p.ReqUid = append(p.ReqUid, _elem318) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResNotifyCardTimes) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int64, 0, size) + p.ExUid = tSlice + for i := 0; i < size; i++ { + var _elem319 int64 + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem319 = v + } + p.ExUid = append(p.ExUid, _elem319) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResNotifyCardTimes) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.GoldTimes = v + } + return nil +} + +func (p *ResNotifyCardTimes) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResNotifyCardTimes"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResNotifyCardTimes) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ExTimes", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ExTimes: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ExTimes)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ExTimes (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ExTimes: ", p), err) + } + return err +} + +func (p *ResNotifyCardTimes) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ReqTimes", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:ReqTimes: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ReqTimes)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ReqTimes (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:ReqTimes: ", p), err) + } + return err +} + +func (p *ResNotifyCardTimes) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ReqUid", thrift.LIST, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:ReqUid: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I64, len(p.ReqUid)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.ReqUid { + if err := oprot.WriteI64(ctx, int64(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:ReqUid: ", p), err) + } + return err +} + +func (p *ResNotifyCardTimes) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ExUid", thrift.LIST, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:ExUid: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I64, len(p.ExUid)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.ExUid { + if err := oprot.WriteI64(ctx, int64(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:ExUid: ", p), err) + } + return err +} + +func (p *ResNotifyCardTimes) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "GoldTimes", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:GoldTimes: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.GoldTimes)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.GoldTimes (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:GoldTimes: ", p), err) + } + return err +} + +func (p *ResNotifyCardTimes) Equals(other *ResNotifyCardTimes) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ExTimes != other.ExTimes { + return false + } + if p.ReqTimes != other.ReqTimes { + return false + } + if len(p.ReqUid) != len(other.ReqUid) { + return false + } + for i, _tgt := range p.ReqUid { + _src320 := other.ReqUid[i] + if _tgt != _src320 { + return false + } + } + if len(p.ExUid) != len(other.ExUid) { + return false + } + for i, _tgt := range p.ExUid { + _src321 := other.ExUid[i] + if _tgt != _src321 { + return false + } + } + if p.GoldTimes != other.GoldTimes { + return false + } + return true +} + +func (p *ResNotifyCardTimes) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResNotifyCardTimes(%+v)", *p) +} + +func (p *ResNotifyCardTimes) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResNotifyCardTimes", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResNotifyCardTimes)(nil) + +func (p *ResNotifyCardTimes) Validate() error { + return nil +} + +// Attributes: +// - DwUin +// - Result_ +// +type ResOfflineReconnect struct { + DwUin int64 `thrift:"dwUin,1" db:"dwUin" json:"dwUin"` + Result_ int32 `thrift:"Result,2" db:"Result" json:"Result"` +} + +func NewResOfflineReconnect() *ResOfflineReconnect { + return &ResOfflineReconnect{} +} + +func (p *ResOfflineReconnect) GetDwUin() int64 { + return p.DwUin +} + +func (p *ResOfflineReconnect) GetResult_() int32 { + return p.Result_ +} + +func (p *ResOfflineReconnect) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResOfflineReconnect) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.DwUin = v + } + return nil +} + +func (p *ResOfflineReconnect) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Result_ = v + } + return nil +} + +func (p *ResOfflineReconnect) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResOfflineReconnect"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResOfflineReconnect) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "dwUin", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:dwUin: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.DwUin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.dwUin (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:dwUin: ", p), err) + } + return err +} + +func (p *ResOfflineReconnect) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Result", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Result: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Result_)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Result (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Result: ", p), err) + } + return err +} + +func (p *ResOfflineReconnect) Equals(other *ResOfflineReconnect) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.DwUin != other.DwUin { + return false + } + if p.Result_ != other.Result_ { + return false + } + return true +} + +func (p *ResOfflineReconnect) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResOfflineReconnect(%+v)", *p) +} + +func (p *ResOfflineReconnect) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResOfflineReconnect", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResOfflineReconnect)(nil) + +func (p *ResOfflineReconnect) Validate() error { + return nil +} + +// Attributes: +// - DwUin +// - BindAccountId +// - ResultCode +// +type ResOnlyBindFacebook struct { + DwUin int64 `thrift:"dwUin,1" db:"dwUin" json:"dwUin"` + BindAccountId string `thrift:"BindAccountId,2" db:"BindAccountId" json:"BindAccountId"` + ResultCode int32 `thrift:"ResultCode,3" db:"ResultCode" json:"ResultCode"` +} + +func NewResOnlyBindFacebook() *ResOnlyBindFacebook { + return &ResOnlyBindFacebook{} +} + +func (p *ResOnlyBindFacebook) GetDwUin() int64 { + return p.DwUin +} + +func (p *ResOnlyBindFacebook) GetBindAccountId() string { + return p.BindAccountId +} + +func (p *ResOnlyBindFacebook) GetResultCode() int32 { + return p.ResultCode +} + +func (p *ResOnlyBindFacebook) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResOnlyBindFacebook) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.DwUin = v + } + return nil +} + +func (p *ResOnlyBindFacebook) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.BindAccountId = v + } + return nil +} + +func (p *ResOnlyBindFacebook) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.ResultCode = v + } + return nil +} + +func (p *ResOnlyBindFacebook) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResOnlyBindFacebook"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResOnlyBindFacebook) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "dwUin", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:dwUin: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.DwUin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.dwUin (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:dwUin: ", p), err) + } + return err +} + +func (p *ResOnlyBindFacebook) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "BindAccountId", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:BindAccountId: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.BindAccountId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.BindAccountId (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:BindAccountId: ", p), err) + } + return err +} + +func (p *ResOnlyBindFacebook) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ResultCode", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:ResultCode: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ResultCode)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ResultCode (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:ResultCode: ", p), err) + } + return err +} + +func (p *ResOnlyBindFacebook) Equals(other *ResOnlyBindFacebook) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.DwUin != other.DwUin { + return false + } + if p.BindAccountId != other.BindAccountId { + return false + } + if p.ResultCode != other.ResultCode { + return false + } + return true +} + +func (p *ResOnlyBindFacebook) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResOnlyBindFacebook(%+v)", *p) +} + +func (p *ResOnlyBindFacebook) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResOnlyBindFacebook", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResOnlyBindFacebook)(nil) + +func (p *ResOnlyBindFacebook) Validate() error { + return nil +} + +// Attributes: +// - OrderList +// +type ResOrderList struct { + OrderList []*Order `thrift:"OrderList,1" db:"OrderList" json:"OrderList"` +} + +func NewResOrderList() *ResOrderList { + return &ResOrderList{} +} + +func (p *ResOrderList) GetOrderList() []*Order { + return p.OrderList +} + +func (p *ResOrderList) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResOrderList) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*Order, 0, size) + p.OrderList = tSlice + for i := 0; i < size; i++ { + _elem322 := &Order{} + if err := _elem322.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem322), err) + } + p.OrderList = append(p.OrderList, _elem322) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResOrderList) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResOrderList"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResOrderList) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "OrderList", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:OrderList: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.OrderList)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.OrderList { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:OrderList: ", p), err) + } + return err +} + +func (p *ResOrderList) Equals(other *ResOrderList) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.OrderList) != len(other.OrderList) { + return false + } + for i, _tgt := range p.OrderList { + _src323 := other.OrderList[i] + if !_tgt.Equals(_src323) { + return false + } + } + return true +} + +func (p *ResOrderList) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResOrderList(%+v)", *p) +} + +func (p *ResOrderList) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResOrderList", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResOrderList)(nil) + +func (p *ResOrderList) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResOrderShipping struct { + Code int32 `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResOrderShipping() *ResOrderShipping { + return &ResOrderShipping{} +} + +func (p *ResOrderShipping) GetCode() int32 { + return p.Code +} + +func (p *ResOrderShipping) GetMsg() string { + return p.Msg +} + +func (p *ResOrderShipping) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResOrderShipping) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Code = v + } + return nil +} + +func (p *ResOrderShipping) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResOrderShipping) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResOrderShipping"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResOrderShipping) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResOrderShipping) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResOrderShipping) Equals(other *ResOrderShipping) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResOrderShipping) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResOrderShipping(%+v)", *p) +} + +func (p *ResOrderShipping) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResOrderShipping", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResOrderShipping)(nil) + +func (p *ResOrderShipping) Validate() error { + return nil +} + +// Attributes: +// - FurId +// - FurSet +// - FreeCount +// +type ResPetFur struct { + FurId []int32 `thrift:"FurId,1" db:"FurId" json:"FurId"` + FurSet int32 `thrift:"FurSet,2" db:"FurSet" json:"FurSet"` + FreeCount int32 `thrift:"FreeCount,3" db:"FreeCount" json:"FreeCount"` +} + +func NewResPetFur() *ResPetFur { + return &ResPetFur{} +} + +func (p *ResPetFur) GetFurId() []int32 { + return p.FurId +} + +func (p *ResPetFur) GetFurSet() int32 { + return p.FurSet +} + +func (p *ResPetFur) GetFreeCount() int32 { + return p.FreeCount +} + +func (p *ResPetFur) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPetFur) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.FurId = tSlice + for i := 0; i < size; i++ { + var _elem324 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem324 = v + } + p.FurId = append(p.FurId, _elem324) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResPetFur) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.FurSet = v + } + return nil +} + +func (p *ResPetFur) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.FreeCount = v + } + return nil +} + +func (p *ResPetFur) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPetFur"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPetFur) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "FurId", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:FurId: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.FurId)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.FurId { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:FurId: ", p), err) + } + return err +} + +func (p *ResPetFur) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "FurSet", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:FurSet: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.FurSet)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.FurSet (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:FurSet: ", p), err) + } + return err +} + +func (p *ResPetFur) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "FreeCount", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:FreeCount: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.FreeCount)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.FreeCount (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:FreeCount: ", p), err) + } + return err +} + +func (p *ResPetFur) Equals(other *ResPetFur) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.FurId) != len(other.FurId) { + return false + } + for i, _tgt := range p.FurId { + _src325 := other.FurId[i] + if _tgt != _src325 { + return false + } + } + if p.FurSet != other.FurSet { + return false + } + if p.FreeCount != other.FreeCount { + return false + } + return true +} + +func (p *ResPetFur) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPetFur(%+v)", *p) +} + +func (p *ResPetFur) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPetFur", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPetFur)(nil) + +func (p *ResPetFur) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResPetFurBuy struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResPetFurBuy() *ResPetFurBuy { + return &ResPetFurBuy{} +} + +func (p *ResPetFurBuy) GetCode() RES_CODE { + return p.Code +} + +func (p *ResPetFurBuy) GetMsg() string { + return p.Msg +} + +func (p *ResPetFurBuy) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPetFurBuy) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResPetFurBuy) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResPetFurBuy) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPetFurBuy"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPetFurBuy) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResPetFurBuy) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResPetFurBuy) Equals(other *ResPetFurBuy) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResPetFurBuy) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPetFurBuy(%+v)", *p) +} + +func (p *ResPetFurBuy) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPetFurBuy", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPetFurBuy)(nil) + +func (p *ResPetFurBuy) Validate() error { + return nil +} + +// Attributes: +// - Type +// - Diamond +// - Count +// - EndTime +// +type ResPiggyBank struct { + Type int32 `thrift:"Type,1" db:"Type" json:"Type"` + Diamond int32 `thrift:"Diamond,2" db:"Diamond" json:"Diamond"` + Count int32 `thrift:"Count,3" db:"Count" json:"Count"` + EndTime int32 `thrift:"EndTime,4" db:"EndTime" json:"EndTime"` +} + +func NewResPiggyBank() *ResPiggyBank { + return &ResPiggyBank{} +} + +func (p *ResPiggyBank) GetType() int32 { + return p.Type +} + +func (p *ResPiggyBank) GetDiamond() int32 { + return p.Diamond +} + +func (p *ResPiggyBank) GetCount() int32 { + return p.Count +} + +func (p *ResPiggyBank) GetEndTime() int32 { + return p.EndTime +} + +func (p *ResPiggyBank) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPiggyBank) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ResPiggyBank) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Diamond = v + } + return nil +} + +func (p *ResPiggyBank) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Count = v + } + return nil +} + +func (p *ResPiggyBank) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.EndTime = v + } + return nil +} + +func (p *ResPiggyBank) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPiggyBank"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPiggyBank) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Type: ", p), err) + } + return err +} + +func (p *ResPiggyBank) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Diamond", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Diamond: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Diamond)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Diamond (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Diamond: ", p), err) + } + return err +} + +func (p *ResPiggyBank) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Count", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Count: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Count)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Count (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Count: ", p), err) + } + return err +} + +func (p *ResPiggyBank) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EndTime", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:EndTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.EndTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EndTime (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:EndTime: ", p), err) + } + return err +} + +func (p *ResPiggyBank) Equals(other *ResPiggyBank) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Type != other.Type { + return false + } + if p.Diamond != other.Diamond { + return false + } + if p.Count != other.Count { + return false + } + if p.EndTime != other.EndTime { + return false + } + return true +} + +func (p *ResPiggyBank) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPiggyBank(%+v)", *p) +} + +func (p *ResPiggyBank) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPiggyBank", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPiggyBank)(nil) + +func (p *ResPiggyBank) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResPiggyBankReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResPiggyBankReward() *ResPiggyBankReward { + return &ResPiggyBankReward{} +} + +func (p *ResPiggyBankReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResPiggyBankReward) GetMsg() string { + return p.Msg +} + +func (p *ResPiggyBankReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPiggyBankReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResPiggyBankReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResPiggyBankReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPiggyBankReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPiggyBankReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResPiggyBankReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResPiggyBankReward) Equals(other *ResPiggyBankReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResPiggyBankReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPiggyBankReward(%+v)", *p) +} + +func (p *ResPiggyBankReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPiggyBankReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPiggyBankReward)(nil) + +func (p *ResPiggyBankReward) Validate() error { + return nil +} + +// Attributes: +// - DwUin +// - Energy +// - Star +// - RecoverTime +// - Diamond +// - Level +// - Exp +// - Login +// - Logout +// - PExp +// - LoginDay +// +type ResPlayerAsset struct { + DwUin int64 `thrift:"dwUin,1" db:"dwUin" json:"dwUin"` + Energy int32 `thrift:"energy,2" db:"energy" json:"energy"` + Star int32 `thrift:"star,3" db:"star" json:"star"` + RecoverTime int32 `thrift:"recoverTime,4" db:"recoverTime" json:"recoverTime"` + Diamond int32 `thrift:"diamond,5" db:"diamond" json:"diamond"` + Level int32 `thrift:"level,6" db:"level" json:"level"` + Exp int32 `thrift:"exp,7" db:"exp" json:"exp"` + Login int32 `thrift:"Login,8" db:"Login" json:"Login"` + Logout int32 `thrift:"Logout,9" db:"Logout" json:"Logout"` + PExp int32 `thrift:"PExp,10" db:"PExp" json:"PExp"` + LoginDay int32 `thrift:"LoginDay,11" db:"LoginDay" json:"LoginDay"` +} + +func NewResPlayerAsset() *ResPlayerAsset { + return &ResPlayerAsset{} +} + +func (p *ResPlayerAsset) GetDwUin() int64 { + return p.DwUin +} + +func (p *ResPlayerAsset) GetEnergy() int32 { + return p.Energy +} + +func (p *ResPlayerAsset) GetStar() int32 { + return p.Star +} + +func (p *ResPlayerAsset) GetRecoverTime() int32 { + return p.RecoverTime +} + +func (p *ResPlayerAsset) GetDiamond() int32 { + return p.Diamond +} + +func (p *ResPlayerAsset) GetLevel() int32 { + return p.Level +} + +func (p *ResPlayerAsset) GetExp() int32 { + return p.Exp +} + +func (p *ResPlayerAsset) GetLogin() int32 { + return p.Login +} + +func (p *ResPlayerAsset) GetLogout() int32 { + return p.Logout +} + +func (p *ResPlayerAsset) GetPExp() int32 { + return p.PExp +} + +func (p *ResPlayerAsset) GetLoginDay() int32 { + return p.LoginDay +} + +func (p *ResPlayerAsset) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.I32 { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.I32 { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 8: + if fieldTypeId == thrift.I32 { + if err := p.ReadField8(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 9: + if fieldTypeId == thrift.I32 { + if err := p.ReadField9(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 10: + if fieldTypeId == thrift.I32 { + if err := p.ReadField10(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 11: + if fieldTypeId == thrift.I32 { + if err := p.ReadField11(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayerAsset) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.DwUin = v + } + return nil +} + +func (p *ResPlayerAsset) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Energy = v + } + return nil +} + +func (p *ResPlayerAsset) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Star = v + } + return nil +} + +func (p *ResPlayerAsset) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.RecoverTime = v + } + return nil +} + +func (p *ResPlayerAsset) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.Diamond = v + } + return nil +} + +func (p *ResPlayerAsset) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 6: ", err) + } else { + p.Level = v + } + return nil +} + +func (p *ResPlayerAsset) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 7: ", err) + } else { + p.Exp = v + } + return nil +} + +func (p *ResPlayerAsset) ReadField8(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 8: ", err) + } else { + p.Login = v + } + return nil +} + +func (p *ResPlayerAsset) ReadField9(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 9: ", err) + } else { + p.Logout = v + } + return nil +} + +func (p *ResPlayerAsset) ReadField10(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 10: ", err) + } else { + p.PExp = v + } + return nil +} + +func (p *ResPlayerAsset) ReadField11(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 11: ", err) + } else { + p.LoginDay = v + } + return nil +} + +func (p *ResPlayerAsset) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayerAsset"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + if err := p.writeField8(ctx, oprot); err != nil { + return err + } + if err := p.writeField9(ctx, oprot); err != nil { + return err + } + if err := p.writeField10(ctx, oprot); err != nil { + return err + } + if err := p.writeField11(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayerAsset) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "dwUin", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:dwUin: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.DwUin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.dwUin (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:dwUin: ", p), err) + } + return err +} + +func (p *ResPlayerAsset) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "energy", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:energy: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Energy)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.energy (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:energy: ", p), err) + } + return err +} + +func (p *ResPlayerAsset) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "star", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:star: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Star)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.star (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:star: ", p), err) + } + return err +} + +func (p *ResPlayerAsset) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "recoverTime", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:recoverTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.RecoverTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.recoverTime (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:recoverTime: ", p), err) + } + return err +} + +func (p *ResPlayerAsset) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "diamond", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:diamond: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Diamond)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.diamond (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:diamond: ", p), err) + } + return err +} + +func (p *ResPlayerAsset) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "level", thrift.I32, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:level: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Level)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.level (6) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:level: ", p), err) + } + return err +} + +func (p *ResPlayerAsset) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "exp", thrift.I32, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:exp: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Exp)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.exp (7) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:exp: ", p), err) + } + return err +} + +func (p *ResPlayerAsset) writeField8(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Login", thrift.I32, 8); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 8:Login: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Login)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Login (8) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 8:Login: ", p), err) + } + return err +} + +func (p *ResPlayerAsset) writeField9(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Logout", thrift.I32, 9); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 9:Logout: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Logout)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Logout (9) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 9:Logout: ", p), err) + } + return err +} + +func (p *ResPlayerAsset) writeField10(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "PExp", thrift.I32, 10); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 10:PExp: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.PExp)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.PExp (10) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 10:PExp: ", p), err) + } + return err +} + +func (p *ResPlayerAsset) writeField11(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "LoginDay", thrift.I32, 11); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 11:LoginDay: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.LoginDay)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.LoginDay (11) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 11:LoginDay: ", p), err) + } + return err +} + +func (p *ResPlayerAsset) Equals(other *ResPlayerAsset) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.DwUin != other.DwUin { + return false + } + if p.Energy != other.Energy { + return false + } + if p.Star != other.Star { + return false + } + if p.RecoverTime != other.RecoverTime { + return false + } + if p.Diamond != other.Diamond { + return false + } + if p.Level != other.Level { + return false + } + if p.Exp != other.Exp { + return false + } + if p.Login != other.Login { + return false + } + if p.Logout != other.Logout { + return false + } + if p.PExp != other.PExp { + return false + } + if p.LoginDay != other.LoginDay { + return false + } + return true +} + +func (p *ResPlayerAsset) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayerAsset(%+v)", *p) +} + +func (p *ResPlayerAsset) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayerAsset", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayerAsset)(nil) + +func (p *ResPlayerAsset) Validate() error { + return nil +} + +// Attributes: +// - DwUin +// - Energy +// - Star +// - RecoverTime +// - Diamond +// - Level +// - Exp +// - StartOrderId +// - MusicCode +// - Guild +// - PackUnlockCount +// - LastPlayTime +// - Ban +// - UserName +// - LoginTime +// - LogoutTime +// - Node +// - Rolecreatetime +// - EmitOrderCnt +// - NoAd +// - ChampshipsGroupID +// - LastChampGroupID +// - FaceBookId +// - RegisterTime +// +type ResPlayerBaseInfo struct { + DwUin int64 `thrift:"dwUin,1" db:"dwUin" json:"dwUin"` + Energy int32 `thrift:"energy,2" db:"energy" json:"energy"` + Star int32 `thrift:"star,3" db:"star" json:"star"` + RecoverTime int32 `thrift:"recoverTime,4" db:"recoverTime" json:"recoverTime"` + Diamond int32 `thrift:"diamond,5" db:"diamond" json:"diamond"` + Level int32 `thrift:"level,6" db:"level" json:"level"` + Exp int32 `thrift:"exp,7" db:"exp" json:"exp"` + StartOrderId string `thrift:"startOrderId,8" db:"startOrderId" json:"startOrderId"` + MusicCode int32 `thrift:"musicCode,9" db:"musicCode" json:"musicCode"` + Guild int32 `thrift:"guild,10" db:"guild" json:"guild"` + PackUnlockCount int32 `thrift:"packUnlockCount,11" db:"packUnlockCount" json:"packUnlockCount"` + LastPlayTime int32 `thrift:"lastPlayTime,12" db:"lastPlayTime" json:"lastPlayTime"` + Ban int64 `thrift:"ban,13" db:"ban" json:"ban"` + UserName string `thrift:"userName,14" db:"userName" json:"userName"` + LoginTime int32 `thrift:"loginTime,15" db:"loginTime" json:"loginTime"` + LogoutTime int32 `thrift:"logoutTime,16" db:"logoutTime" json:"logoutTime"` + Node int32 `thrift:"node,17" db:"node" json:"node"` + Rolecreatetime int32 `thrift:"rolecreatetime,18" db:"rolecreatetime" json:"rolecreatetime"` + EmitOrderCnt int32 `thrift:"EmitOrderCnt,19" db:"EmitOrderCnt" json:"EmitOrderCnt"` + NoAd int32 `thrift:"NoAd,20" db:"NoAd" json:"NoAd"` + ChampshipsGroupID int32 `thrift:"ChampshipsGroupID,21" db:"ChampshipsGroupID" json:"ChampshipsGroupID"` + LastChampGroupID int32 `thrift:"LastChampGroupID,22" db:"LastChampGroupID" json:"LastChampGroupID"` + FaceBookId string `thrift:"FaceBookId,23" db:"FaceBookId" json:"FaceBookId"` + RegisterTime int32 `thrift:"registerTime,24" db:"registerTime" json:"registerTime"` +} + +func NewResPlayerBaseInfo() *ResPlayerBaseInfo { + return &ResPlayerBaseInfo{} +} + +func (p *ResPlayerBaseInfo) GetDwUin() int64 { + return p.DwUin +} + +func (p *ResPlayerBaseInfo) GetEnergy() int32 { + return p.Energy +} + +func (p *ResPlayerBaseInfo) GetStar() int32 { + return p.Star +} + +func (p *ResPlayerBaseInfo) GetRecoverTime() int32 { + return p.RecoverTime +} + +func (p *ResPlayerBaseInfo) GetDiamond() int32 { + return p.Diamond +} + +func (p *ResPlayerBaseInfo) GetLevel() int32 { + return p.Level +} + +func (p *ResPlayerBaseInfo) GetExp() int32 { + return p.Exp +} + +func (p *ResPlayerBaseInfo) GetStartOrderId() string { + return p.StartOrderId +} + +func (p *ResPlayerBaseInfo) GetMusicCode() int32 { + return p.MusicCode +} + +func (p *ResPlayerBaseInfo) GetGuild() int32 { + return p.Guild +} + +func (p *ResPlayerBaseInfo) GetPackUnlockCount() int32 { + return p.PackUnlockCount +} + +func (p *ResPlayerBaseInfo) GetLastPlayTime() int32 { + return p.LastPlayTime +} + +func (p *ResPlayerBaseInfo) GetBan() int64 { + return p.Ban +} + +func (p *ResPlayerBaseInfo) GetUserName() string { + return p.UserName +} + +func (p *ResPlayerBaseInfo) GetLoginTime() int32 { + return p.LoginTime +} + +func (p *ResPlayerBaseInfo) GetLogoutTime() int32 { + return p.LogoutTime +} + +func (p *ResPlayerBaseInfo) GetNode() int32 { + return p.Node +} + +func (p *ResPlayerBaseInfo) GetRolecreatetime() int32 { + return p.Rolecreatetime +} + +func (p *ResPlayerBaseInfo) GetEmitOrderCnt() int32 { + return p.EmitOrderCnt +} + +func (p *ResPlayerBaseInfo) GetNoAd() int32 { + return p.NoAd +} + +func (p *ResPlayerBaseInfo) GetChampshipsGroupID() int32 { + return p.ChampshipsGroupID +} + +func (p *ResPlayerBaseInfo) GetLastChampGroupID() int32 { + return p.LastChampGroupID +} + +func (p *ResPlayerBaseInfo) GetFaceBookId() string { + return p.FaceBookId +} + +func (p *ResPlayerBaseInfo) GetRegisterTime() int32 { + return p.RegisterTime +} + +func (p *ResPlayerBaseInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.I32 { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.I32 { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 8: + if fieldTypeId == thrift.STRING { + if err := p.ReadField8(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 9: + if fieldTypeId == thrift.I32 { + if err := p.ReadField9(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 10: + if fieldTypeId == thrift.I32 { + if err := p.ReadField10(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 11: + if fieldTypeId == thrift.I32 { + if err := p.ReadField11(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 12: + if fieldTypeId == thrift.I32 { + if err := p.ReadField12(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 13: + if fieldTypeId == thrift.I64 { + if err := p.ReadField13(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 14: + if fieldTypeId == thrift.STRING { + if err := p.ReadField14(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 15: + if fieldTypeId == thrift.I32 { + if err := p.ReadField15(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 16: + if fieldTypeId == thrift.I32 { + if err := p.ReadField16(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 17: + if fieldTypeId == thrift.I32 { + if err := p.ReadField17(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 18: + if fieldTypeId == thrift.I32 { + if err := p.ReadField18(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 19: + if fieldTypeId == thrift.I32 { + if err := p.ReadField19(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 20: + if fieldTypeId == thrift.I32 { + if err := p.ReadField20(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 21: + if fieldTypeId == thrift.I32 { + if err := p.ReadField21(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 22: + if fieldTypeId == thrift.I32 { + if err := p.ReadField22(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 23: + if fieldTypeId == thrift.STRING { + if err := p.ReadField23(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 24: + if fieldTypeId == thrift.I32 { + if err := p.ReadField24(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayerBaseInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.DwUin = v + } + return nil +} + +func (p *ResPlayerBaseInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Energy = v + } + return nil +} + +func (p *ResPlayerBaseInfo) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Star = v + } + return nil +} + +func (p *ResPlayerBaseInfo) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.RecoverTime = v + } + return nil +} + +func (p *ResPlayerBaseInfo) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.Diamond = v + } + return nil +} + +func (p *ResPlayerBaseInfo) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 6: ", err) + } else { + p.Level = v + } + return nil +} + +func (p *ResPlayerBaseInfo) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 7: ", err) + } else { + p.Exp = v + } + return nil +} + +func (p *ResPlayerBaseInfo) ReadField8(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 8: ", err) + } else { + p.StartOrderId = v + } + return nil +} + +func (p *ResPlayerBaseInfo) ReadField9(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 9: ", err) + } else { + p.MusicCode = v + } + return nil +} + +func (p *ResPlayerBaseInfo) ReadField10(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 10: ", err) + } else { + p.Guild = v + } + return nil +} + +func (p *ResPlayerBaseInfo) ReadField11(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 11: ", err) + } else { + p.PackUnlockCount = v + } + return nil +} + +func (p *ResPlayerBaseInfo) ReadField12(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 12: ", err) + } else { + p.LastPlayTime = v + } + return nil +} + +func (p *ResPlayerBaseInfo) ReadField13(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 13: ", err) + } else { + p.Ban = v + } + return nil +} + +func (p *ResPlayerBaseInfo) ReadField14(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 14: ", err) + } else { + p.UserName = v + } + return nil +} + +func (p *ResPlayerBaseInfo) ReadField15(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 15: ", err) + } else { + p.LoginTime = v + } + return nil +} + +func (p *ResPlayerBaseInfo) ReadField16(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 16: ", err) + } else { + p.LogoutTime = v + } + return nil +} + +func (p *ResPlayerBaseInfo) ReadField17(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 17: ", err) + } else { + p.Node = v + } + return nil +} + +func (p *ResPlayerBaseInfo) ReadField18(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 18: ", err) + } else { + p.Rolecreatetime = v + } + return nil +} + +func (p *ResPlayerBaseInfo) ReadField19(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 19: ", err) + } else { + p.EmitOrderCnt = v + } + return nil +} + +func (p *ResPlayerBaseInfo) ReadField20(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 20: ", err) + } else { + p.NoAd = v + } + return nil +} + +func (p *ResPlayerBaseInfo) ReadField21(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 21: ", err) + } else { + p.ChampshipsGroupID = v + } + return nil +} + +func (p *ResPlayerBaseInfo) ReadField22(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 22: ", err) + } else { + p.LastChampGroupID = v + } + return nil +} + +func (p *ResPlayerBaseInfo) ReadField23(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 23: ", err) + } else { + p.FaceBookId = v + } + return nil +} + +func (p *ResPlayerBaseInfo) ReadField24(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 24: ", err) + } else { + p.RegisterTime = v + } + return nil +} + +func (p *ResPlayerBaseInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayerBaseInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + if err := p.writeField8(ctx, oprot); err != nil { + return err + } + if err := p.writeField9(ctx, oprot); err != nil { + return err + } + if err := p.writeField10(ctx, oprot); err != nil { + return err + } + if err := p.writeField11(ctx, oprot); err != nil { + return err + } + if err := p.writeField12(ctx, oprot); err != nil { + return err + } + if err := p.writeField13(ctx, oprot); err != nil { + return err + } + if err := p.writeField14(ctx, oprot); err != nil { + return err + } + if err := p.writeField15(ctx, oprot); err != nil { + return err + } + if err := p.writeField16(ctx, oprot); err != nil { + return err + } + if err := p.writeField17(ctx, oprot); err != nil { + return err + } + if err := p.writeField18(ctx, oprot); err != nil { + return err + } + if err := p.writeField19(ctx, oprot); err != nil { + return err + } + if err := p.writeField20(ctx, oprot); err != nil { + return err + } + if err := p.writeField21(ctx, oprot); err != nil { + return err + } + if err := p.writeField22(ctx, oprot); err != nil { + return err + } + if err := p.writeField23(ctx, oprot); err != nil { + return err + } + if err := p.writeField24(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayerBaseInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "dwUin", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:dwUin: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.DwUin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.dwUin (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:dwUin: ", p), err) + } + return err +} + +func (p *ResPlayerBaseInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "energy", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:energy: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Energy)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.energy (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:energy: ", p), err) + } + return err +} + +func (p *ResPlayerBaseInfo) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "star", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:star: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Star)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.star (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:star: ", p), err) + } + return err +} + +func (p *ResPlayerBaseInfo) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "recoverTime", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:recoverTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.RecoverTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.recoverTime (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:recoverTime: ", p), err) + } + return err +} + +func (p *ResPlayerBaseInfo) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "diamond", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:diamond: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Diamond)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.diamond (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:diamond: ", p), err) + } + return err +} + +func (p *ResPlayerBaseInfo) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "level", thrift.I32, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:level: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Level)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.level (6) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:level: ", p), err) + } + return err +} + +func (p *ResPlayerBaseInfo) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "exp", thrift.I32, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:exp: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Exp)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.exp (7) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:exp: ", p), err) + } + return err +} + +func (p *ResPlayerBaseInfo) writeField8(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "startOrderId", thrift.STRING, 8); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 8:startOrderId: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.StartOrderId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.startOrderId (8) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 8:startOrderId: ", p), err) + } + return err +} + +func (p *ResPlayerBaseInfo) writeField9(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "musicCode", thrift.I32, 9); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 9:musicCode: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.MusicCode)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.musicCode (9) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 9:musicCode: ", p), err) + } + return err +} + +func (p *ResPlayerBaseInfo) writeField10(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "guild", thrift.I32, 10); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 10:guild: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Guild)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.guild (10) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 10:guild: ", p), err) + } + return err +} + +func (p *ResPlayerBaseInfo) writeField11(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "packUnlockCount", thrift.I32, 11); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 11:packUnlockCount: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.PackUnlockCount)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.packUnlockCount (11) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 11:packUnlockCount: ", p), err) + } + return err +} + +func (p *ResPlayerBaseInfo) writeField12(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "lastPlayTime", thrift.I32, 12); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 12:lastPlayTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.LastPlayTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.lastPlayTime (12) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 12:lastPlayTime: ", p), err) + } + return err +} + +func (p *ResPlayerBaseInfo) writeField13(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ban", thrift.I64, 13); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 13:ban: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Ban)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ban (13) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 13:ban: ", p), err) + } + return err +} + +func (p *ResPlayerBaseInfo) writeField14(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "userName", thrift.STRING, 14); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 14:userName: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.UserName)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.userName (14) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 14:userName: ", p), err) + } + return err +} + +func (p *ResPlayerBaseInfo) writeField15(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "loginTime", thrift.I32, 15); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 15:loginTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.LoginTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.loginTime (15) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 15:loginTime: ", p), err) + } + return err +} + +func (p *ResPlayerBaseInfo) writeField16(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "logoutTime", thrift.I32, 16); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 16:logoutTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.LogoutTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.logoutTime (16) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 16:logoutTime: ", p), err) + } + return err +} + +func (p *ResPlayerBaseInfo) writeField17(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "node", thrift.I32, 17); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 17:node: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Node)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.node (17) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 17:node: ", p), err) + } + return err +} + +func (p *ResPlayerBaseInfo) writeField18(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "rolecreatetime", thrift.I32, 18); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 18:rolecreatetime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Rolecreatetime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.rolecreatetime (18) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 18:rolecreatetime: ", p), err) + } + return err +} + +func (p *ResPlayerBaseInfo) writeField19(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EmitOrderCnt", thrift.I32, 19); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 19:EmitOrderCnt: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.EmitOrderCnt)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EmitOrderCnt (19) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 19:EmitOrderCnt: ", p), err) + } + return err +} + +func (p *ResPlayerBaseInfo) writeField20(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "NoAd", thrift.I32, 20); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 20:NoAd: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.NoAd)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.NoAd (20) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 20:NoAd: ", p), err) + } + return err +} + +func (p *ResPlayerBaseInfo) writeField21(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChampshipsGroupID", thrift.I32, 21); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 21:ChampshipsGroupID: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ChampshipsGroupID)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ChampshipsGroupID (21) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 21:ChampshipsGroupID: ", p), err) + } + return err +} + +func (p *ResPlayerBaseInfo) writeField22(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "LastChampGroupID", thrift.I32, 22); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 22:LastChampGroupID: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.LastChampGroupID)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.LastChampGroupID (22) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 22:LastChampGroupID: ", p), err) + } + return err +} + +func (p *ResPlayerBaseInfo) writeField23(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "FaceBookId", thrift.STRING, 23); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 23:FaceBookId: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.FaceBookId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.FaceBookId (23) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 23:FaceBookId: ", p), err) + } + return err +} + +func (p *ResPlayerBaseInfo) writeField24(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "registerTime", thrift.I32, 24); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 24:registerTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.RegisterTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.registerTime (24) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 24:registerTime: ", p), err) + } + return err +} + +func (p *ResPlayerBaseInfo) Equals(other *ResPlayerBaseInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.DwUin != other.DwUin { + return false + } + if p.Energy != other.Energy { + return false + } + if p.Star != other.Star { + return false + } + if p.RecoverTime != other.RecoverTime { + return false + } + if p.Diamond != other.Diamond { + return false + } + if p.Level != other.Level { + return false + } + if p.Exp != other.Exp { + return false + } + if p.StartOrderId != other.StartOrderId { + return false + } + if p.MusicCode != other.MusicCode { + return false + } + if p.Guild != other.Guild { + return false + } + if p.PackUnlockCount != other.PackUnlockCount { + return false + } + if p.LastPlayTime != other.LastPlayTime { + return false + } + if p.Ban != other.Ban { + return false + } + if p.UserName != other.UserName { + return false + } + if p.LoginTime != other.LoginTime { + return false + } + if p.LogoutTime != other.LogoutTime { + return false + } + if p.Node != other.Node { + return false + } + if p.Rolecreatetime != other.Rolecreatetime { + return false + } + if p.EmitOrderCnt != other.EmitOrderCnt { + return false + } + if p.NoAd != other.NoAd { + return false + } + if p.ChampshipsGroupID != other.ChampshipsGroupID { + return false + } + if p.LastChampGroupID != other.LastChampGroupID { + return false + } + if p.FaceBookId != other.FaceBookId { + return false + } + if p.RegisterTime != other.RegisterTime { + return false + } + return true +} + +func (p *ResPlayerBaseInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayerBaseInfo(%+v)", *p) +} + +func (p *ResPlayerBaseInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayerBaseInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayerBaseInfo)(nil) + +func (p *ResPlayerBaseInfo) Validate() error { + return nil +} + +// Attributes: +// - DwUin +// - ImageFrame +// - ImageIcon +// - DecorateCnt +// - NickName +// - PicURL +// - ActiveTime +// - SetEmoji +// +type ResPlayerBriefProfileData struct { + DwUin int64 `thrift:"dwUin,1" db:"dwUin" json:"dwUin"` + ImageFrame int32 `thrift:"ImageFrame,2" db:"ImageFrame" json:"ImageFrame"` + ImageIcon int32 `thrift:"ImageIcon,3" db:"ImageIcon" json:"ImageIcon"` + DecorateCnt int32 `thrift:"DecorateCnt,4" db:"DecorateCnt" json:"DecorateCnt"` + NickName string `thrift:"NickName,5" db:"NickName" json:"NickName"` + PicURL string `thrift:"PicURL,6" db:"PicURL" json:"PicURL"` + ActiveTime int32 `thrift:"ActiveTime,7" db:"ActiveTime" json:"ActiveTime"` + // unused fields # 8 to 10 + SetEmoji map[int32]int32 `thrift:"SetEmoji,11" db:"SetEmoji" json:"SetEmoji"` +} + +func NewResPlayerBriefProfileData() *ResPlayerBriefProfileData { + return &ResPlayerBriefProfileData{} +} + +func (p *ResPlayerBriefProfileData) GetDwUin() int64 { + return p.DwUin +} + +func (p *ResPlayerBriefProfileData) GetImageFrame() int32 { + return p.ImageFrame +} + +func (p *ResPlayerBriefProfileData) GetImageIcon() int32 { + return p.ImageIcon +} + +func (p *ResPlayerBriefProfileData) GetDecorateCnt() int32 { + return p.DecorateCnt +} + +func (p *ResPlayerBriefProfileData) GetNickName() string { + return p.NickName +} + +func (p *ResPlayerBriefProfileData) GetPicURL() string { + return p.PicURL +} + +func (p *ResPlayerBriefProfileData) GetActiveTime() int32 { + return p.ActiveTime +} + +func (p *ResPlayerBriefProfileData) GetSetEmoji() map[int32]int32 { + return p.SetEmoji +} + +func (p *ResPlayerBriefProfileData) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.STRING { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.STRING { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.I32 { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 11: + if fieldTypeId == thrift.MAP { + if err := p.ReadField11(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayerBriefProfileData) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.DwUin = v + } + return nil +} + +func (p *ResPlayerBriefProfileData) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.ImageFrame = v + } + return nil +} + +func (p *ResPlayerBriefProfileData) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.ImageIcon = v + } + return nil +} + +func (p *ResPlayerBriefProfileData) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.DecorateCnt = v + } + return nil +} + +func (p *ResPlayerBriefProfileData) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.NickName = v + } + return nil +} + +func (p *ResPlayerBriefProfileData) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 6: ", err) + } else { + p.PicURL = v + } + return nil +} + +func (p *ResPlayerBriefProfileData) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 7: ", err) + } else { + p.ActiveTime = v + } + return nil +} + +func (p *ResPlayerBriefProfileData) ReadField11(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.SetEmoji = tMap + for i := 0; i < size; i++ { + var _key326 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key326 = v + } + var _val327 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val327 = v + } + p.SetEmoji[_key326] = _val327 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResPlayerBriefProfileData) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayerBriefProfileData"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + if err := p.writeField11(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayerBriefProfileData) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "dwUin", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:dwUin: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.DwUin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.dwUin (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:dwUin: ", p), err) + } + return err +} + +func (p *ResPlayerBriefProfileData) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ImageFrame", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:ImageFrame: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ImageFrame)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ImageFrame (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:ImageFrame: ", p), err) + } + return err +} + +func (p *ResPlayerBriefProfileData) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ImageIcon", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:ImageIcon: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ImageIcon)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ImageIcon (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:ImageIcon: ", p), err) + } + return err +} + +func (p *ResPlayerBriefProfileData) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "DecorateCnt", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:DecorateCnt: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.DecorateCnt)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.DecorateCnt (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:DecorateCnt: ", p), err) + } + return err +} + +func (p *ResPlayerBriefProfileData) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "NickName", thrift.STRING, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:NickName: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.NickName)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.NickName (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:NickName: ", p), err) + } + return err +} + +func (p *ResPlayerBriefProfileData) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "PicURL", thrift.STRING, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:PicURL: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.PicURL)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.PicURL (6) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:PicURL: ", p), err) + } + return err +} + +func (p *ResPlayerBriefProfileData) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ActiveTime", thrift.I32, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:ActiveTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ActiveTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ActiveTime (7) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:ActiveTime: ", p), err) + } + return err +} + +func (p *ResPlayerBriefProfileData) writeField11(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "SetEmoji", thrift.MAP, 11); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 11:SetEmoji: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.SetEmoji)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.SetEmoji { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 11:SetEmoji: ", p), err) + } + return err +} + +func (p *ResPlayerBriefProfileData) Equals(other *ResPlayerBriefProfileData) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.DwUin != other.DwUin { + return false + } + if p.ImageFrame != other.ImageFrame { + return false + } + if p.ImageIcon != other.ImageIcon { + return false + } + if p.DecorateCnt != other.DecorateCnt { + return false + } + if p.NickName != other.NickName { + return false + } + if p.PicURL != other.PicURL { + return false + } + if p.ActiveTime != other.ActiveTime { + return false + } + if len(p.SetEmoji) != len(other.SetEmoji) { + return false + } + for k, _tgt := range p.SetEmoji { + _src328 := other.SetEmoji[k] + if _tgt != _src328 { + return false + } + } + return true +} + +func (p *ResPlayerBriefProfileData) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayerBriefProfileData(%+v)", *p) +} + +func (p *ResPlayerBriefProfileData) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayerBriefProfileData", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayerBriefProfileData)(nil) + +func (p *ResPlayerBriefProfileData) Validate() error { + return nil +} + +// Attributes: +// - DwUin +// - MChessData +// - ChessList +// - ChessBuff +// +type ResPlayerChessData struct { + DwUin int64 `thrift:"dwUin,1" db:"dwUin" json:"dwUin"` + MChessData map[string]int32 `thrift:"MChessData,2" db:"MChessData" json:"MChessData"` + ChessList []int32 `thrift:"ChessList,3" db:"ChessList" json:"ChessList"` + ChessBuff []int32 `thrift:"ChessBuff,4" db:"ChessBuff" json:"ChessBuff"` +} + +func NewResPlayerChessData() *ResPlayerChessData { + return &ResPlayerChessData{} +} + +func (p *ResPlayerChessData) GetDwUin() int64 { + return p.DwUin +} + +func (p *ResPlayerChessData) GetMChessData() map[string]int32 { + return p.MChessData +} + +func (p *ResPlayerChessData) GetChessList() []int32 { + return p.ChessList +} + +func (p *ResPlayerChessData) GetChessBuff() []int32 { + return p.ChessBuff +} + +func (p *ResPlayerChessData) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.MAP { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.LIST { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.LIST { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayerChessData) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.DwUin = v + } + return nil +} + +func (p *ResPlayerChessData) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[string]int32, size) + p.MChessData = tMap + for i := 0; i < size; i++ { + var _key329 string + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key329 = v + } + var _val330 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val330 = v + } + p.MChessData[_key329] = _val330 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResPlayerChessData) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.ChessList = tSlice + for i := 0; i < size; i++ { + var _elem331 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem331 = v + } + p.ChessList = append(p.ChessList, _elem331) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResPlayerChessData) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.ChessBuff = tSlice + for i := 0; i < size; i++ { + var _elem332 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem332 = v + } + p.ChessBuff = append(p.ChessBuff, _elem332) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResPlayerChessData) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayerChessData"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayerChessData) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "dwUin", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:dwUin: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.DwUin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.dwUin (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:dwUin: ", p), err) + } + return err +} + +func (p *ResPlayerChessData) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MChessData", thrift.MAP, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:MChessData: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.STRING, thrift.I32, len(p.MChessData)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.MChessData { + if err := oprot.WriteString(ctx, string(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:MChessData: ", p), err) + } + return err +} + +func (p *ResPlayerChessData) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChessList", thrift.LIST, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:ChessList: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.ChessList)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.ChessList { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:ChessList: ", p), err) + } + return err +} + +func (p *ResPlayerChessData) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChessBuff", thrift.LIST, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:ChessBuff: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.ChessBuff)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.ChessBuff { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:ChessBuff: ", p), err) + } + return err +} + +func (p *ResPlayerChessData) Equals(other *ResPlayerChessData) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.DwUin != other.DwUin { + return false + } + if len(p.MChessData) != len(other.MChessData) { + return false + } + for k, _tgt := range p.MChessData { + _src333 := other.MChessData[k] + if _tgt != _src333 { + return false + } + } + if len(p.ChessList) != len(other.ChessList) { + return false + } + for i, _tgt := range p.ChessList { + _src334 := other.ChessList[i] + if _tgt != _src334 { + return false + } + } + if len(p.ChessBuff) != len(other.ChessBuff) { + return false + } + for i, _tgt := range p.ChessBuff { + _src335 := other.ChessBuff[i] + if _tgt != _src335 { + return false + } + } + return true +} + +func (p *ResPlayerChessData) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayerChessData(%+v)", *p) +} + +func (p *ResPlayerChessData) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayerChessData", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayerChessData)(nil) + +func (p *ResPlayerChessData) Validate() error { + return nil +} + +// Attributes: +// - ChessList +// - ChessBuff +// - ChessBag +// - RetireEmit +// - Honor +// - PartBag +// - RetireReward +// +type ResPlayerChessInfo struct { + ChessList []int32 `thrift:"ChessList,1" db:"ChessList" json:"ChessList"` + ChessBuff []int32 `thrift:"ChessBuff,2" db:"ChessBuff" json:"ChessBuff"` + ChessBag *ChessBag `thrift:"ChessBag,3" db:"ChessBag" json:"ChessBag"` + RetireEmit []string `thrift:"RetireEmit,4" db:"RetireEmit" json:"RetireEmit"` + Honor []int32 `thrift:"Honor,5" db:"Honor" json:"Honor"` + PartBag *PartBag `thrift:"PartBag,6" db:"PartBag" json:"PartBag"` + RetireReward []string `thrift:"RetireReward,7" db:"RetireReward" json:"RetireReward"` +} + +func NewResPlayerChessInfo() *ResPlayerChessInfo { + return &ResPlayerChessInfo{} +} + +func (p *ResPlayerChessInfo) GetChessList() []int32 { + return p.ChessList +} + +func (p *ResPlayerChessInfo) GetChessBuff() []int32 { + return p.ChessBuff +} + +var ResPlayerChessInfo_ChessBag_DEFAULT *ChessBag + +func (p *ResPlayerChessInfo) GetChessBag() *ChessBag { + if !p.IsSetChessBag() { + return ResPlayerChessInfo_ChessBag_DEFAULT + } + return p.ChessBag +} + +func (p *ResPlayerChessInfo) GetRetireEmit() []string { + return p.RetireEmit +} + +func (p *ResPlayerChessInfo) GetHonor() []int32 { + return p.Honor +} + +var ResPlayerChessInfo_PartBag_DEFAULT *PartBag + +func (p *ResPlayerChessInfo) GetPartBag() *PartBag { + if !p.IsSetPartBag() { + return ResPlayerChessInfo_PartBag_DEFAULT + } + return p.PartBag +} + +func (p *ResPlayerChessInfo) GetRetireReward() []string { + return p.RetireReward +} + +func (p *ResPlayerChessInfo) IsSetChessBag() bool { + return p.ChessBag != nil +} + +func (p *ResPlayerChessInfo) IsSetPartBag() bool { + return p.PartBag != nil +} + +func (p *ResPlayerChessInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.LIST { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.LIST { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.LIST { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.LIST { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayerChessInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.ChessList = tSlice + for i := 0; i < size; i++ { + var _elem336 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem336 = v + } + p.ChessList = append(p.ChessList, _elem336) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResPlayerChessInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.ChessBuff = tSlice + for i := 0; i < size; i++ { + var _elem337 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem337 = v + } + p.ChessBuff = append(p.ChessBuff, _elem337) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResPlayerChessInfo) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + p.ChessBag = &ChessBag{} + if err := p.ChessBag.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.ChessBag), err) + } + return nil +} + +func (p *ResPlayerChessInfo) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]string, 0, size) + p.RetireEmit = tSlice + for i := 0; i < size; i++ { + var _elem338 string + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem338 = v + } + p.RetireEmit = append(p.RetireEmit, _elem338) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResPlayerChessInfo) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.Honor = tSlice + for i := 0; i < size; i++ { + var _elem339 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem339 = v + } + p.Honor = append(p.Honor, _elem339) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResPlayerChessInfo) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + p.PartBag = &PartBag{} + if err := p.PartBag.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.PartBag), err) + } + return nil +} + +func (p *ResPlayerChessInfo) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]string, 0, size) + p.RetireReward = tSlice + for i := 0; i < size; i++ { + var _elem340 string + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem340 = v + } + p.RetireReward = append(p.RetireReward, _elem340) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResPlayerChessInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayerChessInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayerChessInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChessList", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ChessList: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.ChessList)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.ChessList { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ChessList: ", p), err) + } + return err +} + +func (p *ResPlayerChessInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChessBuff", thrift.LIST, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:ChessBuff: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.ChessBuff)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.ChessBuff { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:ChessBuff: ", p), err) + } + return err +} + +func (p *ResPlayerChessInfo) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChessBag", thrift.STRUCT, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:ChessBag: ", p), err) + } + if err := p.ChessBag.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.ChessBag), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:ChessBag: ", p), err) + } + return err +} + +func (p *ResPlayerChessInfo) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "RetireEmit", thrift.LIST, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:RetireEmit: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRING, len(p.RetireEmit)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.RetireEmit { + if err := oprot.WriteString(ctx, string(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:RetireEmit: ", p), err) + } + return err +} + +func (p *ResPlayerChessInfo) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Honor", thrift.LIST, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Honor: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.Honor)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Honor { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Honor: ", p), err) + } + return err +} + +func (p *ResPlayerChessInfo) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "PartBag", thrift.STRUCT, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:PartBag: ", p), err) + } + if err := p.PartBag.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.PartBag), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:PartBag: ", p), err) + } + return err +} + +func (p *ResPlayerChessInfo) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "RetireReward", thrift.LIST, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:RetireReward: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRING, len(p.RetireReward)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.RetireReward { + if err := oprot.WriteString(ctx, string(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:RetireReward: ", p), err) + } + return err +} + +func (p *ResPlayerChessInfo) Equals(other *ResPlayerChessInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.ChessList) != len(other.ChessList) { + return false + } + for i, _tgt := range p.ChessList { + _src341 := other.ChessList[i] + if _tgt != _src341 { + return false + } + } + if len(p.ChessBuff) != len(other.ChessBuff) { + return false + } + for i, _tgt := range p.ChessBuff { + _src342 := other.ChessBuff[i] + if _tgt != _src342 { + return false + } + } + if !p.ChessBag.Equals(other.ChessBag) { + return false + } + if len(p.RetireEmit) != len(other.RetireEmit) { + return false + } + for i, _tgt := range p.RetireEmit { + _src343 := other.RetireEmit[i] + if _tgt != _src343 { + return false + } + } + if len(p.Honor) != len(other.Honor) { + return false + } + for i, _tgt := range p.Honor { + _src344 := other.Honor[i] + if _tgt != _src344 { + return false + } + } + if !p.PartBag.Equals(other.PartBag) { + return false + } + if len(p.RetireReward) != len(other.RetireReward) { + return false + } + for i, _tgt := range p.RetireReward { + _src345 := other.RetireReward[i] + if _tgt != _src345 { + return false + } + } + return true +} + +func (p *ResPlayerChessInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayerChessInfo(%+v)", *p) +} + +func (p *ResPlayerChessInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayerChessInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayerChessInfo)(nil) + +func (p *ResPlayerChessInfo) Validate() error { + return nil +} + +// Attributes: +// - Type +// - Name +// - Face +// - Count +// - FacebookPic +// - Uids +// +type ResPlayerLougouMsg struct { + Type int32 `thrift:"Type,1" db:"Type" json:"Type"` + Name string `thrift:"Name,2" db:"Name" json:"Name"` + Face []int32 `thrift:"Face,3" db:"Face" json:"Face"` + Count int32 `thrift:"Count,4" db:"Count" json:"Count"` + FacebookPic []string `thrift:"FacebookPic,5" db:"FacebookPic" json:"FacebookPic"` + Uids []int64 `thrift:"Uids,6" db:"Uids" json:"Uids"` +} + +func NewResPlayerLougouMsg() *ResPlayerLougouMsg { + return &ResPlayerLougouMsg{} +} + +func (p *ResPlayerLougouMsg) GetType() int32 { + return p.Type +} + +func (p *ResPlayerLougouMsg) GetName() string { + return p.Name +} + +func (p *ResPlayerLougouMsg) GetFace() []int32 { + return p.Face +} + +func (p *ResPlayerLougouMsg) GetCount() int32 { + return p.Count +} + +func (p *ResPlayerLougouMsg) GetFacebookPic() []string { + return p.FacebookPic +} + +func (p *ResPlayerLougouMsg) GetUids() []int64 { + return p.Uids +} + +func (p *ResPlayerLougouMsg) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.LIST { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.LIST { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.LIST { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayerLougouMsg) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ResPlayerLougouMsg) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Name = v + } + return nil +} + +func (p *ResPlayerLougouMsg) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.Face = tSlice + for i := 0; i < size; i++ { + var _elem346 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem346 = v + } + p.Face = append(p.Face, _elem346) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResPlayerLougouMsg) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Count = v + } + return nil +} + +func (p *ResPlayerLougouMsg) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]string, 0, size) + p.FacebookPic = tSlice + for i := 0; i < size; i++ { + var _elem347 string + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem347 = v + } + p.FacebookPic = append(p.FacebookPic, _elem347) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResPlayerLougouMsg) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int64, 0, size) + p.Uids = tSlice + for i := 0; i < size; i++ { + var _elem348 int64 + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem348 = v + } + p.Uids = append(p.Uids, _elem348) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResPlayerLougouMsg) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayerLougouMsg"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayerLougouMsg) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Type: ", p), err) + } + return err +} + +func (p *ResPlayerLougouMsg) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Name", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Name: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Name)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Name (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Name: ", p), err) + } + return err +} + +func (p *ResPlayerLougouMsg) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Face", thrift.LIST, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Face: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.Face)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Face { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Face: ", p), err) + } + return err +} + +func (p *ResPlayerLougouMsg) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Count", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Count: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Count)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Count (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Count: ", p), err) + } + return err +} + +func (p *ResPlayerLougouMsg) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "FacebookPic", thrift.LIST, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:FacebookPic: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRING, len(p.FacebookPic)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.FacebookPic { + if err := oprot.WriteString(ctx, string(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:FacebookPic: ", p), err) + } + return err +} + +func (p *ResPlayerLougouMsg) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uids", thrift.LIST, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:Uids: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I64, len(p.Uids)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Uids { + if err := oprot.WriteI64(ctx, int64(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:Uids: ", p), err) + } + return err +} + +func (p *ResPlayerLougouMsg) Equals(other *ResPlayerLougouMsg) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Type != other.Type { + return false + } + if p.Name != other.Name { + return false + } + if len(p.Face) != len(other.Face) { + return false + } + for i, _tgt := range p.Face { + _src349 := other.Face[i] + if _tgt != _src349 { + return false + } + } + if p.Count != other.Count { + return false + } + if len(p.FacebookPic) != len(other.FacebookPic) { + return false + } + for i, _tgt := range p.FacebookPic { + _src350 := other.FacebookPic[i] + if _tgt != _src350 { + return false + } + } + if len(p.Uids) != len(other.Uids) { + return false + } + for i, _tgt := range p.Uids { + _src351 := other.Uids[i] + if _tgt != _src351 { + return false + } + } + return true +} + +func (p *ResPlayerLougouMsg) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayerLougouMsg(%+v)", *p) +} + +func (p *ResPlayerLougouMsg) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayerLougouMsg", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayerLougouMsg)(nil) + +func (p *ResPlayerLougouMsg) Validate() error { + return nil +} + +// Attributes: +// - DwUin +// - ImageFrame +// - ImageIcon +// - DecorateCnt +// - NickName +// - PicURL +// - UnlockFrame +// - UnlockIcon +// - ActiveTime +// +type ResPlayerProfileData struct { + DwUin int64 `thrift:"dwUin,1" db:"dwUin" json:"dwUin"` + ImageFrame int32 `thrift:"ImageFrame,2" db:"ImageFrame" json:"ImageFrame"` + ImageIcon int32 `thrift:"ImageIcon,3" db:"ImageIcon" json:"ImageIcon"` + DecorateCnt int32 `thrift:"DecorateCnt,4" db:"DecorateCnt" json:"DecorateCnt"` + NickName string `thrift:"NickName,5" db:"NickName" json:"NickName"` + PicURL string `thrift:"PicURL,6" db:"PicURL" json:"PicURL"` + UnlockFrame string `thrift:"UnlockFrame,7" db:"UnlockFrame" json:"UnlockFrame"` + UnlockIcon string `thrift:"UnlockIcon,8" db:"UnlockIcon" json:"UnlockIcon"` + ActiveTime int32 `thrift:"ActiveTime,9" db:"ActiveTime" json:"ActiveTime"` +} + +func NewResPlayerProfileData() *ResPlayerProfileData { + return &ResPlayerProfileData{} +} + +func (p *ResPlayerProfileData) GetDwUin() int64 { + return p.DwUin +} + +func (p *ResPlayerProfileData) GetImageFrame() int32 { + return p.ImageFrame +} + +func (p *ResPlayerProfileData) GetImageIcon() int32 { + return p.ImageIcon +} + +func (p *ResPlayerProfileData) GetDecorateCnt() int32 { + return p.DecorateCnt +} + +func (p *ResPlayerProfileData) GetNickName() string { + return p.NickName +} + +func (p *ResPlayerProfileData) GetPicURL() string { + return p.PicURL +} + +func (p *ResPlayerProfileData) GetUnlockFrame() string { + return p.UnlockFrame +} + +func (p *ResPlayerProfileData) GetUnlockIcon() string { + return p.UnlockIcon +} + +func (p *ResPlayerProfileData) GetActiveTime() int32 { + return p.ActiveTime +} + +func (p *ResPlayerProfileData) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.STRING { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.STRING { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.STRING { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 8: + if fieldTypeId == thrift.STRING { + if err := p.ReadField8(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 9: + if fieldTypeId == thrift.I32 { + if err := p.ReadField9(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayerProfileData) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.DwUin = v + } + return nil +} + +func (p *ResPlayerProfileData) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.ImageFrame = v + } + return nil +} + +func (p *ResPlayerProfileData) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.ImageIcon = v + } + return nil +} + +func (p *ResPlayerProfileData) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.DecorateCnt = v + } + return nil +} + +func (p *ResPlayerProfileData) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.NickName = v + } + return nil +} + +func (p *ResPlayerProfileData) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 6: ", err) + } else { + p.PicURL = v + } + return nil +} + +func (p *ResPlayerProfileData) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 7: ", err) + } else { + p.UnlockFrame = v + } + return nil +} + +func (p *ResPlayerProfileData) ReadField8(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 8: ", err) + } else { + p.UnlockIcon = v + } + return nil +} + +func (p *ResPlayerProfileData) ReadField9(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 9: ", err) + } else { + p.ActiveTime = v + } + return nil +} + +func (p *ResPlayerProfileData) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayerProfileData"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + if err := p.writeField8(ctx, oprot); err != nil { + return err + } + if err := p.writeField9(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayerProfileData) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "dwUin", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:dwUin: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.DwUin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.dwUin (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:dwUin: ", p), err) + } + return err +} + +func (p *ResPlayerProfileData) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ImageFrame", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:ImageFrame: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ImageFrame)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ImageFrame (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:ImageFrame: ", p), err) + } + return err +} + +func (p *ResPlayerProfileData) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ImageIcon", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:ImageIcon: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ImageIcon)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ImageIcon (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:ImageIcon: ", p), err) + } + return err +} + +func (p *ResPlayerProfileData) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "DecorateCnt", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:DecorateCnt: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.DecorateCnt)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.DecorateCnt (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:DecorateCnt: ", p), err) + } + return err +} + +func (p *ResPlayerProfileData) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "NickName", thrift.STRING, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:NickName: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.NickName)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.NickName (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:NickName: ", p), err) + } + return err +} + +func (p *ResPlayerProfileData) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "PicURL", thrift.STRING, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:PicURL: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.PicURL)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.PicURL (6) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:PicURL: ", p), err) + } + return err +} + +func (p *ResPlayerProfileData) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "UnlockFrame", thrift.STRING, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:UnlockFrame: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.UnlockFrame)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.UnlockFrame (7) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:UnlockFrame: ", p), err) + } + return err +} + +func (p *ResPlayerProfileData) writeField8(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "UnlockIcon", thrift.STRING, 8); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 8:UnlockIcon: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.UnlockIcon)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.UnlockIcon (8) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 8:UnlockIcon: ", p), err) + } + return err +} + +func (p *ResPlayerProfileData) writeField9(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ActiveTime", thrift.I32, 9); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 9:ActiveTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ActiveTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ActiveTime (9) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 9:ActiveTime: ", p), err) + } + return err +} + +func (p *ResPlayerProfileData) Equals(other *ResPlayerProfileData) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.DwUin != other.DwUin { + return false + } + if p.ImageFrame != other.ImageFrame { + return false + } + if p.ImageIcon != other.ImageIcon { + return false + } + if p.DecorateCnt != other.DecorateCnt { + return false + } + if p.NickName != other.NickName { + return false + } + if p.PicURL != other.PicURL { + return false + } + if p.UnlockFrame != other.UnlockFrame { + return false + } + if p.UnlockIcon != other.UnlockIcon { + return false + } + if p.ActiveTime != other.ActiveTime { + return false + } + return true +} + +func (p *ResPlayerProfileData) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayerProfileData(%+v)", *p) +} + +func (p *ResPlayerProfileData) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayerProfileData", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayerProfileData)(nil) + +func (p *ResPlayerProfileData) Validate() error { + return nil +} + +// Attributes: +// - Uid +// - Name +// - Face +// - Avatar +// - Level +// - Score +// - Type +// - PlayroomSet +// - DressSet +// - FurSet +// - Last +// - PetName +// +type ResPlayerRank struct { + Uid int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` + Name string `thrift:"Name,2" db:"Name" json:"Name"` + Face int32 `thrift:"Face,3" db:"Face" json:"Face"` + Avatar int32 `thrift:"Avatar,4" db:"Avatar" json:"Avatar"` + Level int32 `thrift:"Level,5" db:"Level" json:"Level"` + Score float64 `thrift:"score,6" db:"score" json:"score"` + Type int32 `thrift:"type,7" db:"type" json:"type"` + PlayroomSet map[int32]int32 `thrift:"PlayroomSet,8" db:"PlayroomSet" json:"PlayroomSet"` + DressSet map[int32]int32 `thrift:"DressSet,9" db:"DressSet" json:"DressSet"` + FurSet int32 `thrift:"FurSet,10" db:"FurSet" json:"FurSet"` + Last *ActLog `thrift:"Last,11" db:"Last" json:"Last"` + PetName string `thrift:"PetName,12" db:"PetName" json:"PetName"` +} + +func NewResPlayerRank() *ResPlayerRank { + return &ResPlayerRank{} +} + +func (p *ResPlayerRank) GetUid() int64 { + return p.Uid +} + +func (p *ResPlayerRank) GetName() string { + return p.Name +} + +func (p *ResPlayerRank) GetFace() int32 { + return p.Face +} + +func (p *ResPlayerRank) GetAvatar() int32 { + return p.Avatar +} + +func (p *ResPlayerRank) GetLevel() int32 { + return p.Level +} + +func (p *ResPlayerRank) GetScore() float64 { + return p.Score +} + +func (p *ResPlayerRank) GetType() int32 { + return p.Type +} + +func (p *ResPlayerRank) GetPlayroomSet() map[int32]int32 { + return p.PlayroomSet +} + +func (p *ResPlayerRank) GetDressSet() map[int32]int32 { + return p.DressSet +} + +func (p *ResPlayerRank) GetFurSet() int32 { + return p.FurSet +} + +var ResPlayerRank_Last_DEFAULT *ActLog + +func (p *ResPlayerRank) GetLast() *ActLog { + if !p.IsSetLast() { + return ResPlayerRank_Last_DEFAULT + } + return p.Last +} + +func (p *ResPlayerRank) GetPetName() string { + return p.PetName +} + +func (p *ResPlayerRank) IsSetLast() bool { + return p.Last != nil +} + +func (p *ResPlayerRank) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.DOUBLE { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.I32 { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 8: + if fieldTypeId == thrift.MAP { + if err := p.ReadField8(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 9: + if fieldTypeId == thrift.MAP { + if err := p.ReadField9(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 10: + if fieldTypeId == thrift.I32 { + if err := p.ReadField10(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 11: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField11(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 12: + if fieldTypeId == thrift.STRING { + if err := p.ReadField12(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayerRank) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ResPlayerRank) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Name = v + } + return nil +} + +func (p *ResPlayerRank) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Face = v + } + return nil +} + +func (p *ResPlayerRank) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Avatar = v + } + return nil +} + +func (p *ResPlayerRank) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.Level = v + } + return nil +} + +func (p *ResPlayerRank) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadDouble(ctx); err != nil { + return thrift.PrependError("error reading field 6: ", err) + } else { + p.Score = v + } + return nil +} + +func (p *ResPlayerRank) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 7: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ResPlayerRank) ReadField8(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.PlayroomSet = tMap + for i := 0; i < size; i++ { + var _key352 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key352 = v + } + var _val353 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val353 = v + } + p.PlayroomSet[_key352] = _val353 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResPlayerRank) ReadField9(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.DressSet = tMap + for i := 0; i < size; i++ { + var _key354 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key354 = v + } + var _val355 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val355 = v + } + p.DressSet[_key354] = _val355 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResPlayerRank) ReadField10(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 10: ", err) + } else { + p.FurSet = v + } + return nil +} + +func (p *ResPlayerRank) ReadField11(ctx context.Context, iprot thrift.TProtocol) error { + p.Last = &ActLog{} + if err := p.Last.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.Last), err) + } + return nil +} + +func (p *ResPlayerRank) ReadField12(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 12: ", err) + } else { + p.PetName = v + } + return nil +} + +func (p *ResPlayerRank) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayerRank"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + if err := p.writeField8(ctx, oprot); err != nil { + return err + } + if err := p.writeField9(ctx, oprot); err != nil { + return err + } + if err := p.writeField10(ctx, oprot); err != nil { + return err + } + if err := p.writeField11(ctx, oprot); err != nil { + return err + } + if err := p.writeField12(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayerRank) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *ResPlayerRank) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Name", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Name: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Name)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Name (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Name: ", p), err) + } + return err +} + +func (p *ResPlayerRank) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Face", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Face: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Face)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Face (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Face: ", p), err) + } + return err +} + +func (p *ResPlayerRank) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Avatar", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Avatar: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Avatar)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Avatar (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Avatar: ", p), err) + } + return err +} + +func (p *ResPlayerRank) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Level", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Level: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Level)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Level (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Level: ", p), err) + } + return err +} + +func (p *ResPlayerRank) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "score", thrift.DOUBLE, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:score: ", p), err) + } + if err := oprot.WriteDouble(ctx, float64(p.Score)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.score (6) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:score: ", p), err) + } + return err +} + +func (p *ResPlayerRank) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "type", thrift.I32, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.type (7) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:type: ", p), err) + } + return err +} + +func (p *ResPlayerRank) writeField8(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "PlayroomSet", thrift.MAP, 8); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 8:PlayroomSet: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.PlayroomSet)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.PlayroomSet { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 8:PlayroomSet: ", p), err) + } + return err +} + +func (p *ResPlayerRank) writeField9(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "DressSet", thrift.MAP, 9); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 9:DressSet: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.DressSet)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.DressSet { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 9:DressSet: ", p), err) + } + return err +} + +func (p *ResPlayerRank) writeField10(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "FurSet", thrift.I32, 10); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 10:FurSet: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.FurSet)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.FurSet (10) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 10:FurSet: ", p), err) + } + return err +} + +func (p *ResPlayerRank) writeField11(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Last", thrift.STRUCT, 11); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 11:Last: ", p), err) + } + if err := p.Last.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.Last), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 11:Last: ", p), err) + } + return err +} + +func (p *ResPlayerRank) writeField12(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "PetName", thrift.STRING, 12); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 12:PetName: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.PetName)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.PetName (12) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 12:PetName: ", p), err) + } + return err +} + +func (p *ResPlayerRank) Equals(other *ResPlayerRank) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Uid != other.Uid { + return false + } + if p.Name != other.Name { + return false + } + if p.Face != other.Face { + return false + } + if p.Avatar != other.Avatar { + return false + } + if p.Level != other.Level { + return false + } + if p.Score != other.Score { + return false + } + if p.Type != other.Type { + return false + } + if len(p.PlayroomSet) != len(other.PlayroomSet) { + return false + } + for k, _tgt := range p.PlayroomSet { + _src356 := other.PlayroomSet[k] + if _tgt != _src356 { + return false + } + } + if len(p.DressSet) != len(other.DressSet) { + return false + } + for k, _tgt := range p.DressSet { + _src357 := other.DressSet[k] + if _tgt != _src357 { + return false + } + } + if p.FurSet != other.FurSet { + return false + } + if !p.Last.Equals(other.Last) { + return false + } + if p.PetName != other.PetName { + return false + } + return true +} + +func (p *ResPlayerRank) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayerRank(%+v)", *p) +} + +func (p *ResPlayerRank) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayerRank", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayerRank)(nil) + +func (p *ResPlayerRank) Validate() error { + return nil +} + +// Attributes: +// - Uid +// - Name +// - Face +// - Avatar +// - Level +// - Decorate +// - Login +// - Loginout +// - Facebook +// - Emoji +// - AddTime +// - Interact +// +type ResPlayerSimple struct { + Uid int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` + Name string `thrift:"Name,2" db:"Name" json:"Name"` + Face int32 `thrift:"Face,3" db:"Face" json:"Face"` + Avatar int32 `thrift:"Avatar,4" db:"Avatar" json:"Avatar"` + Level int32 `thrift:"Level,5" db:"Level" json:"Level"` + Decorate int32 `thrift:"Decorate,6" db:"Decorate" json:"Decorate"` + Login int32 `thrift:"login,7" db:"login" json:"login"` + Loginout int32 `thrift:"loginout,8" db:"loginout" json:"loginout"` + Facebook string `thrift:"Facebook,9" db:"Facebook" json:"Facebook"` + Emoji map[int32]int32 `thrift:"Emoji,10" db:"Emoji" json:"Emoji"` + AddTime int64 `thrift:"AddTime,11" db:"AddTime" json:"AddTime"` + Interact int64 `thrift:"Interact,12" db:"Interact" json:"Interact"` +} + +func NewResPlayerSimple() *ResPlayerSimple { + return &ResPlayerSimple{} +} + +func (p *ResPlayerSimple) GetUid() int64 { + return p.Uid +} + +func (p *ResPlayerSimple) GetName() string { + return p.Name +} + +func (p *ResPlayerSimple) GetFace() int32 { + return p.Face +} + +func (p *ResPlayerSimple) GetAvatar() int32 { + return p.Avatar +} + +func (p *ResPlayerSimple) GetLevel() int32 { + return p.Level +} + +func (p *ResPlayerSimple) GetDecorate() int32 { + return p.Decorate +} + +func (p *ResPlayerSimple) GetLogin() int32 { + return p.Login +} + +func (p *ResPlayerSimple) GetLoginout() int32 { + return p.Loginout +} + +func (p *ResPlayerSimple) GetFacebook() string { + return p.Facebook +} + +func (p *ResPlayerSimple) GetEmoji() map[int32]int32 { + return p.Emoji +} + +func (p *ResPlayerSimple) GetAddTime() int64 { + return p.AddTime +} + +func (p *ResPlayerSimple) GetInteract() int64 { + return p.Interact +} + +func (p *ResPlayerSimple) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.I32 { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.I32 { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 8: + if fieldTypeId == thrift.I32 { + if err := p.ReadField8(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 9: + if fieldTypeId == thrift.STRING { + if err := p.ReadField9(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 10: + if fieldTypeId == thrift.MAP { + if err := p.ReadField10(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 11: + if fieldTypeId == thrift.I64 { + if err := p.ReadField11(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 12: + if fieldTypeId == thrift.I64 { + if err := p.ReadField12(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayerSimple) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ResPlayerSimple) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Name = v + } + return nil +} + +func (p *ResPlayerSimple) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Face = v + } + return nil +} + +func (p *ResPlayerSimple) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Avatar = v + } + return nil +} + +func (p *ResPlayerSimple) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.Level = v + } + return nil +} + +func (p *ResPlayerSimple) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 6: ", err) + } else { + p.Decorate = v + } + return nil +} + +func (p *ResPlayerSimple) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 7: ", err) + } else { + p.Login = v + } + return nil +} + +func (p *ResPlayerSimple) ReadField8(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 8: ", err) + } else { + p.Loginout = v + } + return nil +} + +func (p *ResPlayerSimple) ReadField9(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 9: ", err) + } else { + p.Facebook = v + } + return nil +} + +func (p *ResPlayerSimple) ReadField10(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.Emoji = tMap + for i := 0; i < size; i++ { + var _key358 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key358 = v + } + var _val359 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val359 = v + } + p.Emoji[_key358] = _val359 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResPlayerSimple) ReadField11(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 11: ", err) + } else { + p.AddTime = v + } + return nil +} + +func (p *ResPlayerSimple) ReadField12(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 12: ", err) + } else { + p.Interact = v + } + return nil +} + +func (p *ResPlayerSimple) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayerSimple"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + if err := p.writeField8(ctx, oprot); err != nil { + return err + } + if err := p.writeField9(ctx, oprot); err != nil { + return err + } + if err := p.writeField10(ctx, oprot); err != nil { + return err + } + if err := p.writeField11(ctx, oprot); err != nil { + return err + } + if err := p.writeField12(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayerSimple) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *ResPlayerSimple) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Name", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Name: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Name)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Name (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Name: ", p), err) + } + return err +} + +func (p *ResPlayerSimple) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Face", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Face: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Face)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Face (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Face: ", p), err) + } + return err +} + +func (p *ResPlayerSimple) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Avatar", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Avatar: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Avatar)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Avatar (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Avatar: ", p), err) + } + return err +} + +func (p *ResPlayerSimple) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Level", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Level: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Level)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Level (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Level: ", p), err) + } + return err +} + +func (p *ResPlayerSimple) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Decorate", thrift.I32, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:Decorate: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Decorate)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Decorate (6) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:Decorate: ", p), err) + } + return err +} + +func (p *ResPlayerSimple) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "login", thrift.I32, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:login: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Login)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.login (7) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:login: ", p), err) + } + return err +} + +func (p *ResPlayerSimple) writeField8(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "loginout", thrift.I32, 8); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 8:loginout: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Loginout)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.loginout (8) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 8:loginout: ", p), err) + } + return err +} + +func (p *ResPlayerSimple) writeField9(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Facebook", thrift.STRING, 9); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 9:Facebook: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Facebook)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Facebook (9) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 9:Facebook: ", p), err) + } + return err +} + +func (p *ResPlayerSimple) writeField10(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Emoji", thrift.MAP, 10); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 10:Emoji: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.Emoji)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Emoji { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 10:Emoji: ", p), err) + } + return err +} + +func (p *ResPlayerSimple) writeField11(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "AddTime", thrift.I64, 11); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 11:AddTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.AddTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.AddTime (11) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 11:AddTime: ", p), err) + } + return err +} + +func (p *ResPlayerSimple) writeField12(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Interact", thrift.I64, 12); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 12:Interact: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Interact)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Interact (12) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 12:Interact: ", p), err) + } + return err +} + +func (p *ResPlayerSimple) Equals(other *ResPlayerSimple) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Uid != other.Uid { + return false + } + if p.Name != other.Name { + return false + } + if p.Face != other.Face { + return false + } + if p.Avatar != other.Avatar { + return false + } + if p.Level != other.Level { + return false + } + if p.Decorate != other.Decorate { + return false + } + if p.Login != other.Login { + return false + } + if p.Loginout != other.Loginout { + return false + } + if p.Facebook != other.Facebook { + return false + } + if len(p.Emoji) != len(other.Emoji) { + return false + } + for k, _tgt := range p.Emoji { + _src360 := other.Emoji[k] + if _tgt != _src360 { + return false + } + } + if p.AddTime != other.AddTime { + return false + } + if p.Interact != other.Interact { + return false + } + return true +} + +func (p *ResPlayerSimple) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayerSimple(%+v)", *p) +} + +func (p *ResPlayerSimple) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayerSimple", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayerSimple)(nil) + +func (p *ResPlayerSimple) Validate() error { + return nil +} + +// Attributes: +// - Status +// - Items +// - Opponent +// - Friend +// - Playroom +// - Collect +// - Mood +// - LoseItem +// - StartTime +// - WorkStatus +// - AllMood +// - Chip +// - WorkOutline +// - Jackpot +// - Physiology +// - Dress +// - DressSet +// - PetAir +// - PetAirSet +// - Upvote +// - RoomPoint +// - Unlock +// - DailyTask +// - DailyTaskReward +// - InteractNum +// - Kiss +// - Revenge +// - AdItem +// - Target +// - WeeklyDiscount +// +type ResPlayroom struct { + Status int32 `thrift:"status,1" db:"status" json:"status"` + Items []*ItemInfo `thrift:"Items,2" db:"Items" json:"Items"` + Opponent []*RoomOpponent `thrift:"Opponent,3" db:"Opponent" json:"Opponent"` + Friend []*FriendRoom `thrift:"Friend,4" db:"Friend" json:"Friend"` + Playroom map[int32]int32 `thrift:"Playroom,5" db:"Playroom" json:"Playroom"` + Collect []*PlayroomCollectInfo `thrift:"collect,6" db:"collect" json:"collect"` + Mood map[int32]int32 `thrift:"Mood,7" db:"Mood" json:"Mood"` + LoseItem []*ItemInfo `thrift:"LoseItem,8" db:"LoseItem" json:"LoseItem"` + StartTime int32 `thrift:"StartTime,9" db:"StartTime" json:"StartTime"` + WorkStatus int32 `thrift:"WorkStatus,10" db:"WorkStatus" json:"WorkStatus"` + AllMood int32 `thrift:"AllMood,11" db:"AllMood" json:"AllMood"` + Chip []*ChipInfo `thrift:"Chip,12" db:"Chip" json:"Chip"` + WorkOutline int32 `thrift:"WorkOutline,13" db:"WorkOutline" json:"WorkOutline"` + Jackpot int32 `thrift:"Jackpot,14" db:"Jackpot" json:"Jackpot"` + Physiology map[int32]int32 `thrift:"Physiology,15" db:"Physiology" json:"Physiology"` + Dress map[int32]*PlayroomDress `thrift:"Dress,16" db:"Dress" json:"Dress"` + DressSet map[int32]int32 `thrift:"DressSet,17" db:"DressSet" json:"DressSet"` + PetAir []*PlayroomAirInfo `thrift:"PetAir,18" db:"PetAir" json:"PetAir"` + PetAirSet int32 `thrift:"PetAirSet,19" db:"PetAirSet" json:"PetAirSet"` + Upvote int32 `thrift:"Upvote,20" db:"Upvote" json:"Upvote"` + RoomPoint int32 `thrift:"RoomPoint,21" db:"RoomPoint" json:"RoomPoint"` + Unlock []int32 `thrift:"Unlock,22" db:"Unlock" json:"Unlock"` + DailyTask []*DailyTask `thrift:"DailyTask,23" db:"DailyTask" json:"DailyTask"` + DailyTaskReward []int32 `thrift:"DailyTaskReward,24" db:"DailyTaskReward" json:"DailyTaskReward"` + InteractNum int32 `thrift:"InteractNum,25" db:"InteractNum" json:"InteractNum"` + Kiss int32 `thrift:"Kiss,26" db:"Kiss" json:"Kiss"` + Revenge int64 `thrift:"Revenge,27" db:"Revenge" json:"Revenge"` + AdItem []*AdItem `thrift:"AdItem,28" db:"AdItem" json:"AdItem"` + Target *FriendRoom `thrift:"Target,29" db:"Target" json:"Target"` + WeeklyDiscount map[int32]*WeeklyDiscountInfo `thrift:"WeeklyDiscount,30" db:"WeeklyDiscount" json:"WeeklyDiscount"` +} + +func NewResPlayroom() *ResPlayroom { + return &ResPlayroom{} +} + +func (p *ResPlayroom) GetStatus() int32 { + return p.Status +} + +func (p *ResPlayroom) GetItems() []*ItemInfo { + return p.Items +} + +func (p *ResPlayroom) GetOpponent() []*RoomOpponent { + return p.Opponent +} + +func (p *ResPlayroom) GetFriend() []*FriendRoom { + return p.Friend +} + +func (p *ResPlayroom) GetPlayroom() map[int32]int32 { + return p.Playroom +} + +func (p *ResPlayroom) GetCollect() []*PlayroomCollectInfo { + return p.Collect +} + +func (p *ResPlayroom) GetMood() map[int32]int32 { + return p.Mood +} + +func (p *ResPlayroom) GetLoseItem() []*ItemInfo { + return p.LoseItem +} + +func (p *ResPlayroom) GetStartTime() int32 { + return p.StartTime +} + +func (p *ResPlayroom) GetWorkStatus() int32 { + return p.WorkStatus +} + +func (p *ResPlayroom) GetAllMood() int32 { + return p.AllMood +} + +func (p *ResPlayroom) GetChip() []*ChipInfo { + return p.Chip +} + +func (p *ResPlayroom) GetWorkOutline() int32 { + return p.WorkOutline +} + +func (p *ResPlayroom) GetJackpot() int32 { + return p.Jackpot +} + +func (p *ResPlayroom) GetPhysiology() map[int32]int32 { + return p.Physiology +} + +func (p *ResPlayroom) GetDress() map[int32]*PlayroomDress { + return p.Dress +} + +func (p *ResPlayroom) GetDressSet() map[int32]int32 { + return p.DressSet +} + +func (p *ResPlayroom) GetPetAir() []*PlayroomAirInfo { + return p.PetAir +} + +func (p *ResPlayroom) GetPetAirSet() int32 { + return p.PetAirSet +} + +func (p *ResPlayroom) GetUpvote() int32 { + return p.Upvote +} + +func (p *ResPlayroom) GetRoomPoint() int32 { + return p.RoomPoint +} + +func (p *ResPlayroom) GetUnlock() []int32 { + return p.Unlock +} + +func (p *ResPlayroom) GetDailyTask() []*DailyTask { + return p.DailyTask +} + +func (p *ResPlayroom) GetDailyTaskReward() []int32 { + return p.DailyTaskReward +} + +func (p *ResPlayroom) GetInteractNum() int32 { + return p.InteractNum +} + +func (p *ResPlayroom) GetKiss() int32 { + return p.Kiss +} + +func (p *ResPlayroom) GetRevenge() int64 { + return p.Revenge +} + +func (p *ResPlayroom) GetAdItem() []*AdItem { + return p.AdItem +} + +var ResPlayroom_Target_DEFAULT *FriendRoom + +func (p *ResPlayroom) GetTarget() *FriendRoom { + if !p.IsSetTarget() { + return ResPlayroom_Target_DEFAULT + } + return p.Target +} + +func (p *ResPlayroom) GetWeeklyDiscount() map[int32]*WeeklyDiscountInfo { + return p.WeeklyDiscount +} + +func (p *ResPlayroom) IsSetTarget() bool { + return p.Target != nil +} + +func (p *ResPlayroom) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.LIST { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.LIST { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.LIST { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.MAP { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.LIST { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.MAP { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 8: + if fieldTypeId == thrift.LIST { + if err := p.ReadField8(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 9: + if fieldTypeId == thrift.I32 { + if err := p.ReadField9(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 10: + if fieldTypeId == thrift.I32 { + if err := p.ReadField10(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 11: + if fieldTypeId == thrift.I32 { + if err := p.ReadField11(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 12: + if fieldTypeId == thrift.LIST { + if err := p.ReadField12(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 13: + if fieldTypeId == thrift.I32 { + if err := p.ReadField13(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 14: + if fieldTypeId == thrift.I32 { + if err := p.ReadField14(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 15: + if fieldTypeId == thrift.MAP { + if err := p.ReadField15(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 16: + if fieldTypeId == thrift.MAP { + if err := p.ReadField16(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 17: + if fieldTypeId == thrift.MAP { + if err := p.ReadField17(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 18: + if fieldTypeId == thrift.LIST { + if err := p.ReadField18(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 19: + if fieldTypeId == thrift.I32 { + if err := p.ReadField19(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 20: + if fieldTypeId == thrift.I32 { + if err := p.ReadField20(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 21: + if fieldTypeId == thrift.I32 { + if err := p.ReadField21(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 22: + if fieldTypeId == thrift.LIST { + if err := p.ReadField22(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 23: + if fieldTypeId == thrift.LIST { + if err := p.ReadField23(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 24: + if fieldTypeId == thrift.LIST { + if err := p.ReadField24(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 25: + if fieldTypeId == thrift.I32 { + if err := p.ReadField25(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 26: + if fieldTypeId == thrift.I32 { + if err := p.ReadField26(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 27: + if fieldTypeId == thrift.I64 { + if err := p.ReadField27(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 28: + if fieldTypeId == thrift.LIST { + if err := p.ReadField28(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 29: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField29(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 30: + if fieldTypeId == thrift.MAP { + if err := p.ReadField30(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayroom) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Status = v + } + return nil +} + +func (p *ResPlayroom) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ItemInfo, 0, size) + p.Items = tSlice + for i := 0; i < size; i++ { + _elem361 := &ItemInfo{} + if err := _elem361.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem361), err) + } + p.Items = append(p.Items, _elem361) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResPlayroom) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*RoomOpponent, 0, size) + p.Opponent = tSlice + for i := 0; i < size; i++ { + _elem362 := &RoomOpponent{} + if err := _elem362.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem362), err) + } + p.Opponent = append(p.Opponent, _elem362) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResPlayroom) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*FriendRoom, 0, size) + p.Friend = tSlice + for i := 0; i < size; i++ { + _elem363 := &FriendRoom{} + if err := _elem363.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem363), err) + } + p.Friend = append(p.Friend, _elem363) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResPlayroom) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.Playroom = tMap + for i := 0; i < size; i++ { + var _key364 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key364 = v + } + var _val365 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val365 = v + } + p.Playroom[_key364] = _val365 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResPlayroom) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*PlayroomCollectInfo, 0, size) + p.Collect = tSlice + for i := 0; i < size; i++ { + _elem366 := &PlayroomCollectInfo{} + if err := _elem366.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem366), err) + } + p.Collect = append(p.Collect, _elem366) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResPlayroom) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.Mood = tMap + for i := 0; i < size; i++ { + var _key367 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key367 = v + } + var _val368 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val368 = v + } + p.Mood[_key367] = _val368 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResPlayroom) ReadField8(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ItemInfo, 0, size) + p.LoseItem = tSlice + for i := 0; i < size; i++ { + _elem369 := &ItemInfo{} + if err := _elem369.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem369), err) + } + p.LoseItem = append(p.LoseItem, _elem369) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResPlayroom) ReadField9(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 9: ", err) + } else { + p.StartTime = v + } + return nil +} + +func (p *ResPlayroom) ReadField10(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 10: ", err) + } else { + p.WorkStatus = v + } + return nil +} + +func (p *ResPlayroom) ReadField11(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 11: ", err) + } else { + p.AllMood = v + } + return nil +} + +func (p *ResPlayroom) ReadField12(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ChipInfo, 0, size) + p.Chip = tSlice + for i := 0; i < size; i++ { + _elem370 := &ChipInfo{} + if err := _elem370.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem370), err) + } + p.Chip = append(p.Chip, _elem370) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResPlayroom) ReadField13(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 13: ", err) + } else { + p.WorkOutline = v + } + return nil +} + +func (p *ResPlayroom) ReadField14(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 14: ", err) + } else { + p.Jackpot = v + } + return nil +} + +func (p *ResPlayroom) ReadField15(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.Physiology = tMap + for i := 0; i < size; i++ { + var _key371 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key371 = v + } + var _val372 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val372 = v + } + p.Physiology[_key371] = _val372 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResPlayroom) ReadField16(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]*PlayroomDress, size) + p.Dress = tMap + for i := 0; i < size; i++ { + var _key373 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key373 = v + } + _val374 := &PlayroomDress{} + if err := _val374.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _val374), err) + } + p.Dress[_key373] = _val374 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResPlayroom) ReadField17(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.DressSet = tMap + for i := 0; i < size; i++ { + var _key375 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key375 = v + } + var _val376 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val376 = v + } + p.DressSet[_key375] = _val376 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResPlayroom) ReadField18(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*PlayroomAirInfo, 0, size) + p.PetAir = tSlice + for i := 0; i < size; i++ { + _elem377 := &PlayroomAirInfo{} + if err := _elem377.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem377), err) + } + p.PetAir = append(p.PetAir, _elem377) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResPlayroom) ReadField19(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 19: ", err) + } else { + p.PetAirSet = v + } + return nil +} + +func (p *ResPlayroom) ReadField20(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 20: ", err) + } else { + p.Upvote = v + } + return nil +} + +func (p *ResPlayroom) ReadField21(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 21: ", err) + } else { + p.RoomPoint = v + } + return nil +} + +func (p *ResPlayroom) ReadField22(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.Unlock = tSlice + for i := 0; i < size; i++ { + var _elem378 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem378 = v + } + p.Unlock = append(p.Unlock, _elem378) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResPlayroom) ReadField23(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*DailyTask, 0, size) + p.DailyTask = tSlice + for i := 0; i < size; i++ { + _elem379 := &DailyTask{} + if err := _elem379.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem379), err) + } + p.DailyTask = append(p.DailyTask, _elem379) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResPlayroom) ReadField24(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int32, 0, size) + p.DailyTaskReward = tSlice + for i := 0; i < size; i++ { + var _elem380 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem380 = v + } + p.DailyTaskReward = append(p.DailyTaskReward, _elem380) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResPlayroom) ReadField25(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 25: ", err) + } else { + p.InteractNum = v + } + return nil +} + +func (p *ResPlayroom) ReadField26(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 26: ", err) + } else { + p.Kiss = v + } + return nil +} + +func (p *ResPlayroom) ReadField27(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 27: ", err) + } else { + p.Revenge = v + } + return nil +} + +func (p *ResPlayroom) ReadField28(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*AdItem, 0, size) + p.AdItem = tSlice + for i := 0; i < size; i++ { + _elem381 := &AdItem{} + if err := _elem381.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem381), err) + } + p.AdItem = append(p.AdItem, _elem381) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResPlayroom) ReadField29(ctx context.Context, iprot thrift.TProtocol) error { + p.Target = &FriendRoom{} + if err := p.Target.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.Target), err) + } + return nil +} + +func (p *ResPlayroom) ReadField30(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]*WeeklyDiscountInfo, size) + p.WeeklyDiscount = tMap + for i := 0; i < size; i++ { + var _key382 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key382 = v + } + _val383 := &WeeklyDiscountInfo{} + if err := _val383.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _val383), err) + } + p.WeeklyDiscount[_key382] = _val383 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResPlayroom) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayroom"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + if err := p.writeField8(ctx, oprot); err != nil { + return err + } + if err := p.writeField9(ctx, oprot); err != nil { + return err + } + if err := p.writeField10(ctx, oprot); err != nil { + return err + } + if err := p.writeField11(ctx, oprot); err != nil { + return err + } + if err := p.writeField12(ctx, oprot); err != nil { + return err + } + if err := p.writeField13(ctx, oprot); err != nil { + return err + } + if err := p.writeField14(ctx, oprot); err != nil { + return err + } + if err := p.writeField15(ctx, oprot); err != nil { + return err + } + if err := p.writeField16(ctx, oprot); err != nil { + return err + } + if err := p.writeField17(ctx, oprot); err != nil { + return err + } + if err := p.writeField18(ctx, oprot); err != nil { + return err + } + if err := p.writeField19(ctx, oprot); err != nil { + return err + } + if err := p.writeField20(ctx, oprot); err != nil { + return err + } + if err := p.writeField21(ctx, oprot); err != nil { + return err + } + if err := p.writeField22(ctx, oprot); err != nil { + return err + } + if err := p.writeField23(ctx, oprot); err != nil { + return err + } + if err := p.writeField24(ctx, oprot); err != nil { + return err + } + if err := p.writeField25(ctx, oprot); err != nil { + return err + } + if err := p.writeField26(ctx, oprot); err != nil { + return err + } + if err := p.writeField27(ctx, oprot); err != nil { + return err + } + if err := p.writeField28(ctx, oprot); err != nil { + return err + } + if err := p.writeField29(ctx, oprot); err != nil { + return err + } + if err := p.writeField30(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayroom) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "status", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:status: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Status)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.status (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:status: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Items", thrift.LIST, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Items: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Items)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Items { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Items: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Opponent", thrift.LIST, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Opponent: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Opponent)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Opponent { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Opponent: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Friend", thrift.LIST, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Friend: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Friend)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Friend { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Friend: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Playroom", thrift.MAP, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Playroom: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.Playroom)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Playroom { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Playroom: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "collect", thrift.LIST, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:collect: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Collect)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Collect { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:collect: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Mood", thrift.MAP, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:Mood: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.Mood)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Mood { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:Mood: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField8(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "LoseItem", thrift.LIST, 8); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 8:LoseItem: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.LoseItem)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.LoseItem { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 8:LoseItem: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField9(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "StartTime", thrift.I32, 9); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 9:StartTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.StartTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.StartTime (9) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 9:StartTime: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField10(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "WorkStatus", thrift.I32, 10); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 10:WorkStatus: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.WorkStatus)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.WorkStatus (10) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 10:WorkStatus: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField11(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "AllMood", thrift.I32, 11); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 11:AllMood: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.AllMood)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.AllMood (11) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 11:AllMood: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField12(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Chip", thrift.LIST, 12); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 12:Chip: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Chip)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Chip { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 12:Chip: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField13(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "WorkOutline", thrift.I32, 13); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 13:WorkOutline: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.WorkOutline)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.WorkOutline (13) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 13:WorkOutline: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField14(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Jackpot", thrift.I32, 14); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 14:Jackpot: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Jackpot)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Jackpot (14) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 14:Jackpot: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField15(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Physiology", thrift.MAP, 15); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 15:Physiology: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.Physiology)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Physiology { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 15:Physiology: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField16(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Dress", thrift.MAP, 16); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 16:Dress: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.STRUCT, len(p.Dress)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Dress { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 16:Dress: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField17(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "DressSet", thrift.MAP, 17); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 17:DressSet: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.DressSet)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.DressSet { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 17:DressSet: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField18(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "PetAir", thrift.LIST, 18); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 18:PetAir: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.PetAir)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.PetAir { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 18:PetAir: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField19(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "PetAirSet", thrift.I32, 19); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 19:PetAirSet: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.PetAirSet)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.PetAirSet (19) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 19:PetAirSet: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField20(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Upvote", thrift.I32, 20); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 20:Upvote: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Upvote)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Upvote (20) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 20:Upvote: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField21(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "RoomPoint", thrift.I32, 21); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 21:RoomPoint: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.RoomPoint)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.RoomPoint (21) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 21:RoomPoint: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField22(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Unlock", thrift.LIST, 22); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 22:Unlock: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.Unlock)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Unlock { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 22:Unlock: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField23(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "DailyTask", thrift.LIST, 23); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 23:DailyTask: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.DailyTask)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.DailyTask { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 23:DailyTask: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField24(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "DailyTaskReward", thrift.LIST, 24); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 24:DailyTaskReward: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I32, len(p.DailyTaskReward)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.DailyTaskReward { + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 24:DailyTaskReward: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField25(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "InteractNum", thrift.I32, 25); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 25:InteractNum: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.InteractNum)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.InteractNum (25) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 25:InteractNum: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField26(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Kiss", thrift.I32, 26); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 26:Kiss: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Kiss)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Kiss (26) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 26:Kiss: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField27(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Revenge", thrift.I64, 27); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 27:Revenge: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Revenge)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Revenge (27) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 27:Revenge: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField28(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "AdItem", thrift.LIST, 28); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 28:AdItem: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.AdItem)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.AdItem { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 28:AdItem: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField29(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Target", thrift.STRUCT, 29); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 29:Target: ", p), err) + } + if err := p.Target.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.Target), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 29:Target: ", p), err) + } + return err +} + +func (p *ResPlayroom) writeField30(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "WeeklyDiscount", thrift.MAP, 30); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 30:WeeklyDiscount: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.STRUCT, len(p.WeeklyDiscount)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.WeeklyDiscount { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 30:WeeklyDiscount: ", p), err) + } + return err +} + +func (p *ResPlayroom) Equals(other *ResPlayroom) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Status != other.Status { + return false + } + if len(p.Items) != len(other.Items) { + return false + } + for i, _tgt := range p.Items { + _src384 := other.Items[i] + if !_tgt.Equals(_src384) { + return false + } + } + if len(p.Opponent) != len(other.Opponent) { + return false + } + for i, _tgt := range p.Opponent { + _src385 := other.Opponent[i] + if !_tgt.Equals(_src385) { + return false + } + } + if len(p.Friend) != len(other.Friend) { + return false + } + for i, _tgt := range p.Friend { + _src386 := other.Friend[i] + if !_tgt.Equals(_src386) { + return false + } + } + if len(p.Playroom) != len(other.Playroom) { + return false + } + for k, _tgt := range p.Playroom { + _src387 := other.Playroom[k] + if _tgt != _src387 { + return false + } + } + if len(p.Collect) != len(other.Collect) { + return false + } + for i, _tgt := range p.Collect { + _src388 := other.Collect[i] + if !_tgt.Equals(_src388) { + return false + } + } + if len(p.Mood) != len(other.Mood) { + return false + } + for k, _tgt := range p.Mood { + _src389 := other.Mood[k] + if _tgt != _src389 { + return false + } + } + if len(p.LoseItem) != len(other.LoseItem) { + return false + } + for i, _tgt := range p.LoseItem { + _src390 := other.LoseItem[i] + if !_tgt.Equals(_src390) { + return false + } + } + if p.StartTime != other.StartTime { + return false + } + if p.WorkStatus != other.WorkStatus { + return false + } + if p.AllMood != other.AllMood { + return false + } + if len(p.Chip) != len(other.Chip) { + return false + } + for i, _tgt := range p.Chip { + _src391 := other.Chip[i] + if !_tgt.Equals(_src391) { + return false + } + } + if p.WorkOutline != other.WorkOutline { + return false + } + if p.Jackpot != other.Jackpot { + return false + } + if len(p.Physiology) != len(other.Physiology) { + return false + } + for k, _tgt := range p.Physiology { + _src392 := other.Physiology[k] + if _tgt != _src392 { + return false + } + } + if len(p.Dress) != len(other.Dress) { + return false + } + for k, _tgt := range p.Dress { + _src393 := other.Dress[k] + if !_tgt.Equals(_src393) { + return false + } + } + if len(p.DressSet) != len(other.DressSet) { + return false + } + for k, _tgt := range p.DressSet { + _src394 := other.DressSet[k] + if _tgt != _src394 { + return false + } + } + if len(p.PetAir) != len(other.PetAir) { + return false + } + for i, _tgt := range p.PetAir { + _src395 := other.PetAir[i] + if !_tgt.Equals(_src395) { + return false + } + } + if p.PetAirSet != other.PetAirSet { + return false + } + if p.Upvote != other.Upvote { + return false + } + if p.RoomPoint != other.RoomPoint { + return false + } + if len(p.Unlock) != len(other.Unlock) { + return false + } + for i, _tgt := range p.Unlock { + _src396 := other.Unlock[i] + if _tgt != _src396 { + return false + } + } + if len(p.DailyTask) != len(other.DailyTask) { + return false + } + for i, _tgt := range p.DailyTask { + _src397 := other.DailyTask[i] + if !_tgt.Equals(_src397) { + return false + } + } + if len(p.DailyTaskReward) != len(other.DailyTaskReward) { + return false + } + for i, _tgt := range p.DailyTaskReward { + _src398 := other.DailyTaskReward[i] + if _tgt != _src398 { + return false + } + } + if p.InteractNum != other.InteractNum { + return false + } + if p.Kiss != other.Kiss { + return false + } + if p.Revenge != other.Revenge { + return false + } + if len(p.AdItem) != len(other.AdItem) { + return false + } + for i, _tgt := range p.AdItem { + _src399 := other.AdItem[i] + if !_tgt.Equals(_src399) { + return false + } + } + if !p.Target.Equals(other.Target) { + return false + } + if len(p.WeeklyDiscount) != len(other.WeeklyDiscount) { + return false + } + for k, _tgt := range p.WeeklyDiscount { + _src400 := other.WeeklyDiscount[k] + if !_tgt.Equals(_src400) { + return false + } + } + return true +} + +func (p *ResPlayroom) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayroom(%+v)", *p) +} + +func (p *ResPlayroom) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayroom", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayroom)(nil) + +func (p *ResPlayroom) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResPlayroomBuyItem struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResPlayroomBuyItem() *ResPlayroomBuyItem { + return &ResPlayroomBuyItem{} +} + +func (p *ResPlayroomBuyItem) GetCode() RES_CODE { + return p.Code +} + +func (p *ResPlayroomBuyItem) GetMsg() string { + return p.Msg +} + +func (p *ResPlayroomBuyItem) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayroomBuyItem) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResPlayroomBuyItem) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResPlayroomBuyItem) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayroomBuyItem"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayroomBuyItem) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResPlayroomBuyItem) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResPlayroomBuyItem) Equals(other *ResPlayroomBuyItem) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResPlayroomBuyItem) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayroomBuyItem(%+v)", *p) +} + +func (p *ResPlayroomBuyItem) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayroomBuyItem", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayroomBuyItem)(nil) + +func (p *ResPlayroomBuyItem) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResPlayroomChip struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResPlayroomChip() *ResPlayroomChip { + return &ResPlayroomChip{} +} + +func (p *ResPlayroomChip) GetCode() RES_CODE { + return p.Code +} + +func (p *ResPlayroomChip) GetMsg() string { + return p.Msg +} + +func (p *ResPlayroomChip) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayroomChip) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResPlayroomChip) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResPlayroomChip) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayroomChip"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayroomChip) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResPlayroomChip) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResPlayroomChip) Equals(other *ResPlayroomChip) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResPlayroomChip) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayroomChip(%+v)", *p) +} + +func (p *ResPlayroomChip) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayroomChip", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayroomChip)(nil) + +func (p *ResPlayroomChip) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Id +// +type ResPlayroomDraw struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Id int32 `thrift:"Id,3" db:"Id" json:"Id"` +} + +func NewResPlayroomDraw() *ResPlayroomDraw { + return &ResPlayroomDraw{} +} + +func (p *ResPlayroomDraw) GetCode() RES_CODE { + return p.Code +} + +func (p *ResPlayroomDraw) GetMsg() string { + return p.Msg +} + +func (p *ResPlayroomDraw) GetId() int32 { + return p.Id +} + +func (p *ResPlayroomDraw) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayroomDraw) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResPlayroomDraw) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResPlayroomDraw) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResPlayroomDraw) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayroomDraw"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayroomDraw) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResPlayroomDraw) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResPlayroomDraw) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Id: ", p), err) + } + return err +} + +func (p *ResPlayroomDraw) Equals(other *ResPlayroomDraw) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ResPlayroomDraw) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayroomDraw(%+v)", *p) +} + +func (p *ResPlayroomDraw) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayroomDraw", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayroomDraw)(nil) + +func (p *ResPlayroomDraw) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResPlayroomDressSet struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResPlayroomDressSet() *ResPlayroomDressSet { + return &ResPlayroomDressSet{} +} + +func (p *ResPlayroomDressSet) GetCode() RES_CODE { + return p.Code +} + +func (p *ResPlayroomDressSet) GetMsg() string { + return p.Msg +} + +func (p *ResPlayroomDressSet) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayroomDressSet) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResPlayroomDressSet) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResPlayroomDressSet) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayroomDressSet"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayroomDressSet) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResPlayroomDressSet) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResPlayroomDressSet) Equals(other *ResPlayroomDressSet) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResPlayroomDressSet) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayroomDressSet(%+v)", *p) +} + +func (p *ResPlayroomDressSet) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayroomDressSet", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayroomDressSet)(nil) + +func (p *ResPlayroomDressSet) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Id +// - CardId +// +type ResPlayroomFlip struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Id int32 `thrift:"Id,3" db:"Id" json:"Id"` + CardId int32 `thrift:"CardId,4" db:"CardId" json:"CardId"` +} + +func NewResPlayroomFlip() *ResPlayroomFlip { + return &ResPlayroomFlip{} +} + +func (p *ResPlayroomFlip) GetCode() RES_CODE { + return p.Code +} + +func (p *ResPlayroomFlip) GetMsg() string { + return p.Msg +} + +func (p *ResPlayroomFlip) GetId() int32 { + return p.Id +} + +func (p *ResPlayroomFlip) GetCardId() int32 { + return p.CardId +} + +func (p *ResPlayroomFlip) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayroomFlip) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResPlayroomFlip) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResPlayroomFlip) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResPlayroomFlip) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.CardId = v + } + return nil +} + +func (p *ResPlayroomFlip) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayroomFlip"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayroomFlip) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResPlayroomFlip) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResPlayroomFlip) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Id: ", p), err) + } + return err +} + +func (p *ResPlayroomFlip) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "CardId", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:CardId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.CardId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.CardId (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:CardId: ", p), err) + } + return err +} + +func (p *ResPlayroomFlip) Equals(other *ResPlayroomFlip) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Id != other.Id { + return false + } + if p.CardId != other.CardId { + return false + } + return true +} + +func (p *ResPlayroomFlip) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayroomFlip(%+v)", *p) +} + +func (p *ResPlayroomFlip) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayroomFlip", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayroomFlip)(nil) + +func (p *ResPlayroomFlip) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Broken +// +type ResPlayroomFlipReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Broken bool `thrift:"Broken,3" db:"Broken" json:"Broken"` +} + +func NewResPlayroomFlipReward() *ResPlayroomFlipReward { + return &ResPlayroomFlipReward{} +} + +func (p *ResPlayroomFlipReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResPlayroomFlipReward) GetMsg() string { + return p.Msg +} + +func (p *ResPlayroomFlipReward) GetBroken() bool { + return p.Broken +} + +func (p *ResPlayroomFlipReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.BOOL { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayroomFlipReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResPlayroomFlipReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResPlayroomFlipReward) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadBool(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Broken = v + } + return nil +} + +func (p *ResPlayroomFlipReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayroomFlipReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayroomFlipReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResPlayroomFlipReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResPlayroomFlipReward) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Broken", thrift.BOOL, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Broken: ", p), err) + } + if err := oprot.WriteBool(ctx, bool(p.Broken)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Broken (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Broken: ", p), err) + } + return err +} + +func (p *ResPlayroomFlipReward) Equals(other *ResPlayroomFlipReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Broken != other.Broken { + return false + } + return true +} + +func (p *ResPlayroomFlipReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayroomFlipReward(%+v)", *p) +} + +func (p *ResPlayroomFlipReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayroomFlipReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayroomFlipReward)(nil) + +func (p *ResPlayroomFlipReward) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Type +// - Items +// +type ResPlayroomGame struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Type int32 `thrift:"Type,3" db:"Type" json:"Type"` + Items map[int32]*ItemInfo `thrift:"Items,4" db:"Items" json:"Items"` +} + +func NewResPlayroomGame() *ResPlayroomGame { + return &ResPlayroomGame{} +} + +func (p *ResPlayroomGame) GetCode() RES_CODE { + return p.Code +} + +func (p *ResPlayroomGame) GetMsg() string { + return p.Msg +} + +func (p *ResPlayroomGame) GetType() int32 { + return p.Type +} + +func (p *ResPlayroomGame) GetItems() map[int32]*ItemInfo { + return p.Items +} + +func (p *ResPlayroomGame) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.MAP { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayroomGame) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResPlayroomGame) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResPlayroomGame) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ResPlayroomGame) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]*ItemInfo, size) + p.Items = tMap + for i := 0; i < size; i++ { + var _key401 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key401 = v + } + _val402 := &ItemInfo{} + if err := _val402.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _val402), err) + } + p.Items[_key401] = _val402 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResPlayroomGame) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayroomGame"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayroomGame) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResPlayroomGame) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResPlayroomGame) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Type: ", p), err) + } + return err +} + +func (p *ResPlayroomGame) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Items", thrift.MAP, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Items: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.STRUCT, len(p.Items)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Items { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Items: ", p), err) + } + return err +} + +func (p *ResPlayroomGame) Equals(other *ResPlayroomGame) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Type != other.Type { + return false + } + if len(p.Items) != len(other.Items) { + return false + } + for k, _tgt := range p.Items { + _src403 := other.Items[k] + if !_tgt.Equals(_src403) { + return false + } + } + return true +} + +func (p *ResPlayroomGame) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayroomGame(%+v)", *p) +} + +func (p *ResPlayroomGame) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayroomGame", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayroomGame)(nil) + +func (p *ResPlayroomGame) Validate() error { + return nil +} + +// Attributes: +// - Items +// +type ResPlayroomGameShowReward struct { + Items []*ItemInfo `thrift:"Items,1" db:"Items" json:"Items"` +} + +func NewResPlayroomGameShowReward() *ResPlayroomGameShowReward { + return &ResPlayroomGameShowReward{} +} + +func (p *ResPlayroomGameShowReward) GetItems() []*ItemInfo { + return p.Items +} + +func (p *ResPlayroomGameShowReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayroomGameShowReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ItemInfo, 0, size) + p.Items = tSlice + for i := 0; i < size; i++ { + _elem404 := &ItemInfo{} + if err := _elem404.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem404), err) + } + p.Items = append(p.Items, _elem404) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResPlayroomGameShowReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayroomGameShowReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayroomGameShowReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Items", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Items: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Items)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Items { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Items: ", p), err) + } + return err +} + +func (p *ResPlayroomGameShowReward) Equals(other *ResPlayroomGameShowReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.Items) != len(other.Items) { + return false + } + for i, _tgt := range p.Items { + _src405 := other.Items[i] + if !_tgt.Equals(_src405) { + return false + } + } + return true +} + +func (p *ResPlayroomGameShowReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayroomGameShowReward(%+v)", *p) +} + +func (p *ResPlayroomGameShowReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayroomGameShowReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayroomGameShowReward)(nil) + +func (p *ResPlayroomGameShowReward) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResPlayroomGuide struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResPlayroomGuide() *ResPlayroomGuide { + return &ResPlayroomGuide{} +} + +func (p *ResPlayroomGuide) GetCode() RES_CODE { + return p.Code +} + +func (p *ResPlayroomGuide) GetMsg() string { + return p.Msg +} + +func (p *ResPlayroomGuide) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayroomGuide) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResPlayroomGuide) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResPlayroomGuide) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayroomGuide"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayroomGuide) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResPlayroomGuide) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResPlayroomGuide) Equals(other *ResPlayroomGuide) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResPlayroomGuide) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayroomGuide(%+v)", *p) +} + +func (p *ResPlayroomGuide) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayroomGuide", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayroomGuide)(nil) + +func (p *ResPlayroomGuide) Validate() error { + return nil +} + +// Attributes: +// - Uid +// - Name +// - Face +// - Avatar +// - Playroom +// - GameId +// - Items +// - Status +// - Defense +// - Flip +// - Chip +// - PetName +// - Emoji +// - Upvote +// - UpvoteCount +// - DressSet +// - Kiss +// - Fur +// - Star +// +type ResPlayroomInfo struct { + Uid int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` + Name string `thrift:"name,2" db:"name" json:"name"` + Face int32 `thrift:"Face,3" db:"Face" json:"Face"` + Avatar int32 `thrift:"Avatar,4" db:"Avatar" json:"Avatar"` + Playroom map[int32]int32 `thrift:"Playroom,5" db:"Playroom" json:"Playroom"` + GameId int32 `thrift:"GameId,6" db:"GameId" json:"GameId"` + Items map[int32]*ItemInfo `thrift:"Items,7" db:"Items" json:"Items"` + Status int32 `thrift:"Status,8" db:"Status" json:"Status"` + Defense bool `thrift:"defense,9" db:"defense" json:"defense"` + Flip map[int32]int32 `thrift:"Flip,10" db:"Flip" json:"Flip"` + Chip int32 `thrift:"Chip,11" db:"Chip" json:"Chip"` + PetName string `thrift:"PetName,12" db:"PetName" json:"PetName"` + Emoji map[int32]int32 `thrift:"Emoji,13" db:"Emoji" json:"Emoji"` + Upvote bool `thrift:"Upvote,14" db:"Upvote" json:"Upvote"` + UpvoteCount int32 `thrift:"UpvoteCount,15" db:"UpvoteCount" json:"UpvoteCount"` + DressSet map[int32]int32 `thrift:"DressSet,16" db:"DressSet" json:"DressSet"` + Kiss int32 `thrift:"Kiss,17" db:"Kiss" json:"Kiss"` + Fur int32 `thrift:"Fur,18" db:"Fur" json:"Fur"` + Star int32 `thrift:"Star,19" db:"Star" json:"Star"` +} + +func NewResPlayroomInfo() *ResPlayroomInfo { + return &ResPlayroomInfo{} +} + +func (p *ResPlayroomInfo) GetUid() int64 { + return p.Uid +} + +func (p *ResPlayroomInfo) GetName() string { + return p.Name +} + +func (p *ResPlayroomInfo) GetFace() int32 { + return p.Face +} + +func (p *ResPlayroomInfo) GetAvatar() int32 { + return p.Avatar +} + +func (p *ResPlayroomInfo) GetPlayroom() map[int32]int32 { + return p.Playroom +} + +func (p *ResPlayroomInfo) GetGameId() int32 { + return p.GameId +} + +func (p *ResPlayroomInfo) GetItems() map[int32]*ItemInfo { + return p.Items +} + +func (p *ResPlayroomInfo) GetStatus() int32 { + return p.Status +} + +func (p *ResPlayroomInfo) GetDefense() bool { + return p.Defense +} + +func (p *ResPlayroomInfo) GetFlip() map[int32]int32 { + return p.Flip +} + +func (p *ResPlayroomInfo) GetChip() int32 { + return p.Chip +} + +func (p *ResPlayroomInfo) GetPetName() string { + return p.PetName +} + +func (p *ResPlayroomInfo) GetEmoji() map[int32]int32 { + return p.Emoji +} + +func (p *ResPlayroomInfo) GetUpvote() bool { + return p.Upvote +} + +func (p *ResPlayroomInfo) GetUpvoteCount() int32 { + return p.UpvoteCount +} + +func (p *ResPlayroomInfo) GetDressSet() map[int32]int32 { + return p.DressSet +} + +func (p *ResPlayroomInfo) GetKiss() int32 { + return p.Kiss +} + +func (p *ResPlayroomInfo) GetFur() int32 { + return p.Fur +} + +func (p *ResPlayroomInfo) GetStar() int32 { + return p.Star +} + +func (p *ResPlayroomInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.MAP { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.I32 { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.MAP { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 8: + if fieldTypeId == thrift.I32 { + if err := p.ReadField8(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 9: + if fieldTypeId == thrift.BOOL { + if err := p.ReadField9(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 10: + if fieldTypeId == thrift.MAP { + if err := p.ReadField10(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 11: + if fieldTypeId == thrift.I32 { + if err := p.ReadField11(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 12: + if fieldTypeId == thrift.STRING { + if err := p.ReadField12(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 13: + if fieldTypeId == thrift.MAP { + if err := p.ReadField13(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 14: + if fieldTypeId == thrift.BOOL { + if err := p.ReadField14(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 15: + if fieldTypeId == thrift.I32 { + if err := p.ReadField15(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 16: + if fieldTypeId == thrift.MAP { + if err := p.ReadField16(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 17: + if fieldTypeId == thrift.I32 { + if err := p.ReadField17(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 18: + if fieldTypeId == thrift.I32 { + if err := p.ReadField18(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 19: + if fieldTypeId == thrift.I32 { + if err := p.ReadField19(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayroomInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ResPlayroomInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Name = v + } + return nil +} + +func (p *ResPlayroomInfo) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Face = v + } + return nil +} + +func (p *ResPlayroomInfo) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Avatar = v + } + return nil +} + +func (p *ResPlayroomInfo) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.Playroom = tMap + for i := 0; i < size; i++ { + var _key406 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key406 = v + } + var _val407 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val407 = v + } + p.Playroom[_key406] = _val407 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResPlayroomInfo) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 6: ", err) + } else { + p.GameId = v + } + return nil +} + +func (p *ResPlayroomInfo) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]*ItemInfo, size) + p.Items = tMap + for i := 0; i < size; i++ { + var _key408 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key408 = v + } + _val409 := &ItemInfo{} + if err := _val409.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _val409), err) + } + p.Items[_key408] = _val409 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResPlayroomInfo) ReadField8(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 8: ", err) + } else { + p.Status = v + } + return nil +} + +func (p *ResPlayroomInfo) ReadField9(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadBool(ctx); err != nil { + return thrift.PrependError("error reading field 9: ", err) + } else { + p.Defense = v + } + return nil +} + +func (p *ResPlayroomInfo) ReadField10(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.Flip = tMap + for i := 0; i < size; i++ { + var _key410 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key410 = v + } + var _val411 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val411 = v + } + p.Flip[_key410] = _val411 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResPlayroomInfo) ReadField11(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 11: ", err) + } else { + p.Chip = v + } + return nil +} + +func (p *ResPlayroomInfo) ReadField12(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 12: ", err) + } else { + p.PetName = v + } + return nil +} + +func (p *ResPlayroomInfo) ReadField13(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.Emoji = tMap + for i := 0; i < size; i++ { + var _key412 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key412 = v + } + var _val413 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val413 = v + } + p.Emoji[_key412] = _val413 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResPlayroomInfo) ReadField14(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadBool(ctx); err != nil { + return thrift.PrependError("error reading field 14: ", err) + } else { + p.Upvote = v + } + return nil +} + +func (p *ResPlayroomInfo) ReadField15(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 15: ", err) + } else { + p.UpvoteCount = v + } + return nil +} + +func (p *ResPlayroomInfo) ReadField16(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.DressSet = tMap + for i := 0; i < size; i++ { + var _key414 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key414 = v + } + var _val415 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val415 = v + } + p.DressSet[_key414] = _val415 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResPlayroomInfo) ReadField17(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 17: ", err) + } else { + p.Kiss = v + } + return nil +} + +func (p *ResPlayroomInfo) ReadField18(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 18: ", err) + } else { + p.Fur = v + } + return nil +} + +func (p *ResPlayroomInfo) ReadField19(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 19: ", err) + } else { + p.Star = v + } + return nil +} + +func (p *ResPlayroomInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayroomInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + if err := p.writeField8(ctx, oprot); err != nil { + return err + } + if err := p.writeField9(ctx, oprot); err != nil { + return err + } + if err := p.writeField10(ctx, oprot); err != nil { + return err + } + if err := p.writeField11(ctx, oprot); err != nil { + return err + } + if err := p.writeField12(ctx, oprot); err != nil { + return err + } + if err := p.writeField13(ctx, oprot); err != nil { + return err + } + if err := p.writeField14(ctx, oprot); err != nil { + return err + } + if err := p.writeField15(ctx, oprot); err != nil { + return err + } + if err := p.writeField16(ctx, oprot); err != nil { + return err + } + if err := p.writeField17(ctx, oprot); err != nil { + return err + } + if err := p.writeField18(ctx, oprot); err != nil { + return err + } + if err := p.writeField19(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayroomInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *ResPlayroomInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "name", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:name: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Name)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.name (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:name: ", p), err) + } + return err +} + +func (p *ResPlayroomInfo) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Face", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Face: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Face)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Face (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Face: ", p), err) + } + return err +} + +func (p *ResPlayroomInfo) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Avatar", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Avatar: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Avatar)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Avatar (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Avatar: ", p), err) + } + return err +} + +func (p *ResPlayroomInfo) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Playroom", thrift.MAP, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Playroom: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.Playroom)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Playroom { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Playroom: ", p), err) + } + return err +} + +func (p *ResPlayroomInfo) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "GameId", thrift.I32, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:GameId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.GameId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.GameId (6) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:GameId: ", p), err) + } + return err +} + +func (p *ResPlayroomInfo) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Items", thrift.MAP, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:Items: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.STRUCT, len(p.Items)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Items { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:Items: ", p), err) + } + return err +} + +func (p *ResPlayroomInfo) writeField8(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Status", thrift.I32, 8); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 8:Status: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Status)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Status (8) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 8:Status: ", p), err) + } + return err +} + +func (p *ResPlayroomInfo) writeField9(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "defense", thrift.BOOL, 9); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 9:defense: ", p), err) + } + if err := oprot.WriteBool(ctx, bool(p.Defense)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.defense (9) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 9:defense: ", p), err) + } + return err +} + +func (p *ResPlayroomInfo) writeField10(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Flip", thrift.MAP, 10); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 10:Flip: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.Flip)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Flip { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 10:Flip: ", p), err) + } + return err +} + +func (p *ResPlayroomInfo) writeField11(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Chip", thrift.I32, 11); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 11:Chip: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Chip)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Chip (11) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 11:Chip: ", p), err) + } + return err +} + +func (p *ResPlayroomInfo) writeField12(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "PetName", thrift.STRING, 12); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 12:PetName: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.PetName)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.PetName (12) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 12:PetName: ", p), err) + } + return err +} + +func (p *ResPlayroomInfo) writeField13(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Emoji", thrift.MAP, 13); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 13:Emoji: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.Emoji)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.Emoji { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 13:Emoji: ", p), err) + } + return err +} + +func (p *ResPlayroomInfo) writeField14(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Upvote", thrift.BOOL, 14); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 14:Upvote: ", p), err) + } + if err := oprot.WriteBool(ctx, bool(p.Upvote)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Upvote (14) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 14:Upvote: ", p), err) + } + return err +} + +func (p *ResPlayroomInfo) writeField15(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "UpvoteCount", thrift.I32, 15); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 15:UpvoteCount: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.UpvoteCount)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.UpvoteCount (15) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 15:UpvoteCount: ", p), err) + } + return err +} + +func (p *ResPlayroomInfo) writeField16(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "DressSet", thrift.MAP, 16); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 16:DressSet: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.DressSet)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.DressSet { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 16:DressSet: ", p), err) + } + return err +} + +func (p *ResPlayroomInfo) writeField17(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Kiss", thrift.I32, 17); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 17:Kiss: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Kiss)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Kiss (17) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 17:Kiss: ", p), err) + } + return err +} + +func (p *ResPlayroomInfo) writeField18(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Fur", thrift.I32, 18); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 18:Fur: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Fur)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Fur (18) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 18:Fur: ", p), err) + } + return err +} + +func (p *ResPlayroomInfo) writeField19(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Star", thrift.I32, 19); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 19:Star: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Star)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Star (19) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 19:Star: ", p), err) + } + return err +} + +func (p *ResPlayroomInfo) Equals(other *ResPlayroomInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Uid != other.Uid { + return false + } + if p.Name != other.Name { + return false + } + if p.Face != other.Face { + return false + } + if p.Avatar != other.Avatar { + return false + } + if len(p.Playroom) != len(other.Playroom) { + return false + } + for k, _tgt := range p.Playroom { + _src416 := other.Playroom[k] + if _tgt != _src416 { + return false + } + } + if p.GameId != other.GameId { + return false + } + if len(p.Items) != len(other.Items) { + return false + } + for k, _tgt := range p.Items { + _src417 := other.Items[k] + if !_tgt.Equals(_src417) { + return false + } + } + if p.Status != other.Status { + return false + } + if p.Defense != other.Defense { + return false + } + if len(p.Flip) != len(other.Flip) { + return false + } + for k, _tgt := range p.Flip { + _src418 := other.Flip[k] + if _tgt != _src418 { + return false + } + } + if p.Chip != other.Chip { + return false + } + if p.PetName != other.PetName { + return false + } + if len(p.Emoji) != len(other.Emoji) { + return false + } + for k, _tgt := range p.Emoji { + _src419 := other.Emoji[k] + if _tgt != _src419 { + return false + } + } + if p.Upvote != other.Upvote { + return false + } + if p.UpvoteCount != other.UpvoteCount { + return false + } + if len(p.DressSet) != len(other.DressSet) { + return false + } + for k, _tgt := range p.DressSet { + _src420 := other.DressSet[k] + if _tgt != _src420 { + return false + } + } + if p.Kiss != other.Kiss { + return false + } + if p.Fur != other.Fur { + return false + } + if p.Star != other.Star { + return false + } + return true +} + +func (p *ResPlayroomInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayroomInfo(%+v)", *p) +} + +func (p *ResPlayroomInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayroomInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayroomInfo)(nil) + +func (p *ResPlayroomInfo) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - InteractNum +// +type ResPlayroomInteract struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + InteractNum int32 `thrift:"InteractNum,3" db:"InteractNum" json:"InteractNum"` +} + +func NewResPlayroomInteract() *ResPlayroomInteract { + return &ResPlayroomInteract{} +} + +func (p *ResPlayroomInteract) GetCode() RES_CODE { + return p.Code +} + +func (p *ResPlayroomInteract) GetMsg() string { + return p.Msg +} + +func (p *ResPlayroomInteract) GetInteractNum() int32 { + return p.InteractNum +} + +func (p *ResPlayroomInteract) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayroomInteract) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResPlayroomInteract) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResPlayroomInteract) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.InteractNum = v + } + return nil +} + +func (p *ResPlayroomInteract) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayroomInteract"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayroomInteract) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResPlayroomInteract) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResPlayroomInteract) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "InteractNum", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:InteractNum: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.InteractNum)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.InteractNum (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:InteractNum: ", p), err) + } + return err +} + +func (p *ResPlayroomInteract) Equals(other *ResPlayroomInteract) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.InteractNum != other.InteractNum { + return false + } + return true +} + +func (p *ResPlayroomInteract) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayroomInteract(%+v)", *p) +} + +func (p *ResPlayroomInteract) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayroomInteract", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayroomInteract)(nil) + +func (p *ResPlayroomInteract) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResPlayroomLose struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResPlayroomLose() *ResPlayroomLose { + return &ResPlayroomLose{} +} + +func (p *ResPlayroomLose) GetCode() RES_CODE { + return p.Code +} + +func (p *ResPlayroomLose) GetMsg() string { + return p.Msg +} + +func (p *ResPlayroomLose) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayroomLose) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResPlayroomLose) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResPlayroomLose) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayroomLose"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayroomLose) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResPlayroomLose) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResPlayroomLose) Equals(other *ResPlayroomLose) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResPlayroomLose) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayroomLose(%+v)", *p) +} + +func (p *ResPlayroomLose) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayroomLose", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayroomLose)(nil) + +func (p *ResPlayroomLose) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResPlayroomOutline struct { + Code RES_CODE `thrift:"code,1" db:"code" json:"code"` + Msg string `thrift:"msg,2" db:"msg" json:"msg"` +} + +func NewResPlayroomOutline() *ResPlayroomOutline { + return &ResPlayroomOutline{} +} + +func (p *ResPlayroomOutline) GetCode() RES_CODE { + return p.Code +} + +func (p *ResPlayroomOutline) GetMsg() string { + return p.Msg +} + +func (p *ResPlayroomOutline) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayroomOutline) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResPlayroomOutline) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResPlayroomOutline) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayroomOutline"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayroomOutline) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:code: ", p), err) + } + return err +} + +func (p *ResPlayroomOutline) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:msg: ", p), err) + } + return err +} + +func (p *ResPlayroomOutline) Equals(other *ResPlayroomOutline) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResPlayroomOutline) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayroomOutline(%+v)", *p) +} + +func (p *ResPlayroomOutline) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayroomOutline", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayroomOutline)(nil) + +func (p *ResPlayroomOutline) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResPlayroomPetAirSet struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResPlayroomPetAirSet() *ResPlayroomPetAirSet { + return &ResPlayroomPetAirSet{} +} + +func (p *ResPlayroomPetAirSet) GetCode() RES_CODE { + return p.Code +} + +func (p *ResPlayroomPetAirSet) GetMsg() string { + return p.Msg +} + +func (p *ResPlayroomPetAirSet) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayroomPetAirSet) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResPlayroomPetAirSet) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResPlayroomPetAirSet) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayroomPetAirSet"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayroomPetAirSet) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResPlayroomPetAirSet) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResPlayroomPetAirSet) Equals(other *ResPlayroomPetAirSet) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResPlayroomPetAirSet) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayroomPetAirSet(%+v)", *p) +} + +func (p *ResPlayroomPetAirSet) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayroomPetAirSet", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayroomPetAirSet)(nil) + +func (p *ResPlayroomPetAirSet) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResPlayroomRest struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResPlayroomRest() *ResPlayroomRest { + return &ResPlayroomRest{} +} + +func (p *ResPlayroomRest) GetCode() RES_CODE { + return p.Code +} + +func (p *ResPlayroomRest) GetMsg() string { + return p.Msg +} + +func (p *ResPlayroomRest) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayroomRest) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResPlayroomRest) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResPlayroomRest) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayroomRest"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayroomRest) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResPlayroomRest) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResPlayroomRest) Equals(other *ResPlayroomRest) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResPlayroomRest) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayroomRest(%+v)", *p) +} + +func (p *ResPlayroomRest) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayroomRest", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayroomRest)(nil) + +func (p *ResPlayroomRest) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResPlayroomSelectReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResPlayroomSelectReward() *ResPlayroomSelectReward { + return &ResPlayroomSelectReward{} +} + +func (p *ResPlayroomSelectReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResPlayroomSelectReward) GetMsg() string { + return p.Msg +} + +func (p *ResPlayroomSelectReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayroomSelectReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResPlayroomSelectReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResPlayroomSelectReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayroomSelectReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayroomSelectReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResPlayroomSelectReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResPlayroomSelectReward) Equals(other *ResPlayroomSelectReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResPlayroomSelectReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayroomSelectReward(%+v)", *p) +} + +func (p *ResPlayroomSelectReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayroomSelectReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayroomSelectReward)(nil) + +func (p *ResPlayroomSelectReward) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResPlayroomSetRoom struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResPlayroomSetRoom() *ResPlayroomSetRoom { + return &ResPlayroomSetRoom{} +} + +func (p *ResPlayroomSetRoom) GetCode() RES_CODE { + return p.Code +} + +func (p *ResPlayroomSetRoom) GetMsg() string { + return p.Msg +} + +func (p *ResPlayroomSetRoom) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayroomSetRoom) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResPlayroomSetRoom) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResPlayroomSetRoom) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayroomSetRoom"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayroomSetRoom) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResPlayroomSetRoom) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResPlayroomSetRoom) Equals(other *ResPlayroomSetRoom) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResPlayroomSetRoom) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayroomSetRoom(%+v)", *p) +} + +func (p *ResPlayroomSetRoom) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayroomSetRoom", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayroomSetRoom)(nil) + +func (p *ResPlayroomSetRoom) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResPlayroomShop struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResPlayroomShop() *ResPlayroomShop { + return &ResPlayroomShop{} +} + +func (p *ResPlayroomShop) GetCode() RES_CODE { + return p.Code +} + +func (p *ResPlayroomShop) GetMsg() string { + return p.Msg +} + +func (p *ResPlayroomShop) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayroomShop) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResPlayroomShop) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResPlayroomShop) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayroomShop"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayroomShop) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResPlayroomShop) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResPlayroomShop) Equals(other *ResPlayroomShop) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResPlayroomShop) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayroomShop(%+v)", *p) +} + +func (p *ResPlayroomShop) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayroomShop", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayroomShop)(nil) + +func (p *ResPlayroomShop) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Id +// +type ResPlayroomTask struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Id int32 `thrift:"Id,3" db:"Id" json:"Id"` +} + +func NewResPlayroomTask() *ResPlayroomTask { + return &ResPlayroomTask{} +} + +func (p *ResPlayroomTask) GetCode() RES_CODE { + return p.Code +} + +func (p *ResPlayroomTask) GetMsg() string { + return p.Msg +} + +func (p *ResPlayroomTask) GetId() int32 { + return p.Id +} + +func (p *ResPlayroomTask) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayroomTask) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResPlayroomTask) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResPlayroomTask) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResPlayroomTask) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayroomTask"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayroomTask) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResPlayroomTask) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResPlayroomTask) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Id: ", p), err) + } + return err +} + +func (p *ResPlayroomTask) Equals(other *ResPlayroomTask) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ResPlayroomTask) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayroomTask(%+v)", *p) +} + +func (p *ResPlayroomTask) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayroomTask", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayroomTask)(nil) + +func (p *ResPlayroomTask) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Id +// - Type +// +type ResPlayroomTaskReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Id int32 `thrift:"Id,3" db:"Id" json:"Id"` + Type int32 `thrift:"Type,4" db:"Type" json:"Type"` +} + +func NewResPlayroomTaskReward() *ResPlayroomTaskReward { + return &ResPlayroomTaskReward{} +} + +func (p *ResPlayroomTaskReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResPlayroomTaskReward) GetMsg() string { + return p.Msg +} + +func (p *ResPlayroomTaskReward) GetId() int32 { + return p.Id +} + +func (p *ResPlayroomTaskReward) GetType() int32 { + return p.Type +} + +func (p *ResPlayroomTaskReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayroomTaskReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResPlayroomTaskReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResPlayroomTaskReward) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResPlayroomTaskReward) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ResPlayroomTaskReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayroomTaskReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayroomTaskReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResPlayroomTaskReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResPlayroomTaskReward) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Id: ", p), err) + } + return err +} + +func (p *ResPlayroomTaskReward) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Type: ", p), err) + } + return err +} + +func (p *ResPlayroomTaskReward) Equals(other *ResPlayroomTaskReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Id != other.Id { + return false + } + if p.Type != other.Type { + return false + } + return true +} + +func (p *ResPlayroomTaskReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayroomTaskReward(%+v)", *p) +} + +func (p *ResPlayroomTaskReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayroomTaskReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayroomTaskReward)(nil) + +func (p *ResPlayroomTaskReward) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Id +// +type ResPlayroomUnlock struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Id int32 `thrift:"Id,3" db:"Id" json:"Id"` +} + +func NewResPlayroomUnlock() *ResPlayroomUnlock { + return &ResPlayroomUnlock{} +} + +func (p *ResPlayroomUnlock) GetCode() RES_CODE { + return p.Code +} + +func (p *ResPlayroomUnlock) GetMsg() string { + return p.Msg +} + +func (p *ResPlayroomUnlock) GetId() int32 { + return p.Id +} + +func (p *ResPlayroomUnlock) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayroomUnlock) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResPlayroomUnlock) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResPlayroomUnlock) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResPlayroomUnlock) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayroomUnlock"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayroomUnlock) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResPlayroomUnlock) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResPlayroomUnlock) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Id: ", p), err) + } + return err +} + +func (p *ResPlayroomUnlock) Equals(other *ResPlayroomUnlock) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ResPlayroomUnlock) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayroomUnlock(%+v)", *p) +} + +func (p *ResPlayroomUnlock) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayroomUnlock", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayroomUnlock)(nil) + +func (p *ResPlayroomUnlock) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Id +// +type ResPlayroomUpvote struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Id int64 `thrift:"Id,3" db:"Id" json:"Id"` +} + +func NewResPlayroomUpvote() *ResPlayroomUpvote { + return &ResPlayroomUpvote{} +} + +func (p *ResPlayroomUpvote) GetCode() RES_CODE { + return p.Code +} + +func (p *ResPlayroomUpvote) GetMsg() string { + return p.Msg +} + +func (p *ResPlayroomUpvote) GetId() int64 { + return p.Id +} + +func (p *ResPlayroomUpvote) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I64 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayroomUpvote) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResPlayroomUpvote) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResPlayroomUpvote) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResPlayroomUpvote) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayroomUpvote"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayroomUpvote) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResPlayroomUpvote) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResPlayroomUpvote) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I64, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Id: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Id: ", p), err) + } + return err +} + +func (p *ResPlayroomUpvote) Equals(other *ResPlayroomUpvote) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ResPlayroomUpvote) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayroomUpvote(%+v)", *p) +} + +func (p *ResPlayroomUpvote) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayroomUpvote", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayroomUpvote)(nil) + +func (p *ResPlayroomUpvote) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResPlayroomWork struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResPlayroomWork() *ResPlayroomWork { + return &ResPlayroomWork{} +} + +func (p *ResPlayroomWork) GetCode() RES_CODE { + return p.Code +} + +func (p *ResPlayroomWork) GetMsg() string { + return p.Msg +} + +func (p *ResPlayroomWork) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayroomWork) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResPlayroomWork) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResPlayroomWork) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayroomWork"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayroomWork) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResPlayroomWork) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResPlayroomWork) Equals(other *ResPlayroomWork) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResPlayroomWork) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayroomWork(%+v)", *p) +} + +func (p *ResPlayroomWork) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayroomWork", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayroomWork)(nil) + +func (p *ResPlayroomWork) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResPlayroomWorkOutline struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResPlayroomWorkOutline() *ResPlayroomWorkOutline { + return &ResPlayroomWorkOutline{} +} + +func (p *ResPlayroomWorkOutline) GetCode() RES_CODE { + return p.Code +} + +func (p *ResPlayroomWorkOutline) GetMsg() string { + return p.Msg +} + +func (p *ResPlayroomWorkOutline) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPlayroomWorkOutline) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResPlayroomWorkOutline) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResPlayroomWorkOutline) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPlayroomWorkOutline"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPlayroomWorkOutline) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResPlayroomWorkOutline) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResPlayroomWorkOutline) Equals(other *ResPlayroomWorkOutline) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResPlayroomWorkOutline) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPlayroomWorkOutline(%+v)", *p) +} + +func (p *ResPlayroomWorkOutline) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPlayroomWorkOutline", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPlayroomWorkOutline)(nil) + +func (p *ResPlayroomWorkOutline) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResPutChessInBag struct { + Code RES_CODE `thrift:"code,1" db:"code" json:"code"` + Msg string `thrift:"msg,2" db:"msg" json:"msg"` +} + +func NewResPutChessInBag() *ResPutChessInBag { + return &ResPutChessInBag{} +} + +func (p *ResPutChessInBag) GetCode() RES_CODE { + return p.Code +} + +func (p *ResPutChessInBag) GetMsg() string { + return p.Msg +} + +func (p *ResPutChessInBag) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPutChessInBag) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResPutChessInBag) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResPutChessInBag) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPutChessInBag"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPutChessInBag) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:code: ", p), err) + } + return err +} + +func (p *ResPutChessInBag) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:msg: ", p), err) + } + return err +} + +func (p *ResPutChessInBag) Equals(other *ResPutChessInBag) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResPutChessInBag) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPutChessInBag(%+v)", *p) +} + +func (p *ResPutChessInBag) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPutChessInBag", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPutChessInBag)(nil) + +func (p *ResPutChessInBag) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResPutPartInBag struct { + Code RES_CODE `thrift:"code,1" db:"code" json:"code"` + Msg string `thrift:"msg,2" db:"msg" json:"msg"` +} + +func NewResPutPartInBag() *ResPutPartInBag { + return &ResPutPartInBag{} +} + +func (p *ResPutPartInBag) GetCode() RES_CODE { + return p.Code +} + +func (p *ResPutPartInBag) GetMsg() string { + return p.Msg +} + +func (p *ResPutPartInBag) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResPutPartInBag) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResPutPartInBag) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResPutPartInBag) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResPutPartInBag"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResPutPartInBag) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:code: ", p), err) + } + return err +} + +func (p *ResPutPartInBag) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:msg: ", p), err) + } + return err +} + +func (p *ResPutPartInBag) Equals(other *ResPutPartInBag) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResPutPartInBag) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResPutPartInBag(%+v)", *p) +} + +func (p *ResPutPartInBag) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResPutPartInBag", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResPutPartInBag)(nil) + +func (p *ResPutPartInBag) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Status +// - EndTime +// - Template +// - Pass +// - GameStartTime +// - GameEndTime +// - Progress +// - Opponent +// - Rank +// +type ResRace struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Status int32 `thrift:"Status,2" db:"Status" json:"Status"` + EndTime int32 `thrift:"EndTime,3" db:"EndTime" json:"EndTime"` + Template int32 `thrift:"Template,4" db:"Template" json:"Template"` + Pass int32 `thrift:"Pass,5" db:"Pass" json:"Pass"` + GameStartTime int32 `thrift:"GameStartTime,6" db:"GameStartTime" json:"GameStartTime"` + GameEndTime int32 `thrift:"GameEndTime,7" db:"GameEndTime" json:"GameEndTime"` + Progress int32 `thrift:"Progress,8" db:"Progress" json:"Progress"` + Opponent []*Raceopponent `thrift:"Opponent,9" db:"Opponent" json:"Opponent"` + Rank int32 `thrift:"Rank,10" db:"Rank" json:"Rank"` +} + +func NewResRace() *ResRace { + return &ResRace{} +} + +func (p *ResRace) GetId() int32 { + return p.Id +} + +func (p *ResRace) GetStatus() int32 { + return p.Status +} + +func (p *ResRace) GetEndTime() int32 { + return p.EndTime +} + +func (p *ResRace) GetTemplate() int32 { + return p.Template +} + +func (p *ResRace) GetPass() int32 { + return p.Pass +} + +func (p *ResRace) GetGameStartTime() int32 { + return p.GameStartTime +} + +func (p *ResRace) GetGameEndTime() int32 { + return p.GameEndTime +} + +func (p *ResRace) GetProgress() int32 { + return p.Progress +} + +func (p *ResRace) GetOpponent() []*Raceopponent { + return p.Opponent +} + +func (p *ResRace) GetRank() int32 { + return p.Rank +} + +func (p *ResRace) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.I32 { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.I32 { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 8: + if fieldTypeId == thrift.I32 { + if err := p.ReadField8(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 9: + if fieldTypeId == thrift.LIST { + if err := p.ReadField9(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 10: + if fieldTypeId == thrift.I32 { + if err := p.ReadField10(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResRace) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResRace) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Status = v + } + return nil +} + +func (p *ResRace) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.EndTime = v + } + return nil +} + +func (p *ResRace) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Template = v + } + return nil +} + +func (p *ResRace) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.Pass = v + } + return nil +} + +func (p *ResRace) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 6: ", err) + } else { + p.GameStartTime = v + } + return nil +} + +func (p *ResRace) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 7: ", err) + } else { + p.GameEndTime = v + } + return nil +} + +func (p *ResRace) ReadField8(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 8: ", err) + } else { + p.Progress = v + } + return nil +} + +func (p *ResRace) ReadField9(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*Raceopponent, 0, size) + p.Opponent = tSlice + for i := 0; i < size; i++ { + _elem421 := &Raceopponent{} + if err := _elem421.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem421), err) + } + p.Opponent = append(p.Opponent, _elem421) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResRace) ReadField10(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 10: ", err) + } else { + p.Rank = v + } + return nil +} + +func (p *ResRace) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResRace"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + if err := p.writeField8(ctx, oprot); err != nil { + return err + } + if err := p.writeField9(ctx, oprot); err != nil { + return err + } + if err := p.writeField10(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResRace) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *ResRace) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Status", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Status: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Status)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Status (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Status: ", p), err) + } + return err +} + +func (p *ResRace) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EndTime", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:EndTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.EndTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.EndTime (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:EndTime: ", p), err) + } + return err +} + +func (p *ResRace) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Template", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Template: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Template)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Template (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Template: ", p), err) + } + return err +} + +func (p *ResRace) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Pass", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Pass: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Pass)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Pass (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Pass: ", p), err) + } + return err +} + +func (p *ResRace) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "GameStartTime", thrift.I32, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:GameStartTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.GameStartTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.GameStartTime (6) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:GameStartTime: ", p), err) + } + return err +} + +func (p *ResRace) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "GameEndTime", thrift.I32, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:GameEndTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.GameEndTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.GameEndTime (7) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:GameEndTime: ", p), err) + } + return err +} + +func (p *ResRace) writeField8(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Progress", thrift.I32, 8); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 8:Progress: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Progress)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Progress (8) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 8:Progress: ", p), err) + } + return err +} + +func (p *ResRace) writeField9(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Opponent", thrift.LIST, 9); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 9:Opponent: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Opponent)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Opponent { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 9:Opponent: ", p), err) + } + return err +} + +func (p *ResRace) writeField10(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Rank", thrift.I32, 10); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 10:Rank: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Rank)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Rank (10) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 10:Rank: ", p), err) + } + return err +} + +func (p *ResRace) Equals(other *ResRace) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Status != other.Status { + return false + } + if p.EndTime != other.EndTime { + return false + } + if p.Template != other.Template { + return false + } + if p.Pass != other.Pass { + return false + } + if p.GameStartTime != other.GameStartTime { + return false + } + if p.GameEndTime != other.GameEndTime { + return false + } + if p.Progress != other.Progress { + return false + } + if len(p.Opponent) != len(other.Opponent) { + return false + } + for i, _tgt := range p.Opponent { + _src422 := other.Opponent[i] + if !_tgt.Equals(_src422) { + return false + } + } + if p.Rank != other.Rank { + return false + } + return true +} + +func (p *ResRace) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResRace(%+v)", *p) +} + +func (p *ResRace) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResRace", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResRace)(nil) + +func (p *ResRace) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResRaceReward struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResRaceReward() *ResRaceReward { + return &ResRaceReward{} +} + +func (p *ResRaceReward) GetCode() RES_CODE { + return p.Code +} + +func (p *ResRaceReward) GetMsg() string { + return p.Msg +} + +func (p *ResRaceReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResRaceReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResRaceReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResRaceReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResRaceReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResRaceReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResRaceReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResRaceReward) Equals(other *ResRaceReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResRaceReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResRaceReward(%+v)", *p) +} + +func (p *ResRaceReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResRaceReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResRaceReward)(nil) + +func (p *ResRaceReward) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResRaceStart struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResRaceStart() *ResRaceStart { + return &ResRaceStart{} +} + +func (p *ResRaceStart) GetCode() RES_CODE { + return p.Code +} + +func (p *ResRaceStart) GetMsg() string { + return p.Msg +} + +func (p *ResRaceStart) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResRaceStart) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResRaceStart) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResRaceStart) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResRaceStart"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResRaceStart) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResRaceStart) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResRaceStart) Equals(other *ResRaceStart) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResRaceStart) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResRaceStart(%+v)", *p) +} + +func (p *ResRaceStart) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResRaceStart", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResRaceStart)(nil) + +func (p *ResRaceStart) Validate() error { + return nil +} + +// Attributes: +// - Type +// - RankList +// - MyRank +// - MyScore +// +type ResRank struct { + Type int32 `thrift:"Type,1" db:"Type" json:"Type"` + RankList map[int32]*ResPlayerSimple `thrift:"RankList,2" db:"RankList" json:"RankList"` + MyRank int32 `thrift:"MyRank,3" db:"MyRank" json:"MyRank"` + MyScore float64 `thrift:"MyScore,4" db:"MyScore" json:"MyScore"` +} + +func NewResRank() *ResRank { + return &ResRank{} +} + +func (p *ResRank) GetType() int32 { + return p.Type +} + +func (p *ResRank) GetRankList() map[int32]*ResPlayerSimple { + return p.RankList +} + +func (p *ResRank) GetMyRank() int32 { + return p.MyRank +} + +func (p *ResRank) GetMyScore() float64 { + return p.MyScore +} + +func (p *ResRank) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.MAP { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.DOUBLE { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResRank) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *ResRank) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]*ResPlayerSimple, size) + p.RankList = tMap + for i := 0; i < size; i++ { + var _key423 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key423 = v + } + _val424 := &ResPlayerSimple{} + if err := _val424.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _val424), err) + } + p.RankList[_key423] = _val424 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResRank) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.MyRank = v + } + return nil +} + +func (p *ResRank) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadDouble(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.MyScore = v + } + return nil +} + +func (p *ResRank) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResRank"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResRank) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Type: ", p), err) + } + return err +} + +func (p *ResRank) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "RankList", thrift.MAP, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:RankList: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.STRUCT, len(p.RankList)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.RankList { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:RankList: ", p), err) + } + return err +} + +func (p *ResRank) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MyRank", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:MyRank: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.MyRank)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.MyRank (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:MyRank: ", p), err) + } + return err +} + +func (p *ResRank) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MyScore", thrift.DOUBLE, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:MyScore: ", p), err) + } + if err := oprot.WriteDouble(ctx, float64(p.MyScore)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.MyScore (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:MyScore: ", p), err) + } + return err +} + +func (p *ResRank) Equals(other *ResRank) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Type != other.Type { + return false + } + if len(p.RankList) != len(other.RankList) { + return false + } + for k, _tgt := range p.RankList { + _src425 := other.RankList[k] + if !_tgt.Equals(_src425) { + return false + } + } + if p.MyRank != other.MyRank { + return false + } + if p.MyScore != other.MyScore { + return false + } + return true +} + +func (p *ResRank) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResRank(%+v)", *p) +} + +func (p *ResRank) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResRank", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResRank)(nil) + +func (p *ResRank) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Id +// +type ResReadMail struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Id int32 `thrift:"Id,3" db:"Id" json:"Id"` +} + +func NewResReadMail() *ResReadMail { + return &ResReadMail{} +} + +func (p *ResReadMail) GetCode() RES_CODE { + return p.Code +} + +func (p *ResReadMail) GetMsg() string { + return p.Msg +} + +func (p *ResReadMail) GetId() int32 { + return p.Id +} + +func (p *ResReadMail) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResReadMail) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResReadMail) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResReadMail) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResReadMail) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResReadMail"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResReadMail) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResReadMail) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResReadMail) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Id: ", p), err) + } + return err +} + +func (p *ResReadMail) Equals(other *ResReadMail) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ResReadMail) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResReadMail(%+v)", *p) +} + +func (p *ResReadMail) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResReadMail", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResReadMail)(nil) + +func (p *ResReadMail) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResRefreshChessShop struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResRefreshChessShop() *ResRefreshChessShop { + return &ResRefreshChessShop{} +} + +func (p *ResRefreshChessShop) GetCode() RES_CODE { + return p.Code +} + +func (p *ResRefreshChessShop) GetMsg() string { + return p.Msg +} + +func (p *ResRefreshChessShop) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResRefreshChessShop) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResRefreshChessShop) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResRefreshChessShop) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResRefreshChessShop"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResRefreshChessShop) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResRefreshChessShop) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResRefreshChessShop) Equals(other *ResRefreshChessShop) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResRefreshChessShop) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResRefreshChessShop(%+v)", *p) +} + +func (p *ResRefreshChessShop) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResRefreshChessShop", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResRefreshChessShop)(nil) + +func (p *ResRefreshChessShop) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Id +// +type ResRefuseCardExchange struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Id string `thrift:"Id,3" db:"Id" json:"Id"` +} + +func NewResRefuseCardExchange() *ResRefuseCardExchange { + return &ResRefuseCardExchange{} +} + +func (p *ResRefuseCardExchange) GetCode() RES_CODE { + return p.Code +} + +func (p *ResRefuseCardExchange) GetMsg() string { + return p.Msg +} + +func (p *ResRefuseCardExchange) GetId() string { + return p.Id +} + +func (p *ResRefuseCardExchange) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.STRING { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResRefuseCardExchange) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResRefuseCardExchange) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResRefuseCardExchange) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResRefuseCardExchange) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResRefuseCardExchange"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResRefuseCardExchange) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResRefuseCardExchange) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResRefuseCardExchange) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.STRING, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Id: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Id: ", p), err) + } + return err +} + +func (p *ResRefuseCardExchange) Equals(other *ResRefuseCardExchange) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ResRefuseCardExchange) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResRefuseCardExchange(%+v)", *p) +} + +func (p *ResRefuseCardExchange) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResRefuseCardExchange", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResRefuseCardExchange)(nil) + +func (p *ResRefuseCardExchange) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Id +// +type ResRefuseCardGive struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Id string `thrift:"Id,3" db:"Id" json:"Id"` +} + +func NewResRefuseCardGive() *ResRefuseCardGive { + return &ResRefuseCardGive{} +} + +func (p *ResRefuseCardGive) GetCode() RES_CODE { + return p.Code +} + +func (p *ResRefuseCardGive) GetMsg() string { + return p.Msg +} + +func (p *ResRefuseCardGive) GetId() string { + return p.Id +} + +func (p *ResRefuseCardGive) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.STRING { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResRefuseCardGive) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResRefuseCardGive) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResRefuseCardGive) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResRefuseCardGive) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResRefuseCardGive"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResRefuseCardGive) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResRefuseCardGive) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResRefuseCardGive) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.STRING, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Id: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Id: ", p), err) + } + return err +} + +func (p *ResRefuseCardGive) Equals(other *ResRefuseCardGive) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ResRefuseCardGive) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResRefuseCardGive(%+v)", *p) +} + +func (p *ResRefuseCardGive) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResRefuseCardGive", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResRefuseCardGive)(nil) + +func (p *ResRefuseCardGive) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Id +// +type ResRefuseCardSelect struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Id string `thrift:"Id,3" db:"Id" json:"Id"` +} + +func NewResRefuseCardSelect() *ResRefuseCardSelect { + return &ResRefuseCardSelect{} +} + +func (p *ResRefuseCardSelect) GetCode() RES_CODE { + return p.Code +} + +func (p *ResRefuseCardSelect) GetMsg() string { + return p.Msg +} + +func (p *ResRefuseCardSelect) GetId() string { + return p.Id +} + +func (p *ResRefuseCardSelect) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.STRING { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResRefuseCardSelect) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResRefuseCardSelect) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResRefuseCardSelect) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResRefuseCardSelect) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResRefuseCardSelect"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResRefuseCardSelect) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResRefuseCardSelect) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResRefuseCardSelect) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.STRING, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Id: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Id: ", p), err) + } + return err +} + +func (p *ResRefuseCardSelect) Equals(other *ResRefuseCardSelect) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ResRefuseCardSelect) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResRefuseCardSelect(%+v)", *p) +} + +func (p *ResRefuseCardSelect) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResRefuseCardSelect", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResRefuseCardSelect)(nil) + +func (p *ResRefuseCardSelect) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Uid +// +type ResRefuseFriend struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Uid int64 `thrift:"Uid,3" db:"Uid" json:"Uid"` +} + +func NewResRefuseFriend() *ResRefuseFriend { + return &ResRefuseFriend{} +} + +func (p *ResRefuseFriend) GetCode() RES_CODE { + return p.Code +} + +func (p *ResRefuseFriend) GetMsg() string { + return p.Msg +} + +func (p *ResRefuseFriend) GetUid() int64 { + return p.Uid +} + +func (p *ResRefuseFriend) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I64 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResRefuseFriend) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResRefuseFriend) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResRefuseFriend) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ResRefuseFriend) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResRefuseFriend"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResRefuseFriend) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResRefuseFriend) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResRefuseFriend) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Uid: ", p), err) + } + return err +} + +func (p *ResRefuseFriend) Equals(other *ResRefuseFriend) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Uid != other.Uid { + return false + } + return true +} + +func (p *ResRefuseFriend) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResRefuseFriend(%+v)", *p) +} + +func (p *ResRefuseFriend) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResRefuseFriend", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResRefuseFriend)(nil) + +func (p *ResRefuseFriend) Validate() error { + return nil +} + +// Attributes: +// - ResultCode +// +type ResRegisterAccount struct { + ResultCode int32 `thrift:"ResultCode,1" db:"ResultCode" json:"ResultCode"` +} + +func NewResRegisterAccount() *ResRegisterAccount { + return &ResRegisterAccount{} +} + +func (p *ResRegisterAccount) GetResultCode() int32 { + return p.ResultCode +} + +func (p *ResRegisterAccount) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResRegisterAccount) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.ResultCode = v + } + return nil +} + +func (p *ResRegisterAccount) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResRegisterAccount"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResRegisterAccount) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ResultCode", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ResultCode: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ResultCode)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ResultCode (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ResultCode: ", p), err) + } + return err +} + +func (p *ResRegisterAccount) Equals(other *ResRegisterAccount) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ResultCode != other.ResultCode { + return false + } + return true +} + +func (p *ResRegisterAccount) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResRegisterAccount(%+v)", *p) +} + +func (p *ResRegisterAccount) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResRegisterAccount", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResRegisterAccount)(nil) + +func (p *ResRegisterAccount) Validate() error { + return nil +} + +// Attributes: +// - ResultCode +// +type ResRemoveAd struct { + ResultCode int32 `thrift:"ResultCode,1" db:"ResultCode" json:"ResultCode"` +} + +func NewResRemoveAd() *ResRemoveAd { + return &ResRemoveAd{} +} + +func (p *ResRemoveAd) GetResultCode() int32 { + return p.ResultCode +} + +func (p *ResRemoveAd) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResRemoveAd) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.ResultCode = v + } + return nil +} + +func (p *ResRemoveAd) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResRemoveAd"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResRemoveAd) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ResultCode", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ResultCode: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ResultCode)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ResultCode (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ResultCode: ", p), err) + } + return err +} + +func (p *ResRemoveAd) Equals(other *ResRemoveAd) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ResultCode != other.ResultCode { + return false + } + return true +} + +func (p *ResRemoveAd) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResRemoveAd(%+v)", *p) +} + +func (p *ResRemoveAd) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResRemoveAd", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResRemoveAd)(nil) + +func (p *ResRemoveAd) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResRewardOrder struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResRewardOrder() *ResRewardOrder { + return &ResRewardOrder{} +} + +func (p *ResRewardOrder) GetCode() RES_CODE { + return p.Code +} + +func (p *ResRewardOrder) GetMsg() string { + return p.Msg +} + +func (p *ResRewardOrder) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResRewardOrder) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResRewardOrder) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResRewardOrder) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResRewardOrder"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResRewardOrder) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResRewardOrder) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResRewardOrder) Equals(other *ResRewardOrder) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResRewardOrder) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResRewardOrder(%+v)", *p) +} + +func (p *ResRewardOrder) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResRewardOrder", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResRewardOrder)(nil) + +func (p *ResRewardOrder) Validate() error { + return nil +} + +// Attributes: +// - Code +// - List +// +type ResSearchPlayer struct { + Code int32 `thrift:"Code,1" db:"Code" json:"Code"` + List []*ResPlayerSimple `thrift:"List,2" db:"List" json:"List"` +} + +func NewResSearchPlayer() *ResSearchPlayer { + return &ResSearchPlayer{} +} + +func (p *ResSearchPlayer) GetCode() int32 { + return p.Code +} + +func (p *ResSearchPlayer) GetList() []*ResPlayerSimple { + return p.List +} + +func (p *ResSearchPlayer) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.LIST { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResSearchPlayer) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Code = v + } + return nil +} + +func (p *ResSearchPlayer) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ResPlayerSimple, 0, size) + p.List = tSlice + for i := 0; i < size; i++ { + _elem426 := &ResPlayerSimple{} + if err := _elem426.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem426), err) + } + p.List = append(p.List, _elem426) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResSearchPlayer) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResSearchPlayer"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResSearchPlayer) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResSearchPlayer) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "List", thrift.LIST, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:List: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.List)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.List { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:List: ", p), err) + } + return err +} + +func (p *ResSearchPlayer) Equals(other *ResSearchPlayer) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if len(p.List) != len(other.List) { + return false + } + for i, _tgt := range p.List { + _src427 := other.List[i] + if !_tgt.Equals(_src427) { + return false + } + } + return true +} + +func (p *ResSearchPlayer) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResSearchPlayer(%+v)", *p) +} + +func (p *ResSearchPlayer) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResSearchPlayer", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResSearchPlayer)(nil) + +func (p *ResSearchPlayer) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Id +// +type ResSelectCardExchange struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Id string `thrift:"Id,3" db:"Id" json:"Id"` +} + +func NewResSelectCardExchange() *ResSelectCardExchange { + return &ResSelectCardExchange{} +} + +func (p *ResSelectCardExchange) GetCode() RES_CODE { + return p.Code +} + +func (p *ResSelectCardExchange) GetMsg() string { + return p.Msg +} + +func (p *ResSelectCardExchange) GetId() string { + return p.Id +} + +func (p *ResSelectCardExchange) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.STRING { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResSelectCardExchange) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResSelectCardExchange) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResSelectCardExchange) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *ResSelectCardExchange) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResSelectCardExchange"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResSelectCardExchange) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResSelectCardExchange) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResSelectCardExchange) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.STRING, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Id: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Id: ", p), err) + } + return err +} + +func (p *ResSelectCardExchange) Equals(other *ResSelectCardExchange) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Id != other.Id { + return false + } + return true +} + +func (p *ResSelectCardExchange) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResSelectCardExchange(%+v)", *p) +} + +func (p *ResSelectCardExchange) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResSelectCardExchange", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResSelectCardExchange)(nil) + +func (p *ResSelectCardExchange) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResSelectLimitEvent struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResSelectLimitEvent() *ResSelectLimitEvent { + return &ResSelectLimitEvent{} +} + +func (p *ResSelectLimitEvent) GetCode() RES_CODE { + return p.Code +} + +func (p *ResSelectLimitEvent) GetMsg() string { + return p.Msg +} + +func (p *ResSelectLimitEvent) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResSelectLimitEvent) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResSelectLimitEvent) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResSelectLimitEvent) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResSelectLimitEvent"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResSelectLimitEvent) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResSelectLimitEvent) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResSelectLimitEvent) Equals(other *ResSelectLimitEvent) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResSelectLimitEvent) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResSelectLimitEvent(%+v)", *p) +} + +func (p *ResSelectLimitEvent) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResSelectLimitEvent", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResSelectLimitEvent)(nil) + +func (p *ResSelectLimitEvent) Validate() error { + return nil +} + +// Attributes: +// - ResultCode +// +type ResSelfInvited struct { + ResultCode int32 `thrift:"ResultCode,1" db:"ResultCode" json:"ResultCode"` +} + +func NewResSelfInvited() *ResSelfInvited { + return &ResSelfInvited{} +} + +func (p *ResSelfInvited) GetResultCode() int32 { + return p.ResultCode +} + +func (p *ResSelfInvited) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResSelfInvited) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.ResultCode = v + } + return nil +} + +func (p *ResSelfInvited) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResSelfInvited"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResSelfInvited) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ResultCode", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ResultCode: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ResultCode)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ResultCode (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ResultCode: ", p), err) + } + return err +} + +func (p *ResSelfInvited) Equals(other *ResSelfInvited) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ResultCode != other.ResultCode { + return false + } + return true +} + +func (p *ResSelfInvited) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResSelfInvited(%+v)", *p) +} + +func (p *ResSelfInvited) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResSelfInvited", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResSelfInvited)(nil) + +func (p *ResSelfInvited) Validate() error { + return nil +} + +// Attributes: +// - Num +// +type ResSellChessNum struct { + Num int32 `thrift:"Num,1" db:"Num" json:"Num"` +} + +func NewResSellChessNum() *ResSellChessNum { + return &ResSellChessNum{} +} + +func (p *ResSellChessNum) GetNum() int32 { + return p.Num +} + +func (p *ResSellChessNum) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResSellChessNum) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Num = v + } + return nil +} + +func (p *ResSellChessNum) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResSellChessNum"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResSellChessNum) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Num", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Num: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Num)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Num (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Num: ", p), err) + } + return err +} + +func (p *ResSellChessNum) Equals(other *ResSellChessNum) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Num != other.Num { + return false + } + return true +} + +func (p *ResSellChessNum) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResSellChessNum(%+v)", *p) +} + +func (p *ResSellChessNum) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResSellChessNum", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResSellChessNum)(nil) + +func (p *ResSellChessNum) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResSendWishBeg struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResSendWishBeg() *ResSendWishBeg { + return &ResSendWishBeg{} +} + +func (p *ResSendWishBeg) GetCode() RES_CODE { + return p.Code +} + +func (p *ResSendWishBeg) GetMsg() string { + return p.Msg +} + +func (p *ResSendWishBeg) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResSendWishBeg) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResSendWishBeg) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResSendWishBeg) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResSendWishBeg"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResSendWishBeg) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResSendWishBeg) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResSendWishBeg) Equals(other *ResSendWishBeg) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResSendWishBeg) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResSendWishBeg(%+v)", *p) +} + +func (p *ResSendWishBeg) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResSendWishBeg", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResSendWishBeg)(nil) + +func (p *ResSendWishBeg) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResSeparateChess struct { + Code RES_CODE `thrift:"code,1" db:"code" json:"code"` + Msg string `thrift:"msg,2" db:"msg" json:"msg"` +} + +func NewResSeparateChess() *ResSeparateChess { + return &ResSeparateChess{} +} + +func (p *ResSeparateChess) GetCode() RES_CODE { + return p.Code +} + +func (p *ResSeparateChess) GetMsg() string { + return p.Msg +} + +func (p *ResSeparateChess) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResSeparateChess) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResSeparateChess) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResSeparateChess) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResSeparateChess"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResSeparateChess) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:code: ", p), err) + } + return err +} + +func (p *ResSeparateChess) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:msg: ", p), err) + } + return err +} + +func (p *ResSeparateChess) Equals(other *ResSeparateChess) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResSeparateChess) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResSeparateChess(%+v)", *p) +} + +func (p *ResSeparateChess) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResSeparateChess", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResSeparateChess)(nil) + +func (p *ResSeparateChess) Validate() error { + return nil +} + +// Attributes: +// - ServerTime +// +type ResServerTime struct { + ServerTime int32 `thrift:"ServerTime,1" db:"ServerTime" json:"ServerTime"` +} + +func NewResServerTime() *ResServerTime { + return &ResServerTime{} +} + +func (p *ResServerTime) GetServerTime() int32 { + return p.ServerTime +} + +func (p *ResServerTime) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResServerTime) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.ServerTime = v + } + return nil +} + +func (p *ResServerTime) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResServerTime"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResServerTime) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ServerTime", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ServerTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ServerTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ServerTime (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ServerTime: ", p), err) + } + return err +} + +func (p *ResServerTime) Equals(other *ResServerTime) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ServerTime != other.ServerTime { + return false + } + return true +} + +func (p *ResServerTime) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResServerTime(%+v)", *p) +} + +func (p *ResServerTime) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResServerTime", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResServerTime)(nil) + +func (p *ResServerTime) Validate() error { + return nil +} + +// Attributes: +// - Version +// +type ResServerVersion struct { + Version int32 `thrift:"Version,1" db:"Version" json:"Version"` +} + +func NewResServerVersion() *ResServerVersion { + return &ResServerVersion{} +} + +func (p *ResServerVersion) GetVersion() int32 { + return p.Version +} + +func (p *ResServerVersion) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResServerVersion) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Version = v + } + return nil +} + +func (p *ResServerVersion) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResServerVersion"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResServerVersion) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Version", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Version: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Version)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Version (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Version: ", p), err) + } + return err +} + +func (p *ResServerVersion) Equals(other *ResServerVersion) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Version != other.Version { + return false + } + return true +} + +func (p *ResServerVersion) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResServerVersion(%+v)", *p) +} + +func (p *ResServerVersion) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResServerVersion", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResServerVersion)(nil) + +func (p *ResServerVersion) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResSetAvatar struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResSetAvatar() *ResSetAvatar { + return &ResSetAvatar{} +} + +func (p *ResSetAvatar) GetCode() RES_CODE { + return p.Code +} + +func (p *ResSetAvatar) GetMsg() string { + return p.Msg +} + +func (p *ResSetAvatar) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResSetAvatar) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResSetAvatar) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResSetAvatar) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResSetAvatar"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResSetAvatar) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResSetAvatar) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResSetAvatar) Equals(other *ResSetAvatar) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResSetAvatar) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResSetAvatar(%+v)", *p) +} + +func (p *ResSetAvatar) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResSetAvatar", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResSetAvatar)(nil) + +func (p *ResSetAvatar) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResSetEmoji struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResSetEmoji() *ResSetEmoji { + return &ResSetEmoji{} +} + +func (p *ResSetEmoji) GetCode() RES_CODE { + return p.Code +} + +func (p *ResSetEmoji) GetMsg() string { + return p.Msg +} + +func (p *ResSetEmoji) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResSetEmoji) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResSetEmoji) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResSetEmoji) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResSetEmoji"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResSetEmoji) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResSetEmoji) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResSetEmoji) Equals(other *ResSetEmoji) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResSetEmoji) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResSetEmoji(%+v)", *p) +} + +func (p *ResSetEmoji) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResSetEmoji", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResSetEmoji)(nil) + +func (p *ResSetEmoji) Validate() error { + return nil +} + +// Attributes: +// - ResultCode +// - Msg +// +type ResSetEnergyMul struct { + ResultCode RES_CODE `thrift:"ResultCode,1" db:"ResultCode" json:"ResultCode"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResSetEnergyMul() *ResSetEnergyMul { + return &ResSetEnergyMul{} +} + +func (p *ResSetEnergyMul) GetResultCode() RES_CODE { + return p.ResultCode +} + +func (p *ResSetEnergyMul) GetMsg() string { + return p.Msg +} + +func (p *ResSetEnergyMul) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResSetEnergyMul) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.ResultCode = temp + } + return nil +} + +func (p *ResSetEnergyMul) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResSetEnergyMul) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResSetEnergyMul"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResSetEnergyMul) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ResultCode", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ResultCode: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ResultCode)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ResultCode (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ResultCode: ", p), err) + } + return err +} + +func (p *ResSetEnergyMul) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResSetEnergyMul) Equals(other *ResSetEnergyMul) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ResultCode != other.ResultCode { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResSetEnergyMul) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResSetEnergyMul(%+v)", *p) +} + +func (p *ResSetEnergyMul) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResSetEnergyMul", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResSetEnergyMul)(nil) + +func (p *ResSetEnergyMul) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResSetFace struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResSetFace() *ResSetFace { + return &ResSetFace{} +} + +func (p *ResSetFace) GetCode() RES_CODE { + return p.Code +} + +func (p *ResSetFace) GetMsg() string { + return p.Msg +} + +func (p *ResSetFace) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResSetFace) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResSetFace) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResSetFace) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResSetFace"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResSetFace) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResSetFace) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResSetFace) Equals(other *ResSetFace) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResSetFace) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResSetFace(%+v)", *p) +} + +func (p *ResSetFace) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResSetFace", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResSetFace)(nil) + +func (p *ResSetFace) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResSetFacebookUrl struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResSetFacebookUrl() *ResSetFacebookUrl { + return &ResSetFacebookUrl{} +} + +func (p *ResSetFacebookUrl) GetCode() RES_CODE { + return p.Code +} + +func (p *ResSetFacebookUrl) GetMsg() string { + return p.Msg +} + +func (p *ResSetFacebookUrl) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResSetFacebookUrl) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResSetFacebookUrl) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResSetFacebookUrl) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResSetFacebookUrl"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResSetFacebookUrl) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResSetFacebookUrl) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResSetFacebookUrl) Equals(other *ResSetFacebookUrl) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResSetFacebookUrl) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResSetFacebookUrl(%+v)", *p) +} + +func (p *ResSetFacebookUrl) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResSetFacebookUrl", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResSetFacebookUrl)(nil) + +func (p *ResSetFacebookUrl) Validate() error { + return nil +} + +// Attributes: +// - ResultCode +// - Msg +// +type ResSetName struct { + ResultCode RES_CODE `thrift:"ResultCode,1" db:"ResultCode" json:"ResultCode"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResSetName() *ResSetName { + return &ResSetName{} +} + +func (p *ResSetName) GetResultCode() RES_CODE { + return p.ResultCode +} + +func (p *ResSetName) GetMsg() string { + return p.Msg +} + +func (p *ResSetName) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResSetName) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.ResultCode = temp + } + return nil +} + +func (p *ResSetName) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResSetName) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResSetName"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResSetName) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ResultCode", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ResultCode: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ResultCode)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ResultCode (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ResultCode: ", p), err) + } + return err +} + +func (p *ResSetName) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResSetName) Equals(other *ResSetName) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ResultCode != other.ResultCode { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResSetName) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResSetName(%+v)", *p) +} + +func (p *ResSetName) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResSetName", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResSetName)(nil) + +func (p *ResSetName) Validate() error { + return nil +} + +// Attributes: +// - ResultCode +// - Msg +// +type ResSetPetName struct { + ResultCode RES_CODE `thrift:"ResultCode,1" db:"ResultCode" json:"ResultCode"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResSetPetName() *ResSetPetName { + return &ResSetPetName{} +} + +func (p *ResSetPetName) GetResultCode() RES_CODE { + return p.ResultCode +} + +func (p *ResSetPetName) GetMsg() string { + return p.Msg +} + +func (p *ResSetPetName) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResSetPetName) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.ResultCode = temp + } + return nil +} + +func (p *ResSetPetName) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResSetPetName) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResSetPetName"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResSetPetName) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ResultCode", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ResultCode: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ResultCode)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ResultCode (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ResultCode: ", p), err) + } + return err +} + +func (p *ResSetPetName) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResSetPetName) Equals(other *ResSetPetName) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ResultCode != other.ResultCode { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResSetPetName) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResSetPetName(%+v)", *p) +} + +func (p *ResSetPetName) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResSetPetName", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResSetPetName)(nil) + +func (p *ResSetPetName) Validate() error { + return nil +} + +// Attributes: +// - WeekReward +// - MonthReward +// - Active +// - IsBack +// +type ResSevenLogin struct { + WeekReward []*SevenLoginReward `thrift:"WeekReward,1" db:"WeekReward" json:"WeekReward"` + MonthReward []*SevenLoginReward `thrift:"MonthReward,2" db:"MonthReward" json:"MonthReward"` + Active int32 `thrift:"Active,3" db:"Active" json:"Active"` + IsBack bool `thrift:"IsBack,4" db:"IsBack" json:"IsBack"` +} + +func NewResSevenLogin() *ResSevenLogin { + return &ResSevenLogin{} +} + +func (p *ResSevenLogin) GetWeekReward() []*SevenLoginReward { + return p.WeekReward +} + +func (p *ResSevenLogin) GetMonthReward() []*SevenLoginReward { + return p.MonthReward +} + +func (p *ResSevenLogin) GetActive() int32 { + return p.Active +} + +func (p *ResSevenLogin) GetIsBack() bool { + return p.IsBack +} + +func (p *ResSevenLogin) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.LIST { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.BOOL { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResSevenLogin) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*SevenLoginReward, 0, size) + p.WeekReward = tSlice + for i := 0; i < size; i++ { + _elem428 := &SevenLoginReward{} + if err := _elem428.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem428), err) + } + p.WeekReward = append(p.WeekReward, _elem428) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResSevenLogin) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*SevenLoginReward, 0, size) + p.MonthReward = tSlice + for i := 0; i < size; i++ { + _elem429 := &SevenLoginReward{} + if err := _elem429.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem429), err) + } + p.MonthReward = append(p.MonthReward, _elem429) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResSevenLogin) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Active = v + } + return nil +} + +func (p *ResSevenLogin) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadBool(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.IsBack = v + } + return nil +} + +func (p *ResSevenLogin) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResSevenLogin"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResSevenLogin) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "WeekReward", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:WeekReward: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.WeekReward)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.WeekReward { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:WeekReward: ", p), err) + } + return err +} + +func (p *ResSevenLogin) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MonthReward", thrift.LIST, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:MonthReward: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.MonthReward)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.MonthReward { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:MonthReward: ", p), err) + } + return err +} + +func (p *ResSevenLogin) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Active", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Active: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Active)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Active (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Active: ", p), err) + } + return err +} + +func (p *ResSevenLogin) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "IsBack", thrift.BOOL, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:IsBack: ", p), err) + } + if err := oprot.WriteBool(ctx, bool(p.IsBack)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.IsBack (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:IsBack: ", p), err) + } + return err +} + +func (p *ResSevenLogin) Equals(other *ResSevenLogin) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.WeekReward) != len(other.WeekReward) { + return false + } + for i, _tgt := range p.WeekReward { + _src430 := other.WeekReward[i] + if !_tgt.Equals(_src430) { + return false + } + } + if len(p.MonthReward) != len(other.MonthReward) { + return false + } + for i, _tgt := range p.MonthReward { + _src431 := other.MonthReward[i] + if !_tgt.Equals(_src431) { + return false + } + } + if p.Active != other.Active { + return false + } + if p.IsBack != other.IsBack { + return false + } + return true +} + +func (p *ResSevenLogin) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResSevenLogin(%+v)", *p) +} + +func (p *ResSevenLogin) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResSevenLogin", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResSevenLogin)(nil) + +func (p *ResSevenLogin) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResShippingOrder struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` +} + +func NewResShippingOrder() *ResShippingOrder { + return &ResShippingOrder{} +} + +func (p *ResShippingOrder) GetCode() RES_CODE { + return p.Code +} + +func (p *ResShippingOrder) GetMsg() string { + return p.Msg +} + +func (p *ResShippingOrder) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResShippingOrder) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResShippingOrder) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResShippingOrder) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResShippingOrder"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResShippingOrder) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResShippingOrder) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResShippingOrder) Equals(other *ResShippingOrder) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResShippingOrder) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResShippingOrder(%+v)", *p) +} + +func (p *ResShippingOrder) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResShippingOrder", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResShippingOrder)(nil) + +func (p *ResShippingOrder) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResSourceChest struct { + Code RES_CODE `thrift:"code,1" db:"code" json:"code"` + Msg string `thrift:"msg,2" db:"msg" json:"msg"` +} + +func NewResSourceChest() *ResSourceChest { + return &ResSourceChest{} +} + +func (p *ResSourceChest) GetCode() RES_CODE { + return p.Code +} + +func (p *ResSourceChest) GetMsg() string { + return p.Msg +} + +func (p *ResSourceChest) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResSourceChest) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResSourceChest) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResSourceChest) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResSourceChest"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResSourceChest) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:code: ", p), err) + } + return err +} + +func (p *ResSourceChest) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:msg: ", p), err) + } + return err +} + +func (p *ResSourceChest) Equals(other *ResSourceChest) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResSourceChest) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResSourceChest(%+v)", *p) +} + +func (p *ResSourceChest) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResSourceChest", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResSourceChest)(nil) + +func (p *ResSourceChest) Validate() error { + return nil +} + +// Attributes: +// - Grade +// - Count +// +type ResSpecialShop struct { + Grade int32 `thrift:"Grade,1" db:"Grade" json:"Grade"` + Count int32 `thrift:"Count,2" db:"Count" json:"Count"` +} + +func NewResSpecialShop() *ResSpecialShop { + return &ResSpecialShop{} +} + +func (p *ResSpecialShop) GetGrade() int32 { + return p.Grade +} + +func (p *ResSpecialShop) GetCount() int32 { + return p.Count +} + +func (p *ResSpecialShop) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResSpecialShop) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Grade = v + } + return nil +} + +func (p *ResSpecialShop) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Count = v + } + return nil +} + +func (p *ResSpecialShop) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResSpecialShop"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResSpecialShop) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Grade", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Grade: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Grade)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Grade (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Grade: ", p), err) + } + return err +} + +func (p *ResSpecialShop) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Count", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Count: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Count)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Count (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Count: ", p), err) + } + return err +} + +func (p *ResSpecialShop) Equals(other *ResSpecialShop) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Grade != other.Grade { + return false + } + if p.Count != other.Count { + return false + } + return true +} + +func (p *ResSpecialShop) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResSpecialShop(%+v)", *p) +} + +func (p *ResSpecialShop) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResSpecialShop", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResSpecialShop)(nil) + +func (p *ResSpecialShop) Validate() error { + return nil +} + +// Attributes: +// - DwUin +// - ResultCode +// +type ResSynGameData struct { + DwUin int64 `thrift:"dwUin,1" db:"dwUin" json:"dwUin"` + ResultCode int32 `thrift:"ResultCode,2" db:"ResultCode" json:"ResultCode"` +} + +func NewResSynGameData() *ResSynGameData { + return &ResSynGameData{} +} + +func (p *ResSynGameData) GetDwUin() int64 { + return p.DwUin +} + +func (p *ResSynGameData) GetResultCode() int32 { + return p.ResultCode +} + +func (p *ResSynGameData) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResSynGameData) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.DwUin = v + } + return nil +} + +func (p *ResSynGameData) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.ResultCode = v + } + return nil +} + +func (p *ResSynGameData) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResSynGameData"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResSynGameData) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "dwUin", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:dwUin: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.DwUin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.dwUin (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:dwUin: ", p), err) + } + return err +} + +func (p *ResSynGameData) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ResultCode", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:ResultCode: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ResultCode)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ResultCode (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:ResultCode: ", p), err) + } + return err +} + +func (p *ResSynGameData) Equals(other *ResSynGameData) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.DwUin != other.DwUin { + return false + } + if p.ResultCode != other.ResultCode { + return false + } + return true +} + +func (p *ResSynGameData) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResSynGameData(%+v)", *p) +} + +func (p *ResSynGameData) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResSynGameData", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResSynGameData)(nil) + +func (p *ResSynGameData) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResTakeChessOutBag struct { + Code RES_CODE `thrift:"code,1" db:"code" json:"code"` + Msg string `thrift:"msg,2" db:"msg" json:"msg"` +} + +func NewResTakeChessOutBag() *ResTakeChessOutBag { + return &ResTakeChessOutBag{} +} + +func (p *ResTakeChessOutBag) GetCode() RES_CODE { + return p.Code +} + +func (p *ResTakeChessOutBag) GetMsg() string { + return p.Msg +} + +func (p *ResTakeChessOutBag) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResTakeChessOutBag) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResTakeChessOutBag) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResTakeChessOutBag) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResTakeChessOutBag"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResTakeChessOutBag) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:code: ", p), err) + } + return err +} + +func (p *ResTakeChessOutBag) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:msg: ", p), err) + } + return err +} + +func (p *ResTakeChessOutBag) Equals(other *ResTakeChessOutBag) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResTakeChessOutBag) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResTakeChessOutBag(%+v)", *p) +} + +func (p *ResTakeChessOutBag) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResTakeChessOutBag", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResTakeChessOutBag)(nil) + +func (p *ResTakeChessOutBag) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResTakeChessOutBagToHonor struct { + Code RES_CODE `thrift:"code,1" db:"code" json:"code"` + Msg string `thrift:"msg,2" db:"msg" json:"msg"` +} + +func NewResTakeChessOutBagToHonor() *ResTakeChessOutBagToHonor { + return &ResTakeChessOutBagToHonor{} +} + +func (p *ResTakeChessOutBagToHonor) GetCode() RES_CODE { + return p.Code +} + +func (p *ResTakeChessOutBagToHonor) GetMsg() string { + return p.Msg +} + +func (p *ResTakeChessOutBagToHonor) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResTakeChessOutBagToHonor) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResTakeChessOutBagToHonor) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResTakeChessOutBagToHonor) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResTakeChessOutBagToHonor"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResTakeChessOutBagToHonor) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:code: ", p), err) + } + return err +} + +func (p *ResTakeChessOutBagToHonor) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:msg: ", p), err) + } + return err +} + +func (p *ResTakeChessOutBagToHonor) Equals(other *ResTakeChessOutBagToHonor) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResTakeChessOutBagToHonor) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResTakeChessOutBagToHonor(%+v)", *p) +} + +func (p *ResTakeChessOutBagToHonor) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResTakeChessOutBagToHonor", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResTakeChessOutBagToHonor)(nil) + +func (p *ResTakeChessOutBagToHonor) Validate() error { + return nil +} + +// Attributes: +// - ResultCode +// - BindAccountId +// +type ResUnBindFacebook struct { + ResultCode int32 `thrift:"ResultCode,1" db:"ResultCode" json:"ResultCode"` + BindAccountId string `thrift:"BindAccountId,2" db:"BindAccountId" json:"BindAccountId"` +} + +func NewResUnBindFacebook() *ResUnBindFacebook { + return &ResUnBindFacebook{} +} + +func (p *ResUnBindFacebook) GetResultCode() int32 { + return p.ResultCode +} + +func (p *ResUnBindFacebook) GetBindAccountId() string { + return p.BindAccountId +} + +func (p *ResUnBindFacebook) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResUnBindFacebook) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.ResultCode = v + } + return nil +} + +func (p *ResUnBindFacebook) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.BindAccountId = v + } + return nil +} + +func (p *ResUnBindFacebook) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResUnBindFacebook"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResUnBindFacebook) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ResultCode", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ResultCode: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.ResultCode)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.ResultCode (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ResultCode: ", p), err) + } + return err +} + +func (p *ResUnBindFacebook) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "BindAccountId", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:BindAccountId: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.BindAccountId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.BindAccountId (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:BindAccountId: ", p), err) + } + return err +} + +func (p *ResUnBindFacebook) Equals(other *ResUnBindFacebook) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.ResultCode != other.ResultCode { + return false + } + if p.BindAccountId != other.BindAccountId { + return false + } + return true +} + +func (p *ResUnBindFacebook) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResUnBindFacebook(%+v)", *p) +} + +func (p *ResUnBindFacebook) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResUnBindFacebook", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResUnBindFacebook)(nil) + +func (p *ResUnBindFacebook) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResUpdatePlayerChessData struct { + Code RES_CODE `thrift:"code,1" db:"code" json:"code"` + Msg string `thrift:"msg,2" db:"msg" json:"msg"` +} + +func NewResUpdatePlayerChessData() *ResUpdatePlayerChessData { + return &ResUpdatePlayerChessData{} +} + +func (p *ResUpdatePlayerChessData) GetCode() RES_CODE { + return p.Code +} + +func (p *ResUpdatePlayerChessData) GetMsg() string { + return p.Msg +} + +func (p *ResUpdatePlayerChessData) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResUpdatePlayerChessData) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResUpdatePlayerChessData) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResUpdatePlayerChessData) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResUpdatePlayerChessData"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResUpdatePlayerChessData) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:code: ", p), err) + } + return err +} + +func (p *ResUpdatePlayerChessData) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:msg: ", p), err) + } + return err +} + +func (p *ResUpdatePlayerChessData) Equals(other *ResUpdatePlayerChessData) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResUpdatePlayerChessData) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResUpdatePlayerChessData(%+v)", *p) +} + +func (p *ResUpdatePlayerChessData) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResUpdatePlayerChessData", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResUpdatePlayerChessData)(nil) + +func (p *ResUpdatePlayerChessData) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// +type ResUpgradeChess struct { + Code RES_CODE `thrift:"code,1" db:"code" json:"code"` + Msg string `thrift:"msg,2" db:"msg" json:"msg"` +} + +func NewResUpgradeChess() *ResUpgradeChess { + return &ResUpgradeChess{} +} + +func (p *ResUpgradeChess) GetCode() RES_CODE { + return p.Code +} + +func (p *ResUpgradeChess) GetMsg() string { + return p.Msg +} + +func (p *ResUpgradeChess) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResUpgradeChess) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResUpgradeChess) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResUpgradeChess) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResUpgradeChess"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResUpgradeChess) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:code: ", p), err) + } + return err +} + +func (p *ResUpgradeChess) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:msg: ", p), err) + } + return err +} + +func (p *ResUpgradeChess) Equals(other *ResUpgradeChess) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + return true +} + +func (p *ResUpgradeChess) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResUpgradeChess(%+v)", *p) +} + +func (p *ResUpgradeChess) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResUpgradeChess", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResUpgradeChess)(nil) + +func (p *ResUpgradeChess) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Info +// +type ResUserDetail struct { + Code int32 `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Info *ResUserDetailInfo `thrift:"info,3" db:"info" json:"info"` +} + +func NewResUserDetail() *ResUserDetail { + return &ResUserDetail{} +} + +func (p *ResUserDetail) GetCode() int32 { + return p.Code +} + +func (p *ResUserDetail) GetMsg() string { + return p.Msg +} + +var ResUserDetail_Info_DEFAULT *ResUserDetailInfo + +func (p *ResUserDetail) GetInfo() *ResUserDetailInfo { + if !p.IsSetInfo() { + return ResUserDetail_Info_DEFAULT + } + return p.Info +} + +func (p *ResUserDetail) IsSetInfo() bool { + return p.Info != nil +} + +func (p *ResUserDetail) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.STRUCT { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResUserDetail) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Code = v + } + return nil +} + +func (p *ResUserDetail) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResUserDetail) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + p.Info = &ResUserDetailInfo{} + if err := p.Info.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", p.Info), err) + } + return nil +} + +func (p *ResUserDetail) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResUserDetail"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResUserDetail) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResUserDetail) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResUserDetail) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "info", thrift.STRUCT, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:info: ", p), err) + } + if err := p.Info.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", p.Info), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:info: ", p), err) + } + return err +} + +func (p *ResUserDetail) Equals(other *ResUserDetail) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if !p.Info.Equals(other.Info) { + return false + } + return true +} + +func (p *ResUserDetail) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResUserDetail(%+v)", *p) +} + +func (p *ResUserDetail) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResUserDetail", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResUserDetail)(nil) + +func (p *ResUserDetail) Validate() error { + return nil +} + +// Attributes: +// - Name +// - Uid +// - AreaId +// - Face +// - Charge +// - MaxCharge +// - Level +// - Diamond +// - Star +// - Energy +// - Mac +// - Login +// - Cumulative +// - RegisterTime +// - TodayCumulative +// - Ban +// - Bonus +// - Code +// - ChessMap +// - ActLog +// - AdWatch +// - FriendList +// - Order +// +type ResUserDetailInfo struct { + Name string `thrift:"Name,1" db:"Name" json:"Name"` + Uid int64 `thrift:"Uid,2" db:"Uid" json:"Uid"` + AreaId int32 `thrift:"AreaId,3" db:"AreaId" json:"AreaId"` + Face int32 `thrift:"Face,4" db:"Face" json:"Face"` + Charge int32 `thrift:"Charge,5" db:"Charge" json:"Charge"` + MaxCharge int32 `thrift:"MaxCharge,6" db:"MaxCharge" json:"MaxCharge"` + Level int32 `thrift:"Level,7" db:"Level" json:"Level"` + Diamond int64 `thrift:"Diamond,8" db:"Diamond" json:"Diamond"` + Star int32 `thrift:"Star,9" db:"Star" json:"Star"` + Energy int32 `thrift:"Energy,10" db:"Energy" json:"Energy"` + Mac string `thrift:"Mac,11" db:"Mac" json:"Mac"` + Login int64 `thrift:"Login,12" db:"Login" json:"Login"` + Cumulative int64 `thrift:"Cumulative,13" db:"Cumulative" json:"Cumulative"` + RegisterTime int64 `thrift:"RegisterTime,14" db:"RegisterTime" json:"RegisterTime"` + TodayCumulative int64 `thrift:"TodayCumulative,15" db:"TodayCumulative" json:"TodayCumulative"` + Ban bool `thrift:"Ban,16" db:"Ban" json:"Ban"` + Bonus int32 `thrift:"Bonus,17" db:"Bonus" json:"Bonus"` + Code string `thrift:"Code,18" db:"Code" json:"Code"` + ChessMap map[string]int32 `thrift:"ChessMap,19" db:"ChessMap" json:"ChessMap"` + ActLog []*ActLog `thrift:"ActLog,20" db:"ActLog" json:"ActLog"` + AdWatch int32 `thrift:"AdWatch,21" db:"AdWatch" json:"AdWatch"` + FriendList []*UserDetailFriendInfo `thrift:"FriendList,22" db:"FriendList" json:"FriendList"` + Order []*UserDetailOrderInfo `thrift:"Order,23" db:"Order" json:"Order"` +} + +func NewResUserDetailInfo() *ResUserDetailInfo { + return &ResUserDetailInfo{} +} + +func (p *ResUserDetailInfo) GetName() string { + return p.Name +} + +func (p *ResUserDetailInfo) GetUid() int64 { + return p.Uid +} + +func (p *ResUserDetailInfo) GetAreaId() int32 { + return p.AreaId +} + +func (p *ResUserDetailInfo) GetFace() int32 { + return p.Face +} + +func (p *ResUserDetailInfo) GetCharge() int32 { + return p.Charge +} + +func (p *ResUserDetailInfo) GetMaxCharge() int32 { + return p.MaxCharge +} + +func (p *ResUserDetailInfo) GetLevel() int32 { + return p.Level +} + +func (p *ResUserDetailInfo) GetDiamond() int64 { + return p.Diamond +} + +func (p *ResUserDetailInfo) GetStar() int32 { + return p.Star +} + +func (p *ResUserDetailInfo) GetEnergy() int32 { + return p.Energy +} + +func (p *ResUserDetailInfo) GetMac() string { + return p.Mac +} + +func (p *ResUserDetailInfo) GetLogin() int64 { + return p.Login +} + +func (p *ResUserDetailInfo) GetCumulative() int64 { + return p.Cumulative +} + +func (p *ResUserDetailInfo) GetRegisterTime() int64 { + return p.RegisterTime +} + +func (p *ResUserDetailInfo) GetTodayCumulative() int64 { + return p.TodayCumulative +} + +func (p *ResUserDetailInfo) GetBan() bool { + return p.Ban +} + +func (p *ResUserDetailInfo) GetBonus() int32 { + return p.Bonus +} + +func (p *ResUserDetailInfo) GetCode() string { + return p.Code +} + +func (p *ResUserDetailInfo) GetChessMap() map[string]int32 { + return p.ChessMap +} + +func (p *ResUserDetailInfo) GetActLog() []*ActLog { + return p.ActLog +} + +func (p *ResUserDetailInfo) GetAdWatch() int32 { + return p.AdWatch +} + +func (p *ResUserDetailInfo) GetFriendList() []*UserDetailFriendInfo { + return p.FriendList +} + +func (p *ResUserDetailInfo) GetOrder() []*UserDetailOrderInfo { + return p.Order +} + +func (p *ResUserDetailInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I64 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.I32 { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.I32 { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 8: + if fieldTypeId == thrift.I64 { + if err := p.ReadField8(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 9: + if fieldTypeId == thrift.I32 { + if err := p.ReadField9(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 10: + if fieldTypeId == thrift.I32 { + if err := p.ReadField10(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 11: + if fieldTypeId == thrift.STRING { + if err := p.ReadField11(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 12: + if fieldTypeId == thrift.I64 { + if err := p.ReadField12(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 13: + if fieldTypeId == thrift.I64 { + if err := p.ReadField13(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 14: + if fieldTypeId == thrift.I64 { + if err := p.ReadField14(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 15: + if fieldTypeId == thrift.I64 { + if err := p.ReadField15(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 16: + if fieldTypeId == thrift.BOOL { + if err := p.ReadField16(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 17: + if fieldTypeId == thrift.I32 { + if err := p.ReadField17(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 18: + if fieldTypeId == thrift.STRING { + if err := p.ReadField18(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 19: + if fieldTypeId == thrift.MAP { + if err := p.ReadField19(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 20: + if fieldTypeId == thrift.LIST { + if err := p.ReadField20(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 21: + if fieldTypeId == thrift.I32 { + if err := p.ReadField21(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 22: + if fieldTypeId == thrift.LIST { + if err := p.ReadField22(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 23: + if fieldTypeId == thrift.LIST { + if err := p.ReadField23(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResUserDetailInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Name = v + } + return nil +} + +func (p *ResUserDetailInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ResUserDetailInfo) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.AreaId = v + } + return nil +} + +func (p *ResUserDetailInfo) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Face = v + } + return nil +} + +func (p *ResUserDetailInfo) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.Charge = v + } + return nil +} + +func (p *ResUserDetailInfo) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 6: ", err) + } else { + p.MaxCharge = v + } + return nil +} + +func (p *ResUserDetailInfo) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 7: ", err) + } else { + p.Level = v + } + return nil +} + +func (p *ResUserDetailInfo) ReadField8(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 8: ", err) + } else { + p.Diamond = v + } + return nil +} + +func (p *ResUserDetailInfo) ReadField9(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 9: ", err) + } else { + p.Star = v + } + return nil +} + +func (p *ResUserDetailInfo) ReadField10(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 10: ", err) + } else { + p.Energy = v + } + return nil +} + +func (p *ResUserDetailInfo) ReadField11(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 11: ", err) + } else { + p.Mac = v + } + return nil +} + +func (p *ResUserDetailInfo) ReadField12(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 12: ", err) + } else { + p.Login = v + } + return nil +} + +func (p *ResUserDetailInfo) ReadField13(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 13: ", err) + } else { + p.Cumulative = v + } + return nil +} + +func (p *ResUserDetailInfo) ReadField14(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 14: ", err) + } else { + p.RegisterTime = v + } + return nil +} + +func (p *ResUserDetailInfo) ReadField15(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 15: ", err) + } else { + p.TodayCumulative = v + } + return nil +} + +func (p *ResUserDetailInfo) ReadField16(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadBool(ctx); err != nil { + return thrift.PrependError("error reading field 16: ", err) + } else { + p.Ban = v + } + return nil +} + +func (p *ResUserDetailInfo) ReadField17(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 17: ", err) + } else { + p.Bonus = v + } + return nil +} + +func (p *ResUserDetailInfo) ReadField18(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 18: ", err) + } else { + p.Code = v + } + return nil +} + +func (p *ResUserDetailInfo) ReadField19(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[string]int32, size) + p.ChessMap = tMap + for i := 0; i < size; i++ { + var _key432 string + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key432 = v + } + var _val433 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val433 = v + } + p.ChessMap[_key432] = _val433 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *ResUserDetailInfo) ReadField20(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ActLog, 0, size) + p.ActLog = tSlice + for i := 0; i < size; i++ { + _elem434 := &ActLog{} + if err := _elem434.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem434), err) + } + p.ActLog = append(p.ActLog, _elem434) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResUserDetailInfo) ReadField21(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 21: ", err) + } else { + p.AdWatch = v + } + return nil +} + +func (p *ResUserDetailInfo) ReadField22(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*UserDetailFriendInfo, 0, size) + p.FriendList = tSlice + for i := 0; i < size; i++ { + _elem435 := &UserDetailFriendInfo{} + if err := _elem435.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem435), err) + } + p.FriendList = append(p.FriendList, _elem435) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResUserDetailInfo) ReadField23(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*UserDetailOrderInfo, 0, size) + p.Order = tSlice + for i := 0; i < size; i++ { + _elem436 := &UserDetailOrderInfo{} + if err := _elem436.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem436), err) + } + p.Order = append(p.Order, _elem436) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResUserDetailInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResUserDetailInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + if err := p.writeField8(ctx, oprot); err != nil { + return err + } + if err := p.writeField9(ctx, oprot); err != nil { + return err + } + if err := p.writeField10(ctx, oprot); err != nil { + return err + } + if err := p.writeField11(ctx, oprot); err != nil { + return err + } + if err := p.writeField12(ctx, oprot); err != nil { + return err + } + if err := p.writeField13(ctx, oprot); err != nil { + return err + } + if err := p.writeField14(ctx, oprot); err != nil { + return err + } + if err := p.writeField15(ctx, oprot); err != nil { + return err + } + if err := p.writeField16(ctx, oprot); err != nil { + return err + } + if err := p.writeField17(ctx, oprot); err != nil { + return err + } + if err := p.writeField18(ctx, oprot); err != nil { + return err + } + if err := p.writeField19(ctx, oprot); err != nil { + return err + } + if err := p.writeField20(ctx, oprot); err != nil { + return err + } + if err := p.writeField21(ctx, oprot); err != nil { + return err + } + if err := p.writeField22(ctx, oprot); err != nil { + return err + } + if err := p.writeField23(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResUserDetailInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Name", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Name: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Name)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Name (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Name: ", p), err) + } + return err +} + +func (p *ResUserDetailInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Uid: ", p), err) + } + return err +} + +func (p *ResUserDetailInfo) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "AreaId", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:AreaId: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.AreaId)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.AreaId (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:AreaId: ", p), err) + } + return err +} + +func (p *ResUserDetailInfo) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Face", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Face: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Face)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Face (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Face: ", p), err) + } + return err +} + +func (p *ResUserDetailInfo) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Charge", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Charge: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Charge)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Charge (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Charge: ", p), err) + } + return err +} + +func (p *ResUserDetailInfo) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MaxCharge", thrift.I32, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:MaxCharge: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.MaxCharge)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.MaxCharge (6) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:MaxCharge: ", p), err) + } + return err +} + +func (p *ResUserDetailInfo) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Level", thrift.I32, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:Level: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Level)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Level (7) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:Level: ", p), err) + } + return err +} + +func (p *ResUserDetailInfo) writeField8(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Diamond", thrift.I64, 8); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 8:Diamond: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Diamond)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Diamond (8) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 8:Diamond: ", p), err) + } + return err +} + +func (p *ResUserDetailInfo) writeField9(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Star", thrift.I32, 9); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 9:Star: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Star)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Star (9) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 9:Star: ", p), err) + } + return err +} + +func (p *ResUserDetailInfo) writeField10(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Energy", thrift.I32, 10); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 10:Energy: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Energy)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Energy (10) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 10:Energy: ", p), err) + } + return err +} + +func (p *ResUserDetailInfo) writeField11(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Mac", thrift.STRING, 11); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 11:Mac: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Mac)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Mac (11) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 11:Mac: ", p), err) + } + return err +} + +func (p *ResUserDetailInfo) writeField12(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Login", thrift.I64, 12); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 12:Login: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Login)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Login (12) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 12:Login: ", p), err) + } + return err +} + +func (p *ResUserDetailInfo) writeField13(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Cumulative", thrift.I64, 13); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 13:Cumulative: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Cumulative)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Cumulative (13) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 13:Cumulative: ", p), err) + } + return err +} + +func (p *ResUserDetailInfo) writeField14(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "RegisterTime", thrift.I64, 14); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 14:RegisterTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.RegisterTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.RegisterTime (14) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 14:RegisterTime: ", p), err) + } + return err +} + +func (p *ResUserDetailInfo) writeField15(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "TodayCumulative", thrift.I64, 15); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 15:TodayCumulative: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.TodayCumulative)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.TodayCumulative (15) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 15:TodayCumulative: ", p), err) + } + return err +} + +func (p *ResUserDetailInfo) writeField16(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Ban", thrift.BOOL, 16); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 16:Ban: ", p), err) + } + if err := oprot.WriteBool(ctx, bool(p.Ban)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Ban (16) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 16:Ban: ", p), err) + } + return err +} + +func (p *ResUserDetailInfo) writeField17(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Bonus", thrift.I32, 17); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 17:Bonus: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Bonus)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Bonus (17) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 17:Bonus: ", p), err) + } + return err +} + +func (p *ResUserDetailInfo) writeField18(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.STRING, 18); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 18:Code: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (18) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 18:Code: ", p), err) + } + return err +} + +func (p *ResUserDetailInfo) writeField19(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChessMap", thrift.MAP, 19); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 19:ChessMap: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.STRING, thrift.I32, len(p.ChessMap)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.ChessMap { + if err := oprot.WriteString(ctx, string(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 19:ChessMap: ", p), err) + } + return err +} + +func (p *ResUserDetailInfo) writeField20(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ActLog", thrift.LIST, 20); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 20:ActLog: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.ActLog)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.ActLog { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 20:ActLog: ", p), err) + } + return err +} + +func (p *ResUserDetailInfo) writeField21(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "AdWatch", thrift.I32, 21); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 21:AdWatch: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.AdWatch)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.AdWatch (21) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 21:AdWatch: ", p), err) + } + return err +} + +func (p *ResUserDetailInfo) writeField22(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "FriendList", thrift.LIST, 22); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 22:FriendList: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.FriendList)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.FriendList { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 22:FriendList: ", p), err) + } + return err +} + +func (p *ResUserDetailInfo) writeField23(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Order", thrift.LIST, 23); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 23:Order: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Order)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Order { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 23:Order: ", p), err) + } + return err +} + +func (p *ResUserDetailInfo) Equals(other *ResUserDetailInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Name != other.Name { + return false + } + if p.Uid != other.Uid { + return false + } + if p.AreaId != other.AreaId { + return false + } + if p.Face != other.Face { + return false + } + if p.Charge != other.Charge { + return false + } + if p.MaxCharge != other.MaxCharge { + return false + } + if p.Level != other.Level { + return false + } + if p.Diamond != other.Diamond { + return false + } + if p.Star != other.Star { + return false + } + if p.Energy != other.Energy { + return false + } + if p.Mac != other.Mac { + return false + } + if p.Login != other.Login { + return false + } + if p.Cumulative != other.Cumulative { + return false + } + if p.RegisterTime != other.RegisterTime { + return false + } + if p.TodayCumulative != other.TodayCumulative { + return false + } + if p.Ban != other.Ban { + return false + } + if p.Bonus != other.Bonus { + return false + } + if p.Code != other.Code { + return false + } + if len(p.ChessMap) != len(other.ChessMap) { + return false + } + for k, _tgt := range p.ChessMap { + _src437 := other.ChessMap[k] + if _tgt != _src437 { + return false + } + } + if len(p.ActLog) != len(other.ActLog) { + return false + } + for i, _tgt := range p.ActLog { + _src438 := other.ActLog[i] + if !_tgt.Equals(_src438) { + return false + } + } + if p.AdWatch != other.AdWatch { + return false + } + if len(p.FriendList) != len(other.FriendList) { + return false + } + for i, _tgt := range p.FriendList { + _src439 := other.FriendList[i] + if !_tgt.Equals(_src439) { + return false + } + } + if len(p.Order) != len(other.Order) { + return false + } + for i, _tgt := range p.Order { + _src440 := other.Order[i] + if !_tgt.Equals(_src440) { + return false + } + } + return true +} + +func (p *ResUserDetailInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResUserDetailInfo(%+v)", *p) +} + +func (p *ResUserDetailInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResUserDetailInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResUserDetailInfo)(nil) + +func (p *ResUserDetailInfo) Validate() error { + return nil +} + +// Attributes: +// - Code +// - Msg +// - Uid +// +type ResWishApply struct { + Code RES_CODE `thrift:"Code,1" db:"Code" json:"Code"` + Msg string `thrift:"Msg,2" db:"Msg" json:"Msg"` + Uid int64 `thrift:"Uid,3" db:"Uid" json:"Uid"` +} + +func NewResWishApply() *ResWishApply { + return &ResWishApply{} +} + +func (p *ResWishApply) GetCode() RES_CODE { + return p.Code +} + +func (p *ResWishApply) GetMsg() string { + return p.Msg +} + +func (p *ResWishApply) GetUid() int64 { + return p.Uid +} + +func (p *ResWishApply) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I64 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResWishApply) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + temp := RES_CODE(v) + p.Code = temp + } + return nil +} + +func (p *ResWishApply) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Msg = v + } + return nil +} + +func (p *ResWishApply) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *ResWishApply) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResWishApply"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResWishApply) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Code", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Code: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Code)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Code (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Code: ", p), err) + } + return err +} + +func (p *ResWishApply) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Msg", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Msg: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Msg)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Msg (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Msg: ", p), err) + } + return err +} + +func (p *ResWishApply) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Uid: ", p), err) + } + return err +} + +func (p *ResWishApply) Equals(other *ResWishApply) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Code != other.Code { + return false + } + if p.Msg != other.Msg { + return false + } + if p.Uid != other.Uid { + return false + } + return true +} + +func (p *ResWishApply) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResWishApply(%+v)", *p) +} + +func (p *ResWishApply) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResWishApply", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResWishApply)(nil) + +func (p *ResWishApply) Validate() error { + return nil +} + +// Attributes: +// - ApplyList +// +type ResWishApplyList struct { + ApplyList []*ResFriendApplyInfo `thrift:"ApplyList,1" db:"ApplyList" json:"ApplyList"` +} + +func NewResWishApplyList() *ResWishApplyList { + return &ResWishApplyList{} +} + +func (p *ResWishApplyList) GetApplyList() []*ResFriendApplyInfo { + return p.ApplyList +} + +func (p *ResWishApplyList) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *ResWishApplyList) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ResFriendApplyInfo, 0, size) + p.ApplyList = tSlice + for i := 0; i < size; i++ { + _elem441 := &ResFriendApplyInfo{} + if err := _elem441.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem441), err) + } + p.ApplyList = append(p.ApplyList, _elem441) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *ResWishApplyList) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "ResWishApplyList"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *ResWishApplyList) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ApplyList", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:ApplyList: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.ApplyList)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.ApplyList { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:ApplyList: ", p), err) + } + return err +} + +func (p *ResWishApplyList) Equals(other *ResWishApplyList) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.ApplyList) != len(other.ApplyList) { + return false + } + for i, _tgt := range p.ApplyList { + _src442 := other.ApplyList[i] + if !_tgt.Equals(_src442) { + return false + } + } + return true +} + +func (p *ResWishApplyList) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("ResWishApplyList(%+v)", *p) +} + +func (p *ResWishApplyList) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.ResWishApplyList", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*ResWishApplyList)(nil) + +func (p *ResWishApplyList) Validate() error { + return nil +} + +// Attributes: +// - Uid +// - Name +// - Face +// - Avatar +// - LastTime +// +type RoomOpponent struct { + Uid int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` + Name string `thrift:"Name,2" db:"Name" json:"Name"` + Face int32 `thrift:"Face,3" db:"Face" json:"Face"` + Avatar int32 `thrift:"Avatar,4" db:"Avatar" json:"Avatar"` + LastTime int32 `thrift:"LastTime,5" db:"LastTime" json:"LastTime"` +} + +func NewRoomOpponent() *RoomOpponent { + return &RoomOpponent{} +} + +func (p *RoomOpponent) GetUid() int64 { + return p.Uid +} + +func (p *RoomOpponent) GetName() string { + return p.Name +} + +func (p *RoomOpponent) GetFace() int32 { + return p.Face +} + +func (p *RoomOpponent) GetAvatar() int32 { + return p.Avatar +} + +func (p *RoomOpponent) GetLastTime() int32 { + return p.LastTime +} + +func (p *RoomOpponent) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *RoomOpponent) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *RoomOpponent) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Name = v + } + return nil +} + +func (p *RoomOpponent) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Face = v + } + return nil +} + +func (p *RoomOpponent) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Avatar = v + } + return nil +} + +func (p *RoomOpponent) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.LastTime = v + } + return nil +} + +func (p *RoomOpponent) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "RoomOpponent"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *RoomOpponent) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *RoomOpponent) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Name", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Name: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Name)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Name (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Name: ", p), err) + } + return err +} + +func (p *RoomOpponent) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Face", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Face: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Face)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Face (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Face: ", p), err) + } + return err +} + +func (p *RoomOpponent) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Avatar", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Avatar: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Avatar)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Avatar (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Avatar: ", p), err) + } + return err +} + +func (p *RoomOpponent) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "LastTime", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:LastTime: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.LastTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.LastTime (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:LastTime: ", p), err) + } + return err +} + +func (p *RoomOpponent) Equals(other *RoomOpponent) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Uid != other.Uid { + return false + } + if p.Name != other.Name { + return false + } + if p.Face != other.Face { + return false + } + if p.Avatar != other.Avatar { + return false + } + if p.LastTime != other.LastTime { + return false + } + return true +} + +func (p *RoomOpponent) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("RoomOpponent(%+v)", *p) +} + +func (p *RoomOpponent) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.RoomOpponent", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*RoomOpponent)(nil) + +func (p *RoomOpponent) Validate() error { + return nil +} + +// Attributes: +// - Item1 +// - Item2 +// - Item3 +// - Status +// - Id +// - NeedActive +// +type SevenLoginReward struct { + Item1 []*ItemInfo `thrift:"Item1,1" db:"Item1" json:"Item1"` + Item2 []*ItemInfo `thrift:"Item2,2" db:"Item2" json:"Item2"` + Item3 []*ItemInfo `thrift:"Item3,3" db:"Item3" json:"Item3"` + Status int32 `thrift:"Status,4" db:"Status" json:"Status"` + Id int32 `thrift:"Id,5" db:"Id" json:"Id"` + NeedActive int32 `thrift:"NeedActive,6" db:"NeedActive" json:"NeedActive"` +} + +func NewSevenLoginReward() *SevenLoginReward { + return &SevenLoginReward{} +} + +func (p *SevenLoginReward) GetItem1() []*ItemInfo { + return p.Item1 +} + +func (p *SevenLoginReward) GetItem2() []*ItemInfo { + return p.Item2 +} + +func (p *SevenLoginReward) GetItem3() []*ItemInfo { + return p.Item3 +} + +func (p *SevenLoginReward) GetStatus() int32 { + return p.Status +} + +func (p *SevenLoginReward) GetId() int32 { + return p.Id +} + +func (p *SevenLoginReward) GetNeedActive() int32 { + return p.NeedActive +} + +func (p *SevenLoginReward) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.LIST { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.LIST { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.LIST { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.I32 { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *SevenLoginReward) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ItemInfo, 0, size) + p.Item1 = tSlice + for i := 0; i < size; i++ { + _elem443 := &ItemInfo{} + if err := _elem443.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem443), err) + } + p.Item1 = append(p.Item1, _elem443) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *SevenLoginReward) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ItemInfo, 0, size) + p.Item2 = tSlice + for i := 0; i < size; i++ { + _elem444 := &ItemInfo{} + if err := _elem444.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem444), err) + } + p.Item2 = append(p.Item2, _elem444) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *SevenLoginReward) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ItemInfo, 0, size) + p.Item3 = tSlice + for i := 0; i < size; i++ { + _elem445 := &ItemInfo{} + if err := _elem445.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem445), err) + } + p.Item3 = append(p.Item3, _elem445) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *SevenLoginReward) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Status = v + } + return nil +} + +func (p *SevenLoginReward) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *SevenLoginReward) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 6: ", err) + } else { + p.NeedActive = v + } + return nil +} + +func (p *SevenLoginReward) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "SevenLoginReward"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *SevenLoginReward) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Item1", thrift.LIST, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Item1: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Item1)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Item1 { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Item1: ", p), err) + } + return err +} + +func (p *SevenLoginReward) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Item2", thrift.LIST, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Item2: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Item2)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Item2 { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Item2: ", p), err) + } + return err +} + +func (p *SevenLoginReward) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Item3", thrift.LIST, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Item3: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Item3)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Item3 { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Item3: ", p), err) + } + return err +} + +func (p *SevenLoginReward) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Status", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Status: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Status)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Status (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Status: ", p), err) + } + return err +} + +func (p *SevenLoginReward) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Id: ", p), err) + } + return err +} + +func (p *SevenLoginReward) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "NeedActive", thrift.I32, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:NeedActive: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.NeedActive)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.NeedActive (6) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:NeedActive: ", p), err) + } + return err +} + +func (p *SevenLoginReward) Equals(other *SevenLoginReward) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if len(p.Item1) != len(other.Item1) { + return false + } + for i, _tgt := range p.Item1 { + _src446 := other.Item1[i] + if !_tgt.Equals(_src446) { + return false + } + } + if len(p.Item2) != len(other.Item2) { + return false + } + for i, _tgt := range p.Item2 { + _src447 := other.Item2[i] + if !_tgt.Equals(_src447) { + return false + } + } + if len(p.Item3) != len(other.Item3) { + return false + } + for i, _tgt := range p.Item3 { + _src448 := other.Item3[i] + if !_tgt.Equals(_src448) { + return false + } + } + if p.Status != other.Status { + return false + } + if p.Id != other.Id { + return false + } + if p.NeedActive != other.NeedActive { + return false + } + return true +} + +func (p *SevenLoginReward) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("SevenLoginReward(%+v)", *p) +} + +func (p *SevenLoginReward) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.SevenLoginReward", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*SevenLoginReward)(nil) + +func (p *SevenLoginReward) Validate() error { + return nil +} + +// Attributes: +// - Pos +// - Type +// - Face +// - Avatar +// - Uid +// - Status +// - NickName +// +type TreasureInfo struct { + Pos int32 `thrift:"Pos,1" db:"Pos" json:"Pos"` + Type int32 `thrift:"Type,2" db:"Type" json:"Type"` + Face int32 `thrift:"Face,3" db:"Face" json:"Face"` + Avatar int32 `thrift:"Avatar,4" db:"Avatar" json:"Avatar"` + Uid int64 `thrift:"Uid,5" db:"Uid" json:"Uid"` + Status int32 `thrift:"Status,6" db:"Status" json:"Status"` + NickName string `thrift:"NickName,7" db:"NickName" json:"NickName"` +} + +func NewTreasureInfo() *TreasureInfo { + return &TreasureInfo{} +} + +func (p *TreasureInfo) GetPos() int32 { + return p.Pos +} + +func (p *TreasureInfo) GetType() int32 { + return p.Type +} + +func (p *TreasureInfo) GetFace() int32 { + return p.Face +} + +func (p *TreasureInfo) GetAvatar() int32 { + return p.Avatar +} + +func (p *TreasureInfo) GetUid() int64 { + return p.Uid +} + +func (p *TreasureInfo) GetStatus() int32 { + return p.Status +} + +func (p *TreasureInfo) GetNickName() string { + return p.NickName +} + +func (p *TreasureInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I64 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.I32 { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.STRING { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *TreasureInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Pos = v + } + return nil +} + +func (p *TreasureInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *TreasureInfo) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Face = v + } + return nil +} + +func (p *TreasureInfo) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Avatar = v + } + return nil +} + +func (p *TreasureInfo) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *TreasureInfo) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 6: ", err) + } else { + p.Status = v + } + return nil +} + +func (p *TreasureInfo) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 7: ", err) + } else { + p.NickName = v + } + return nil +} + +func (p *TreasureInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "TreasureInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *TreasureInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Pos", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Pos: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Pos)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Pos (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Pos: ", p), err) + } + return err +} + +func (p *TreasureInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Type: ", p), err) + } + return err +} + +func (p *TreasureInfo) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Face", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Face: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Face)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Face (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Face: ", p), err) + } + return err +} + +func (p *TreasureInfo) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Avatar", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Avatar: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Avatar)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Avatar (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Avatar: ", p), err) + } + return err +} + +func (p *TreasureInfo) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Uid: ", p), err) + } + return err +} + +func (p *TreasureInfo) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Status", thrift.I32, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:Status: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Status)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Status (6) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:Status: ", p), err) + } + return err +} + +func (p *TreasureInfo) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "NickName", thrift.STRING, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:NickName: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.NickName)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.NickName (7) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:NickName: ", p), err) + } + return err +} + +func (p *TreasureInfo) Equals(other *TreasureInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Pos != other.Pos { + return false + } + if p.Type != other.Type { + return false + } + if p.Face != other.Face { + return false + } + if p.Avatar != other.Avatar { + return false + } + if p.Uid != other.Uid { + return false + } + if p.Status != other.Status { + return false + } + if p.NickName != other.NickName { + return false + } + return true +} + +func (p *TreasureInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("TreasureInfo(%+v)", *p) +} + +func (p *TreasureInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.TreasureInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*TreasureInfo)(nil) + +func (p *TreasureInfo) Validate() error { + return nil +} + +// Attributes: +// - DwUin +// - MUpdateItem +// +type UpdateBaseItemInfo struct { + DwUin int64 `thrift:"dwUin,1" db:"dwUin" json:"dwUin"` + MUpdateItem map[int32]int32 `thrift:"MUpdateItem,2" db:"MUpdateItem" json:"MUpdateItem"` +} + +func NewUpdateBaseItemInfo() *UpdateBaseItemInfo { + return &UpdateBaseItemInfo{} +} + +func (p *UpdateBaseItemInfo) GetDwUin() int64 { + return p.DwUin +} + +func (p *UpdateBaseItemInfo) GetMUpdateItem() map[int32]int32 { + return p.MUpdateItem +} + +func (p *UpdateBaseItemInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.MAP { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *UpdateBaseItemInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.DwUin = v + } + return nil +} + +func (p *UpdateBaseItemInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.MUpdateItem = tMap + for i := 0; i < size; i++ { + var _key449 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key449 = v + } + var _val450 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val450 = v + } + p.MUpdateItem[_key449] = _val450 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *UpdateBaseItemInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "UpdateBaseItemInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *UpdateBaseItemInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "dwUin", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:dwUin: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.DwUin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.dwUin (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:dwUin: ", p), err) + } + return err +} + +func (p *UpdateBaseItemInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MUpdateItem", thrift.MAP, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:MUpdateItem: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.MUpdateItem)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.MUpdateItem { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:MUpdateItem: ", p), err) + } + return err +} + +func (p *UpdateBaseItemInfo) Equals(other *UpdateBaseItemInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.DwUin != other.DwUin { + return false + } + if len(p.MUpdateItem) != len(other.MUpdateItem) { + return false + } + for k, _tgt := range p.MUpdateItem { + _src451 := other.MUpdateItem[k] + if _tgt != _src451 { + return false + } + } + return true +} + +func (p *UpdateBaseItemInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("UpdateBaseItemInfo(%+v)", *p) +} + +func (p *UpdateBaseItemInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.UpdateBaseItemInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*UpdateBaseItemInfo)(nil) + +func (p *UpdateBaseItemInfo) Validate() error { + return nil +} + +// Attributes: +// - DwUin +// - MChessData +// - MChessHandle +// +type UpdatePlayerChessData struct { + DwUin int64 `thrift:"dwUin,1" db:"dwUin" json:"dwUin"` + MChessData map[string]int32 `thrift:"MChessData,2" db:"MChessData" json:"MChessData"` + MChessHandle []*ChessHandle `thrift:"mChessHandle,3" db:"mChessHandle" json:"mChessHandle"` +} + +func NewUpdatePlayerChessData() *UpdatePlayerChessData { + return &UpdatePlayerChessData{} +} + +func (p *UpdatePlayerChessData) GetDwUin() int64 { + return p.DwUin +} + +func (p *UpdatePlayerChessData) GetMChessData() map[string]int32 { + return p.MChessData +} + +func (p *UpdatePlayerChessData) GetMChessHandle() []*ChessHandle { + return p.MChessHandle +} + +func (p *UpdatePlayerChessData) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.MAP { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.LIST { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *UpdatePlayerChessData) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.DwUin = v + } + return nil +} + +func (p *UpdatePlayerChessData) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[string]int32, size) + p.MChessData = tMap + for i := 0; i < size; i++ { + var _key452 string + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key452 = v + } + var _val453 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val453 = v + } + p.MChessData[_key452] = _val453 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *UpdatePlayerChessData) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*ChessHandle, 0, size) + p.MChessHandle = tSlice + for i := 0; i < size; i++ { + _elem454 := &ChessHandle{} + if err := _elem454.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem454), err) + } + p.MChessHandle = append(p.MChessHandle, _elem454) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *UpdatePlayerChessData) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "UpdatePlayerChessData"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *UpdatePlayerChessData) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "dwUin", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:dwUin: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.DwUin)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.dwUin (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:dwUin: ", p), err) + } + return err +} + +func (p *UpdatePlayerChessData) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "MChessData", thrift.MAP, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:MChessData: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.STRING, thrift.I32, len(p.MChessData)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.MChessData { + if err := oprot.WriteString(ctx, string(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:MChessData: ", p), err) + } + return err +} + +func (p *UpdatePlayerChessData) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "mChessHandle", thrift.LIST, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:mChessHandle: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.MChessHandle)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.MChessHandle { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:mChessHandle: ", p), err) + } + return err +} + +func (p *UpdatePlayerChessData) Equals(other *UpdatePlayerChessData) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.DwUin != other.DwUin { + return false + } + if len(p.MChessData) != len(other.MChessData) { + return false + } + for k, _tgt := range p.MChessData { + _src455 := other.MChessData[k] + if _tgt != _src455 { + return false + } + } + if len(p.MChessHandle) != len(other.MChessHandle) { + return false + } + for i, _tgt := range p.MChessHandle { + _src456 := other.MChessHandle[i] + if !_tgt.Equals(_src456) { + return false + } + } + return true +} + +func (p *UpdatePlayerChessData) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("UpdatePlayerChessData(%+v)", *p) +} + +func (p *UpdatePlayerChessData) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.UpdatePlayerChessData", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*UpdatePlayerChessData)(nil) + +func (p *UpdatePlayerChessData) Validate() error { + return nil +} + +// Attributes: +// - Uid +// - NickName +// - Avatar +// - Level +// - LogoutTime +// - LoginTime +// - AvatarUrl +// - OnlineStatus +// +type UserDetailFriendInfo struct { + Uid int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` + NickName string `thrift:"NickName,2" db:"NickName" json:"NickName"` + Avatar int32 `thrift:"Avatar,3" db:"Avatar" json:"Avatar"` + Level int32 `thrift:"Level,4" db:"Level" json:"Level"` + LogoutTime int64 `thrift:"LogoutTime,5" db:"LogoutTime" json:"LogoutTime"` + LoginTime int64 `thrift:"LoginTime,6" db:"LoginTime" json:"LoginTime"` + AvatarUrl string `thrift:"AvatarUrl,7" db:"AvatarUrl" json:"AvatarUrl"` + OnlineStatus bool `thrift:"OnlineStatus,8" db:"OnlineStatus" json:"OnlineStatus"` +} + +func NewUserDetailFriendInfo() *UserDetailFriendInfo { + return &UserDetailFriendInfo{} +} + +func (p *UserDetailFriendInfo) GetUid() int64 { + return p.Uid +} + +func (p *UserDetailFriendInfo) GetNickName() string { + return p.NickName +} + +func (p *UserDetailFriendInfo) GetAvatar() int32 { + return p.Avatar +} + +func (p *UserDetailFriendInfo) GetLevel() int32 { + return p.Level +} + +func (p *UserDetailFriendInfo) GetLogoutTime() int64 { + return p.LogoutTime +} + +func (p *UserDetailFriendInfo) GetLoginTime() int64 { + return p.LoginTime +} + +func (p *UserDetailFriendInfo) GetAvatarUrl() string { + return p.AvatarUrl +} + +func (p *UserDetailFriendInfo) GetOnlineStatus() bool { + return p.OnlineStatus +} + +func (p *UserDetailFriendInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I64 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.I64 { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.STRING { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 8: + if fieldTypeId == thrift.BOOL { + if err := p.ReadField8(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *UserDetailFriendInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *UserDetailFriendInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.NickName = v + } + return nil +} + +func (p *UserDetailFriendInfo) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Avatar = v + } + return nil +} + +func (p *UserDetailFriendInfo) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Level = v + } + return nil +} + +func (p *UserDetailFriendInfo) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.LogoutTime = v + } + return nil +} + +func (p *UserDetailFriendInfo) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 6: ", err) + } else { + p.LoginTime = v + } + return nil +} + +func (p *UserDetailFriendInfo) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 7: ", err) + } else { + p.AvatarUrl = v + } + return nil +} + +func (p *UserDetailFriendInfo) ReadField8(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadBool(ctx); err != nil { + return thrift.PrependError("error reading field 8: ", err) + } else { + p.OnlineStatus = v + } + return nil +} + +func (p *UserDetailFriendInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "UserDetailFriendInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + if err := p.writeField8(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *UserDetailFriendInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *UserDetailFriendInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "NickName", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:NickName: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.NickName)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.NickName (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:NickName: ", p), err) + } + return err +} + +func (p *UserDetailFriendInfo) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Avatar", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Avatar: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Avatar)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Avatar (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Avatar: ", p), err) + } + return err +} + +func (p *UserDetailFriendInfo) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Level", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Level: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Level)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Level (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Level: ", p), err) + } + return err +} + +func (p *UserDetailFriendInfo) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "LogoutTime", thrift.I64, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:LogoutTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.LogoutTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.LogoutTime (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:LogoutTime: ", p), err) + } + return err +} + +func (p *UserDetailFriendInfo) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "LoginTime", thrift.I64, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:LoginTime: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.LoginTime)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.LoginTime (6) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:LoginTime: ", p), err) + } + return err +} + +func (p *UserDetailFriendInfo) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "AvatarUrl", thrift.STRING, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:AvatarUrl: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.AvatarUrl)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.AvatarUrl (7) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:AvatarUrl: ", p), err) + } + return err +} + +func (p *UserDetailFriendInfo) writeField8(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "OnlineStatus", thrift.BOOL, 8); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 8:OnlineStatus: ", p), err) + } + if err := oprot.WriteBool(ctx, bool(p.OnlineStatus)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.OnlineStatus (8) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 8:OnlineStatus: ", p), err) + } + return err +} + +func (p *UserDetailFriendInfo) Equals(other *UserDetailFriendInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Uid != other.Uid { + return false + } + if p.NickName != other.NickName { + return false + } + if p.Avatar != other.Avatar { + return false + } + if p.Level != other.Level { + return false + } + if p.LogoutTime != other.LogoutTime { + return false + } + if p.LoginTime != other.LoginTime { + return false + } + if p.AvatarUrl != other.AvatarUrl { + return false + } + if p.OnlineStatus != other.OnlineStatus { + return false + } + return true +} + +func (p *UserDetailFriendInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("UserDetailFriendInfo(%+v)", *p) +} + +func (p *UserDetailFriendInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.UserDetailFriendInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*UserDetailFriendInfo)(nil) + +func (p *UserDetailFriendInfo) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Type +// - Time +// - Chess +// - Diff +// - ChessId +// +type UserDetailOrderInfo struct { + Id string `thrift:"Id,1" db:"Id" json:"Id"` + Type int32 `thrift:"Type,2" db:"Type" json:"Type"` + Time int64 `thrift:"Time,3" db:"Time" json:"Time"` + Chess []*UserDetailOrderInfoChess `thrift:"Chess,4" db:"Chess" json:"Chess"` + Diff int32 `thrift:"Diff,5" db:"Diff" json:"Diff"` + ChessId []*UserDetailOrderInfoChess `thrift:"ChessId,6" db:"ChessId" json:"ChessId"` +} + +func NewUserDetailOrderInfo() *UserDetailOrderInfo { + return &UserDetailOrderInfo{} +} + +func (p *UserDetailOrderInfo) GetId() string { + return p.Id +} + +func (p *UserDetailOrderInfo) GetType() int32 { + return p.Type +} + +func (p *UserDetailOrderInfo) GetTime() int64 { + return p.Time +} + +func (p *UserDetailOrderInfo) GetChess() []*UserDetailOrderInfoChess { + return p.Chess +} + +func (p *UserDetailOrderInfo) GetDiff() int32 { + return p.Diff +} + +func (p *UserDetailOrderInfo) GetChessId() []*UserDetailOrderInfoChess { + return p.ChessId +} + +func (p *UserDetailOrderInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.STRING { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I64 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.LIST { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.LIST { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *UserDetailOrderInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *UserDetailOrderInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Type = v + } + return nil +} + +func (p *UserDetailOrderInfo) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Time = v + } + return nil +} + +func (p *UserDetailOrderInfo) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*UserDetailOrderInfoChess, 0, size) + p.Chess = tSlice + for i := 0; i < size; i++ { + _elem457 := &UserDetailOrderInfoChess{} + if err := _elem457.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem457), err) + } + p.Chess = append(p.Chess, _elem457) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *UserDetailOrderInfo) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.Diff = v + } + return nil +} + +func (p *UserDetailOrderInfo) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*UserDetailOrderInfoChess, 0, size) + p.ChessId = tSlice + for i := 0; i < size; i++ { + _elem458 := &UserDetailOrderInfoChess{} + if err := _elem458.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem458), err) + } + p.ChessId = append(p.ChessId, _elem458) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *UserDetailOrderInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "UserDetailOrderInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *UserDetailOrderInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.STRING, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *UserDetailOrderInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Type", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Type: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Type)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Type (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Type: ", p), err) + } + return err +} + +func (p *UserDetailOrderInfo) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Time", thrift.I64, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Time: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Time)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Time (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Time: ", p), err) + } + return err +} + +func (p *UserDetailOrderInfo) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Chess", thrift.LIST, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Chess: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.Chess)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Chess { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Chess: ", p), err) + } + return err +} + +func (p *UserDetailOrderInfo) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Diff", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Diff: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Diff)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Diff (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Diff: ", p), err) + } + return err +} + +func (p *UserDetailOrderInfo) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "ChessId", thrift.LIST, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:ChessId: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.ChessId)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.ChessId { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:ChessId: ", p), err) + } + return err +} + +func (p *UserDetailOrderInfo) Equals(other *UserDetailOrderInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Type != other.Type { + return false + } + if p.Time != other.Time { + return false + } + if len(p.Chess) != len(other.Chess) { + return false + } + for i, _tgt := range p.Chess { + _src459 := other.Chess[i] + if !_tgt.Equals(_src459) { + return false + } + } + if p.Diff != other.Diff { + return false + } + if len(p.ChessId) != len(other.ChessId) { + return false + } + for i, _tgt := range p.ChessId { + _src460 := other.ChessId[i] + if !_tgt.Equals(_src460) { + return false + } + } + return true +} + +func (p *UserDetailOrderInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("UserDetailOrderInfo(%+v)", *p) +} + +func (p *UserDetailOrderInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.UserDetailOrderInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*UserDetailOrderInfo)(nil) + +func (p *UserDetailOrderInfo) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Icon +// +type UserDetailOrderInfoChess struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Icon string `thrift:"Icon,2" db:"Icon" json:"Icon"` +} + +func NewUserDetailOrderInfoChess() *UserDetailOrderInfoChess { + return &UserDetailOrderInfoChess{} +} + +func (p *UserDetailOrderInfoChess) GetId() int32 { + return p.Id +} + +func (p *UserDetailOrderInfoChess) GetIcon() string { + return p.Icon +} + +func (p *UserDetailOrderInfoChess) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *UserDetailOrderInfoChess) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *UserDetailOrderInfoChess) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Icon = v + } + return nil +} + +func (p *UserDetailOrderInfoChess) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "UserDetailOrderInfoChess"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *UserDetailOrderInfoChess) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *UserDetailOrderInfoChess) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Icon", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Icon: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Icon)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Icon (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Icon: ", p), err) + } + return err +} + +func (p *UserDetailOrderInfoChess) Equals(other *UserDetailOrderInfoChess) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Icon != other.Icon { + return false + } + return true +} + +func (p *UserDetailOrderInfoChess) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("UserDetailOrderInfoChess(%+v)", *p) +} + +func (p *UserDetailOrderInfoChess) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.UserDetailOrderInfoChess", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*UserDetailOrderInfoChess)(nil) + +func (p *UserDetailOrderInfoChess) Validate() error { + return nil +} + +// Attributes: +// - Uid +// +type UserDetailParam struct { + Uid int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` +} + +func NewUserDetailParam() *UserDetailParam { + return &UserDetailParam{} +} + +func (p *UserDetailParam) GetUid() int64 { + return p.Uid +} + +func (p *UserDetailParam) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *UserDetailParam) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *UserDetailParam) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "UserDetailParam"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *UserDetailParam) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *UserDetailParam) Equals(other *UserDetailParam) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Uid != other.Uid { + return false + } + return true +} + +func (p *UserDetailParam) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("UserDetailParam(%+v)", *p) +} + +func (p *UserDetailParam) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.UserDetailParam", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*UserDetailParam)(nil) + +func (p *UserDetailParam) Validate() error { + return nil +} + +// Attributes: +// - Uid +// - Nickname +// - Avatar +// - Face +// - DecorateCnt +// - AvatarList +// - FaceList +// - Login +// - PetName +// - EmojiList +// - SetEmoji +// - IdNum +// - AddCode +// +type UserInfo struct { + Uid int64 `thrift:"Uid,1" db:"Uid" json:"Uid"` + Nickname string `thrift:"Nickname,2" db:"Nickname" json:"Nickname"` + Avatar int32 `thrift:"Avatar,3" db:"Avatar" json:"Avatar"` + Face int32 `thrift:"Face,4" db:"Face" json:"Face"` + DecorateCnt int32 `thrift:"DecorateCnt,5" db:"DecorateCnt" json:"DecorateCnt"` + AvatarList []*AvatarInfo `thrift:"AvatarList,6" db:"AvatarList" json:"AvatarList"` + FaceList []*FaceInfo `thrift:"FaceList,7" db:"FaceList" json:"FaceList"` + Login int32 `thrift:"Login,8" db:"Login" json:"Login"` + PetName string `thrift:"PetName,9" db:"PetName" json:"PetName"` + EmojiList []*EmojiInfo `thrift:"EmojiList,10" db:"EmojiList" json:"EmojiList"` + SetEmoji map[int32]int32 `thrift:"SetEmoji,11" db:"SetEmoji" json:"SetEmoji"` + IdNum string `thrift:"IdNum,12" db:"IdNum" json:"IdNum"` + AddCode string `thrift:"AddCode,13" db:"AddCode" json:"AddCode"` +} + +func NewUserInfo() *UserInfo { + return &UserInfo{} +} + +func (p *UserInfo) GetUid() int64 { + return p.Uid +} + +func (p *UserInfo) GetNickname() string { + return p.Nickname +} + +func (p *UserInfo) GetAvatar() int32 { + return p.Avatar +} + +func (p *UserInfo) GetFace() int32 { + return p.Face +} + +func (p *UserInfo) GetDecorateCnt() int32 { + return p.DecorateCnt +} + +func (p *UserInfo) GetAvatarList() []*AvatarInfo { + return p.AvatarList +} + +func (p *UserInfo) GetFaceList() []*FaceInfo { + return p.FaceList +} + +func (p *UserInfo) GetLogin() int32 { + return p.Login +} + +func (p *UserInfo) GetPetName() string { + return p.PetName +} + +func (p *UserInfo) GetEmojiList() []*EmojiInfo { + return p.EmojiList +} + +func (p *UserInfo) GetSetEmoji() map[int32]int32 { + return p.SetEmoji +} + +func (p *UserInfo) GetIdNum() string { + return p.IdNum +} + +func (p *UserInfo) GetAddCode() string { + return p.AddCode +} + +func (p *UserInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I64 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 6: + if fieldTypeId == thrift.LIST { + if err := p.ReadField6(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 7: + if fieldTypeId == thrift.LIST { + if err := p.ReadField7(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 8: + if fieldTypeId == thrift.I32 { + if err := p.ReadField8(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 9: + if fieldTypeId == thrift.STRING { + if err := p.ReadField9(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 10: + if fieldTypeId == thrift.LIST { + if err := p.ReadField10(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 11: + if fieldTypeId == thrift.MAP { + if err := p.ReadField11(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 12: + if fieldTypeId == thrift.STRING { + if err := p.ReadField12(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 13: + if fieldTypeId == thrift.STRING { + if err := p.ReadField13(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *UserInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Uid = v + } + return nil +} + +func (p *UserInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Nickname = v + } + return nil +} + +func (p *UserInfo) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Avatar = v + } + return nil +} + +func (p *UserInfo) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Face = v + } + return nil +} + +func (p *UserInfo) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.DecorateCnt = v + } + return nil +} + +func (p *UserInfo) ReadField6(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*AvatarInfo, 0, size) + p.AvatarList = tSlice + for i := 0; i < size; i++ { + _elem461 := &AvatarInfo{} + if err := _elem461.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem461), err) + } + p.AvatarList = append(p.AvatarList, _elem461) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *UserInfo) ReadField7(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*FaceInfo, 0, size) + p.FaceList = tSlice + for i := 0; i < size; i++ { + _elem462 := &FaceInfo{} + if err := _elem462.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem462), err) + } + p.FaceList = append(p.FaceList, _elem462) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *UserInfo) ReadField8(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 8: ", err) + } else { + p.Login = v + } + return nil +} + +func (p *UserInfo) ReadField9(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 9: ", err) + } else { + p.PetName = v + } + return nil +} + +func (p *UserInfo) ReadField10(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]*EmojiInfo, 0, size) + p.EmojiList = tSlice + for i := 0; i < size; i++ { + _elem463 := &EmojiInfo{} + if err := _elem463.Read(ctx, iprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error reading struct: ", _elem463), err) + } + p.EmojiList = append(p.EmojiList, _elem463) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *UserInfo) ReadField11(ctx context.Context, iprot thrift.TProtocol) error { + _, _, size, err := iprot.ReadMapBegin(ctx) + if err != nil { + return thrift.PrependError("error reading map begin: ", err) + } + tMap := make(map[int32]int32, size) + p.SetEmoji = tMap + for i := 0; i < size; i++ { + var _key464 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _key464 = v + } + var _val465 int32 + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _val465 = v + } + p.SetEmoji[_key464] = _val465 + } + if err := iprot.ReadMapEnd(ctx); err != nil { + return thrift.PrependError("error reading map end: ", err) + } + return nil +} + +func (p *UserInfo) ReadField12(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 12: ", err) + } else { + p.IdNum = v + } + return nil +} + +func (p *UserInfo) ReadField13(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 13: ", err) + } else { + p.AddCode = v + } + return nil +} + +func (p *UserInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "UserInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + if err := p.writeField6(ctx, oprot); err != nil { + return err + } + if err := p.writeField7(ctx, oprot); err != nil { + return err + } + if err := p.writeField8(ctx, oprot); err != nil { + return err + } + if err := p.writeField9(ctx, oprot); err != nil { + return err + } + if err := p.writeField10(ctx, oprot); err != nil { + return err + } + if err := p.writeField11(ctx, oprot); err != nil { + return err + } + if err := p.writeField12(ctx, oprot); err != nil { + return err + } + if err := p.writeField13(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *UserInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.I64, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Uid: ", p), err) + } + if err := oprot.WriteI64(ctx, int64(p.Uid)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Uid (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Uid: ", p), err) + } + return err +} + +func (p *UserInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Nickname", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Nickname: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Nickname)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Nickname (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Nickname: ", p), err) + } + return err +} + +func (p *UserInfo) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Avatar", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Avatar: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Avatar)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Avatar (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Avatar: ", p), err) + } + return err +} + +func (p *UserInfo) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Face", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Face: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Face)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Face (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Face: ", p), err) + } + return err +} + +func (p *UserInfo) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "DecorateCnt", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:DecorateCnt: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.DecorateCnt)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.DecorateCnt (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:DecorateCnt: ", p), err) + } + return err +} + +func (p *UserInfo) writeField6(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "AvatarList", thrift.LIST, 6); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 6:AvatarList: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.AvatarList)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.AvatarList { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 6:AvatarList: ", p), err) + } + return err +} + +func (p *UserInfo) writeField7(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "FaceList", thrift.LIST, 7); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 7:FaceList: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.FaceList)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.FaceList { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 7:FaceList: ", p), err) + } + return err +} + +func (p *UserInfo) writeField8(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Login", thrift.I32, 8); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 8:Login: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Login)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Login (8) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 8:Login: ", p), err) + } + return err +} + +func (p *UserInfo) writeField9(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "PetName", thrift.STRING, 9); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 9:PetName: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.PetName)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.PetName (9) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 9:PetName: ", p), err) + } + return err +} + +func (p *UserInfo) writeField10(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "EmojiList", thrift.LIST, 10); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 10:EmojiList: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.STRUCT, len(p.EmojiList)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.EmojiList { + if err := v.Write(ctx, oprot); err != nil { + return thrift.PrependError(fmt.Sprintf("%T error writing struct: ", v), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 10:EmojiList: ", p), err) + } + return err +} + +func (p *UserInfo) writeField11(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "SetEmoji", thrift.MAP, 11); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 11:SetEmoji: ", p), err) + } + if err := oprot.WriteMapBegin(ctx, thrift.I32, thrift.I32, len(p.SetEmoji)); err != nil { + return thrift.PrependError("error writing map begin: ", err) + } + for k, v := range p.SetEmoji { + if err := oprot.WriteI32(ctx, int32(k)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteMapEnd(ctx); err != nil { + return thrift.PrependError("error writing map end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 11:SetEmoji: ", p), err) + } + return err +} + +func (p *UserInfo) writeField12(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "IdNum", thrift.STRING, 12); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 12:IdNum: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.IdNum)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.IdNum (12) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 12:IdNum: ", p), err) + } + return err +} + +func (p *UserInfo) writeField13(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "AddCode", thrift.STRING, 13); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 13:AddCode: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.AddCode)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.AddCode (13) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 13:AddCode: ", p), err) + } + return err +} + +func (p *UserInfo) Equals(other *UserInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Uid != other.Uid { + return false + } + if p.Nickname != other.Nickname { + return false + } + if p.Avatar != other.Avatar { + return false + } + if p.Face != other.Face { + return false + } + if p.DecorateCnt != other.DecorateCnt { + return false + } + if len(p.AvatarList) != len(other.AvatarList) { + return false + } + for i, _tgt := range p.AvatarList { + _src466 := other.AvatarList[i] + if !_tgt.Equals(_src466) { + return false + } + } + if len(p.FaceList) != len(other.FaceList) { + return false + } + for i, _tgt := range p.FaceList { + _src467 := other.FaceList[i] + if !_tgt.Equals(_src467) { + return false + } + } + if p.Login != other.Login { + return false + } + if p.PetName != other.PetName { + return false + } + if len(p.EmojiList) != len(other.EmojiList) { + return false + } + for i, _tgt := range p.EmojiList { + _src468 := other.EmojiList[i] + if !_tgt.Equals(_src468) { + return false + } + } + if len(p.SetEmoji) != len(other.SetEmoji) { + return false + } + for k, _tgt := range p.SetEmoji { + _src469 := other.SetEmoji[k] + if _tgt != _src469 { + return false + } + } + if p.IdNum != other.IdNum { + return false + } + if p.AddCode != other.AddCode { + return false + } + return true +} + +func (p *UserInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("UserInfo(%+v)", *p) +} + +func (p *UserInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.UserInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*UserInfo)(nil) + +func (p *UserInfo) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Count +// - Discount +// +type WeeklyDiscountInfo struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Count int32 `thrift:"Count,2" db:"Count" json:"Count"` + Discount int32 `thrift:"Discount,3" db:"Discount" json:"Discount"` +} + +func NewWeeklyDiscountInfo() *WeeklyDiscountInfo { + return &WeeklyDiscountInfo{} +} + +func (p *WeeklyDiscountInfo) GetId() int32 { + return p.Id +} + +func (p *WeeklyDiscountInfo) GetCount() int32 { + return p.Count +} + +func (p *WeeklyDiscountInfo) GetDiscount() int32 { + return p.Discount +} + +func (p *WeeklyDiscountInfo) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *WeeklyDiscountInfo) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *WeeklyDiscountInfo) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Count = v + } + return nil +} + +func (p *WeeklyDiscountInfo) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Discount = v + } + return nil +} + +func (p *WeeklyDiscountInfo) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "WeeklyDiscountInfo"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *WeeklyDiscountInfo) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *WeeklyDiscountInfo) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Count", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Count: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Count)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Count (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Count: ", p), err) + } + return err +} + +func (p *WeeklyDiscountInfo) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Discount", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Discount: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Discount)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Discount (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Discount: ", p), err) + } + return err +} + +func (p *WeeklyDiscountInfo) Equals(other *WeeklyDiscountInfo) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Count != other.Count { + return false + } + if p.Discount != other.Discount { + return false + } + return true +} + +func (p *WeeklyDiscountInfo) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("WeeklyDiscountInfo(%+v)", *p) +} + +func (p *WeeklyDiscountInfo) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.WeeklyDiscountInfo", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*WeeklyDiscountInfo)(nil) + +func (p *WeeklyDiscountInfo) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Count +// - Uid +// +type WishList struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Count int32 `thrift:"Count,2" db:"Count" json:"Count"` + Uid []int64 `thrift:"Uid,3" db:"Uid" json:"Uid"` +} + +func NewWishList() *WishList { + return &WishList{} +} + +func (p *WishList) GetId() int32 { + return p.Id +} + +func (p *WishList) GetCount() int32 { + return p.Count +} + +func (p *WishList) GetUid() []int64 { + return p.Uid +} + +func (p *WishList) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.LIST { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *WishList) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *WishList) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Count = v + } + return nil +} + +func (p *WishList) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + _, size, err := iprot.ReadListBegin(ctx) + if err != nil { + return thrift.PrependError("error reading list begin: ", err) + } + tSlice := make([]int64, 0, size) + p.Uid = tSlice + for i := 0; i < size; i++ { + var _elem470 int64 + if v, err := iprot.ReadI64(ctx); err != nil { + return thrift.PrependError("error reading field 0: ", err) + } else { + _elem470 = v + } + p.Uid = append(p.Uid, _elem470) + } + if err := iprot.ReadListEnd(ctx); err != nil { + return thrift.PrependError("error reading list end: ", err) + } + return nil +} + +func (p *WishList) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "WishList"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *WishList) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *WishList) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Count", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Count: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Count)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Count (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Count: ", p), err) + } + return err +} + +func (p *WishList) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Uid", thrift.LIST, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Uid: ", p), err) + } + if err := oprot.WriteListBegin(ctx, thrift.I64, len(p.Uid)); err != nil { + return thrift.PrependError("error writing list begin: ", err) + } + for _, v := range p.Uid { + if err := oprot.WriteI64(ctx, int64(v)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T. (0) field write error: ", p), err) + } + } + if err := oprot.WriteListEnd(ctx); err != nil { + return thrift.PrependError("error writing list end: ", err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Uid: ", p), err) + } + return err +} + +func (p *WishList) Equals(other *WishList) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Count != other.Count { + return false + } + if len(p.Uid) != len(other.Uid) { + return false + } + for i, _tgt := range p.Uid { + _src471 := other.Uid[i] + if _tgt != _src471 { + return false + } + } + return true +} + +func (p *WishList) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("WishList(%+v)", *p) +} + +func (p *WishList) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.WishList", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*WishList)(nil) + +func (p *WishList) Validate() error { + return nil +} + +// Attributes: +// - Name +// - Face +// - Avatar +// - Progress +// +type Opponent struct { + // unused field # 1 + Name string `thrift:"Name,2" db:"Name" json:"Name"` + Face int32 `thrift:"Face,3" db:"Face" json:"Face"` + Avatar int32 `thrift:"Avatar,4" db:"Avatar" json:"Avatar"` + Progress int32 `thrift:"Progress,5" db:"Progress" json:"Progress"` +} + +func NewOpponent() *Opponent { + return &Opponent{} +} + +func (p *Opponent) GetName() string { + return p.Name +} + +func (p *Opponent) GetFace() int32 { + return p.Face +} + +func (p *Opponent) GetAvatar() int32 { + return p.Avatar +} + +func (p *Opponent) GetProgress() int32 { + return p.Progress +} + +func (p *Opponent) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 2: + if fieldTypeId == thrift.STRING { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.I32 { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *Opponent) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Name = v + } + return nil +} + +func (p *Opponent) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Face = v + } + return nil +} + +func (p *Opponent) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Avatar = v + } + return nil +} + +func (p *Opponent) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.Progress = v + } + return nil +} + +func (p *Opponent) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "opponent"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *Opponent) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Name", thrift.STRING, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Name: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Name)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Name (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Name: ", p), err) + } + return err +} + +func (p *Opponent) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Face", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Face: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Face)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Face (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Face: ", p), err) + } + return err +} + +func (p *Opponent) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Avatar", thrift.I32, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Avatar: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Avatar)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Avatar (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Avatar: ", p), err) + } + return err +} + +func (p *Opponent) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Progress", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Progress: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Progress)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Progress (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Progress: ", p), err) + } + return err +} + +func (p *Opponent) Equals(other *Opponent) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Name != other.Name { + return false + } + if p.Face != other.Face { + return false + } + if p.Avatar != other.Avatar { + return false + } + if p.Progress != other.Progress { + return false + } + return true +} + +func (p *Opponent) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("Opponent(%+v)", *p) +} + +func (p *Opponent) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.Opponent", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*Opponent)(nil) + +func (p *Opponent) Validate() error { + return nil +} + +// Attributes: +// - Id +// - Face +// - Avatar +// - Name +// - Progress +// +type Raceopponent struct { + Id int32 `thrift:"Id,1" db:"Id" json:"Id"` + Face int32 `thrift:"Face,2" db:"Face" json:"Face"` + Avatar int32 `thrift:"Avatar,3" db:"Avatar" json:"Avatar"` + Name string `thrift:"Name,4" db:"Name" json:"Name"` + Progress int32 `thrift:"Progress,5" db:"Progress" json:"Progress"` +} + +func NewRaceopponent() *Raceopponent { + return &Raceopponent{} +} + +func (p *Raceopponent) GetId() int32 { + return p.Id +} + +func (p *Raceopponent) GetFace() int32 { + return p.Face +} + +func (p *Raceopponent) GetAvatar() int32 { + return p.Avatar +} + +func (p *Raceopponent) GetName() string { + return p.Name +} + +func (p *Raceopponent) GetProgress() int32 { + return p.Progress +} + +func (p *Raceopponent) Read(ctx context.Context, iprot thrift.TProtocol) error { + if _, err := iprot.ReadStructBegin(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read error: ", p), err) + } + + for { + _, fieldTypeId, fieldId, err := iprot.ReadFieldBegin(ctx) + if err != nil { + return thrift.PrependError(fmt.Sprintf("%T field %d read error: ", p, fieldId), err) + } + if fieldTypeId == thrift.STOP { + break + } + switch fieldId { + case 1: + if fieldTypeId == thrift.I32 { + if err := p.ReadField1(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 2: + if fieldTypeId == thrift.I32 { + if err := p.ReadField2(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 3: + if fieldTypeId == thrift.I32 { + if err := p.ReadField3(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 4: + if fieldTypeId == thrift.STRING { + if err := p.ReadField4(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + case 5: + if fieldTypeId == thrift.I32 { + if err := p.ReadField5(ctx, iprot); err != nil { + return err + } + } else { + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + default: + if err := iprot.Skip(ctx, fieldTypeId); err != nil { + return err + } + } + if err := iprot.ReadFieldEnd(ctx); err != nil { + return err + } + } + if err := iprot.ReadStructEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T read struct end error: ", p), err) + } + return nil +} + +func (p *Raceopponent) ReadField1(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 1: ", err) + } else { + p.Id = v + } + return nil +} + +func (p *Raceopponent) ReadField2(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 2: ", err) + } else { + p.Face = v + } + return nil +} + +func (p *Raceopponent) ReadField3(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 3: ", err) + } else { + p.Avatar = v + } + return nil +} + +func (p *Raceopponent) ReadField4(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadString(ctx); err != nil { + return thrift.PrependError("error reading field 4: ", err) + } else { + p.Name = v + } + return nil +} + +func (p *Raceopponent) ReadField5(ctx context.Context, iprot thrift.TProtocol) error { + if v, err := iprot.ReadI32(ctx); err != nil { + return thrift.PrependError("error reading field 5: ", err) + } else { + p.Progress = v + } + return nil +} + +func (p *Raceopponent) Write(ctx context.Context, oprot thrift.TProtocol) error { + if err := oprot.WriteStructBegin(ctx, "raceopponent"); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write struct begin error: ", p), err) + } + if p != nil { + if err := p.writeField1(ctx, oprot); err != nil { + return err + } + if err := p.writeField2(ctx, oprot); err != nil { + return err + } + if err := p.writeField3(ctx, oprot); err != nil { + return err + } + if err := p.writeField4(ctx, oprot); err != nil { + return err + } + if err := p.writeField5(ctx, oprot); err != nil { + return err + } + } + if err := oprot.WriteFieldStop(ctx); err != nil { + return thrift.PrependError("write field stop error: ", err) + } + if err := oprot.WriteStructEnd(ctx); err != nil { + return thrift.PrependError("write struct stop error: ", err) + } + return nil +} + +func (p *Raceopponent) writeField1(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Id", thrift.I32, 1); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 1:Id: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Id)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Id (1) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 1:Id: ", p), err) + } + return err +} + +func (p *Raceopponent) writeField2(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Face", thrift.I32, 2); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 2:Face: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Face)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Face (2) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 2:Face: ", p), err) + } + return err +} + +func (p *Raceopponent) writeField3(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Avatar", thrift.I32, 3); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 3:Avatar: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Avatar)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Avatar (3) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 3:Avatar: ", p), err) + } + return err +} + +func (p *Raceopponent) writeField4(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Name", thrift.STRING, 4); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 4:Name: ", p), err) + } + if err := oprot.WriteString(ctx, string(p.Name)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Name (4) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 4:Name: ", p), err) + } + return err +} + +func (p *Raceopponent) writeField5(ctx context.Context, oprot thrift.TProtocol) (err error) { + if err := oprot.WriteFieldBegin(ctx, "Progress", thrift.I32, 5); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field begin error 5:Progress: ", p), err) + } + if err := oprot.WriteI32(ctx, int32(p.Progress)); err != nil { + return thrift.PrependError(fmt.Sprintf("%T.Progress (5) field write error: ", p), err) + } + if err := oprot.WriteFieldEnd(ctx); err != nil { + return thrift.PrependError(fmt.Sprintf("%T write field end error 5:Progress: ", p), err) + } + return err +} + +func (p *Raceopponent) Equals(other *Raceopponent) bool { + if p == other { + return true + } else if p == nil || other == nil { + return false + } + if p.Id != other.Id { + return false + } + if p.Face != other.Face { + return false + } + if p.Avatar != other.Avatar { + return false + } + if p.Name != other.Name { + return false + } + if p.Progress != other.Progress { + return false + } + return true +} + +func (p *Raceopponent) String() string { + if p == nil { + return "" + } + return fmt.Sprintf("Raceopponent(%+v)", *p) +} + +func (p *Raceopponent) LogValue() slog.Value { + if p == nil { + return slog.AnyValue(nil) + } + v := thrift.SlogTStructWrapper{ + Type: "*meowmentnet.Raceopponent", + Value: p, + } + return slog.AnyValue(v) +} + +var _ slog.LogValuer = (*Raceopponent)(nil) + +func (p *Raceopponent) Validate() error { + return nil +} diff --git a/compiler/exe/thrift-go.exe b/compiler/exe/thrift-go.exe new file mode 100644 index 0000000..ff6c002 Binary files /dev/null and b/compiler/exe/thrift-go.exe differ diff --git a/thrift-files/meowment-network/Network.thrift b/thrift-files/meowment-network/Network.thrift index 7ace6cc..42fab22 100644 --- a/thrift-files/meowment-network/Network.thrift +++ b/thrift-files/meowment-network/Network.thrift @@ -919,7 +919,7 @@ struct ReqCatReturnGiftReward { } -struct ReqCatReturnGiftRewardGfit { +struct ReqCatReturnGiftRewardGift { 1: i32 Id, } @@ -1544,7 +1544,7 @@ struct ReqPlayroomWork { } -struct ReqPlayroomWrokOutline { +struct ReqPlayroomWorkOutline { } @@ -2002,7 +2002,7 @@ struct ResCatReturnGiftReward { } -struct ResCatReturnGiftRewardGfit { +struct ResCatReturnGiftRewardGift { 1: RES_CODE Code, 2: string Msg, } @@ -2942,11 +2942,12 @@ struct ResPlayerRank { 5: i32 Level, 6: double score, 7: i32 type, - 8: map PlayroomSet - 9: map DressSet + 8: map PlayroomSet, + 9: map DressSet, 10: i32 FurSet, 11: ActLog Last, 12: string PetName, + 13: i32 Rank, } @@ -3166,7 +3167,7 @@ struct ResPlayroomWork { } -struct ResPlayroomWrokOutline { +struct ResPlayroomWorkOutline { 1: RES_CODE Code, 2: string Msg, }