pb

package
v0.0.0-...-f1d9293 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 10, 2022 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var UserInf_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "douyin.core.userinf.UserInf",
	HandlerType: (*UserInfServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "GetUserinf",
			Handler:    _UserInf_GetUserinf_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "user.proto",
}

UserInf_ServiceDesc is the grpc.ServiceDesc for UserInf service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterUserInfServer

func RegisterUserInfServer(s grpc.ServiceRegistrar, srv UserInfServer)

Types

type DouyinUserRequest

type DouyinUserRequest struct {

	//用户id
	UserId *int64 `protobuf:"varint,1,req,name=user_id,json=userId" json:"user_id,omitempty"`
	//用户鉴权token
	Token *string `protobuf:"bytes,2,req,name=token" json:"token,omitempty"`
	// contains filtered or unexported fields
}

func (*DouyinUserRequest) Descriptor deprecated

func (*DouyinUserRequest) Descriptor() ([]byte, []int)

Deprecated: Use DouyinUserRequest.ProtoReflect.Descriptor instead.

func (*DouyinUserRequest) GetToken

func (x *DouyinUserRequest) GetToken() string

func (*DouyinUserRequest) GetUserId

func (x *DouyinUserRequest) GetUserId() int64

func (*DouyinUserRequest) ProtoMessage

func (*DouyinUserRequest) ProtoMessage()

func (*DouyinUserRequest) ProtoReflect

func (x *DouyinUserRequest) ProtoReflect() protoreflect.Message

func (*DouyinUserRequest) Reset

func (x *DouyinUserRequest) Reset()

func (*DouyinUserRequest) String

func (x *DouyinUserRequest) String() string

type DouyinUserResponse

type DouyinUserResponse struct {

	//状态码,0-成功,其他值-失败
	StatusCode *int32 `protobuf:"varint,1,req,name=status_code,json=statusCode" json:"status_code,omitempty"`
	//返回状态描述
	StatusMsg *string `protobuf:"bytes,2,opt,name=status_msg,json=statusMsg" json:"status_msg,omitempty"`
	//用户信息
	User *User `protobuf:"bytes,3,req,name=user" json:"user,omitempty"`
	// contains filtered or unexported fields
}

func (*DouyinUserResponse) Descriptor deprecated

func (*DouyinUserResponse) Descriptor() ([]byte, []int)

Deprecated: Use DouyinUserResponse.ProtoReflect.Descriptor instead.

func (*DouyinUserResponse) GetStatusCode

func (x *DouyinUserResponse) GetStatusCode() int32

func (*DouyinUserResponse) GetStatusMsg

func (x *DouyinUserResponse) GetStatusMsg() string

func (*DouyinUserResponse) GetUser

func (x *DouyinUserResponse) GetUser() *User

func (*DouyinUserResponse) ProtoMessage

func (*DouyinUserResponse) ProtoMessage()

func (*DouyinUserResponse) ProtoReflect

func (x *DouyinUserResponse) ProtoReflect() protoreflect.Message

func (*DouyinUserResponse) Reset

func (x *DouyinUserResponse) Reset()

func (*DouyinUserResponse) String

func (x *DouyinUserResponse) String() string

type UnimplementedUserInfServer

type UnimplementedUserInfServer struct {
}

UnimplementedUserInfServer must be embedded to have forward compatible implementations.

func (UnimplementedUserInfServer) GetUserinf

type UnsafeUserInfServer

type UnsafeUserInfServer interface {
	// contains filtered or unexported methods
}

UnsafeUserInfServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to UserInfServer will result in compilation errors.

type User

type User struct {

	//用户id
	Id *int64 `protobuf:"varint,1,req,name=id" json:"id,omitempty"`
	//用户名称
	Name *string `protobuf:"bytes,2,req,name=name" json:"name,omitempty"`
	//关注总数
	FollowCount *int64 `protobuf:"varint,3,opt,name=follow_count,json=followCount" json:"follow_count,omitempty"`
	//粉丝总数
	FollowerCount *int64 `protobuf:"varint,4,opt,name=follower_count,json=followerCount" json:"follower_count,omitempty"`
	//true-已关注,false-未关注
	IsFollow *bool `protobuf:"varint,5,req,name=is_follow,json=isFollow" json:"is_follow,omitempty"`
	// contains filtered or unexported fields
}

func (*User) Descriptor deprecated

func (*User) Descriptor() ([]byte, []int)

Deprecated: Use User.ProtoReflect.Descriptor instead.

func (*User) GetFollowCount

func (x *User) GetFollowCount() int64

func (*User) GetFollowerCount

func (x *User) GetFollowerCount() int64

func (*User) GetId

func (x *User) GetId() int64

func (*User) GetIsFollow

func (x *User) GetIsFollow() bool

func (*User) GetName

func (x *User) GetName() string

func (*User) ProtoMessage

func (*User) ProtoMessage()

func (*User) ProtoReflect

func (x *User) ProtoReflect() protoreflect.Message

func (*User) Reset

func (x *User) Reset()

func (*User) String

func (x *User) String() string

type UserInfClient

type UserInfClient interface {
	GetUserinf(ctx context.Context, in *DouyinUserRequest, opts ...grpc.CallOption) (*DouyinUserResponse, error)
}

UserInfClient is the client API for UserInf service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.golang.ir/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

func NewUserInfClient

func NewUserInfClient(cc grpc.ClientConnInterface) UserInfClient

type UserInfServer

type UserInfServer interface {
	GetUserinf(context.Context, *DouyinUserRequest) (*DouyinUserResponse, error)
	// contains filtered or unexported methods
}

UserInfServer is the server API for UserInf service. All implementations must embed UnimplementedUserInfServer for forward compatibility

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL