v1

package
v0.0.0-...-5c4e16d Latest Latest
Warning

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

Go to latest
Published: Aug 23, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Post_DEL_FLAG_name = map[int32]string{
		0: "DEL_FLAG_UNSPECIFIED",
		1: "DEL_FLAG_NORMAL",
		2: "DEL_FLAG_USER",
		3: "DEL_FLAG_ADMIN",
	}
	Post_DEL_FLAG_value = map[string]int32{
		"DEL_FLAG_UNSPECIFIED": 0,
		"DEL_FLAG_NORMAL":      1,
		"DEL_FLAG_USER":        2,
		"DEL_FLAG_ADMIN":       3,
	}
)

Enum value maps for Post_DEL_FLAG.

View Source
var (
	Post_VISIBLE_name = map[int32]string{
		0: "VISIBLE_UNSPECIFIED",
		1: "VISIBLE_ALL",
		2: "VISIBLE_SELF",
	}
	Post_VISIBLE_value = map[string]int32{
		"VISIBLE_UNSPECIFIED": 0,
		"VISIBLE_ALL":         1,
		"VISIBLE_SELF":        2,
	}
)

Enum value maps for Post_VISIBLE.

View Source
var CommentService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "api.moment.v1.CommentService",
	HandlerType: (*CommentServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "CreateComment",
			Handler:    _CommentService_CreateComment_Handler,
		},
		{
			MethodName: "UpdateComment",
			Handler:    _CommentService_UpdateComment_Handler,
		},
		{
			MethodName: "DeleteComment",
			Handler:    _CommentService_DeleteComment_Handler,
		},
		{
			MethodName: "ReplyComment",
			Handler:    _CommentService_ReplyComment_Handler,
		},
		{
			MethodName: "GetComment",
			Handler:    _CommentService_GetComment_Handler,
		},
		{
			MethodName: "BatchGetComments",
			Handler:    _CommentService_BatchGetComments_Handler,
		},
		{
			MethodName: "ListHotComments",
			Handler:    _CommentService_ListHotComments_Handler,
		},
		{
			MethodName: "ListLatestComments",
			Handler:    _CommentService_ListLatestComments_Handler,
		},
		{
			MethodName: "ListReplyComments",
			Handler:    _CommentService_ListReplyComments_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "api/moment/v1/comment.proto",
}

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

View Source
var File_api_moment_v1_comment_proto protoreflect.FileDescriptor
View Source
var File_api_moment_v1_like_proto protoreflect.FileDescriptor
View Source
var File_api_moment_v1_post_proto protoreflect.FileDescriptor
View Source
var LikeService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "api.moment.v1.LikeService",
	HandlerType: (*LikeServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "CreateLike",
			Handler:    _LikeService_CreateLike_Handler,
		},
		{
			MethodName: "UpdateLike",
			Handler:    _LikeService_UpdateLike_Handler,
		},
		{
			MethodName: "DeleteLike",
			Handler:    _LikeService_DeleteLike_Handler,
		},
		{
			MethodName: "GetLike",
			Handler:    _LikeService_GetLike_Handler,
		},
		{
			MethodName: "BatchGetLikes",
			Handler:    _LikeService_BatchGetLikes_Handler,
		},
		{
			MethodName: "ListPostLikes",
			Handler:    _LikeService_ListPostLikes_Handler,
		},
		{
			MethodName: "ListCommentsLike",
			Handler:    _LikeService_ListCommentsLike_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "api/moment/v1/like.proto",
}

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

View Source
var PostService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "api.moment.v1.PostService",
	HandlerType: (*PostServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "CreatePost",
			Handler:    _PostService_CreatePost_Handler,
		},
		{
			MethodName: "UpdatePost",
			Handler:    _PostService_UpdatePost_Handler,
		},
		{
			MethodName: "DeletePost",
			Handler:    _PostService_DeletePost_Handler,
		},
		{
			MethodName: "GetPost",
			Handler:    _PostService_GetPost_Handler,
		},
		{
			MethodName: "BatchGetPosts",
			Handler:    _PostService_BatchGetPosts_Handler,
		},
		{
			MethodName: "ListMyPost",
			Handler:    _PostService_ListMyPost_Handler,
		},
		{
			MethodName: "ListLatestPost",
			Handler:    _PostService_ListLatestPost_Handler,
		},
		{
			MethodName: "ListHotPost",
			Handler:    _PostService_ListHotPost_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "api/moment/v1/post.proto",
}

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

Functions

func RegisterCommentServiceServer

func RegisterCommentServiceServer(s grpc.ServiceRegistrar, srv CommentServiceServer)

func RegisterLikeServiceServer

func RegisterLikeServiceServer(s grpc.ServiceRegistrar, srv LikeServiceServer)

func RegisterPostServiceServer

func RegisterPostServiceServer(s grpc.ServiceRegistrar, srv PostServiceServer)

Types

type BatchGetCommentsReply

type BatchGetCommentsReply struct {
	Comments []*Comment `protobuf:"bytes,1,rep,name=comments,proto3" json:"comments,omitempty"`
	// contains filtered or unexported fields
}

func (*BatchGetCommentsReply) Descriptor deprecated

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

Deprecated: Use BatchGetCommentsReply.ProtoReflect.Descriptor instead.

func (*BatchGetCommentsReply) GetComments

func (x *BatchGetCommentsReply) GetComments() []*Comment

func (*BatchGetCommentsReply) ProtoMessage

func (*BatchGetCommentsReply) ProtoMessage()

func (*BatchGetCommentsReply) ProtoReflect

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

func (*BatchGetCommentsReply) Reset

func (x *BatchGetCommentsReply) Reset()

func (*BatchGetCommentsReply) String

func (x *BatchGetCommentsReply) String() string

type BatchGetCommentsRequest

type BatchGetCommentsRequest struct {
	Ids []int64 `protobuf:"varint,1,rep,packed,name=ids,proto3" json:"ids,omitempty"`
	// contains filtered or unexported fields
}

func (*BatchGetCommentsRequest) Descriptor deprecated

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

Deprecated: Use BatchGetCommentsRequest.ProtoReflect.Descriptor instead.

func (*BatchGetCommentsRequest) GetIds

func (x *BatchGetCommentsRequest) GetIds() []int64

func (*BatchGetCommentsRequest) ProtoMessage

func (*BatchGetCommentsRequest) ProtoMessage()

func (*BatchGetCommentsRequest) ProtoReflect

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

func (*BatchGetCommentsRequest) Reset

func (x *BatchGetCommentsRequest) Reset()

func (*BatchGetCommentsRequest) String

func (x *BatchGetCommentsRequest) String() string

type BatchGetLikesReply

type BatchGetLikesReply struct {

	// 返回的data, map 结构
	Data map[int64]int32 `` /* 151-byte string literal not displayed */
	// contains filtered or unexported fields
}

批量获取点赞响应

func (*BatchGetLikesReply) Descriptor deprecated

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

Deprecated: Use BatchGetLikesReply.ProtoReflect.Descriptor instead.

func (*BatchGetLikesReply) GetData

func (x *BatchGetLikesReply) GetData() map[int64]int32

func (*BatchGetLikesReply) ProtoMessage

func (*BatchGetLikesReply) ProtoMessage()

func (*BatchGetLikesReply) ProtoReflect

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

func (*BatchGetLikesReply) Reset

func (x *BatchGetLikesReply) Reset()

func (*BatchGetLikesReply) String

func (x *BatchGetLikesReply) String() string

type BatchGetLikesRequest

type BatchGetLikesRequest struct {
	UserId  int64   `protobuf:"varint,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"`
	ObjType int32   `protobuf:"varint,2,opt,name=obj_type,json=objType,proto3" json:"obj_type,omitempty"`
	ObjIds  []int64 `protobuf:"varint,3,rep,packed,name=obj_ids,json=objIds,proto3" json:"obj_ids,omitempty"`
	// contains filtered or unexported fields
}

批量获取点赞请求参数

func (*BatchGetLikesRequest) Descriptor deprecated

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

Deprecated: Use BatchGetLikesRequest.ProtoReflect.Descriptor instead.

func (*BatchGetLikesRequest) GetObjIds

func (x *BatchGetLikesRequest) GetObjIds() []int64

func (*BatchGetLikesRequest) GetObjType

func (x *BatchGetLikesRequest) GetObjType() int32

func (*BatchGetLikesRequest) GetUserId

func (x *BatchGetLikesRequest) GetUserId() int64

func (*BatchGetLikesRequest) ProtoMessage

func (*BatchGetLikesRequest) ProtoMessage()

func (*BatchGetLikesRequest) ProtoReflect

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

func (*BatchGetLikesRequest) Reset

func (x *BatchGetLikesRequest) Reset()

func (*BatchGetLikesRequest) String

func (x *BatchGetLikesRequest) String() string

type BatchGetPostsReply

type BatchGetPostsReply struct {

	// 多个帖子信息
	Posts []*Post `protobuf:"bytes,1,rep,name=posts,proto3" json:"posts,omitempty"`
	// contains filtered or unexported fields
}

返回帖子信息

func (*BatchGetPostsReply) Descriptor deprecated

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

Deprecated: Use BatchGetPostsReply.ProtoReflect.Descriptor instead.

func (*BatchGetPostsReply) GetPosts

func (x *BatchGetPostsReply) GetPosts() []*Post

func (*BatchGetPostsReply) ProtoMessage

func (*BatchGetPostsReply) ProtoMessage()

func (*BatchGetPostsReply) ProtoReflect

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

func (*BatchGetPostsReply) Reset

func (x *BatchGetPostsReply) Reset()

func (*BatchGetPostsReply) String

func (x *BatchGetPostsReply) String() string

