// Code generated by goctl. DO NOT EDIT. // Source: app.proto package appclient import ( "context" "mingyang-admin-app-rpc/types/app" "github.com/zeromicro/go-zero/zrpc" "google.golang.org/grpc" ) type ( AuthToken = app.AuthToken BaseIDResp = app.BaseIDResp BaseMsg = app.BaseMsg BaseResp = app.BaseResp BaseUUIDResp = app.BaseUUIDResp Empty = app.Empty IDReq = app.IDReq IDsReq = app.IDsReq LoginRequest = app.LoginRequest LoginResponse = app.LoginResponse PageInfoReq = app.PageInfoReq PageUserRequest = app.PageUserRequest PageUserResponse = app.PageUserResponse RegisterUserRequest = app.RegisterUserRequest RegisterUserResponse = app.RegisterUserResponse UUIDReq = app.UUIDReq UUIDsReq = app.UUIDsReq UserInfo = app.UserInfo VerifyCodeReq = app.VerifyCodeReq VerifyCodeResp = app.VerifyCodeResp App interface { // 获取验证码 GetVerifyCode(ctx context.Context, in *VerifyCodeReq, opts ...grpc.CallOption) (*VerifyCodeResp, error) // 用户注册 RegisterUser(ctx context.Context, in *RegisterUserRequest, opts ...grpc.CallOption) (*RegisterUserResponse, error) // 用户登录 LoginUser(ctx context.Context, in *LoginRequest, opts ...grpc.CallOption) (*LoginResponse, error) // 分页查询用户信息 ListUsers(ctx context.Context, in *PageUserRequest, opts ...grpc.CallOption) (*PageUserResponse, error) InitDatabase(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*BaseResp, error) } defaultApp struct { cli zrpc.Client } ) func NewApp(cli zrpc.Client) App { return &defaultApp{ cli: cli, } } // 获取验证码 func (m *defaultApp) GetVerifyCode(ctx context.Context, in *VerifyCodeReq, opts ...grpc.CallOption) (*VerifyCodeResp, error) { client := app.NewAppClient(m.cli.Conn()) return client.GetVerifyCode(ctx, in, opts...) } // 用户注册 func (m *defaultApp) RegisterUser(ctx context.Context, in *RegisterUserRequest, opts ...grpc.CallOption) (*RegisterUserResponse, error) { client := app.NewAppClient(m.cli.Conn()) return client.RegisterUser(ctx, in, opts...) } // 用户登录 func (m *defaultApp) LoginUser(ctx context.Context, in *LoginRequest, opts ...grpc.CallOption) (*LoginResponse, error) { client := app.NewAppClient(m.cli.Conn()) return client.LoginUser(ctx, in, opts...) } // 分页查询用户信息 func (m *defaultApp) ListUsers(ctx context.Context, in *PageUserRequest, opts ...grpc.CallOption) (*PageUserResponse, error) { client := app.NewAppClient(m.cli.Conn()) return client.ListUsers(ctx, in, opts...) } func (m *defaultApp) InitDatabase(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*BaseResp, error) { client := app.NewAppClient(m.cli.Conn()) return client.InitDatabase(ctx, in, opts...) }