// Code generated by protoc-gen-go-grpc. DO NOT EDIT. package accounts import ( context "context" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" emptypb "google.golang.org/protobuf/types/known/emptypb" ) // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. // Requires gRPC-Go v1.32.0 or later. const _ = grpc.SupportPackageIsVersion7 // AccountsClient is the client API for Accounts 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 AccountsClient interface { SignUp(ctx context.Context, in *AccountWithPassword, opts ...grpc.CallOption) (*AccountFullWithToken, error) SignIn(ctx context.Context, in *AccountWithPassword, opts ...grpc.CallOption) (*AccountFullWithToken, error) ResetPassword(ctx context.Context, in *AccountData, opts ...grpc.CallOption) (*emptypb.Empty, error) NewPassword(ctx context.Context, in *AccountWithPasswordAndCode, opts ...grpc.CallOption) (*emptypb.Empty, error) IsEmailVerified(ctx context.Context, in *AccountData, opts ...grpc.CallOption) (*EmailVerified, error) } type accountsClient struct { cc grpc.ClientConnInterface } func NewAccountsClient(cc grpc.ClientConnInterface) AccountsClient { return &accountsClient{cc} } func (c *accountsClient) SignUp(ctx context.Context, in *AccountWithPassword, opts ...grpc.CallOption) (*AccountFullWithToken, error) { out := new(AccountFullWithToken) err := c.cc.Invoke(ctx, "/accounts.Accounts/SignUp", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *accountsClient) SignIn(ctx context.Context, in *AccountWithPassword, opts ...grpc.CallOption) (*AccountFullWithToken, error) { out := new(AccountFullWithToken) err := c.cc.Invoke(ctx, "/accounts.Accounts/SignIn", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *accountsClient) ResetPassword(ctx context.Context, in *AccountData, opts ...grpc.CallOption) (*emptypb.Empty, error) { out := new(emptypb.Empty) err := c.cc.Invoke(ctx, "/accounts.Accounts/ResetPassword", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *accountsClient) NewPassword(ctx context.Context, in *AccountWithPasswordAndCode, opts ...grpc.CallOption) (*emptypb.Empty, error) { out := new(emptypb.Empty) err := c.cc.Invoke(ctx, "/accounts.Accounts/NewPassword", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *accountsClient) IsEmailVerified(ctx context.Context, in *AccountData, opts ...grpc.CallOption) (*EmailVerified, error) { out := new(EmailVerified) err := c.cc.Invoke(ctx, "/accounts.Accounts/IsEmailVerified", in, out, opts...) if err != nil { return nil, err } return out, nil } // AccountsServer is the server API for Accounts service. // All implementations must embed UnimplementedAccountsServer // for forward compatibility type AccountsServer interface { SignUp(context.Context, *AccountWithPassword) (*AccountFullWithToken, error) SignIn(context.Context, *AccountWithPassword) (*AccountFullWithToken, error) ResetPassword(context.Context, *AccountData) (*emptypb.Empty, error) NewPassword(context.Context, *AccountWithPasswordAndCode) (*emptypb.Empty, error) IsEmailVerified(context.Context, *AccountData) (*EmailVerified, error) mustEmbedUnimplementedAccountsServer() } // UnimplementedAccountsServer must be embedded to have forward compatible implementations. type UnimplementedAccountsServer struct { } func (UnimplementedAccountsServer) SignUp(context.Context, *AccountWithPassword) (*AccountFullWithToken, error) { return nil, status.Errorf(codes.Unimplemented, "method SignUp not implemented") } func (UnimplementedAccountsServer) SignIn(context.Context, *AccountWithPassword) (*AccountFullWithToken, error) { return nil, status.Errorf(codes.Unimplemented, "method SignIn not implemented") } func (UnimplementedAccountsServer) ResetPassword(context.Context, *AccountData) (*emptypb.Empty, error) { return nil, status.Errorf(codes.Unimplemented, "method ResetPassword not implemented") } func (UnimplementedAccountsServer) NewPassword(context.Context, *AccountWithPasswordAndCode) (*emptypb.Empty, error) { return nil, status.Errorf(codes.Unimplemented, "method NewPassword not implemented") } func (UnimplementedAccountsServer) IsEmailVerified(context.Context, *AccountData) (*EmailVerified, error) { return nil, status.Errorf(codes.Unimplemented, "method IsEmailVerified not implemented") } func (UnimplementedAccountsServer) mustEmbedUnimplementedAccountsServer() {} // UnsafeAccountsServer may be embedded to opt out of forward compatibility for this service. // Use of this interface is not recommended, as added methods to AccountsServer will // result in compilation errors. type UnsafeAccountsServer interface { mustEmbedUnimplementedAccountsServer() } func RegisterAccountsServer(s grpc.ServiceRegistrar, srv AccountsServer) { s.RegisterService(&Accounts_ServiceDesc, srv) } func _Accounts_SignUp_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(AccountWithPassword) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(AccountsServer).SignUp(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/accounts.Accounts/SignUp", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(AccountsServer).SignUp(ctx, req.(*AccountWithPassword)) } return interceptor(ctx, in, info, handler) } func _Accounts_SignIn_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(AccountWithPassword) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(AccountsServer).SignIn(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/accounts.Accounts/SignIn", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(AccountsServer).SignIn(ctx, req.(*AccountWithPassword)) } return interceptor(ctx, in, info, handler) } func _Accounts_ResetPassword_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(AccountData) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(AccountsServer).ResetPassword(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/accounts.Accounts/ResetPassword", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(AccountsServer).ResetPassword(ctx, req.(*AccountData)) } return interceptor(ctx, in, info, handler) } func _Accounts_NewPassword_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(AccountWithPasswordAndCode) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(AccountsServer).NewPassword(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/accounts.Accounts/NewPassword", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(AccountsServer).NewPassword(ctx, req.(*AccountWithPasswordAndCode)) } return interceptor(ctx, in, info, handler) } func _Accounts_IsEmailVerified_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(AccountData) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(AccountsServer).IsEmailVerified(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/accounts.Accounts/IsEmailVerified", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(AccountsServer).IsEmailVerified(ctx, req.(*AccountData)) } return interceptor(ctx, in, info, handler) } // Accounts_ServiceDesc is the grpc.ServiceDesc for Accounts service. // It's only intended for direct use with grpc.RegisterService, // and not to be introspected or modified (even as a copy) var Accounts_ServiceDesc = grpc.ServiceDesc{ ServiceName: "accounts.Accounts", HandlerType: (*AccountsServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "SignUp", Handler: _Accounts_SignUp_Handler, }, { MethodName: "SignIn", Handler: _Accounts_SignIn_Handler, }, { MethodName: "ResetPassword", Handler: _Accounts_ResetPassword_Handler, }, { MethodName: "NewPassword", Handler: _Accounts_NewPassword_Handler, }, { MethodName: "IsEmailVerified", Handler: _Accounts_IsEmailVerified_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "accounts/accounts_v1.proto", }