type BatchGetPostsRequest

type BatchGetPostsRequest struct {

	// 帖子id, 多个用逗号分隔
	Ids []int64 `protobuf:"varint,1,rep,packed,name=ids,proto3" json:"ids,omitempty"`
	// contains filtered or unexported fields
}

批量获取帖子

func (*BatchGetPostsRequest) Descriptor deprecated

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

Deprecated: Use BatchGetPostsRequest.ProtoReflect.Descriptor instead.

func (*BatchGetPostsRequest) GetIds

func (x *BatchGetPostsRequest) GetIds() []int64

func (*BatchGetPostsRequest) ProtoMessage

func (*BatchGetPostsRequest) ProtoMessage()

func (*BatchGetPostsRequest) ProtoReflect

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

func (*BatchGetPostsRequest) Reset

func (x *BatchGetPostsRequest) Reset()

func (*BatchGetPostsRequest) String

func (x *BatchGetPostsRequest) String() string

type Comment

type Comment struct {
	Id         int64  `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	PostId     int64  `protobuf:"varint,2,opt,name=post_id,json=postId,proto3" json:"post_id,omitempty"`
	UserId     int64  `protobuf:"varint,3,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"`
	Content    string `protobuf:"bytes,4,opt,name=content,proto3" json:"content,omitempty"`
	RootId     int64  `protobuf:"varint,5,opt,name=root_id,json=rootId,proto3" json:"root_id,omitempty"`
	ParentId   int64  `protobuf:"varint,6,opt,name=parent_id,json=parentId,proto3" json:"parent_id,omitempty"`
	LikeCount  int32  `protobuf:"varint,7,opt,name=like_count,json=likeCount,proto3" json:"like_count,omitempty"`
	ReplyCount int32  `protobuf:"varint,8,opt,name=reply_count,json=replyCount,proto3" json:"reply_count,omitempty"`
	Score      int64  `protobuf:"varint,9,opt,name=score,proto3" json:"score,omitempty"`
	DelFlag    int32  `protobuf:"varint,10,opt,name=del_flag,json=delFlag,proto3" json:"del_flag,omitempty"`
	CreatedAt  string `protobuf:"bytes,11,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"`
	UpdatedAt  string `protobuf:"bytes,12,opt,name=updated_at,json=updatedAt,proto3" json:"updated_at,omitempty"`
	DeviceType string `protobuf:"bytes,13,opt,name=device_type,json=deviceType,proto3" json:"device_type,omitempty"`
	Ip         string `protobuf:"bytes,14,opt,name=ip,proto3" json:"ip,omitempty"`
	// contains filtered or unexported fields
}

func (*Comment) Descriptor deprecated

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

Deprecated: Use Comment.ProtoReflect.Descriptor instead.

func (*Comment) GetContent

func (x *Comment) GetContent() string

func (*Comment) GetCreatedAt

func (x *Comment) GetCreatedAt() string

func (*Comment) GetDelFlag

func (x *Comment) GetDelFlag() int32

func (*Comment) GetDeviceType

func (x *Comment) GetDeviceType() string

func (*Comment) GetId

func (x *Comment) GetId() int64

func (*Comment) GetIp

func (x *Comment) GetIp() string

func (*Comment) GetLikeCount

func (x *Comment) GetLikeCount() int32

func (*Comment) GetParentId

func (x *Comment) GetParentId() int64

func (*Comment) GetPostId

func (x *Comment) GetPostId() int64

func (*Comment) GetReplyCount

func (x *Comment) GetReplyCount() int32

func (*Comment) GetRootId

func (x *Comment) GetRootId() int64

func (*Comment) GetScore

func (x *Comment) GetScore() int64

func (*Comment) GetUpdatedAt

func (x *Comment) GetUpdatedAt() string

func (*Comment) GetUserId

func (x *Comment) GetUserId() int64

func (*Comment) ProtoMessage

func (*Comment) ProtoMessage()

func (*Comment) ProtoReflect

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

func (*Comment) Reset

func (x *Comment) Reset()

func (*Comment) String

func (x *Comment) String() string

type CommentServiceClient

type CommentServiceClient interface {
	// 发布评论
	CreateComment(ctx context.Context, in *CreateCommentRequest, opts ...grpc.CallOption) (*CreateCommentReply, error)
	// 更新评论
	UpdateComment(ctx context.Context, in *UpdateCommentRequest, opts ...grpc.CallOption) (*UpdateCommentReply, error)
	// 删除评论
	DeleteComment(ctx context.Context, in *DeleteCommentRequest, opts ...grpc.CallOption) (*DeleteCommentReply, error)
	// 回复评论
	ReplyComment(ctx context.Context, in *ReplyCommentRequest, opts ...grpc.CallOption) (*ReplyCommentReply, error)
	// 获取评论
	GetComment(ctx context.Context, in *GetCommentRequest, opts ...grpc.CallOption) (*GetCommentReply, error)
	// 批量获取评论
	BatchGetComments(ctx context.Context, in *BatchGetCommentsRequest, opts ...grpc.CallOption) (*BatchGetCommentsReply, error)
	// 热门评论列表
	ListHotComments(ctx context.Context, in *ListCommentsRequest, opts ...grpc.CallOption) (*ListCommentsReply, error)
	// 最新评论列表
	ListLatestComments(ctx context.Context, in *ListCommentsRequest, opts ...grpc.CallOption) (*ListCommentsReply, error)
	// 评论回复列表
	ListReplyComments(ctx context.Context, in *ListReplyCommentsRequest, opts ...grpc.CallOption) (*ListReplyCommentsReply, error)
}

CommentServiceClient is the client API for CommentService 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.

type CommentServiceServer

type CommentServiceServer interface {
	// 发布评论
	CreateComment(context.Context, *CreateCommentRequest) (*CreateCommentReply, error)
	// 更新评论
	UpdateComment(context.Context, *UpdateCommentRequest) (*UpdateCommentReply, error)
	// 删除评论
	DeleteComment(context.Context, *DeleteCommentRequest) (*DeleteCommentReply, error)
	// 回复评论
	ReplyComment(context.Context, *ReplyCommentRequest) (*ReplyCommentReply, error)
	// 获取评论
	GetComment(context.Context, *GetCommentRequest) (*GetCommentReply, error)
	// 批量获取评论
	BatchGetComments(context.Context, *BatchGetCommentsRequest) (*BatchGetCommentsReply, error)
	// 热门评论列表
	ListHotComments(context.Context, *ListCommentsRequest) (*ListCommentsReply, error)
	// 最新评论列表
	ListLatestComments(context.Context, *ListCommentsRequest) (*ListCommentsReply, error)
	// 评论回复列表
	ListReplyComments(context.Context, *ListReplyCommentsRequest) (*ListReplyCommentsReply, error)
	// contains filtered or unexported methods
}

CommentServiceServer is the server API for CommentService service. All implementations must embed UnimplementedCommentServiceServer for forward compatibility

type Content

type Content struct {
	Text   string       `protobuf:"bytes,1,opt,name=text,proto3" json:"text,omitempty"`
	Images []*PostImage `protobuf:"bytes,2,rep,name=images,proto3" json:"images,omitempty"` // image content
	Video  *Video       `protobuf:"bytes,3,opt,name=video,proto3" json:"video,omitempty"`   // video content
	// contains filtered or unexported fields
}

帖子内容结构

func (*Content) Descriptor deprecated

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

Deprecated: Use Content.ProtoReflect.Descriptor instead.

func (*Content) GetImages

func (x *Content) GetImages() []*PostImage

func (*Content) GetText

func (x *Content) GetText() string

func (*Content) GetVideo

func (x *Content) GetVideo() *Video

func (*Content) ProtoMessage

func (*Content) ProtoMessage()

func (*Content) ProtoReflect

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

func (*Content) Reset

func (x *Content) Reset()

func (*Content) String

func (x *Content) String() string

type CreateCommentReply

type CreateCommentReply struct {
	Comment *Comment `protobuf:"bytes,1,opt,name=comment,proto3" json:"comment,omitempty"`
	// contains filtered or unexported fields
}

func (*CreateCommentReply) Descriptor deprecated

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

Deprecated: Use CreateCommentReply.ProtoReflect.Descriptor instead.

func (*CreateCommentReply) GetComment

func (x *CreateCommentReply) GetComment() *Comment

func (*CreateCommentReply) ProtoMessage

func (*CreateCommentReply) ProtoMessage()

func (*CreateCommentReply) ProtoReflect

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

func (*CreateCommentReply) Reset

func (x *CreateCommentReply) Reset()

func (*CreateCommentReply) String

func (x *CreateCommentReply) String() string

type CreateCommentRequest

type CreateCommentRequest struct {
	PostId     int64  `protobuf:"varint,1,opt,name=post_id,json=postId,proto3" json:"post_id,omitempty"`
	UserId     int64  `protobuf:"varint,2,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"`
	Content    string `protobuf:"bytes,3,opt,name=content,proto3" json:"content,omitempty"`
	RootId     int64  `protobuf:"varint,4,opt,name=root_id,json=rootId,proto3" json:"root_id,omitempty"`
	ParentId   int64  `protobuf:"varint,5,opt,name=parent_id,json=parentId,proto3" json:"parent_id,omitempty"`
	DeviceType string `protobuf:"bytes,6,opt,name=device_type,json=deviceType,proto3" json:"device_type,omitempty"`
	Ip         string `protobuf:"bytes,7,opt,name=ip,proto3" json:"ip,omitempty"`
	// contains filtered or unexported fields
}

func (*CreateCommentRequest) Descriptor deprecated

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

Deprecated: Use CreateCommentRequest.ProtoReflect.Descriptor instead.

func (*CreateCommentRequest) GetContent

func (x *CreateCommentRequest) GetContent() string

func (*CreateCommentRequest) GetDeviceType

func (x *CreateCommentRequest) GetDeviceType() string

func (*CreateCommentRequest) GetIp

func (x *CreateCommentRequest) GetIp() string

func (*CreateCommentRequest) GetParentId

func (x *CreateCommentRequest) GetParentId() int64

func (*CreateCommentRequest) GetPostId

func (x *CreateCommentRequest) GetPostId() int64

func (*CreateCommentRequest) GetRootId

func (x *CreateCommentRequest) GetRootId() int64

func (*CreateCommentRequest) GetUserId

func (x *CreateCommentRequest) GetUserId() int64

func (*CreateCommentRequest) ProtoMessage

func (*CreateCommentRequest) ProtoMessage()

func (*CreateCommentRequest) ProtoReflect

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

func (*CreateCommentRequest) Reset

func (x *CreateCommentRequest) Reset()

func (*CreateCommentRequest) String

func (x *CreateCommentRequest) String() string

type CreateLikeReply

type CreateLikeReply struct {
	// contains filtered or unexported fields
}

func (*CreateLikeReply) Descriptor deprecated

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

Deprecated: Use CreateLikeReply.ProtoReflect.Descriptor instead.

func (*CreateLikeReply) ProtoMessage

func (*CreateLikeReply) ProtoMessage()

func (*CreateLikeReply) ProtoReflect

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

func (*CreateLikeReply) Reset

func (x *CreateLikeReply) Reset()

func (*CreateLikeReply) String

func (x *CreateLikeReply) String() string

type CreateLikeRequest

type CreateLikeRequest struct {
	UserId  int64 `protobuf:"varint,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"`
	ObjType int32 `protobuf:"varint,2,opt,name=obj_type,json=objType,proto3" json:"obj_type,omitempty"`
	ObjId   int64 `protobuf:"varint,3,opt,name=obj_id,json=objId,proto3" json:"obj_id,omitempty"`
	// contains filtered or unexported fields
}

创建点赞请求

func (*CreateLikeRequest) Descriptor deprecated

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

Deprecated: Use CreateLikeRequest.ProtoReflect.Descriptor instead.

func (*CreateLikeRequest) GetObjId

func (x *CreateLikeRequest) GetObjId() int64

func (*CreateLikeRequest) GetObjType

func (x *CreateLikeRequest) GetObjType() int32

func (*CreateLikeRequest) GetUserId

func (x *CreateLikeRequest) GetUserId() int64

func (*CreateLikeRequest) ProtoMessage

func (*CreateLikeRequest) ProtoMessage()

func (*CreateLikeRequest) ProtoReflect

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

func (*CreateLikeRequest) Reset

func (x *CreateLikeRequest) Reset()

func (*CreateLikeRequest) String

func (x *CreateLikeRequest) String() string

type CreatePostReply

type CreatePostReply struct {

	// 返回帖子信息
	Post *Post `protobuf:"bytes,1,opt,name=post,proto3" json:"post,omitempty"`
	// contains filtered or unexported fields
}

发布帖子返回结构

func (*CreatePostReply) Descriptor deprecated

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

Deprecated: Use CreatePostReply.ProtoReflect.Descriptor instead.

func (*CreatePostReply) GetPost

func (x *CreatePostReply) GetPost() *Post

func (*CreatePostReply) ProtoMessage

func (*CreatePostReply) ProtoMessage()

func (*CreatePostReply) ProtoReflect

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

func (*CreatePostReply) Reset

func (x *CreatePostReply) Reset()

func (*CreatePostReply) String

func (x *CreatePostReply) String() string

type CreatePostRequest

type CreatePostRequest struct {

	// 用户uid
	UserId int64 `protobuf:"varint,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"`
	// 帖子标题
	Title string `protobuf:"bytes,2,opt,name=title,proto3" json:"title,omitempty"`
	// 帖子内容
	Text string `protobuf:"bytes,3,opt,name=text,proto3" json:"text,omitempty"`
	// 帖子图片,多个传入数组,
	// json格式:[{"image_key":"/abc/a.jpg","image_type":"jpg","width":200,"height":200}]
	Images []*PostImage `protobuf:"bytes,4,rep,name=images,proto3" json:"images,omitempty"`
	// 视频信息
	Video *Video `protobuf:"bytes,5,opt,name=video,proto3" json:"video,omitempty"`
	// 发帖人位置
	Position string `protobuf:"bytes,6,opt,name=position,proto3" json:"position,omitempty"`
	// 发帖时的经度
	Longitude float32 `protobuf:"fixed32,7,opt,name=longitude,proto3" json:"longitude,omitempty"`
	// 发帖时的纬度
	Latitude float32 `protobuf:"fixed32,8,opt,name=latitude,proto3" json:"latitude,omitempty"`
	// contains filtered or unexported fields
}

发布帖子

func (*CreatePostRequest) Descriptor deprecated

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

Deprecated: Use CreatePostRequest.ProtoReflect.Descriptor instead.

func (*CreatePostRequest) GetImages

func (x *CreatePostRequest) GetImages() []*PostImage

func (*CreatePostRequest) GetLatitude

func (x *CreatePostRequest) GetLatitude() float32

func (*CreatePostRequest) GetLongitude

func (x *CreatePostRequest) GetLongitude() float32

func (*CreatePostRequest) GetPosition

func (x *CreatePostRequest) GetPosition() string

func (*CreatePostRequest) GetText

func (x *CreatePostRequest) GetText() string

func (*CreatePostRequest) GetTitle

func (x *CreatePostRequest) GetTitle() string

func (*CreatePostRequest) GetUserId

func (x *CreatePostRequest) GetUserId() int64

func (*CreatePostRequest) GetVideo

func (x *CreatePostRequest) GetVideo() *Video

func (*CreatePostRequest) ProtoMessage

func (*CreatePostRequest) ProtoMessage()

func (*CreatePostRequest) ProtoReflect

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

func (*CreatePostRequest) Reset

func (x *CreatePostRequest) Reset()

func (*CreatePostRequest) String

func (x *CreatePostRequest) String() string

type DeleteCommentReply

type DeleteCommentReply struct {
	// contains filtered or unexported fields
}

func (*DeleteCommentReply) Descriptor deprecated

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

Deprecated: Use DeleteCommentReply.ProtoReflect.Descriptor instead.

func (*DeleteCommentReply) ProtoMessage

func (*DeleteCommentReply) ProtoMessage()

func (*DeleteCommentReply) ProtoReflect

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

func (*DeleteCommentReply) Reset

func (x *DeleteCommentReply) Reset()

func (*DeleteCommentReply) String

func (x *DeleteCommentReply) String() string

type DeleteCommentRequest

type DeleteCommentRequest struct {
	Id      int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	UserId  int64 `protobuf:"varint,2,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"`
	DelFlag int32 `protobuf:"varint,3,opt,name=del_flag,json=delFlag,proto3" json:"del_flag,omitempty"`
	// contains filtered or unexported fields
}

func (*DeleteCommentRequest) Descriptor deprecated

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

Deprecated: Use DeleteCommentRequest.ProtoReflect.Descriptor instead.

func (*DeleteCommentRequest) GetDelFlag

func (x *DeleteCommentRequest) GetDelFlag() int32

func (*DeleteCommentRequest) GetId

func (x *DeleteCommentRequest) GetId() int64

func (*DeleteCommentRequest) GetUserId

func (x *DeleteCommentRequest) GetUserId() int64

func (*DeleteCommentRequest) ProtoMessage

func (*DeleteCommentRequest) ProtoMessage()

func (*DeleteCommentRequest) ProtoReflect

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

func (*DeleteCommentRequest) Reset

func (x *DeleteCommentRequest) Reset()

func (*DeleteCommentRequest) String

func (x *DeleteCommentRequest) String() string

type DeleteLikeReply

type DeleteLikeReply struct {
	// contains filtered or unexported fields
}

func (*DeleteLikeReply) Descriptor deprecated

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

Deprecated: Use DeleteLikeReply.ProtoReflect.Descriptor instead.

func (*DeleteLikeReply) ProtoMessage

func (*DeleteLikeReply) ProtoMessage()

func (*DeleteLikeReply) ProtoReflect

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

func (*DeleteLikeReply) Reset

func (x *DeleteLikeReply) Reset()

func (*DeleteLikeReply) String

func (x *DeleteLikeReply) String() string

type DeleteLikeRequest

type DeleteLikeRequest struct {
	UserId  int64 `protobuf:"varint,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"`
	ObjType int32 `protobuf:"varint,2,opt,name=obj_type,json=objType,proto3" json:"obj_type,omitempty"`
	ObjId   int64 `protobuf:"varint,3,opt,name=obj_id,json=objId,proto3" json:"obj_id,omitempty"`
	// contains filtered or unexported fields
}

func (*DeleteLikeRequest) Descriptor deprecated

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

Deprecated: Use DeleteLikeRequest.ProtoReflect.Descriptor instead.

func (*DeleteLikeRequest) GetObjId

func (x *DeleteLikeRequest) GetObjId() int64

func (*DeleteLikeRequest) GetObjType

func (x *DeleteLikeRequest) GetObjType() int32

func (*DeleteLikeRequest) GetUserId

func (x *DeleteLikeRequest) GetUserId() int64

func (*DeleteLikeRequest) ProtoMessage

func (*DeleteLikeRequest) ProtoMessage()

func (*DeleteLikeRequest) ProtoReflect

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

func (*DeleteLikeRequest) Reset

func (x *DeleteLikeRequest) Reset()

func (*DeleteLikeRequest) String

func (x *DeleteLikeRequest) String() string

type DeletePostReply

type DeletePostReply struct {
	// contains filtered or unexported fields
}

删除帖子响应

func (*DeletePostReply) Descriptor deprecated

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

Deprecated: Use DeletePostReply.ProtoReflect.Descriptor instead.

func (*DeletePostReply) ProtoMessage

func (*DeletePostReply) ProtoMessage()

func (*DeletePostReply) ProtoReflect

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

func (*DeletePostReply) Reset

func (x *DeletePostReply) Reset()

func (*DeletePostReply) String

func (x *DeletePostReply) String() string

type DeletePostRequest

type DeletePostRequest struct {

	// 帖子id
	Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// 删除人的uid
	UserId int64 `protobuf:"varint,2,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"`
	// 删除标记
	DelFlag int32 `protobuf:"varint,3,opt,name=del_flag,json=delFlag,proto3" json:"del_flag,omitempty"`
	// contains filtered or unexported fields
}

删除帖子

func (*DeletePostRequest) Descriptor deprecated

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

Deprecated: Use DeletePostRequest.ProtoReflect.Descriptor instead.

func (*DeletePostRequest) GetDelFlag

func (x *DeletePostRequest) GetDelFlag() int32

func (*DeletePostRequest) GetId

func (x *DeletePostRequest) GetId() int64

func (*DeletePostRequest) GetUserId

func (x *DeletePostRequest) GetUserId() int64

func (*DeletePostRequest) ProtoMessage

func (*DeletePostRequest) ProtoMessage()

func (*DeletePostRequest) ProtoReflect

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

func (*DeletePostRequest) Reset

func (x *DeletePostRequest) Reset()

func (*DeletePostRequest) String

func (x *DeletePostRequest) String() string

type GetCommentReply

type GetCommentReply struct {
	Comment *Comment `protobuf:"bytes,1,opt,name=comment,proto3" json:"comment,omitempty"`
	// contains filtered or unexported fields
}

func (*GetCommentReply) Descriptor deprecated

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

Deprecated: Use GetCommentReply.ProtoReflect.Descriptor instead.

func (*GetCommentReply) GetComment

func (x *GetCommentReply) GetComment() *Comment

func (*GetCommentReply) ProtoMessage

func (*GetCommentReply) ProtoMessage()

func (*GetCommentReply) ProtoReflect

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

func (*GetCommentReply) Reset

func (x *GetCommentReply) Reset()

func (*GetCommentReply) String

func (x *GetCommentReply) String() string

type GetCommentRequest

type GetCommentRequest struct {
	Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

func (*GetCommentRequest) Descriptor deprecated

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

Deprecated: Use GetCommentRequest.ProtoReflect.Descriptor instead.

func (*GetCommentRequest) GetId

func (x *GetCommentRequest) GetId() int64

func (*GetCommentRequest) ProtoMessage

func (*GetCommentRequest) ProtoMessage()

func (*GetCommentRequest) ProtoReflect

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

func (*GetCommentRequest) Reset

func (x *GetCommentRequest) Reset()

func (*GetCommentRequest) String

func (x *GetCommentRequest) String() string

type GetLikeReply

type GetLikeReply struct {
	Like *Like `protobuf:"bytes,1,opt,name=like,proto3" json:"like,omitempty"`
	// contains filtered or unexported fields
}

func (*GetLikeReply) Descriptor deprecated

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

Deprecated: Use GetLikeReply.ProtoReflect.Descriptor instead.

func (*GetLikeReply) GetLike

func (x *GetLikeReply) GetLike() *Like

func (*GetLikeReply) ProtoMessage

func (*GetLikeReply) ProtoMessage()

func (*GetLikeReply) ProtoReflect

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

func (*GetLikeReply) Reset

func (x *GetLikeReply) Reset()

func (*GetLikeReply) String

func (x *GetLikeReply) String() string

type GetLikeRequest

type GetLikeRequest struct {
	UserId  int64 `protobuf:"varint,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"`
	ObjType int32 `protobuf:"varint,2,opt,name=obj_type,json=objType,proto3" json:"obj_type,omitempty"`
	ObjId   int64 `protobuf:"varint,3,opt,name=obj_id,json=objId,proto3" json:"obj_id,omitempty"`
	// contains filtered or unexported fields
}

func (*GetLikeRequest) Descriptor deprecated

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

Deprecated: Use GetLikeRequest.ProtoReflect.Descriptor instead.

func (*GetLikeRequest) GetObjId

func (x *GetLikeRequest) GetObjId() int64

func (*GetLikeRequest) GetObjType

func (x *GetLikeRequest) GetObjType() int32

func (*GetLikeRequest) GetUserId

func (x *GetLikeRequest) GetUserId() int64

func (*GetLikeRequest) ProtoMessage

func (*GetLikeRequest) ProtoMessage()

func (*GetLikeRequest) ProtoReflect

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

func (*GetLikeRequest) Reset

func (x *GetLikeRequest) Reset()

func (*GetLikeRequest) String

func (x *GetLikeRequest) String() string

type GetPostReply

type GetPostReply struct {

	// 帖子信息
	Post *Post `protobuf:"bytes,1,opt,name=post,proto3" json:"post,omitempty"`
	// contains filtered or unexported fields
}

获取帖子响应

func (*GetPostReply) Descriptor deprecated

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

Deprecated: Use GetPostReply.ProtoReflect.Descriptor instead.

func (*GetPostReply) GetPost

func (x *GetPostReply) GetPost() *Post

func (*GetPostReply) ProtoMessage

func (*GetPostReply) ProtoMessage()

func (*GetPostReply) ProtoReflect

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

func (*GetPostReply) Reset

func (x *GetPostReply) Reset()

func (*GetPostReply) String

func (x *GetPostReply) String() string

type GetPostRequest

type GetPostRequest struct {

	// 帖子id
	Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

获取帖子请求

func (*GetPostRequest) Descriptor deprecated

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

Deprecated: Use GetPostRequest.ProtoReflect.Descriptor instead.

func (*GetPostRequest) GetId

func (x *GetPostRequest) GetId() int64

func (*GetPostRequest) ProtoMessage

func (*GetPostRequest) ProtoMessage()

func (*GetPostRequest) ProtoReflect

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

func (*GetPostRequest) Reset

func (x *GetPostRequest) Reset()

func (*GetPostRequest) String

func (x *GetPostRequest) String() string

type Like

type Like struct {
	Id        int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	UserId    int64 `protobuf:"varint,2,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"`
	ObjType   int32 `protobuf:"varint,3,opt,name=obj_type,json=objType,proto3" json:"obj_type,omitempty"`
	ObjId     int64 `protobuf:"varint,4,opt,name=obj_id,json=objId,proto3" json:"obj_id,omitempty"`
	Status    int32 `protobuf:"varint,5,opt,name=status,proto3" json:"status,omitempty"`
	CreatedAt int64 `protobuf:"varint,6,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"`
	UpdatedAt int64 `protobuf:"varint,7,opt,name=updated_at,json=updatedAt,proto3" json:"updated_at,omitempty"`
	// contains filtered or unexported fields
}

点赞信息

func (*Like) Descriptor deprecated

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

Deprecated: Use Like.ProtoReflect.Descriptor instead.

func (*Like) GetCreatedAt

func (x *Like) GetCreatedAt() int64

func (*Like) GetId

func (x *Like) GetId() int64

func (*Like) GetObjId

func (x *Like) GetObjId() int64

func (*Like) GetObjType

func (x *Like) GetObjType() int32

func (*Like) GetStatus

func (x *Like) GetStatus() int32

func (*Like) GetUpdatedAt

func (x *Like) GetUpdatedAt() int64

func (*Like) GetUserId

func (x *Like) GetUserId() int64

func (*Like) ProtoMessage

func (*Like) ProtoMessage()

func (*Like) ProtoReflect

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

func (*Like) Reset

func (x *Like) Reset()

func (*Like) String

func (x *Like) String() string

type LikeServiceClient

type LikeServiceClient interface {
	// 创建点赞
	CreateLike(ctx context.Context, in *CreateLikeRequest, opts ...grpc.CallOption) (*CreateLikeReply, error)
	// 更新点赞
	UpdateLike(ctx context.Context, in *UpdateLikeRequest, opts ...grpc.CallOption) (*UpdateLikeReply, error)
	// 删除点赞
	DeleteLike(ctx context.Context, in *DeleteLikeRequest, opts ...grpc.CallOption) (*DeleteLikeReply, error)
	// 获得点赞
	GetLike(ctx context.Context, in *GetLikeRequest, opts ...grpc.CallOption) (*GetLikeReply, error)
	// 批量获取点赞
	BatchGetLikes(ctx context.Context, in *BatchGetLikesRequest, opts ...grpc.CallOption) (*BatchGetLikesReply, error)
	// 帖子点赞列表
	ListPostLikes(ctx context.Context, in *ListPostLikesRequest, opts ...grpc.CallOption) (*ListPostLikesReply, error)
	// 评论点赞列表
	ListCommentsLike(ctx context.Context, in *ListCommentLikesRequest, opts ...grpc.CallOption) (*ListCommentLikesReply, error)
}

LikeServiceClient is the client API for LikeService 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.

type LikeServiceServer

type LikeServiceServer interface {
	// 创建点赞
	CreateLike(context.Context, *CreateLikeRequest) (*CreateLikeReply, error)
	// 更新点赞
	UpdateLike(context.Context, *UpdateLikeRequest) (*UpdateLikeReply, error)
	// 删除点赞
	DeleteLike(context.Context, *DeleteLikeRequest) (*DeleteLikeReply, error)
	// 获得点赞
	GetLike(context.Context, *GetLikeRequest) (*GetLikeReply, error)
	// 批量获取点赞
	BatchGetLikes(context.Context, *BatchGetLikesRequest) (*BatchGetLikesReply, error)
	// 帖子点赞列表
	ListPostLikes(context.Context, *ListPostLikesRequest) (*ListPostLikesReply, error)
	// 评论点赞列表
	ListCommentsLike(context.Context, *ListCommentLikesRequest) (*ListCommentLikesReply, error)
	// contains filtered or unexported methods
}

LikeServiceServer is the server API for LikeService service. All implementations must embed UnimplementedLikeServiceServer for forward compatibility

type ListCommentLikesReply

type ListCommentLikesReply struct {
	Items []*Like `protobuf:"bytes,1,rep,name=items,proto3" json:"items,omitempty"`
	Count int64   `protobuf:"varint,2,opt,name=count,proto3" json:"count,omitempty"`
	// 下一次请求用到的token, 如果为空说明没有下一页
	NextPageToken int64 `protobuf:"varint,3,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"`
	// contains filtered or unexported fields
}

评论点赞列表响应

func (*ListCommentLikesReply) Descriptor deprecated

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

Deprecated: Use ListCommentLikesReply.ProtoReflect.Descriptor instead.

func (*ListCommentLikesReply) GetCount

func (x *ListCommentLikesReply) GetCount() int64

func (*ListCommentLikesReply) GetItems

func (x *ListCommentLikesReply) GetItems() []*Like

func (*ListCommentLikesReply) GetNextPageToken

func (x *ListCommentLikesReply) GetNextPageToken() int64

func (*ListCommentLikesReply) ProtoMessage

func (*ListCommentLikesReply) ProtoMessage()

func (*ListCommentLikesReply) ProtoReflect

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

func (*ListCommentLikesReply) Reset

func (x *ListCommentLikesReply) Reset()

func (*ListCommentLikesReply) String

func (x *ListCommentLikesReply) String() string

type ListCommentLikesRequest

type ListCommentLikesRequest struct {
	UserId    int64 `protobuf:"varint,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"`
	CommentId int64 `protobuf:"varint,2,opt,name=comment_id,json=commentId,proto3" json:"comment_id,omitempty"`
	// 每页数量
	PageSize int32 `protobuf:"varint,3,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"`
	// 分页token
	PageToken int64 `protobuf:"varint,4,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"`
	// contains filtered or unexported fields
}

评论点赞列表请求参数

func (*ListCommentLikesRequest) Descriptor deprecated

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

Deprecated: Use ListCommentLikesRequest.ProtoReflect.Descriptor instead.

func (*ListCommentLikesRequest) GetCommentId

func (x *ListCommentLikesRequest) GetCommentId() int64

func (*ListCommentLikesRequest) GetPageSize

func (x *ListCommentLikesRequest) GetPageSize() int32

func (*ListCommentLikesRequest) GetPageToken

func (x *ListCommentLikesRequest) GetPageToken() int64

func (*ListCommentLikesRequest) GetUserId

func (x *ListCommentLikesRequest) GetUserId() int64

func (*ListCommentLikesRequest) ProtoMessage

func (*ListCommentLikesRequest) ProtoMessage()

func (*ListCommentLikesRequest) ProtoReflect

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

func (*ListCommentLikesRequest) Reset

func (x *ListCommentLikesRequest) Reset()

func (*ListCommentLikesRequest) String

func (x *ListCommentLikesRequest) String() string

type ListCommentsReply

type ListCommentsReply struct {
	Items []*Comment `protobuf:"bytes,1,rep,name=items,proto3" json:"items,omitempty"`
	Count int64      `protobuf:"varint,2,opt,name=count,proto3" json:"count,omitempty"`
	// 下一次请求用到的token, 如果为空说明没有下一页
	NextPageToken int64 `protobuf:"varint,3,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"`
	// contains filtered or unexported fields
}

评论列表响应

func (*ListCommentsReply) Descriptor deprecated

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

Deprecated: Use ListCommentsReply.ProtoReflect.Descriptor instead.

func (*ListCommentsReply) GetCount

func (x *ListCommentsReply) GetCount() int64

func (*ListCommentsReply) GetItems

func (x *ListCommentsReply) GetItems() []*Comment

func (*ListCommentsReply) GetNextPageToken

func (x *ListCommentsReply) GetNextPageToken() int64

func (*ListCommentsReply) ProtoMessage

func (*ListCommentsReply) ProtoMessage()

func (*ListCommentsReply) ProtoReflect

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

func (*ListCommentsReply) Reset

func (x *ListCommentsReply) Reset()

func (*ListCommentsReply) String

func (x *ListCommentsReply) String() string

type ListCommentsRequest

type ListCommentsRequest struct {

	// 帖子id
	PostId int64 `protobuf:"varint,1,opt,name=post_id,json=postId,proto3" json:"post_id,omitempty"`
	// 每页数量
	PageSize int32 `protobuf:"varint,2,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"`
	// 分页token
	PageToken int64 `protobuf:"varint,3,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"`
	// contains filtered or unexported fields
}

评论列表请求参数

func (*ListCommentsRequest) Descriptor deprecated

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

Deprecated: Use ListCommentsRequest.ProtoReflect.Descriptor instead.

func (*ListCommentsRequest) GetPageSize

func (x *ListCommentsRequest) GetPageSize() int32

func (*ListCommentsRequest) GetPageToken

func (x *ListCommentsRequest) GetPageToken() int64

func (*ListCommentsRequest) GetPostId

func (x *ListCommentsRequest) GetPostId() int64

func (*ListCommentsRequest) ProtoMessage

func (*ListCommentsRequest) ProtoMessage()

func (*ListCommentsRequest) ProtoReflect

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

func (*ListCommentsRequest) Reset

func (x *ListCommentsRequest) Reset()

func (*ListCommentsRequest) String

func (x *ListCommentsRequest) String() string

type ListHotPostsReply

type ListHotPostsReply struct {

	// 多个帖子信息
	Posts []*Post `protobuf:"bytes,1,rep,name=posts,proto3" json:"posts,omitempty"`
	// 下一次请求用到的token, 如果为空说明没有下一页
	NextPageToken int64 `protobuf:"varint,2,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"`
	// contains filtered or unexported fields
}

获取热门帖子列表响应

func (*ListHotPostsReply) Descriptor deprecated

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

Deprecated: Use ListHotPostsReply.ProtoReflect.Descriptor instead.

func (*ListHotPostsReply) GetNextPageToken

func (x *ListHotPostsReply) GetNextPageToken() int64

func (*ListHotPostsReply) GetPosts

func (x *ListHotPostsReply) GetPosts() []*Post

func (*ListHotPostsReply) ProtoMessage

func (*ListHotPostsReply) ProtoMessage()

func (*ListHotPostsReply) ProtoReflect

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

func (*ListHotPostsReply) Reset

func (x *ListHotPostsReply) Reset()

func (*ListHotPostsReply) String

func (x *ListHotPostsReply) String() string

type ListHotPostsRequest

type ListHotPostsRequest struct {

	// 每页大小
	PageSize int32 `protobuf:"varint,1,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"`
	// 分页token
	PageToken int64 `protobuf:"varint,2,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"`
	// contains filtered or unexported fields
}

获取热门帖子列表请求

func (*ListHotPostsRequest) Descriptor deprecated

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

Deprecated: Use ListHotPostsRequest.ProtoReflect.Descriptor instead.

func (*ListHotPostsRequest) GetPageSize

func (x *ListHotPostsRequest) GetPageSize() int32

func (*ListHotPostsRequest) GetPageToken

func (x *ListHotPostsRequest) GetPageToken() int64

func (*ListHotPostsRequest) ProtoMessage

func (*ListHotPostsRequest) ProtoMessage()

func (*ListHotPostsRequest) ProtoReflect

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

func (*ListHotPostsRequest) Reset

func (x *ListHotPostsRequest) Reset()

func (*ListHotPostsRequest) String

func (x *ListHotPostsRequest) String() string

type ListLatestPostsReply

type ListLatestPostsReply struct {

	// 多个帖子信息
	Posts []*Post `protobuf:"bytes,1,rep,name=posts,proto3" json:"posts,omitempty"`
	// 下一次请求用到的token, 如果为空说明没有下一页
	NextPageToken int64 `protobuf:"varint,2,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"`
	// contains filtered or unexported fields
}

获取最新的帖子列表响应

func (*ListLatestPostsReply) Descriptor deprecated

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

Deprecated: Use ListLatestPostsReply.ProtoReflect.Descriptor instead.

func (*ListLatestPostsReply) GetNextPageToken

func (x *ListLatestPostsReply) GetNextPageToken() int64

func (*ListLatestPostsReply) GetPosts

func (x *ListLatestPostsReply) GetPosts() []*Post

func (*ListLatestPostsReply) ProtoMessage

func (*ListLatestPostsReply) ProtoMessage()

func (*ListLatestPostsReply) ProtoReflect

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

func (*ListLatestPostsReply) Reset

func (x *ListLatestPostsReply) Reset()

func (*ListLatestPostsReply) String

func (x *ListLatestPostsReply) String() string

type ListLatestPostsRequest

type ListLatestPostsRequest struct {

	// 每页大小
	PageSize int32 `protobuf:"varint,1,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"`
	// 分页token
	PageToken int64 `protobuf:"varint,2,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"`
	// contains filtered or unexported fields
}

获取最新的帖子列表请求

func (*ListLatestPostsRequest) Descriptor deprecated

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

Deprecated: Use ListLatestPostsRequest.ProtoReflect.Descriptor instead.

func (*ListLatestPostsRequest) GetPageSize

func (x *ListLatestPostsRequest) GetPageSize() int32

func (*ListLatestPostsRequest) GetPageToken

func (x *ListLatestPostsRequest) GetPageToken() int64

func (*ListLatestPostsRequest) ProtoMessage

func (*ListLatestPostsRequest) ProtoMessage()

func (*ListLatestPostsRequest) ProtoReflect

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

func (*ListLatestPostsRequest) Reset

func (x *ListLatestPostsRequest) Reset()

func (*ListLatestPostsRequest) String

func (x *ListLatestPostsRequest) String() string

type ListMyPostsReply

type ListMyPostsReply struct {

	// 多个帖子信息
	Posts []*Post `protobuf:"bytes,1,rep,name=posts,proto3" json:"posts,omitempty"`
	// 下一次请求用到的token, 如果为空说明没有下一页
	NextPageToken int64 `protobuf:"varint,2,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"`
	// contains filtered or unexported fields
}

获取我发布过的帖子响应

func (*ListMyPostsReply) Descriptor deprecated

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

Deprecated: Use ListMyPostsReply.ProtoReflect.Descriptor instead.

func (*ListMyPostsReply) GetNextPageToken

func (x *ListMyPostsReply) GetNextPageToken() int64

func (*ListMyPostsReply) GetPosts

func (x *ListMyPostsReply) GetPosts() []*Post

func (*ListMyPostsReply) ProtoMessage

func (*ListMyPostsReply) ProtoMessage()

func (*ListMyPostsReply) ProtoReflect

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

func (*ListMyPostsReply) Reset

func (x *ListMyPostsReply) Reset()

func (*ListMyPostsReply) String

func (x *ListMyPostsReply) String() string

type ListMyPostsRequest

type ListMyPostsRequest struct {

	// 用户uid
	UserId int64 `protobuf:"varint,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"`
	// 每页大小
	PageSize int32 `protobuf:"varint,2,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"`
	// 分页token
	PageToken int64 `protobuf:"varint,3,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"`
	// contains filtered or unexported fields
}

获取我发布过的帖子请求

func (*ListMyPostsRequest) Descriptor deprecated

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

Deprecated: Use ListMyPostsRequest.ProtoReflect.Descriptor instead.

func (*ListMyPostsRequest) GetPageSize

func (x *ListMyPostsRequest) GetPageSize() int32

func (*ListMyPostsRequest) GetPageToken

func (x *ListMyPostsRequest) GetPageToken() int64

func (*ListMyPostsRequest) GetUserId

func (x *ListMyPostsRequest) GetUserId() int64

func (*ListMyPostsRequest) ProtoMessage

func (*ListMyPostsRequest) ProtoMessage()

func (*ListMyPostsRequest) ProtoReflect

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

func (*ListMyPostsRequest) Reset

func (x *ListMyPostsRequest) Reset()

func (*ListMyPostsRequest) String

func (x *ListMyPostsRequest) String() string

type ListPostLikesReply

type ListPostLikesReply struct {
	Items []*Like `protobuf:"bytes,1,rep,name=items,proto3" json:"items,omitempty"`
	Count int64   `protobuf:"varint,2,opt,name=count,proto3" json:"count,omitempty"`
	// 下一次请求用到的token, 如果为空说明没有下一页
	NextPageToken int64 `protobuf:"varint,3,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"`
	// contains filtered or unexported fields
}

帖子点赞列表响应

func (*ListPostLikesReply) Descriptor deprecated

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

Deprecated: Use ListPostLikesReply.ProtoReflect.Descriptor instead.

func (*ListPostLikesReply) GetCount

func (x *ListPostLikesReply) GetCount() int64

func (*ListPostLikesReply) GetItems

func (x *ListPostLikesReply) GetItems() []*Like

func (*ListPostLikesReply) GetNextPageToken

func (x *ListPostLikesReply) GetNextPageToken() int64

func (*ListPostLikesReply) ProtoMessage

func (*ListPostLikesReply) ProtoMessage()

func (*ListPostLikesReply) ProtoReflect

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

func (*ListPostLikesReply) Reset

func (x *ListPostLikesReply) Reset()

func (*ListPostLikesReply) String

func (x *ListPostLikesReply) String() string

type ListPostLikesRequest

type ListPostLikesRequest struct {

	// 用户id
	UserId int64 `protobuf:"varint,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"`
	// 帖子id
	PostId int64 `protobuf:"varint,2,opt,name=post_id,json=postId,proto3" json:"post_id,omitempty"`
	// 每页数量
	PageSize int32 `protobuf:"varint,3,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"`
	// 分页token
	PageToken int64 `protobuf:"varint,4,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"`
	// contains filtered or unexported fields
}

帖子点赞列表请求参数

func (*ListPostLikesRequest) Descriptor deprecated

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

Deprecated: Use ListPostLikesRequest.ProtoReflect.Descriptor instead.

func (*ListPostLikesRequest) GetPageSize

func (x *ListPostLikesRequest) GetPageSize() int32

func (*ListPostLikesRequest) GetPageToken

func (x *ListPostLikesRequest) GetPageToken() int64

func (*ListPostLikesRequest) GetPostId

func (x *ListPostLikesRequest) GetPostId() int64

func (*ListPostLikesRequest) GetUserId

func (x *ListPostLikesRequest) GetUserId() int64

func (*ListPostLikesRequest) ProtoMessage

func (*ListPostLikesRequest) ProtoMessage()

func (*ListPostLikesRequest) ProtoReflect

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

func (*ListPostLikesRequest) Reset

func (x *ListPostLikesRequest) Reset()

func (*ListPostLikesRequest) String

func (x *ListPostLikesRequest) String() string

type ListReplyCommentsReply

type ListReplyCommentsReply struct {
	Items []*Comment `protobuf:"bytes,1,rep,name=items,proto3" json:"items,omitempty"`
	Count int64      `protobuf:"varint,2,opt,name=count,proto3" json:"count,omitempty"`
	// 下一次请求用到的token, 如果为空说明没有下一页
	NextPageToken int64 `protobuf:"varint,3,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"`
	// contains filtered or unexported fields
}

评论的回复列表响应

func (*ListReplyCommentsReply) Descriptor deprecated

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

Deprecated: Use ListReplyCommentsReply.ProtoReflect.Descriptor instead.

func (*ListReplyCommentsReply) GetCount

func (x *ListReplyCommentsReply) GetCount() int64

func (*ListReplyCommentsReply) GetItems

func (x *ListReplyCommentsReply) GetItems() []*Comment

func (*ListReplyCommentsReply) GetNextPageToken

func (x *ListReplyCommentsReply) GetNextPageToken() int64

func (*ListReplyCommentsReply) ProtoMessage

func (*ListReplyCommentsReply) ProtoMessage()

func (*ListReplyCommentsReply) ProtoReflect

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

func (*ListReplyCommentsReply) Reset

func (x *ListReplyCommentsReply) Reset()

func (*ListReplyCommentsReply) String

func (x *ListReplyCommentsReply) String() string

type ListReplyCommentsRequest

type ListReplyCommentsRequest struct {
	CommentId int64 `protobuf:"varint,1,opt,name=comment_id,json=commentId,proto3" json:"comment_id,omitempty"`
	// 每页数量
	PageSize int32 `protobuf:"varint,2,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"`
	// 分页token
	PageToken int64 `protobuf:"varint,3,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"`
	// contains filtered or unexported fields
}

评论的回复列表请求参数

func (*ListReplyCommentsRequest) Descriptor deprecated

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

Deprecated: Use ListReplyCommentsRequest.ProtoReflect.Descriptor instead.

func (*ListReplyCommentsRequest) GetCommentId

func (x *ListReplyCommentsRequest) GetCommentId() int64

func (*ListReplyCommentsRequest) GetPageSize

func (x *ListReplyCommentsRequest) GetPageSize() int32

func (*ListReplyCommentsRequest) GetPageToken

func (x *ListReplyCommentsRequest) GetPageToken() int64

func (*ListReplyCommentsRequest) ProtoMessage

func (*ListReplyCommentsRequest) ProtoMessage()

func (*ListReplyCommentsRequest) ProtoReflect

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

func (*ListReplyCommentsRequest) Reset

func (x *ListReplyCommentsRequest) Reset()

func (*ListReplyCommentsRequest) String

func (x *ListReplyCommentsRequest) String() string

type Post

type Post struct {

	// 帖子id
	Id           int64         `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	PostType     int32         `protobuf:"varint,2,opt,name=post_type,json=postType,proto3" json:"post_type,omitempty"`                                // post type
	UserId       int64         `protobuf:"varint,3,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"`                                      // user id
	Title        string        `protobuf:"bytes,4,opt,name=title,proto3" json:"title,omitempty"`                                                       // post title
	Content      *Content      `protobuf:"bytes,5,opt,name=content,proto3" json:"content,omitempty"`                                                   // post content, json format
	ViewCount    int64         `protobuf:"varint,6,opt,name=view_count,json=viewCount,proto3" json:"view_count,omitempty"`                             // view count
	LikeCount    int64         `protobuf:"varint,7,opt,name=like_count,json=likeCount,proto3" json:"like_count,omitempty"`                             // like count
	CommentCount int64         `protobuf:"varint,8,opt,name=comment_count,json=commentCount,proto3" json:"comment_count,omitempty"`                    // comment count
	CollectCount int64         `protobuf:"varint,9,opt,name=collect_count,json=collectCount,proto3" json:"collect_count,omitempty"`                    // collect count
	ShareCount   int64         `protobuf:"varint,10,opt,name=share_count,json=shareCount,proto3" json:"share_count,omitempty"`                         // 分享数
	DelFlag      Post_DEL_FLAG `protobuf:"varint,11,opt,name=del_flag,json=delFlag,proto3,enum=api.moment.v1.Post_DEL_FLAG" json:"del_flag,omitempty"` // 删除标记
	Visible      Post_VISIBLE  `protobuf:"varint,12,opt,name=visible,proto3,enum=api.moment.v1.Post_VISIBLE" json:"visible,omitempty"`                 // 帖子可见性
	Longitude    float32       `protobuf:"fixed32,13,opt,name=longitude,proto3" json:"longitude,omitempty"`                                            // 经度
	Latitude     float32       `protobuf:"fixed32,14,opt,name=latitude,proto3" json:"latitude,omitempty"`                                              // 纬度
	Position     string        `protobuf:"bytes,15,opt,name=position,proto3" json:"position,omitempty"`                                                // 发帖人的位置,比如北京
	CreatedAt    int64         `protobuf:"varint,16,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"`                            // 创建时间
	UpdatedAt    int64         `protobuf:"varint,17,opt,name=updated_at,json=updatedAt,proto3" json:"updated_at,omitempty"`                            // 更新时间
	DeletedAt    int64         `protobuf:"varint,18,opt,name=deleted_at,json=deletedAt,proto3" json:"deleted_at,omitempty"`                            // 删除时间
	// contains filtered or unexported fields
}

