Documentation ¶
Index ¶
- Variables
- func RegisterAccountsServer(s grpc.ServiceRegistrar, srv AccountsServer)
- func RegisterAuthServer(s grpc.ServiceRegistrar, srv AuthServer)
- func RegisterTransactionsServer(s grpc.ServiceRegistrar, srv TransactionsServer)
- type AccountsClient
- type AccountsServer
- type AuthClient
- type AuthRequest
- func (*AuthRequest) Descriptor() ([]byte, []int)deprecated
- func (x *AuthRequest) GetEmail() string
- func (x *AuthRequest) GetPassword() string
- func (*AuthRequest) ProtoMessage()
- func (x *AuthRequest) ProtoReflect() protoreflect.Message
- func (x *AuthRequest) Reset()
- func (x *AuthRequest) String() string
- type AuthResponse
- type AuthServer
- type CreateAccountRequest
- func (*CreateAccountRequest) Descriptor() ([]byte, []int)deprecated
- func (x *CreateAccountRequest) GetAccountType() string
- func (x *CreateAccountRequest) GetCustomerName() string
- func (x *CreateAccountRequest) GetDocumentNumber() string
- func (x *CreateAccountRequest) GetEmail() string
- func (x *CreateAccountRequest) GetPassword() string
- func (x *CreateAccountRequest) GetPhoneNumber() string
- func (*CreateAccountRequest) ProtoMessage()
- func (x *CreateAccountRequest) ProtoReflect() protoreflect.Message
- func (x *CreateAccountRequest) Reset()
- func (x *CreateAccountRequest) String() string
- type CreateAccountResponse
- func (*CreateAccountResponse) Descriptor() ([]byte, []int)deprecated
- func (x *CreateAccountResponse) GetId() string
- func (*CreateAccountResponse) ProtoMessage()
- func (x *CreateAccountResponse) ProtoReflect() protoreflect.Message
- func (x *CreateAccountResponse) Reset()
- func (x *CreateAccountResponse) String() string
- type DepositRequest
- type FetchAccountRequest
- type FetchAccountResponse
- func (*FetchAccountResponse) Descriptor() ([]byte, []int)deprecated
- func (x *FetchAccountResponse) GetAccountType() string
- func (x *FetchAccountResponse) GetBalance() string
- func (x *FetchAccountResponse) GetCustomerName() string
- func (x *FetchAccountResponse) GetEmail() string
- func (x *FetchAccountResponse) GetId() string
- func (x *FetchAccountResponse) GetStatus() string
- func (*FetchAccountResponse) ProtoMessage()
- func (x *FetchAccountResponse) ProtoReflect() protoreflect.Message
- func (x *FetchAccountResponse) Reset()
- func (x *FetchAccountResponse) String() string
- type ListRequest
- type ListResponse
- type TransactionResponse
- func (*TransactionResponse) Descriptor() ([]byte, []int)deprecated
- func (x *TransactionResponse) GetId() string
- func (*TransactionResponse) ProtoMessage()
- func (x *TransactionResponse) ProtoReflect() protoreflect.Message
- func (x *TransactionResponse) Reset()
- func (x *TransactionResponse) String() string
- type TransactionsClient
- type TransactionsServer
- type TransferRequest
- func (*TransferRequest) Descriptor() ([]byte, []int)deprecated
- func (x *TransferRequest) GetPayeeId() string
- func (x *TransferRequest) GetValue() float32
- func (*TransferRequest) ProtoMessage()
- func (x *TransferRequest) ProtoReflect() protoreflect.Message
- func (x *TransferRequest) Reset()
- func (x *TransferRequest) String() string
- type UnimplementedAccountsServer
- func (UnimplementedAccountsServer) Create(context.Context, *CreateAccountRequest) (*CreateAccountResponse, error)
- func (UnimplementedAccountsServer) Fetch(context.Context, *FetchAccountRequest) (*FetchAccountResponse, error)
- func (UnimplementedAccountsServer) List(context.Context, *ListRequest) (*ListResponse, error)
- type UnimplementedAuthServer
- type UnimplementedTransactionsServer
- type UnsafeAccountsServer
- type UnsafeAuthServer
- type UnsafeTransactionsServer
Constants ¶
This section is empty.
Variables ¶
var Accounts_ServiceDesc = grpc.ServiceDesc{ ServiceName: "pb.Accounts", HandlerType: (*AccountsServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Create", Handler: _Accounts_Create_Handler, }, { MethodName: "Fetch", Handler: _Accounts_Fetch_Handler, }, { MethodName: "List", Handler: _Accounts_List_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "pkg/pb/application.proto", }
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 Auth_ServiceDesc = grpc.ServiceDesc{ ServiceName: "pb.Auth", HandlerType: (*AuthServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Auth", Handler: _Auth_Auth_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "pkg/pb/application.proto", }
Auth_ServiceDesc is the grpc.ServiceDesc for Auth service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var File_pkg_pb_application_proto protoreflect.FileDescriptor
var Transactions_ServiceDesc = grpc.ServiceDesc{ ServiceName: "pb.Transactions", HandlerType: (*TransactionsServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Deposit", Handler: _Transactions_Deposit_Handler, }, { MethodName: "Transfer", Handler: _Transactions_Transfer_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "pkg/pb/application.proto", }
Transactions_ServiceDesc is the grpc.ServiceDesc for Transactions service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterAccountsServer ¶
func RegisterAccountsServer(s grpc.ServiceRegistrar, srv AccountsServer)
func RegisterAuthServer ¶
func RegisterAuthServer(s grpc.ServiceRegistrar, srv AuthServer)
func RegisterTransactionsServer ¶
func RegisterTransactionsServer(s grpc.ServiceRegistrar, srv TransactionsServer)
Types ¶
type AccountsClient ¶
type AccountsClient interface { Create(ctx context.Context, in *CreateAccountRequest, opts ...grpc.CallOption) (*CreateAccountResponse, error) Fetch(ctx context.Context, in *FetchAccountRequest, opts ...grpc.CallOption) (*FetchAccountResponse, error) List(ctx context.Context, in *ListRequest, opts ...grpc.CallOption) (*ListResponse, error) }
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.
func NewAccountsClient ¶
func NewAccountsClient(cc grpc.ClientConnInterface) AccountsClient
type AccountsServer ¶
type AccountsServer interface { Create(context.Context, *CreateAccountRequest) (*CreateAccountResponse, error) Fetch(context.Context, *FetchAccountRequest) (*FetchAccountResponse, error) List(context.Context, *ListRequest) (*ListResponse, error) // contains filtered or unexported methods }
AccountsServer is the server API for Accounts service. All implementations must embed UnimplementedAccountsServer for forward compatibility
type AuthClient ¶
type AuthClient interface {
Auth(ctx context.Context, in *AuthRequest, opts ...grpc.CallOption) (*AuthResponse, error)
}
AuthClient is the client API for Auth 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.
func NewAuthClient ¶
func NewAuthClient(cc grpc.ClientConnInterface) AuthClient
type AuthRequest ¶
type AuthRequest struct { Email string `protobuf:"bytes,1,opt,name=email,proto3" json:"email,omitempty"` Password string `protobuf:"bytes,2,opt,name=password,proto3" json:"password,omitempty"` // contains filtered or unexported fields }
func (*AuthRequest) Descriptor
deprecated
func (*AuthRequest) Descriptor() ([]byte, []int)
Deprecated: Use AuthRequest.ProtoReflect.Descriptor instead.
func (*AuthRequest) GetEmail ¶
func (x *AuthRequest) GetEmail() string
func (*AuthRequest) GetPassword ¶
func (x *AuthRequest) GetPassword() string
func (*AuthRequest) ProtoMessage ¶
func (*AuthRequest) ProtoMessage()
func (*AuthRequest) ProtoReflect ¶
func (x *AuthRequest) ProtoReflect() protoreflect.Message
func (*AuthRequest) Reset ¶
func (x *AuthRequest) Reset()
func (*AuthRequest) String ¶
func (x *AuthRequest) String() string
type AuthResponse ¶
type AuthResponse struct { Token string `protobuf:"bytes,1,opt,name=token,proto3" json:"token,omitempty"` // contains filtered or unexported fields }
func (*AuthResponse) Descriptor
deprecated
func (*AuthResponse) Descriptor() ([]byte, []int)
Deprecated: Use AuthResponse.ProtoReflect.Descriptor instead.
func (*AuthResponse) GetToken ¶
func (x *AuthResponse) GetToken() string
func (*AuthResponse) ProtoMessage ¶
func (*AuthResponse) ProtoMessage()
func (*AuthResponse) ProtoReflect ¶
func (x *AuthResponse) ProtoReflect() protoreflect.Message
func (*AuthResponse) Reset ¶
func (x *AuthResponse) Reset()
func (*AuthResponse) String ¶
func (x *AuthResponse) String() string
type AuthServer ¶
type AuthServer interface { Auth(context.Context, *AuthRequest) (*AuthResponse, error) // contains filtered or unexported methods }
AuthServer is the server API for Auth service. All implementations must embed UnimplementedAuthServer for forward compatibility
type CreateAccountRequest ¶
type CreateAccountRequest struct { CustomerName string `protobuf:"bytes,1,opt,name=customer_name,json=customerName,proto3" json:"customer_name,omitempty"` DocumentNumber string `protobuf:"bytes,2,opt,name=document_number,json=documentNumber,proto3" json:"document_number,omitempty"` PhoneNumber string `protobuf:"bytes,3,opt,name=phone_number,json=phoneNumber,proto3" json:"phone_number,omitempty"` Email string `protobuf:"bytes,4,opt,name=email,proto3" json:"email,omitempty"` Password string `protobuf:"bytes,5,opt,name=password,proto3" json:"password,omitempty"` AccountType string `protobuf:"bytes,6,opt,name=account_type,json=accountType,proto3" json:"account_type,omitempty"` // contains filtered or unexported fields }
func (*CreateAccountRequest) Descriptor
deprecated
func (*CreateAccountRequest) Descriptor() ([]byte, []int)
Deprecated: Use CreateAccountRequest.ProtoReflect.Descriptor instead.
func (*CreateAccountRequest) GetAccountType ¶
func (x *CreateAccountRequest) GetAccountType() string
func (*CreateAccountRequest) GetCustomerName ¶
func (x *CreateAccountRequest) GetCustomerName() string
func (*CreateAccountRequest) GetDocumentNumber ¶
func (x *CreateAccountRequest) GetDocumentNumber() string
func (*CreateAccountRequest) GetEmail ¶
func (x *CreateAccountRequest) GetEmail() string
func (*CreateAccountRequest) GetPassword ¶
func (x *CreateAccountRequest) GetPassword() string
func (*CreateAccountRequest) GetPhoneNumber ¶
func (x *CreateAccountRequest) GetPhoneNumber() string
func (*CreateAccountRequest) ProtoMessage ¶
func (*CreateAccountRequest) ProtoMessage()
func (*CreateAccountRequest) ProtoReflect ¶
func (x *CreateAccountRequest) ProtoReflect() protoreflect.Message
func (*CreateAccountRequest) Reset ¶
func (x *CreateAccountRequest) Reset()
func (*CreateAccountRequest) String ¶
func (x *CreateAccountRequest) String() string
type CreateAccountResponse ¶
type CreateAccountResponse struct { Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` // contains filtered or unexported fields }
func (*CreateAccountResponse) Descriptor
deprecated
func (*CreateAccountResponse) Descriptor() ([]byte, []int)
Deprecated: Use CreateAccountResponse.ProtoReflect.Descriptor instead.
func (*CreateAccountResponse) GetId ¶
func (x *CreateAccountResponse) GetId() string
func (*CreateAccountResponse) ProtoMessage ¶
func (*CreateAccountResponse) ProtoMessage()
func (*CreateAccountResponse) ProtoReflect ¶
func (x *CreateAccountResponse) ProtoReflect() protoreflect.Message
func (*CreateAccountResponse) Reset ¶
func (x *CreateAccountResponse) Reset()
func (*CreateAccountResponse) String ¶
func (x *CreateAccountResponse) String() string
type DepositRequest ¶
type DepositRequest struct { Value float32 `protobuf:"fixed32,1,opt,name=value,proto3" json:"value,omitempty"` // contains filtered or unexported fields }
func (*DepositRequest) Descriptor
deprecated
func (*DepositRequest) Descriptor() ([]byte, []int)
Deprecated: Use DepositRequest.ProtoReflect.Descriptor instead.
func (*DepositRequest) GetValue ¶
func (x *DepositRequest) GetValue() float32
func (*DepositRequest) ProtoMessage ¶
func (*DepositRequest) ProtoMessage()
func (*DepositRequest) ProtoReflect ¶
func (x *DepositRequest) ProtoReflect() protoreflect.Message
func (*DepositRequest) Reset ¶
func (x *DepositRequest) Reset()
func (*DepositRequest) String ¶
func (x *DepositRequest) String() string
type FetchAccountRequest ¶
type FetchAccountRequest struct {
// contains filtered or unexported fields
}
func (*FetchAccountRequest) Descriptor
deprecated
func (*FetchAccountRequest) Descriptor() ([]byte, []int)
Deprecated: Use FetchAccountRequest.ProtoReflect.Descriptor instead.
func (*FetchAccountRequest) ProtoMessage ¶
func (*FetchAccountRequest) ProtoMessage()
func (*FetchAccountRequest) ProtoReflect ¶
func (x *FetchAccountRequest) ProtoReflect() protoreflect.Message
func (*FetchAccountRequest) Reset ¶
func (x *FetchAccountRequest) Reset()
func (*FetchAccountRequest) String ¶
func (x *FetchAccountRequest) String() string
type FetchAccountResponse ¶
type FetchAccountResponse struct { Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` AccountType string `protobuf:"bytes,2,opt,name=account_type,json=accountType,proto3" json:"account_type,omitempty"` CustomerName string `protobuf:"bytes,3,opt,name=customer_name,json=customerName,proto3" json:"customer_name,omitempty"` Email string `protobuf:"bytes,4,opt,name=email,proto3" json:"email,omitempty"` Balance string `protobuf:"bytes,5,opt,name=balance,proto3" json:"balance,omitempty"` Status string `protobuf:"bytes,6,opt,name=status,proto3" json:"status,omitempty"` // contains filtered or unexported fields }
func (*FetchAccountResponse) Descriptor
deprecated
func (*FetchAccountResponse) Descriptor() ([]byte, []int)
Deprecated: Use FetchAccountResponse.ProtoReflect.Descriptor instead.
func (*FetchAccountResponse) GetAccountType ¶
func (x *FetchAccountResponse) GetAccountType() string
func (*FetchAccountResponse) GetBalance ¶
func (x *FetchAccountResponse) GetBalance() string
func (*FetchAccountResponse) GetCustomerName ¶
func (x *FetchAccountResponse) GetCustomerName() string
func (*FetchAccountResponse) GetEmail ¶
func (x *FetchAccountResponse) GetEmail() string
func (*FetchAccountResponse) GetId ¶
func (x *FetchAccountResponse) GetId() string
func (*FetchAccountResponse) GetStatus ¶
func (x *FetchAccountResponse) GetStatus() string
func (*FetchAccountResponse) ProtoMessage ¶
func (*FetchAccountResponse) ProtoMessage()
func (*FetchAccountResponse) ProtoReflect ¶
func (x *FetchAccountResponse) ProtoReflect() protoreflect.Message
func (*FetchAccountResponse) Reset ¶
func (x *FetchAccountResponse) Reset()
func (*FetchAccountResponse) String ¶
func (x *FetchAccountResponse) String() string
type ListRequest ¶
type ListRequest struct {
// contains filtered or unexported fields
}
func (*ListRequest) Descriptor
deprecated
func (*ListRequest) Descriptor() ([]byte, []int)
Deprecated: Use ListRequest.ProtoReflect.Descriptor instead.
func (*ListRequest) ProtoMessage ¶
func (*ListRequest) ProtoMessage()
func (*ListRequest) ProtoReflect ¶
func (x *ListRequest) ProtoReflect() protoreflect.Message
func (*ListRequest) Reset ¶
func (x *ListRequest) Reset()
func (*ListRequest) String ¶
func (x *ListRequest) String() string
type ListResponse ¶
type ListResponse struct { Accounts []*FetchAccountResponse `protobuf:"bytes,1,rep,name=accounts,proto3" json:"accounts,omitempty"` // contains filtered or unexported fields }
func (*ListResponse) Descriptor
deprecated
func (*ListResponse) Descriptor() ([]byte, []int)
Deprecated: Use ListResponse.ProtoReflect.Descriptor instead.
func (*ListResponse) GetAccounts ¶
func (x *ListResponse) GetAccounts() []*FetchAccountResponse
func (*ListResponse) ProtoMessage ¶
func (*ListResponse) ProtoMessage()
func (*ListResponse) ProtoReflect ¶
func (x *ListResponse) ProtoReflect() protoreflect.Message
func (*ListResponse) Reset ¶
func (x *ListResponse) Reset()
func (*ListResponse) String ¶
func (x *ListResponse) String() string
type TransactionResponse ¶
type TransactionResponse struct { Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` // contains filtered or unexported fields }
func (*TransactionResponse) Descriptor
deprecated
func (*TransactionResponse) Descriptor() ([]byte, []int)
Deprecated: Use TransactionResponse.ProtoReflect.Descriptor instead.
func (*TransactionResponse) GetId ¶
func (x *TransactionResponse) GetId() string
func (*TransactionResponse) ProtoMessage ¶
func (*TransactionResponse) ProtoMessage()
func (*TransactionResponse) ProtoReflect ¶
func (x *TransactionResponse) ProtoReflect() protoreflect.Message
func (*TransactionResponse) Reset ¶
func (x *TransactionResponse) Reset()
func (*TransactionResponse) String ¶
func (x *TransactionResponse) String() string
type TransactionsClient ¶
type TransactionsClient interface { Deposit(ctx context.Context, in *DepositRequest, opts ...grpc.CallOption) (*TransactionResponse, error) Transfer(ctx context.Context, in *TransferRequest, opts ...grpc.CallOption) (*TransactionResponse, error) }
TransactionsClient is the client API for Transactions 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.
func NewTransactionsClient ¶
func NewTransactionsClient(cc grpc.ClientConnInterface) TransactionsClient
type TransactionsServer ¶
type TransactionsServer interface { Deposit(context.Context, *DepositRequest) (*TransactionResponse, error) Transfer(context.Context, *TransferRequest) (*TransactionResponse, error) // contains filtered or unexported methods }
TransactionsServer is the server API for Transactions service. All implementations must embed UnimplementedTransactionsServer for forward compatibility
type TransferRequest ¶
type TransferRequest struct { PayeeId string `protobuf:"bytes,1,opt,name=payee_id,json=payeeId,proto3" json:"payee_id,omitempty"` Value float32 `protobuf:"fixed32,2,opt,name=value,proto3" json:"value,omitempty"` // contains filtered or unexported fields }
func (*TransferRequest) Descriptor
deprecated
func (*TransferRequest) Descriptor() ([]byte, []int)
Deprecated: Use TransferRequest.ProtoReflect.Descriptor instead.
func (*TransferRequest) GetPayeeId ¶
func (x *TransferRequest) GetPayeeId() string
func (*TransferRequest) GetValue ¶
func (x *TransferRequest) GetValue() float32
func (*TransferRequest) ProtoMessage ¶
func (*TransferRequest) ProtoMessage()
func (*TransferRequest) ProtoReflect ¶
func (x *TransferRequest) ProtoReflect() protoreflect.Message
func (*TransferRequest) Reset ¶
func (x *TransferRequest) Reset()
func (*TransferRequest) String ¶
func (x *TransferRequest) String() string
type UnimplementedAccountsServer ¶
type UnimplementedAccountsServer struct { }
UnimplementedAccountsServer must be embedded to have forward compatible implementations.
func (UnimplementedAccountsServer) Create ¶
func (UnimplementedAccountsServer) Create(context.Context, *CreateAccountRequest) (*CreateAccountResponse, error)
func (UnimplementedAccountsServer) Fetch ¶
func (UnimplementedAccountsServer) Fetch(context.Context, *FetchAccountRequest) (*FetchAccountResponse, error)
func (UnimplementedAccountsServer) List ¶
func (UnimplementedAccountsServer) List(context.Context, *ListRequest) (*ListResponse, error)
type UnimplementedAuthServer ¶
type UnimplementedAuthServer struct { }
UnimplementedAuthServer must be embedded to have forward compatible implementations.
func (UnimplementedAuthServer) Auth ¶
func (UnimplementedAuthServer) Auth(context.Context, *AuthRequest) (*AuthResponse, error)
type UnimplementedTransactionsServer ¶
type UnimplementedTransactionsServer struct { }
UnimplementedTransactionsServer must be embedded to have forward compatible implementations.
func (UnimplementedTransactionsServer) Deposit ¶
func (UnimplementedTransactionsServer) Deposit(context.Context, *DepositRequest) (*TransactionResponse, error)
func (UnimplementedTransactionsServer) Transfer ¶
func (UnimplementedTransactionsServer) Transfer(context.Context, *TransferRequest) (*TransactionResponse, error)
type UnsafeAccountsServer ¶
type UnsafeAccountsServer interface {
// contains filtered or unexported methods
}
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 UnsafeAuthServer ¶
type UnsafeAuthServer interface {
// contains filtered or unexported methods
}
UnsafeAuthServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to AuthServer will result in compilation errors.
type UnsafeTransactionsServer ¶
type UnsafeTransactionsServer interface {
// contains filtered or unexported methods
}
UnsafeTransactionsServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to TransactionsServer will result in compilation errors.