Documentation ¶
Index ¶
- Constants
- func ExampleReadFrameAsJpeg(inFileName string, frameNum int) io.Reader
- type CommentService
- func (c *CommentService) DoAddCommentAction(loginUserId, videoId int64, commentText string) (*common.CommentVo, error)
- func (c *CommentService) DoCommentList(loginUserId, videoId int64) ([]common.CommentVo, error)
- func (c *CommentService) DoDelCommentAction(loginUserId, videoId, commentId int64) error
- type FavoriteService
- type FeedService
- type PublishService
- type RelationService
- type UserService
Constants ¶
View Source
const MaxPasswordLen = 32
View Source
const MaxUsernameLen = 32
View Source
const ResourceBase = "http://47.108.239.8:8085/static/"
ResourceBase 如果映射的域名和改了,需要更改这个配置
Variables ¶
This section is empty.
Functions ¶
Types ¶
type CommentService ¶
type CommentService struct { }
func NewCommentServiceInstance ¶
func NewCommentServiceInstance() *CommentService
NewCommentServiceInstance 返回一个评论服务类的指针变量,可以方便调用该结构体的方法
func (*CommentService) DoAddCommentAction ¶
func (c *CommentService) DoAddCommentAction(loginUserId, videoId int64, commentText string) (*common.CommentVo, error)
DoAddCommentAction 新增评论功能
func (*CommentService) DoCommentList ¶
func (c *CommentService) DoCommentList(loginUserId, videoId int64) ([]common.CommentVo, error)
DoCommentList 获取评论列表
func (*CommentService) DoDelCommentAction ¶
func (c *CommentService) DoDelCommentAction(loginUserId, videoId, commentId int64) error
DoDelCommentAction 删除评论功能
type FavoriteService ¶
type FavoriteService struct { }
func NewFavoriteServiceInstance ¶
func NewFavoriteServiceInstance() *FavoriteService
NewFavoriteServiceInstance 返回一个点赞服务类的指针变量,可以方便调用该结构体的方法
func (*FavoriteService) DoFavoriteAction ¶
func (f *FavoriteService) DoFavoriteAction(userId, videoId int64, actionType int32) error
DoFavoriteAction 点赞
func (*FavoriteService) DoFavoriteList ¶
func (f *FavoriteService) DoFavoriteList(userId, loginUserId int64) ([]common.VideoVo, error)
DoFavoriteList 获取点赞列表
type FeedService ¶
type FeedService struct { }
func NewFeedServiceInstance ¶
func NewFeedServiceInstance() *FeedService
NewFeedServiceInstance 返回一个视频流服务类的指针变量,可以方便调用该结构体的方法
type PublishService ¶
type PublishService struct { }
func NewPublishServiceInstance ¶
func NewPublishServiceInstance() *PublishService
NewPublishServiceInstance 返回一个发布视频服务类的指针变量,可以方便调用该结构体的方法
func (*PublishService) DoPublishList ¶
func (p *PublishService) DoPublishList(userId, loginUserId int64) ([]common.VideoVo, error)
DoPublishList 发布视频列表
func (*PublishService) DoPublishVideo ¶
DoPublishVideo 发布视频
type RelationService ¶
type RelationService struct { }
func NewRelationServiceInstance ¶
func NewRelationServiceInstance() *RelationService
NewRelationServiceInstance 返回一个关注服务类的指针变量,可以方便调用该结构体的方法
func (*RelationService) DoRelationAction ¶
func (r *RelationService) DoRelationAction(userId, toUserId, actionType int64) error
DoRelationAction 关注
func (*RelationService) DoRelationFollowList ¶
func (r *RelationService) DoRelationFollowList(userId, loginUserId int64) ([]common.UserVo, error)
DoRelationFollowList 获取关注列表
func (*RelationService) DoRelationFollowerList ¶
func (r *RelationService) DoRelationFollowerList(userId, loginUserId int64) ([]common.UserVo, error)
DoRelationFollowerList 获取粉丝列表
type UserService ¶
type UserService struct { }
func NewUserServiceInstance ¶
func NewUserServiceInstance() *UserService
NewUserServiceInstance 返回一个用户服务类的指针变量,可以方便调用该结构体的方法
func (*UserService) DoLogin ¶
func (u *UserService) DoLogin(userName, password string) (*repository.User, string, error)
DoLogin 登录
func (*UserService) DoRegister ¶
func (u *UserService) DoRegister(userName, password string) (int64, string, error)
DoRegister 注册
func (*UserService) DoUserInfo ¶
func (u *UserService) DoUserInfo(userId, loginUserId int64) (*common.UserVo, error)
DoUserInfo 获取用户信息
Click to show internal directories.
Click to hide internal directories.