帖子信息

func (*Post) Descriptor deprecated

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

Deprecated: Use Post.ProtoReflect.Descriptor instead.

func (*Post) GetCollectCount

func (x *Post) GetCollectCount() int64

func (*Post) GetCommentCount

func (x *Post) GetCommentCount() int64

func (*Post) GetContent

func (x *Post) GetContent() *Content

func (*Post) GetCreatedAt

func (x *Post) GetCreatedAt() int64

func (*Post) GetDelFlag

func (x *Post) GetDelFlag() Post_DEL_FLAG

func (*Post) GetDeletedAt

func (x *Post) GetDeletedAt() int64

func (*Post) GetId

func (x *Post) GetId() int64

func (*Post) GetLatitude

func (x *Post) GetLatitude() float32

func (*Post) GetLikeCount

func (x *Post) GetLikeCount() int64

func (*Post) GetLongitude

func (x *Post) GetLongitude() float32

func (*Post) GetPosition

func (x *Post) GetPosition() string

func (*Post) GetPostType

func (x *Post) GetPostType() int32

func (*Post) GetShareCount

func (x *Post) GetShareCount() int64

func (*Post) GetTitle

func (x *Post) GetTitle() string

func (*Post) GetUpdatedAt

func (x *Post) GetUpdatedAt() int64

