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 File_publist_proto protoreflect.FileDescriptor
View Source
var Publish_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "douyin.core.publist.publish",
	HandlerType: (*PublishServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "publish_video",
			Handler:    _Publish_PublishVideo_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "publist.proto",
}

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

Functions

func RegisterPublishServer

func RegisterPublishServer(s grpc.ServiceRegistrar, srv PublishServer)

Types

type DouyinPublishListRequest

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

func (*DouyinPublishListRequest) Descriptor deprecated

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

Deprecated: Use DouyinPublishListRequest.ProtoReflect.Descriptor instead.

func (*DouyinPublishListRequest) GetToken

func (x *DouyinPublishListRequest) GetToken() string

func (*DouyinPublishListRequest) GetUserId

func (x *DouyinPublishListRequest) GetUserId() int64

func (*DouyinPublishListRequest) ProtoMessage

func (*DouyinPublishListRequest) ProtoMessage()

func (*DouyinPublishListRequest) ProtoReflect

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

func (*DouyinPublishListRequest) Reset

func (x *DouyinPublishListRequest) Reset()

func (*DouyinPublishListRequest) String

func (x *DouyinPublishListRequest) String() string

type DouyinPublishListResponse

type DouyinPublishListResponse 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"`
	//用户发布的视频列表
	VideoList []*Video `protobuf:"bytes,3,rep,name=video_list,json=videoList" json:"video_list,omitempty"`
	// contains filtered or unexported fields
}

func (*DouyinPublishListResponse) Descriptor deprecated

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

Deprecated: Use DouyinPublishListResponse.ProtoReflect.Descriptor instead.

func (*DouyinPublishListResponse) GetStatusCode

func (x *DouyinPublishListResponse) GetStatusCode() int32

func (*DouyinPublishListResponse) GetStatusMsg

func (x *DouyinPublishListResponse) GetStatusMsg() string

func (*DouyinPublishListResponse) GetVideoList

func (x *DouyinPublishListResponse) GetVideoList() []*Video

func (*DouyinPublishListResponse) ProtoMessage

func (*DouyinPublishListResponse) ProtoMessage()

func (*DouyinPublishListResponse) ProtoReflect

func (*DouyinPublishListResponse) Reset

func (x *DouyinPublishListResponse) Reset()

func (*DouyinPublishListResponse) String

func (x *DouyinPublishListResponse) String() string

type PublishClient

type PublishClient interface {
	PublishVideo(ctx context.Context, in *DouyinPublishListRequest, opts ...grpc.CallOption) (*DouyinPublishListResponse, error)
}

PublishClient is the client API for Publish 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 NewPublishClient

func NewPublishClient(cc grpc.ClientConnInterface) PublishClient

type PublishServer

type PublishServer interface {
	PublishVideo(context.Context, *DouyinPublishListRequest) (*DouyinPublishListResponse, error)
	// contains filtered or unexported methods
}

PublishServer is the server API for Publish service. All implementations must embed UnimplementedPublishServer for forward compatibility

type UnimplementedPublishServer

type UnimplementedPublishServer struct {
}

UnimplementedPublishServer must be embedded to have forward compatible implementations.

type UnsafePublishServer

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

UnsafePublishServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to PublishServer 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 Video

type Video struct {

	//视频唯─标识
	Id *int64 `protobuf:"varint,1,req,name=id" json:"id,omitempty"`
	//视频作者信息
	Author *User `protobuf:"bytes,2,req,name=author" json:"author,omitempty"`
	//视频播放地址
	PlayUrl *string `protobuf:"bytes,3,req,name=play_url,json=playUrl" json:"play_url,omitempty"`
	//视频封面地址
	CoverUrl *string `protobuf:"bytes,4,req,name=cover_url,json=coverUrl" json:"cover_url,omitempty"`
	//视频的点赞总数
	FavoriteCount *int64 `protobuf:"varint,5,req,name=favorite_count,json=favoriteCount" json:"favorite_count,omitempty"`
	//视频的评论总数
	CommentCount *int64 `protobuf:"varint,6,req,name=comment_count,json=commentCount" json:"comment_count,omitempty"`
	//true-已点赞,faLse-未点赞
	IsFavorite *bool `protobuf:"varint,7,req,name=is_favorite,json=isFavorite" json:"is_favorite,omitempty"`
	//视频标题
	Title *string `protobuf:"bytes,8,req,name=title" json:"title,omitempty"`
	// contains filtered or unexported fields
}

func (*Video) Descriptor deprecated

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

Deprecated: Use Video.ProtoReflect.Descriptor instead.

func (*Video) GetAuthor

func (x *Video) GetAuthor() *User

func (*Video) GetCommentCount

func (x *Video) GetCommentCount() int64

func (*Video) GetCoverUrl

func (x *Video) GetCoverUrl() string

func (*Video) GetFavoriteCount

func (x *Video) GetFavoriteCount() int64

func (*Video) GetId

func (x *Video) GetId() int64

func (*Video) GetIsFavorite

func (x *Video) GetIsFavorite() bool

func (*Video) GetPlayUrl

func (x *Video) GetPlayUrl() string

func (*Video) GetTitle

func (x *Video) GetTitle() string

func (*Video) ProtoMessage

func (*Video) ProtoMessage()

func (*Video) ProtoReflect

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

func (*Video) Reset

func (x *Video) Reset()

func (*Video) String

func (x *Video) String() string

Jump to

Keyboard shortcuts

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