Documentation ¶
Index ¶
- Constants
- func App531ABTest(ctx context.Context, content string, build string, platform string) (grayType int64)
- func AppFilterGold(ctx context.Context, originResult *v1pb.LiveAnchorResp) (resp []*v1pb.LiveAnchorResp_Rooms, err error)
- func AppFilterRuleFansMedal(ctx context.Context, originResult *v1pb.LiveAnchorResp, targetUIDs []int64) (resp []*v1pb.LiveAnchorResp_Rooms, err error)
- func AppSortRuleGold(ctx context.Context, originResult *v1pb.LiveAnchorResp) (resp []*v1pb.LiveAnchorResp_Rooms)
- func AppSortRuleLiveTime(originResult *v1pb.LiveAnchorResp) (resp []*v1pb.LiveAnchorResp_Rooms)
- func AppSortRuleOnline(originResult *v1pb.LiveAnchorResp) (resp []*v1pb.LiveAnchorResp_Rooms)
- func GetChunkInfo(rpcName string) (rpcChunkSize int64, RPCTimeout int64, err error)
- func GetFansMedal(ctx context.Context, req *fansMedalV1.FansMedalTargetsWithMedalReq) (fansResult map[int64]bool, err error)
- func GetGiftInfo(ctx context.Context) (giftInfo map[int64]int64, err error)
- func GetGrayRule(ctx context.Context, req *userExV1.GrayRuleGetByMarkReq) (extResult *userExV1.GrayRuleGetByMarkResp_Data, err error)
- func GetLastLiveTime(ctx context.Context, rolaids []int64) (literature map[string]string, err error)
- func GetPkID(ctx context.Context, req *avV1.PkGetPkIdsByRoomIdsReq) (avResult map[string]int64, err error)
- func GetRoomInfo(ctx context.Context, input *roomV1.RoomGetStatusInfoByUidsReq) (roomResult map[int64]*roomV1.RoomGetStatusInfoByUidsResp_RoomInfo, err error)
- func GetRoomNewsInfo(ctx context.Context, rolaids *roomExV1.RoomNewsMultiGetReq) (roomNewsResult map[int64]*roomExV1.RoomNewsMultiGetResp_Data, err error)
- func GetRoomPendantInfo(ctx context.Context, req *roomV1.RoomPendantGetPendantByIdsReq) (roomNewsResult map[int64]*roomV1.RoomPendantGetPendantByIdsResp_Result, ...)
- func GetUIDFromHeader(ctx context.Context) (uid int64)
- func RParseInt(inputStr string, defaultValue int64) (output int64)
- func RoleMap(role int8) (changeType int64)
- func UIDs2roomIDs(ctx context.Context, ufos []int64) (rolaids map[int64]int64, err error)
- type ChunkCallInfo
- type ErrLogStrut
- type Gray
- type GrayList
- type GrayRule
- type Pair
- type PairList
- type SendGift
- type SortLiveTime
- type SortOnlineTime
- type SortUIDGift
Constants ¶
const ( // AppFilterDefault implementation // 默认排序 AppFilterDefault = 0 // AppFilterFansMedal implementation // 只看我有粉丝勋章的 AppFilterFansMedal = 1 // AppFilterGoldType implementation // 按照金瓜子排序 AppFilterGoldType = 2 )
const ( // AppSortDefaultT ... // 默认排序 AppSortDefaultT = 0 // AppSortRuleLiveTimeT ... // 开播时间倒序 AppSortRuleLiveTimeT = 1 // AppSortRuleOnlineT ... // 人气值倒序 AppSortRuleOnlineT = 2 // AppSortRuleGoldT ... // 金瓜子倒序 AppSortRuleGoldT = 3 )
const ( // AccountGRPC ... // 主站grpc用户信息 AccountGRPC = "Cards3" // LiveUserExpGRPC ... // 直播用户经验grpc LiveUserExpGRPC = "xuserExp" // FansNum ... // 直播粉丝 FansNum = "GetUserFcBatch" // LiveDomain implementation // 域名 LiveDomain = "http://live.bilibili.com/" // BoastURL implementation // 秒开url BoastURL = "?broadcast_type=" // GoRoutingErr ... // 协程wait错误 GoRoutingErr = "协程等待数据错误" // App533CardType implementation // 大卡类型 App533CardType = 1 // PendentMobileBadge implementation // 角标类型 PendentMobileBadge = "mobile_index_badge" // PendentPosition implementation // 角标位置 PendentPosition = 2 // App531GrayRule implementation // 灰度策略 App531GrayRule = "r_big_card" // App536GrayRule implementation // 灰度策略 App536GrayRule = "r_homepage_card536" // SelfUID implementation // 调试UID SelfUID = 22973824 // DummyUIDEnable implementation // 调试开 DummyUIDEnable = 1 )
Variables ¶
This section is empty.
Functions ¶
func App531ABTest ¶
func App531ABTest(ctx context.Context, content string, build string, platform string) (grayType int64)
App531ABTest ... ABTest
func AppFilterGold ¶
func AppFilterGold(ctx context.Context, originResult *v1pb.LiveAnchorResp) (resp []*v1pb.LiveAnchorResp_Rooms, err error)
AppFilterGold implementation [app端关注二级页]过滤送礼
func AppFilterRuleFansMedal ¶
func AppFilterRuleFansMedal(ctx context.Context, originResult *v1pb.LiveAnchorResp, targetUIDs []int64) (resp []*v1pb.LiveAnchorResp_Rooms, err error)
AppFilterRuleFansMedal implementation [app端关注二级页]过滤粉丝勋章
func AppSortRuleGold ¶
func AppSortRuleGold(ctx context.Context, originResult *v1pb.LiveAnchorResp) (resp []*v1pb.LiveAnchorResp_Rooms)
AppSortRuleGold implementation [app端关注二级页]按照送礼排序
func AppSortRuleLiveTime ¶
func AppSortRuleLiveTime(originResult *v1pb.LiveAnchorResp) (resp []*v1pb.LiveAnchorResp_Rooms)
AppSortRuleLiveTime implementation [app端关注二级页]按照开播时间排序
func AppSortRuleOnline ¶
func AppSortRuleOnline(originResult *v1pb.LiveAnchorResp) (resp []*v1pb.LiveAnchorResp_Rooms)
AppSortRuleOnline implementation [app端关注二级页]按照人气值排序
func GetChunkInfo ¶
GetChunkInfo ... 获取分块信息
func GetFansMedal ¶
func GetFansMedal(ctx context.Context, req *fansMedalV1.FansMedalTargetsWithMedalReq) (fansResult map[int64]bool, err error)
GetFansMedal ... 获取粉丝勋章佩戴信息
func GetGiftInfo ¶
GetGiftInfo ... 获取送礼信息
func GetGrayRule ¶
func GetGrayRule(ctx context.Context, req *userExV1.GrayRuleGetByMarkReq) (extResult *userExV1.GrayRuleGetByMarkResp_Data, err error)
GetGrayRule ... 获取灰度规则信息
func GetLastLiveTime ¶
func GetLastLiveTime(ctx context.Context, rolaids []int64) (literature map[string]string, err error)
GetLastLiveTime ... 获取Record信息
func GetPkID ¶
func GetPkID(ctx context.Context, req *avV1.PkGetPkIdsByRoomIdsReq) (avResult map[string]int64, err error)
GetPkID ... 获取PkId信息
func GetRoomInfo ¶
func GetRoomInfo(ctx context.Context, input *roomV1.RoomGetStatusInfoByUidsReq) (roomResult map[int64]*roomV1.RoomGetStatusInfoByUidsResp_RoomInfo, err error)
GetRoomInfo ... 获取room信息
func GetRoomNewsInfo ¶
func GetRoomNewsInfo(ctx context.Context, rolaids *roomExV1.RoomNewsMultiGetReq) (roomNewsResult map[int64]*roomExV1.RoomNewsMultiGetResp_Data, err error)
GetRoomNewsInfo ... 获取公告信息
func GetRoomPendantInfo ¶
func GetRoomPendantInfo(ctx context.Context, req *roomV1.RoomPendantGetPendantByIdsReq) (roomNewsResult map[int64]*roomV1.RoomPendantGetPendantByIdsResp_Result, err error)
GetRoomPendantInfo ... 获取角标信息
func GetUIDFromHeader ¶
GetUIDFromHeader ... 获取uid
Types ¶
type ChunkCallInfo ¶
type ChunkCallInfo struct { ParamsName string URLName string ChunkSize int64 ChunkNum int64 RPCTimeout int64 }
ChunkCallInfo ... 日志结构体
type ErrLogStrut ¶
type ErrLogStrut struct { Code int64 Msg string ErrDesc string ErrType string URLName string RPCTimeout int64 ChunkSize int64 ChunkNum int64 ErrorPtr *error }
ErrLogStrut ... 自定义ErrLog结构
type GrayRule ¶
type GrayRule struct { Name string `json:"name"` Mark string `json:"mark"` Value string `json:"value"` }
GrayRule ... 自定义灰度策略
type SendGift ¶
type SendGift struct { Mid int64 // contains filtered or unexported fields }
SendGift ... [app端关注二级页]按照金瓜子排序结构
type SortLiveTime ¶
type SortLiveTime []*v1pb.LiveAnchorResp_Rooms
SortLiveTime ... implementation [app端关注二级页]按照开播时间排序
func (SortLiveTime) Len ¶
func (p SortLiveTime) Len() int
AppSortRuleLiveTime implementation [app端关注二级页]按照开播时间排序
func (SortLiveTime) Less ¶
func (p SortLiveTime) Less(i, j int) bool
AppSortRuleLiveTime implementation [app端关注二级页]按照开播时间排序
func (SortLiveTime) Swap ¶
func (p SortLiveTime) Swap(i, j int)
AppSortRuleLiveTime implementation [app端关注二级页]按照开播时间排序
type SortOnlineTime ¶
type SortOnlineTime []*v1pb.LiveAnchorResp_Rooms
SortOnlineTime ... implementation [app端关注二级页]按照开播时间排序
func (SortOnlineTime) Len ¶
func (p SortOnlineTime) Len() int
AppSortRuleLiveTime implementation [app端关注二级页]按照开播时间排序
func (SortOnlineTime) Less ¶
func (p SortOnlineTime) Less(i, j int) bool
AppSortRuleLiveTime implementation [app端关注二级页]按照开播时间排序
func (SortOnlineTime) Swap ¶
func (p SortOnlineTime) Swap(i, j int)
AppSortRuleLiveTime implementation [app端关注二级页]按照开播时间排序