Documentation ¶
Index ¶
- Variables
- func RegisterAccountSrvServer(s grpc.ServiceRegistrar, srv AccountSrvServer)
- type AccountGetReq
- func (*AccountGetReq) Descriptor() ([]byte, []int)deprecated
- func (x *AccountGetReq) GetCurrency() string
- func (x *AccountGetReq) GetIsAdmin() bool
- func (x *AccountGetReq) GetRemarks() string
- func (x *AccountGetReq) GetUid() string
- func (*AccountGetReq) ProtoMessage()
- func (x *AccountGetReq) ProtoReflect() protoreflect.Message
- func (x *AccountGetReq) Reset()
- func (x *AccountGetReq) String() string
- type AccountSrvClient
- type AccountSrvServer
- type AccountType
- func (AccountType) Descriptor() protoreflect.EnumDescriptor
- func (x AccountType) Enum() *AccountType
- func (AccountType) EnumDescriptor() ([]byte, []int)deprecated
- func (x AccountType) Number() protoreflect.EnumNumber
- func (x AccountType) String() string
- func (AccountType) Type() protoreflect.EnumType
- type AddressGetReq
- func (*AddressGetReq) Descriptor() ([]byte, []int)deprecated
- func (x *AddressGetReq) GetNet() string
- func (x *AddressGetReq) GetUid() string
- func (*AddressGetReq) ProtoMessage()
- func (x *AddressGetReq) ProtoReflect() protoreflect.Message
- func (x *AddressGetReq) Reset()
- func (x *AddressGetReq) String() string
- type AddressResp
- type Empty
- type UnimplementedAccountSrvServer
- type UnsafeAccountSrvServer
Constants ¶
This section is empty.
Variables ¶
var ( AccountType_name = map[int32]string{ 0: "AccountType_UnUsed", 1: "AccountType_Used", 2: "AccountType_Manager", } AccountType_value = map[string]int32{ "AccountType_UnUsed": 0, "AccountType_Used": 1, "AccountType_Manager": 2, } )
Enum value maps for AccountType.
var AccountSrv_ServiceDesc = grpc.ServiceDesc{ ServiceName: "Account.service.v1.AccountSrv", HandlerType: (*AccountSrvServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "AccountGet", Handler: _AccountSrv_AccountGet_Handler, }, { MethodName: "AddressGet", Handler: _AccountSrv_AddressGet_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "account.srv.proto", }
AccountSrv_ServiceDesc is the grpc.ServiceDesc for AccountSrv service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var File_account_srv_proto protoreflect.FileDescriptor
Functions ¶
func RegisterAccountSrvServer ¶
func RegisterAccountSrvServer(s grpc.ServiceRegistrar, srv AccountSrvServer)
Types ¶
type AccountGetReq ¶
type AccountGetReq struct { Currency string `protobuf:"bytes,1,opt,name=currency,proto3" json:"currency,omitempty"` // 币种 Uid string `protobuf:"bytes,2,opt,name=uid,proto3" json:"uid,omitempty"` // 用户唯一标识 IsAdmin bool `protobuf:"varint,3,opt,name=isAdmin,proto3" json:"isAdmin,omitempty"` // 是否渠道管理用户 Remarks string `protobuf:"bytes,4,opt,name=remarks,proto3" json:"remarks,omitempty"` // 备注 // contains filtered or unexported fields }
func (*AccountGetReq) Descriptor
deprecated
func (*AccountGetReq) Descriptor() ([]byte, []int)
Deprecated: Use AccountGetReq.ProtoReflect.Descriptor instead.
func (*AccountGetReq) GetCurrency ¶
func (x *AccountGetReq) GetCurrency() string
func (*AccountGetReq) GetIsAdmin ¶
func (x *AccountGetReq) GetIsAdmin() bool
func (*AccountGetReq) GetRemarks ¶
func (x *AccountGetReq) GetRemarks() string
func (*AccountGetReq) GetUid ¶
func (x *AccountGetReq) GetUid() string
func (*AccountGetReq) ProtoMessage ¶
func (*AccountGetReq) ProtoMessage()
func (*AccountGetReq) ProtoReflect ¶
func (x *AccountGetReq) ProtoReflect() protoreflect.Message
func (*AccountGetReq) Reset ¶
func (x *AccountGetReq) Reset()
func (*AccountGetReq) String ¶
func (x *AccountGetReq) String() string
type AccountSrvClient ¶
type AccountSrvClient interface { // 获取(创建)帐号 如果已经存在账户,则直接返回 AccountGet(ctx context.Context, in *AccountGetReq, opts ...grpc.CallOption) (*AddressResp, error) // 获取账户转账地址 AddressGet(ctx context.Context, in *AddressGetReq, opts ...grpc.CallOption) (*AddressResp, error) }
AccountSrvClient is the client API for AccountSrv 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 NewAccountSrvClient ¶
func NewAccountSrvClient(cc grpc.ClientConnInterface) AccountSrvClient
type AccountSrvServer ¶
type AccountSrvServer interface { // 获取(创建)帐号 如果已经存在账户,则直接返回 AccountGet(context.Context, *AccountGetReq) (*AddressResp, error) // 获取账户转账地址 AddressGet(context.Context, *AddressGetReq) (*AddressResp, error) // contains filtered or unexported methods }
AccountSrvServer is the server API for AccountSrv service. All implementations must embed UnimplementedAccountSrvServer for forward compatibility
type AccountType ¶
type AccountType int32
const ( AccountType_AccountType_UnUsed AccountType = 0 // 未使用 AccountType_AccountType_Used AccountType = 1 // 已使用 AccountType_AccountType_Manager AccountType = 2 // 渠道管理用户 )
func (AccountType) Descriptor ¶
func (AccountType) Descriptor() protoreflect.EnumDescriptor
func (AccountType) Enum ¶
func (x AccountType) Enum() *AccountType
func (AccountType) EnumDescriptor
deprecated
func (AccountType) EnumDescriptor() ([]byte, []int)
Deprecated: Use AccountType.Descriptor instead.
func (AccountType) Number ¶
func (x AccountType) Number() protoreflect.EnumNumber
func (AccountType) String ¶
func (x AccountType) String() string
func (AccountType) Type ¶
func (AccountType) Type() protoreflect.EnumType
type AddressGetReq ¶
type AddressGetReq struct { Uid string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid,omitempty"` // 用户唯一标识 Net string `protobuf:"bytes,2,opt,name=net,proto3" json:"net,omitempty"` // 网络名称 // contains filtered or unexported fields }
func (*AddressGetReq) Descriptor
deprecated
func (*AddressGetReq) Descriptor() ([]byte, []int)
Deprecated: Use AddressGetReq.ProtoReflect.Descriptor instead.
func (*AddressGetReq) GetNet ¶
func (x *AddressGetReq) GetNet() string
func (*AddressGetReq) GetUid ¶
func (x *AddressGetReq) GetUid() string
func (*AddressGetReq) ProtoMessage ¶
func (*AddressGetReq) ProtoMessage()
func (*AddressGetReq) ProtoReflect ¶
func (x *AddressGetReq) ProtoReflect() protoreflect.Message
func (*AddressGetReq) Reset ¶
func (x *AddressGetReq) Reset()
func (*AddressGetReq) String ¶
func (x *AddressGetReq) String() string
type AddressResp ¶
type AddressResp struct { Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` // 地址 // contains filtered or unexported fields }
func (*AddressResp) Descriptor
deprecated
func (*AddressResp) Descriptor() ([]byte, []int)
Deprecated: Use AddressResp.ProtoReflect.Descriptor instead.
func (*AddressResp) GetAddress ¶
func (x *AddressResp) GetAddress() string
func (*AddressResp) ProtoMessage ¶
func (*AddressResp) ProtoMessage()
func (*AddressResp) ProtoReflect ¶
func (x *AddressResp) ProtoReflect() protoreflect.Message
func (*AddressResp) Reset ¶
func (x *AddressResp) Reset()
func (*AddressResp) String ¶
func (x *AddressResp) String() string
type Empty ¶
type Empty struct {
// contains filtered or unexported fields
}
func (*Empty) Descriptor
deprecated
func (*Empty) ProtoMessage ¶
func (*Empty) ProtoMessage()
func (*Empty) ProtoReflect ¶
func (x *Empty) ProtoReflect() protoreflect.Message
type UnimplementedAccountSrvServer ¶
type UnimplementedAccountSrvServer struct { }
UnimplementedAccountSrvServer must be embedded to have forward compatible implementations.
func (UnimplementedAccountSrvServer) AccountGet ¶
func (UnimplementedAccountSrvServer) AccountGet(context.Context, *AccountGetReq) (*AddressResp, error)
func (UnimplementedAccountSrvServer) AddressGet ¶
func (UnimplementedAccountSrvServer) AddressGet(context.Context, *AddressGetReq) (*AddressResp, error)
type UnsafeAccountSrvServer ¶
type UnsafeAccountSrvServer interface {
// contains filtered or unexported methods
}
UnsafeAccountSrvServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to AccountSrvServer will result in compilation errors.