func (*Post) GetUserId

func (x *Post) GetUserId() int64

func (*Post) GetViewCount

func (x *Post) GetViewCount() int64

func (*Post) GetVisible

func (x *Post) GetVisible() Post_VISIBLE

func (*Post) ProtoMessage

func (*Post) ProtoMessage()

func (*Post) ProtoReflect

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

func (*Post) Reset

func (x *Post) Reset()

func (*Post) String

func (x *Post) String() string

type PostImage

type PostImage struct {
	ImageKey  string `protobuf:"bytes,1,opt,name=image_key,json=imageKey,proto3" json:"image_key,omitempty"`    // 图片key
	ImageUrl  string `protobuf:"bytes,2,opt,name=image_url,json=imageUrl,proto3" json:"image_url,omitempty"`    // 图片url
	ImageType string `protobuf:"bytes,3,opt,name=image_type,json=imageType,proto3" json:"image_type,omitempty"` // 图片类型
	Width     int32  `protobuf:"varint,4,opt,name=width,proto3" json:"width,omitempty"`                         // 图片宽度
	Height    int32  `protobuf:"varint,5,opt,name=height,proto3" json:"height,omitempty"`                       // 图片高度
	// contains filtered or unexported fields
}

图片内容

func (*PostImage) Descriptor deprecated

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

