// Code generated by protoc-gen-go-grpc. DO NOT EDIT. package base import ( context "context" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" ) // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. const _ = grpc.SupportPackageIsVersion7 // ApiClient is the client API for Api service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. type ApiClient interface { SignUp(ctx context.Context, in *SignUpRequest, opts ...grpc.CallOption) (*DefaultReply, error) SignIn(ctx context.Context, in *SignInRequest, opts ...grpc.CallOption) (*SignInReply, error) SignOut(ctx context.Context, in *DefaultRequest, opts ...grpc.CallOption) (*DefaultReply, error) } type apiClient struct { cc grpc.ClientConnInterface } func NewApiClient(cc grpc.ClientConnInterface) ApiClient { return &apiClient{cc} } func (c *apiClient) SignUp(ctx context.Context, in *SignUpRequest, opts ...grpc.CallOption) (*DefaultReply, error) { out := new(DefaultReply) err := c.cc.Invoke(ctx, "/base.Api/SignUp", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *apiClient) SignIn(ctx context.Context, in *SignInRequest, opts ...grpc.CallOption) (*SignInReply, error) { out := new(SignInReply) err := c.cc.Invoke(ctx, "/base.Api/SignIn", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *apiClient) SignOut(ctx context.Context, in *DefaultRequest, opts ...grpc.CallOption) (*DefaultReply, error) { out := new(DefaultReply) err := c.cc.Invoke(ctx, "/base.Api/SignOut", in, out, opts...) if err != nil { return nil, err } return out, nil } // ApiServer is the server API for Api service. // All implementations must embed UnimplementedApiServer // for forward compatibility type ApiServer interface { SignUp(context.Context, *SignUpRequest) (*DefaultReply, error) SignIn(context.Context, *SignInRequest) (*SignInReply, error) SignOut(context.Context, *DefaultRequest) (*DefaultReply, error) mustEmbedUnimplementedApiServer() } // UnimplementedApiServer must be embedded to have forward compatible implementations. type UnimplementedApiServer struct { } func (UnimplementedApiServer) SignUp(context.Context, *SignUpRequest) (*DefaultReply, error) { return nil, status.Errorf(codes.Unimplemented, "method SignUp not implemented") } func (UnimplementedApiServer) SignIn(context.Context, *SignInRequest) (*SignInReply, error) { return nil, status.Errorf(codes.Unimplemented, "method SignIn not implemented") } func (UnimplementedApiServer) SignOut(context.Context, *DefaultRequest) (*DefaultReply, error) { return nil, status.Errorf(codes.Unimplemented, "method SignOut not implemented") } func (UnimplementedApiServer) mustEmbedUnimplementedApiServer() {} // UnsafeApiServer may be embedded to opt out of forward compatibility for this service. // Use of this interface is not recommended, as added methods to ApiServer will // result in compilation errors. type UnsafeApiServer interface { mustEmbedUnimplementedApiServer() } func RegisterApiServer(s grpc.ServiceRegistrar, srv ApiServer) { s.RegisterService(&_Api_serviceDesc, srv) } func _Api_SignUp_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(SignUpRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(ApiServer).SignUp(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/base.Api/SignUp", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(ApiServer).SignUp(ctx, req.(*SignUpRequest)) } return interceptor(ctx, in, info, handler) } func _Api_SignIn_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(SignInRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(ApiServer).SignIn(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/base.Api/SignIn", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(ApiServer).SignIn(ctx, req.(*SignInRequest)) } return interceptor(ctx, in, info, handler) } func _Api_SignOut_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(DefaultRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(ApiServer).SignOut(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/base.Api/SignOut", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(ApiServer).SignOut(ctx, req.(*DefaultRequest)) } return interceptor(ctx, in, info, handler) } var _Api_serviceDesc = grpc.ServiceDesc{ ServiceName: "base.Api", HandlerType: (*ApiServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "SignUp", Handler: _Api_SignUp_Handler, }, { MethodName: "SignIn", Handler: _Api_SignIn_Handler, }, { MethodName: "SignOut", Handler: _Api_SignOut_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "base.proto", }