Documentation ¶
Index ¶
- type Dao
- func (d *Dao) AvidVideoMap(ctx context.Context, avids []int64) (avidVideoMap map[int64]*model.UpCardVideo, err error)
- func (d *Dao) Close()
- func (d *Dao) CountUpCard(ctx context.Context) (total int, err error)
- func (d *Dao) GetUpInfo(ctx context.Context, mid int64) (card *model.UpCardInfo, err error)
- func (d *Dao) ListAVID(ctx context.Context, mid int64) (avids []int64, err error)
- func (d *Dao) ListUpAccount(ctx context.Context, mid int64) (accounts []*model.UpCardAccount, err error)
- func (d *Dao) ListUpBase(c context.Context, size int, lastID int64, where string) (idMids map[int64]int64, err error)
- func (d *Dao) ListUpImage(ctx context.Context, mid int64) (images []*model.UpCardImage, err error)
- func (d *Dao) ListUpInfo(ctx context.Context, offset uint, size uint) (infos []*model.UpCardInfo, err error)
- func (d *Dao) ListUpMID(ctx context.Context) (mids []int64, err error)
- func (d *Dao) ListVideoArchive(ctx context.Context, avids []int64) (videos []*model.UpCardVideo, err error)
- func (d *Dao) MidAccountsMap(ctx context.Context, mids []int64) (midAccountsMap map[int64][]*model.UpCardAccount, err error)
- func (d *Dao) MidAvidsMap(ctx context.Context, mids []int64) (midAvidsMap map[int64][]int64, err error)
- func (d *Dao) MidImagesMap(ctx context.Context, mids []int64) (midImagesMap map[int64][]*model.UpCardImage, err error)
- func (d *Dao) MidUpInfoMap(ctx context.Context, mids []int64) (midUpInfoMap map[int64]*model.UpCardInfo, err error)
- func (d *Dao) Ping(c context.Context) (err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Dao ¶
type Dao struct {
// contains filtered or unexported fields
}
Dao is redis dao.
func (*Dao) AvidVideoMap ¶
func (d *Dao) AvidVideoMap(ctx context.Context, avids []int64) (avidVideoMap map[int64]*model.UpCardVideo, err error)
AvidVideoMap get <avid, video> map by avids
func (*Dao) CountUpCard ¶
CountUpCard count up num
func (*Dao) ListUpAccount ¶
func (d *Dao) ListUpAccount(ctx context.Context, mid int64) (accounts []*model.UpCardAccount, err error)
ListUpAccount list up accounts by mid
func (*Dao) ListUpBase ¶
func (d *Dao) ListUpBase(c context.Context, size int, lastID int64, where string) (idMids map[int64]int64, err error)
ListUpBase list <id, mid> k-v pairs
func (*Dao) ListUpImage ¶
ListUpImage list up images by mid
func (*Dao) ListUpInfo ¶
func (d *Dao) ListUpInfo(ctx context.Context, offset uint, size uint) (infos []*model.UpCardInfo, err error)
ListUpInfo page list up mids
func (*Dao) ListVideoArchive ¶
func (d *Dao) ListVideoArchive(ctx context.Context, avids []int64) (videos []*model.UpCardVideo, err error)
ListVideoArchive list videos by avids
func (*Dao) MidAccountsMap ¶
func (d *Dao) MidAccountsMap(ctx context.Context, mids []int64) (midAccountsMap map[int64][]*model.UpCardAccount, err error)
MidAccountsMap get <mid, Accounts> map by mids
func (*Dao) MidAvidsMap ¶
func (d *Dao) MidAvidsMap(ctx context.Context, mids []int64) (midAvidsMap map[int64][]int64, err error)
MidAvidsMap get <mid, Avids> map by mids
func (*Dao) MidImagesMap ¶
func (d *Dao) MidImagesMap(ctx context.Context, mids []int64) (midImagesMap map[int64][]*model.UpCardImage, err error)
MidImagesMap get <mid, Images> map by mids
func (*Dao) MidUpInfoMap ¶
func (d *Dao) MidUpInfoMap(ctx context.Context, mids []int64) (midUpInfoMap map[int64]*model.UpCardInfo, err error)
MidUpInfoMap get <mid, UpInfo> map by mids
Click to show internal directories.
Click to hide internal directories.