Deprecated: Use PostImage.ProtoReflect.Descriptor instead.

func (*PostImage) GetHeight

func (x *PostImage) GetHeight() int32

func (*PostImage) GetImageKey

func (x *PostImage) GetImageKey() string

func (*PostImage) GetImageType

func (x *PostImage) GetImageType() string

func (*PostImage) GetImageUrl

func (x *PostImage) GetImageUrl() string

func (*PostImage) GetWidth

func (x *PostImage) GetWidth() int32

func (*PostImage) ProtoMessage

func (*PostImage) ProtoMessage()

func (*PostImage) ProtoReflect

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

func (*PostImage) Reset

func (x *PostImage) Reset()

func (*PostImage) String

func (x *PostImage) String() string

type PostServiceClient

type PostServiceClient interface {
	// 创建帖子
	CreatePost(ctx context.Context, in *CreatePostRequest, opts ...grpc.CallOption) (*CreatePostReply, error)
	// 更新帖子,暂时不提供
	UpdatePost(ctx context.Context, in *UpdatePostRequest, opts ...grpc.CallOption) (*UpdatePostReply, error)
	// 删除帖子
	DeletePost(ctx context.Context, in *DeletePostRequest, opts ...grpc.CallOption) (*DeletePostReply, error)
	// 根据id获取指定帖子
	GetPost(ctx context.Context, in *GetPostRequest, opts ...grpc.CallOption) (*GetPostReply, error)
	// 批量获取帖子
	BatchGetPosts(ctx context.Context, in *BatchGetPostsRequest, opts ...grpc.CallOption) (*BatchGetPostsReply, error)
	// 我发布过的帖子列表
	ListMyPost(ctx context.Context, in *ListMyPostsRequest, opts ...grpc.CallOption) (*ListMyPostsReply, error)
	// 最新的帖子列表
	ListLatestPost(ctx context.Context, in *ListLatestPostsRequest, opts ...grpc.CallOption) (*ListLatestPostsReply, error)
	// 热门的帖子列表
	ListHotPost(ctx context.Context, in *ListHotPostsRequest, opts ...grpc.CallOption) (*ListHotPostsReply, error)
}

