| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316 |
- // Code generated by goctl. DO NOT EDIT.
- // Source: slowwild.proto
- package slowwildserverclient
- import (
- "context"
- "git.banshen.xyz/huangguangrong/slow_wild_protobuff/slowwild/slowwildserver"
- "github.com/zeromicro/go-zero/zrpc"
- "google.golang.org/grpc"
- )
- type (
- CommentItem = slowwildserver.CommentItem
- CreatePostReq = slowwildserver.CreatePostReq
- CreatePostRsp = slowwildserver.CreatePostRsp
- FindUserReq = slowwildserver.FindUserReq
- FindUserResp = slowwildserver.FindUserResp
- FollowUserInfo = slowwildserver.FollowUserInfo
- FollowUserReq = slowwildserver.FollowUserReq
- FollowUserRes = slowwildserver.FollowUserRes
- GetFollowReq = slowwildserver.GetFollowReq
- GetFollowRes = slowwildserver.GetFollowRes
- GetFollowingReq = slowwildserver.GetFollowingReq
- GetFollowingRes = slowwildserver.GetFollowingRes
- GetPostCommentListReq = slowwildserver.GetPostCommentListReq
- GetPostCommentListRsp = slowwildserver.GetPostCommentListRsp
- GetPostListItem = slowwildserver.GetPostListItem
- GetPostListReq = slowwildserver.GetPostListReq
- GetPostListRsp = slowwildserver.GetPostListRsp
- GetPostReq = slowwildserver.GetPostReq
- GetPostRsp = slowwildserver.GetPostRsp
- GetReplyListReq = slowwildserver.GetReplyListReq
- GetReplyListRsp = slowwildserver.GetReplyListRsp
- GetTagListReq = slowwildserver.GetTagListReq
- GetTagListRsp = slowwildserver.GetTagListRsp
- GetTagReq = slowwildserver.GetTagReq
- GetTagRsp = slowwildserver.GetTagRsp
- GetUserInfoReq = slowwildserver.GetUserInfoReq
- GetUserInfoResp = slowwildserver.GetUserInfoResp
- GetUserProfileReq = slowwildserver.GetUserProfileReq
- GetUserProfileRes = slowwildserver.GetUserProfileRes
- LoginAndRegisterRsp = slowwildserver.LoginAndRegisterRsp
- LoginReq = slowwildserver.LoginReq
- PostCollectionReq = slowwildserver.PostCollectionReq
- PostCollectionRsp = slowwildserver.PostCollectionRsp
- PostCommentReq = slowwildserver.PostCommentReq
- PostCommentRsp = slowwildserver.PostCommentRsp
- PostCommentUpvoteReq = slowwildserver.PostCommentUpvoteReq
- PostCommentUpvoteRsp = slowwildserver.PostCommentUpvoteRsp
- PostReplyReq = slowwildserver.PostReplyReq
- PostReplyRsp = slowwildserver.PostReplyRsp
- PostShareReq = slowwildserver.PostShareReq
- PostShareRsp = slowwildserver.PostShareRsp
- PostUpvoteReq = slowwildserver.PostUpvoteReq
- PostUpvoteRsp = slowwildserver.PostUpvoteRsp
- RegisterReq = slowwildserver.RegisterReq
- RepliesItem = slowwildserver.RepliesItem
- SearchUsernameItem = slowwildserver.SearchUsernameItem
- SearchUsernameReq = slowwildserver.SearchUsernameReq
- SearchUsernameRes = slowwildserver.SearchUsernameRes
- TagItem = slowwildserver.TagItem
- UnFollowUserReq = slowwildserver.UnFollowUserReq
- UnFollowUserRes = slowwildserver.UnFollowUserRes
- UserEntity = slowwildserver.UserEntity
- UserInfo = slowwildserver.UserInfo
- PostDeleteReq = slowwildserver.PostDeleteReq
- PostDeleteRsp = slowwildserver.PostDeleteRsp
- CommentDeleteReq = slowwildserver.CommentDeleteReq
- CommentDeleteRsp = slowwildserver.CommentDeleteRsp
- GetUserPostCollectionListReq = slowwildserver.GetUserPostCollectionListReq
- GetUserPostCollectionListRsp = slowwildserver.GetUserPostCollectionListRsp
- GetUserPostLikeListReq = slowwildserver.GetUserPostLikeListReq
- GetUserPostLikeListRsp = slowwildserver.GetUserPostLikeListRsp
- GetUserPostListReq = slowwildserver.GetUserPostListReq
- GetUserPostListRsp = slowwildserver.GetUserPostListRsp
- SlowWildServer interface {
- // 用户登录
- Login(ctx context.Context, in *LoginReq, opts ...grpc.CallOption) (*LoginAndRegisterRsp, error)
- // 用户注册
- Register(ctx context.Context, in *RegisterReq, opts ...grpc.CallOption) (*LoginAndRegisterRsp, error)
- // 获取用户信息
- GetUserInfo(ctx context.Context, in *GetUserInfoReq, opts ...grpc.CallOption) (*GetUserInfoResp, error)
- // 查询用户信息
- FindUser(ctx context.Context, in *FindUserReq, opts ...grpc.CallOption) (*FindUserResp, error)
- // 关注用户
- UserFollow(ctx context.Context, in *FollowUserReq, opts ...grpc.CallOption) (*FollowUserRes, error)
- // 取消关注用户
- UnUserFollow(ctx context.Context, in *UnFollowUserReq, opts ...grpc.CallOption) (*UnFollowUserRes, error)
- // 获取我得粉丝
- GetFans(ctx context.Context, in *GetFollowingReq, opts ...grpc.CallOption) (*GetFollowingRes, error)
- // 查询我的关注
- GetFollows(ctx context.Context, in *GetFollowingReq, opts ...grpc.CallOption) (*GetFollowingRes, error)
- // 查询用户的详细信息
- GetUserProfile(ctx context.Context, in *GetUserProfileReq, opts ...grpc.CallOption) (*GetUserProfileRes, error)
- // 搜索用户名称
- SearchUsername(ctx context.Context, in *SearchUsernameReq, opts ...grpc.CallOption) (*SearchUsernameRes, error)
- // 发布帖子
- CreatePost(ctx context.Context, in *CreatePostReq, opts ...grpc.CallOption) (*CreatePostRsp, error)
- // 获取话题列表
- GetTagList(ctx context.Context, in *GetTagListReq, opts ...grpc.CallOption) (*GetTagListRsp, error)
- // 获取话题详情
- GetTag(ctx context.Context, in *GetTagReq, opts ...grpc.CallOption) (*GetTagRsp, error)
- // 获取帖子列表
- GetPostList(ctx context.Context, in *GetPostListReq, opts ...grpc.CallOption) (*GetPostListRsp, error)
- // 获取帖子详情
- GetPost(ctx context.Context, in *GetPostReq, opts ...grpc.CallOption) (*GetPostRsp, error)
- // 点赞帖子
- PostUpvote(ctx context.Context, in *PostUpvoteReq, opts ...grpc.CallOption) (*PostUpvoteRsp, error)
- // 分享帖子
- PostShare(ctx context.Context, in *PostShareReq, opts ...grpc.CallOption) (*PostShareRsp, error)
- // 收藏帖子
- PostCollection(ctx context.Context, in *PostCollectionReq, opts ...grpc.CallOption) (*PostCollectionRsp, error)
- // 发布评论
- PostComment(ctx context.Context, in *PostCommentReq, opts ...grpc.CallOption) (*PostCommentRsp, error)
- // 发布回复
- PostReply(ctx context.Context, in *PostReplyReq, opts ...grpc.CallOption) (*PostReplyRsp, error)
- // 获取评论列表
- GetPostCommentList(ctx context.Context, in *GetPostCommentListReq, opts ...grpc.CallOption) (*GetPostCommentListRsp, error)
- // 获取回复列表
- GetReplyList(ctx context.Context, in *GetReplyListReq, opts ...grpc.CallOption) (*GetReplyListRsp, error)
- // 评论点赞
- PostCommentUpvote(ctx context.Context, in *PostCommentUpvoteReq, opts ...grpc.CallOption) (*PostCommentUpvoteRsp, error)
- // 删除帖子
- PostDelete(ctx context.Context, in *PostDeleteReq, opts ...grpc.CallOption) (*PostDeleteRsp, error)
- // 删除回复/评论
- CommentDelete(ctx context.Context, in *CommentDeleteReq, opts ...grpc.CallOption) (*CommentDeleteRsp, error)
- // 获取用户发布的帖子
- GetUserPostList(ctx context.Context, in *GetUserPostListReq, opts ...grpc.CallOption) (*GetUserPostListRsp, error)
- // 获取用户收藏的帖子
- GetUserPostCollectionList(ctx context.Context, in *GetUserPostCollectionListReq, opts ...grpc.CallOption) (*GetUserPostCollectionListRsp, error)
- // 获取用户点赞过的帖子
- GetUserPostLikeList(ctx context.Context, in *GetUserPostLikeListReq, opts ...grpc.CallOption) (*GetUserPostLikeListRsp, error)
- }
- defaultSlowWildServer struct {
- cli zrpc.Client
- }
- )
- func NewSlowWildServer(cli zrpc.Client) SlowWildServer {
- return &defaultSlowWildServer{
- cli: cli,
- }
- }
- // 用户登录
- func (m *defaultSlowWildServer) Login(ctx context.Context, in *LoginReq, opts ...grpc.CallOption) (*LoginAndRegisterRsp, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.Login(ctx, in, opts...)
- }
- // 用户注册
- func (m *defaultSlowWildServer) Register(ctx context.Context, in *RegisterReq, opts ...grpc.CallOption) (*LoginAndRegisterRsp, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.Register(ctx, in, opts...)
- }
- // 获取用户信息
- func (m *defaultSlowWildServer) GetUserInfo(ctx context.Context, in *GetUserInfoReq, opts ...grpc.CallOption) (*GetUserInfoResp, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.GetUserInfo(ctx, in, opts...)
- }
- // 查询用户信息
- func (m *defaultSlowWildServer) FindUser(ctx context.Context, in *FindUserReq, opts ...grpc.CallOption) (*FindUserResp, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.FindUser(ctx, in, opts...)
- }
- // 关注用户
- func (m *defaultSlowWildServer) UserFollow(ctx context.Context, in *FollowUserReq, opts ...grpc.CallOption) (*FollowUserRes, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.UserFollow(ctx, in, opts...)
- }
- // 取消关注用户
- func (m *defaultSlowWildServer) UnUserFollow(ctx context.Context, in *UnFollowUserReq, opts ...grpc.CallOption) (*UnFollowUserRes, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.UnUserFollow(ctx, in, opts...)
- }
- // 获取我得粉丝
- func (m *defaultSlowWildServer) GetFans(ctx context.Context, in *GetFollowingReq, opts ...grpc.CallOption) (*GetFollowingRes, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.GetFans(ctx, in, opts...)
- }
- // 查询我的关注
- func (m *defaultSlowWildServer) GetFollows(ctx context.Context, in *GetFollowingReq, opts ...grpc.CallOption) (*GetFollowingRes, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.GetFollows(ctx, in, opts...)
- }
- // 查询用户的详细信息
- func (m *defaultSlowWildServer) GetUserProfile(ctx context.Context, in *GetUserProfileReq, opts ...grpc.CallOption) (*GetUserProfileRes, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.GetUserProfile(ctx, in, opts...)
- }
- // 搜索用户名称
- func (m *defaultSlowWildServer) SearchUsername(ctx context.Context, in *SearchUsernameReq, opts ...grpc.CallOption) (*SearchUsernameRes, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.SearchUsername(ctx, in, opts...)
- }
- // 发布帖子
- func (m *defaultSlowWildServer) CreatePost(ctx context.Context, in *CreatePostReq, opts ...grpc.CallOption) (*CreatePostRsp, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.CreatePost(ctx, in, opts...)
- }
- // 获取话题列表
- func (m *defaultSlowWildServer) GetTagList(ctx context.Context, in *GetTagListReq, opts ...grpc.CallOption) (*GetTagListRsp, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.GetTagList(ctx, in, opts...)
- }
- // 获取话题详情
- func (m *defaultSlowWildServer) GetTag(ctx context.Context, in *GetTagReq, opts ...grpc.CallOption) (*GetTagRsp, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.GetTag(ctx, in, opts...)
- }
- // 获取帖子列表
- func (m *defaultSlowWildServer) GetPostList(ctx context.Context, in *GetPostListReq, opts ...grpc.CallOption) (*GetPostListRsp, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.GetPostList(ctx, in, opts...)
- }
- // 获取帖子详情
- func (m *defaultSlowWildServer) GetPost(ctx context.Context, in *GetPostReq, opts ...grpc.CallOption) (*GetPostRsp, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.GetPost(ctx, in, opts...)
- }
- // 点赞帖子
- func (m *defaultSlowWildServer) PostUpvote(ctx context.Context, in *PostUpvoteReq, opts ...grpc.CallOption) (*PostUpvoteRsp, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.PostUpvote(ctx, in, opts...)
- }
- // 分享帖子
- func (m *defaultSlowWildServer) PostShare(ctx context.Context, in *PostShareReq, opts ...grpc.CallOption) (*PostShareRsp, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.PostShare(ctx, in, opts...)
- }
- // 收藏帖子
- func (m *defaultSlowWildServer) PostCollection(ctx context.Context, in *PostCollectionReq, opts ...grpc.CallOption) (*PostCollectionRsp, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.PostCollection(ctx, in, opts...)
- }
- // 发布评论
- func (m *defaultSlowWildServer) PostComment(ctx context.Context, in *PostCommentReq, opts ...grpc.CallOption) (*PostCommentRsp, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.PostComment(ctx, in, opts...)
- }
- // 发布回复
- func (m *defaultSlowWildServer) PostReply(ctx context.Context, in *PostReplyReq, opts ...grpc.CallOption) (*PostReplyRsp, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.PostReply(ctx, in, opts...)
- }
- // 获取评论列表
- func (m *defaultSlowWildServer) GetPostCommentList(ctx context.Context, in *GetPostCommentListReq, opts ...grpc.CallOption) (*GetPostCommentListRsp, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.GetPostCommentList(ctx, in, opts...)
- }
- // 获取回复列表
- func (m *defaultSlowWildServer) GetReplyList(ctx context.Context, in *GetReplyListReq, opts ...grpc.CallOption) (*GetReplyListRsp, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.GetReplyList(ctx, in, opts...)
- }
- // 评论点赞
- func (m *defaultSlowWildServer) PostCommentUpvote(ctx context.Context, in *PostCommentUpvoteReq, opts ...grpc.CallOption) (*PostCommentUpvoteRsp, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.PostCommentUpvote(ctx, in, opts...)
- }
- // 删除帖子
- func (m *defaultSlowWildServer) PostDelete(ctx context.Context, in *PostDeleteReq, opts ...grpc.CallOption) (*PostDeleteRsp, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.PostDelete(ctx, in, opts...)
- }
- // 删除回复/评论
- func (m *defaultSlowWildServer) CommentDelete(ctx context.Context, in *CommentDeleteReq, opts ...grpc.CallOption) (*CommentDeleteRsp, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.CommentDelete(ctx, in, opts...)
- }
- // 获取用户发布的帖子
- func (m *defaultSlowWildServer) GetUserPostList(ctx context.Context, in *GetUserPostListReq, opts ...grpc.CallOption) (*GetUserPostListRsp, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.GetUserPostList(ctx, in, opts...)
- }
- // 获取用户收藏的帖子
- func (m *defaultSlowWildServer) GetUserPostCollectionList(ctx context.Context, in *GetUserPostCollectionListReq, opts ...grpc.CallOption) (*GetUserPostCollectionListRsp, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.GetUserPostCollectionList(ctx, in, opts...)
- }
- // 获取用户点赞过的帖子
- func (m *defaultSlowWildServer) GetUserPostLikeList(ctx context.Context, in *GetUserPostLikeListReq, opts ...grpc.CallOption) (*GetUserPostLikeListRsp, error) {
- client := slowwildserver.NewSlowWildServerClient(m.cli.Conn())
- return client.GetUserPostLikeList(ctx, in, opts...)
- }
|