Documentation ¶
Index ¶
- func RegisterUserServer(s *grpc.Server, srv UserServer)
- type LoginReq
- func (*LoginReq) Descriptor() ([]byte, []int)
- func (m *LoginReq) GetPwd() string
- func (m *LoginReq) GetUsername() string
- func (*LoginReq) ProtoMessage()
- func (m *LoginReq) Reset()
- func (m *LoginReq) String() string
- func (m *LoginReq) XXX_DiscardUnknown()
- func (m *LoginReq) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (dst *LoginReq) XXX_Merge(src proto.Message)
- func (m *LoginReq) XXX_Size() int
- func (m *LoginReq) XXX_Unmarshal(b []byte) error
- type LoginRes
- func (*LoginRes) Descriptor() ([]byte, []int)
- func (m *LoginRes) GetCode() int64
- func (m *LoginRes) GetMsg() string
- func (*LoginRes) ProtoMessage()
- func (m *LoginRes) Reset()
- func (m *LoginRes) String() string
- func (m *LoginRes) XXX_DiscardUnknown()
- func (m *LoginRes) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (dst *LoginRes) XXX_Merge(src proto.Message)
- func (m *LoginRes) XXX_Size() int
- func (m *LoginRes) XXX_Unmarshal(b []byte) error
- type UserClient
- type UserServer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterUserServer ¶
func RegisterUserServer(s *grpc.Server, srv UserServer)
Types ¶
type LoginReq ¶
type LoginReq struct { Username string `protobuf:"bytes,1,opt,name=username,proto3" json:"username,omitempty"` Pwd string `protobuf:"bytes,2,opt,name=pwd,proto3" json:"pwd,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*LoginReq) Descriptor ¶
func (*LoginReq) GetUsername ¶
func (*LoginReq) ProtoMessage ¶
func (*LoginReq) ProtoMessage()
func (*LoginReq) XXX_DiscardUnknown ¶
func (m *LoginReq) XXX_DiscardUnknown()
func (*LoginReq) XXX_Marshal ¶
func (*LoginReq) XXX_Unmarshal ¶
type LoginRes ¶
type LoginRes struct { Code int64 `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty"` Msg string `protobuf:"bytes,2,opt,name=msg,proto3" json:"msg,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*LoginRes) Descriptor ¶
func (*LoginRes) ProtoMessage ¶
func (*LoginRes) ProtoMessage()
func (*LoginRes) XXX_DiscardUnknown ¶
func (m *LoginRes) XXX_DiscardUnknown()
func (*LoginRes) XXX_Marshal ¶
func (*LoginRes) XXX_Unmarshal ¶
type UserClient ¶
type UserClient interface {
Login(ctx context.Context, in *LoginReq, opts ...grpc.CallOption) (*LoginRes, error)
}
UserClient is the client API for User service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewUserClient ¶
func NewUserClient(cc *grpc.ClientConn) UserClient
Click to show internal directories.
Click to hide internal directories.