PostServiceClient is the client API for PostService 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.

type PostServiceServer

type PostServiceServer interface {
	// 创建帖子
	CreatePost(context.Context, *CreatePostRequest) (*CreatePostReply, error)
	// 更新帖子,暂时不提供
	UpdatePost(context.Context, *UpdatePostRequest) (*UpdatePostReply, error)
	// 删除帖子
	DeletePost(context.Context, *DeletePostRequest) (*DeletePostReply, error)
	// 根据id获取指定帖子
	GetPost(context.Context, *GetPostRequest) (*GetPostReply, error)
	// 批量获取帖子
	BatchGetPosts(context.Context, *BatchGetPostsRequest) (*BatchGetPostsReply, error)
	// 我发布过的帖子列表
	ListMyPost(context.Context, *ListMyPostsRequest) (*ListMyPostsReply, error)
	// 最新的帖子列表
	ListLatestPost(context.Context, *ListLatestPostsRequest) (*ListLatestPostsReply, error)
	// 热门的帖子列表
	ListHotPost(context.Context, *ListHotPostsRequest) (*ListHotPostsReply, error)
	// contains filtered or unexported methods
}

PostServiceServer is the server API for PostService service. All implementations must embed UnimplementedPostServiceServer for forward compatibility

type Post_DEL_FLAG

