Documentation ¶
Index ¶
- func RegisterAuthServer(s *grpc.Server, srv AuthServer)
- type AuthClient
- type AuthServer
- type UserInfo
- func (*UserInfo) Descriptor() ([]byte, []int)
- func (m *UserInfo) GetCreatedAt() *timestamp.Timestamp
- func (m *UserInfo) GetUserId() uint64
- func (m *UserInfo) GetUsername() string
- func (*UserInfo) ProtoMessage()
- func (m *UserInfo) Reset()
- func (m *UserInfo) String() string
- func (m *UserInfo) XXX_DiscardUnknown()
- func (m *UserInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *UserInfo) XXX_Merge(src proto.Message)
- func (m *UserInfo) XXX_Size() int
- func (m *UserInfo) XXX_Unmarshal(b []byte) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterAuthServer ¶
func RegisterAuthServer(s *grpc.Server, srv AuthServer)
Types ¶
type AuthClient ¶
type AuthClient interface { // GetUserInfo принимает авторизованный токен, // и по нему возвращает информацию о пользователе. GetUserInfo(ctx context.Context, in *empty.Empty, opts ...grpc.CallOption) (*UserInfo, error) }
AuthClient is the client API for Auth service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewAuthClient ¶
func NewAuthClient(cc *grpc.ClientConn) AuthClient
type AuthServer ¶
type AuthServer interface { // GetUserInfo принимает авторизованный токен, // и по нему возвращает информацию о пользователе. GetUserInfo(context.Context, *empty.Empty) (*UserInfo, error) }
AuthServer is the server API for Auth service.
type UserInfo ¶
type UserInfo struct { UserId uint64 `protobuf:"varint,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"` Username string `protobuf:"bytes,2,opt,name=username,proto3" json:"username,omitempty"` CreatedAt *timestamp.Timestamp `protobuf:"bytes,3,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*UserInfo) Descriptor ¶
func (*UserInfo) GetCreatedAt ¶
func (*UserInfo) GetUsername ¶
func (*UserInfo) ProtoMessage ¶
func (*UserInfo) ProtoMessage()
func (*UserInfo) XXX_DiscardUnknown ¶
func (m *UserInfo) XXX_DiscardUnknown()
func (*UserInfo) XXX_Marshal ¶
func (*UserInfo) XXX_Unmarshal ¶
Click to show internal directories.
Click to hide internal directories.