type Post_DEL_FLAG int32

删除标记

const (
	Post_DEL_FLAG_UNSPECIFIED Post_DEL_FLAG = 0
	Post_DEL_FLAG_NORMAL      Post_DEL_FLAG = 1 // normal status
	Post_DEL_FLAG_USER        Post_DEL_FLAG = 2 // user self delete
	Post_DEL_FLAG_ADMIN       Post_DEL_FLAG = 3 // admin delete
)

func (Post_DEL_FLAG) Descriptor

func (Post_DEL_FLAG) Enum

func (x Post_DEL_FLAG) Enum() *Post_DEL_FLAG

func (Post_DEL_FLAG) EnumDescriptor deprecated

func (Post_DEL_FLAG) EnumDescriptor() ([]byte, []int)

Deprecated: Use Post_DEL_FLAG.Descriptor instead.

func (Post_DEL_FLAG) Number

func (Post_DEL_FLAG) String

func (x Post_DEL_FLAG) String() string

func (Post_DEL_FLAG) Type

type Post_VISIBLE

type Post_VISIBLE int32

帖子的可见性

const (
	Post_VISIBLE_UNSPECIFIED Post_VISIBLE = 0
	Post_VISIBLE_ALL         Post_VISIBLE = 1 // everyone can see
	Post_VISIBLE_SELF        Post_VISIBLE = 2 // only self see
)

func (Post_VISIBLE) Descriptor

func (Post_VISIBLE) Enum

func (x Post_VISIBLE) Enum() *Post_VISIBLE

func (Post_VISIBLE) EnumDescriptor deprecated

func (Post_VISIBLE) EnumDescriptor() ([]byte, []int)

Deprecated: Use Post_VISIBLE.Descriptor instead.

func (Post_VISIBLE) Number

func (Post_VISIBLE) String

func (x Post_VISIBLE) String() string

func (Post_VISIBLE) Type

type ReplyCommentReply

type ReplyCommentReply struct {
	Comment *Comment `protobuf:"bytes,1,opt,name=comment,proto3" json:"comment,omitempty"`
	// contains filtered or unexported fields
}

func (*ReplyCommentReply) Descriptor deprecated

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

Deprecated: Use ReplyCommentReply.ProtoReflect.Descriptor instead.

func (*ReplyCommentReply) GetComment

func (x *ReplyCommentReply) GetComment() *Comment

func (*ReplyCommentReply) ProtoMessage

func (*ReplyCommentReply) ProtoMessage()

func (*ReplyCommentReply) ProtoReflect

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

func (*ReplyCommentReply) Reset

func (x *ReplyCommentReply) Reset()

func (*ReplyCommentReply) String

func (x *ReplyCommentReply) String() string

type ReplyCommentRequest

type ReplyCommentRequest struct {
	CommentId  int64  `protobuf:"varint,1,opt,name=comment_id,json=commentId,proto3" json:"comment_id,omitempty"`
	UserId     int64  `protobuf:"varint,2,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"`
	Content    string `protobuf:"bytes,3,opt,name=content,proto3" json:"content,omitempty"`
	RootId     int64  `protobuf:"varint,4,opt,name=root_id,json=rootId,proto3" json:"root_id,omitempty"`
	ParentId   int64  `protobuf:"varint,5,opt,name=parent_id,json=parentId,proto3" json:"parent_id,omitempty"`
	DeviceType string `protobuf:"bytes,6,opt,name=device_type,json=deviceType,proto3" json:"device_type,omitempty"`
	Ip         string `protobuf:"bytes,7,opt,name=ip,proto3" json:"ip,omitempty"`
	// contains filtered or unexported fields
}

func (*ReplyCommentRequest) Descriptor deprecated

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

Deprecated: Use ReplyCommentRequest.ProtoReflect.Descriptor instead.

func (*ReplyCommentRequest) GetCommentId

func (x *ReplyCommentRequest) GetCommentId() int64

func (*ReplyCommentRequest) GetContent

func (x *ReplyCommentRequest) GetContent() string

func (*ReplyCommentRequest) GetDeviceType

func (x *ReplyCommentRequest) GetDeviceType() string

func (*ReplyCommentRequest) GetIp

func (x *ReplyCommentRequest) GetIp() string

func (*ReplyCommentRequest) GetParentId

func (x *ReplyCommentRequest) GetParentId() int64

func (*ReplyCommentRequest) GetRootId

func (x *ReplyCommentRequest) GetRootId() int64

func (*ReplyCommentRequest) GetUserId

func (x *ReplyCommentRequest) GetUserId() int64

func (*ReplyCommentRequest) ProtoMessage

func (*ReplyCommentRequest) ProtoMessage()

func (*ReplyCommentRequest) ProtoReflect

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

func (*ReplyCommentRequest) Reset

func (x *ReplyCommentRequest) Reset()

func (*ReplyCommentRequest) String

func (x *ReplyCommentRequest) String() string

type UnimplementedCommentServiceServer

type UnimplementedCommentServiceServer struct {
}

UnimplementedCommentServiceServer must be embedded to have forward compatible implementations.

func (UnimplementedCommentServiceServer) BatchGetComments

func (UnimplementedCommentServiceServer) CreateComment

func (UnimplementedCommentServiceServer) DeleteComment

func (UnimplementedCommentServiceServer) GetComment

func (UnimplementedCommentServiceServer) ListHotComments

func (UnimplementedCommentServiceServer) ListLatestComments

func (UnimplementedCommentServiceServer) ListReplyComments

func (UnimplementedCommentServiceServer) ReplyComment

func (UnimplementedCommentServiceServer) UpdateComment

type UnimplementedLikeServiceServer

type UnimplementedLikeServiceServer struct {
}

UnimplementedLikeServiceServer must be embedded to have forward compatible implementations.

func (UnimplementedLikeServiceServer) BatchGetLikes

func (UnimplementedLikeServiceServer) CreateLike

func (UnimplementedLikeServiceServer) DeleteLike

func (UnimplementedLikeServiceServer) GetLike

func (UnimplementedLikeServiceServer) ListCommentsLike

func (UnimplementedLikeServiceServer) ListPostLikes

func (UnimplementedLikeServiceServer) UpdateLike

type UnimplementedPostServiceServer

type UnimplementedPostServiceServer struct {
}

UnimplementedPostServiceServer must be embedded to have forward compatible implementations.

func (UnimplementedPostServiceServer) BatchGetPosts

func (UnimplementedPostServiceServer) CreatePost

func (UnimplementedPostServiceServer) DeletePost

func (UnimplementedPostServiceServer) GetPost

func (UnimplementedPostServiceServer) ListHotPost

func (UnimplementedPostServiceServer) ListLatestPost

func (UnimplementedPostServiceServer) ListMyPost

func (UnimplementedPostServiceServer) UpdatePost

type UnsafeCommentServiceServer

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

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

type UnsafeLikeServiceServer

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

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

type UnsafePostServiceServer

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

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

type UpdateCommentReply

type UpdateCommentReply struct {
	// contains filtered or unexported fields
}

func (*UpdateCommentReply) Descriptor deprecated

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

Deprecated: Use UpdateCommentReply.ProtoReflect.Descriptor instead.

func (*UpdateCommentReply) ProtoMessage

func (*UpdateCommentReply) ProtoMessage()

func (*UpdateCommentReply) ProtoReflect

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

func (*UpdateCommentReply) Reset

func (x *UpdateCommentReply) Reset()

func (*UpdateCommentReply) String

func (x *UpdateCommentReply) String() string

type UpdateCommentRequest

type UpdateCommentRequest struct {
	// contains filtered or unexported fields
}

func (*UpdateCommentRequest) Descriptor deprecated

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

Deprecated: Use UpdateCommentRequest.ProtoReflect.Descriptor instead.

func (*UpdateCommentRequest) ProtoMessage

func (*UpdateCommentRequest) ProtoMessage()

func (*UpdateCommentRequest) ProtoReflect

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

func (*UpdateCommentRequest) Reset

func (x *UpdateCommentRequest) Reset()

func (*UpdateCommentRequest) String

func (x *UpdateCommentRequest) String() string

type UpdateLikeReply

type UpdateLikeReply struct {
	// contains filtered or unexported fields
}

func (*UpdateLikeReply) Descriptor deprecated

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

Deprecated: Use UpdateLikeReply.ProtoReflect.Descriptor instead.

func (*UpdateLikeReply) ProtoMessage

func (*UpdateLikeReply) ProtoMessage()

func (*UpdateLikeReply) ProtoReflect

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

func (*UpdateLikeReply) Reset

func (x *UpdateLikeReply) Reset()

func (*UpdateLikeReply) String

func (x *UpdateLikeReply) String() string

type UpdateLikeRequest

type UpdateLikeRequest struct {
	// contains filtered or unexported fields
}

func (*UpdateLikeRequest) Descriptor deprecated

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

Deprecated: Use UpdateLikeRequest.ProtoReflect.Descriptor instead.

func (*UpdateLikeRequest) ProtoMessage

func (*UpdateLikeRequest) ProtoMessage()

func (*UpdateLikeRequest) ProtoReflect

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

func (*UpdateLikeRequest) Reset

func (x *UpdateLikeRequest) Reset()

func (*UpdateLikeRequest) String

func (x *UpdateLikeRequest) String() string

type UpdatePostReply

type UpdatePostReply struct {
	// contains filtered or unexported fields
}

更新帖子响应,暂时不提供

func (*UpdatePostReply) Descriptor deprecated

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

Deprecated: Use UpdatePostReply.ProtoReflect.Descriptor instead.

func (*UpdatePostReply) ProtoMessage

func (*UpdatePostReply) ProtoMessage()

func (*UpdatePostReply) ProtoReflect

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

func (*UpdatePostReply) Reset

func (x *UpdatePostReply) Reset()

func (*UpdatePostReply) String

func (x *UpdatePostReply) String() string

type UpdatePostRequest

type UpdatePostRequest struct {
	// contains filtered or unexported fields
}

更新帖子请求,暂时不提供

func (*UpdatePostRequest) Descriptor deprecated

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

Deprecated: Use UpdatePostRequest.ProtoReflect.Descriptor instead.

func (*UpdatePostRequest) ProtoMessage

func (*UpdatePostRequest) ProtoMessage()

func (*UpdatePostRequest) ProtoReflect

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

func (*UpdatePostRequest) Reset

func (x *UpdatePostRequest) Reset()

func (*UpdatePostRequest) String

func (x *UpdatePostRequest) String() string

type Video

type Video struct {
	VideoKey string  `protobuf:"bytes,1,opt,name=video_key,json=videoKey,proto3" json:"video_key,omitempty"` // 视频key
	VideoUrl string  `protobuf:"bytes,2,opt,name=video_url,json=videoUrl,proto3" json:"video_url,omitempty"` // 视频完成url
	CoverKey string  `protobuf:"bytes,3,opt,name=cover_key,json=coverKey,proto3" json:"cover_key,omitempty"` // 视频封面key
	CoverUrl string  `protobuf:"bytes,4,opt,name=cover_url,json=coverUrl,proto3" json:"cover_url,omitempty"` // 视频封面url
	Duration float32 `protobuf:"fixed32,5,opt,name=duration,proto3" json:"duration,omitempty"`               // 视频长度
	Width    int32   `protobuf:"varint,6,opt,name=width,proto3" json:"width,omitempty"`                      // 视频封面宽
	Height   int32   `protobuf:"varint,7,opt,name=height,proto3" json:"height,omitempty"`                    // 视频封面高
	// contains filtered or unexported fields
}

视频内容

func (*Video) Descriptor deprecated

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

Deprecated: Use Video.ProtoReflect.Descriptor instead.

func (*Video) GetCoverKey

func (x *Video) GetCoverKey() string

func (*Video) GetCoverUrl

func (x *Video) GetCoverUrl() string

func (*Video) GetDuration

func (x *Video) GetDuration() float32

func (*Video) GetHeight

func (x *Video) GetHeight() int32

func (*Video) GetVideoKey

func (x *Video) GetVideoKey() string

func (*Video) GetVideoUrl

func (x *Video) GetVideoUrl() string

func (*Video) GetWidth

func (x *Video) GetWidth() int32

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