Documentation ¶
Index ¶
- type Cache
- func (c *Cache) DeleteByID(ctx context.Context, id int64) (int, error)
- func (c *Cache) Get2DModelerCount(ctx context.Context, top int) (data []entity.DesignerCount, code int, err error)
- func (c *Cache) Get3DModelerCount(ctx context.Context, top int) (data []entity.DesignerCount, code int, err error)
- func (c *Cache) GetAll(ctx context.Context, req entity.GetAllRequest) (_ []entity.Vtuber, _ int, code int, err error)
- func (c *Cache) GetAllForAgencyTree(ctx context.Context) (data []entity.Vtuber, code int, err error)
- func (c *Cache) GetAllForFamilyTree(ctx context.Context) (data []entity.Vtuber, code int, err error)
- func (c *Cache) GetAllIDs(ctx context.Context) ([]int64, int, error)
- func (c *Cache) GetAllImages(ctx context.Context, shuffle bool, limit int) (data []entity.Vtuber, code int, err error)
- func (c *Cache) GetAverageActiveTime(ctx context.Context) (data float64, code int, err error)
- func (c *Cache) GetAverageHeight(ctx context.Context) (data float64, code int, err error)
- func (c *Cache) GetAverageVideoCount(ctx context.Context) (data float64, code int, err error)
- func (c *Cache) GetAverageVideoDuration(ctx context.Context) (data float64, code int, err error)
- func (c *Cache) GetAverageWeight(ctx context.Context) (data float64, code int, err error)
- func (c *Cache) GetBirthdayCount(ctx context.Context) (data []entity.BirthdayCount, code int, err error)
- func (c *Cache) GetBloodTypeCount(ctx context.Context, top int) (data []entity.BloodTypeCount, code int, err error)
- func (c *Cache) GetByID(ctx context.Context, id int64) (data *entity.Vtuber, code int, err error)
- func (c *Cache) GetChannelTypeCount(ctx context.Context) (data []entity.ChannelTypeCount, code int, err error)
- func (c *Cache) GetCharacter2DModelers(ctx context.Context) (data []string, code int, err error)
- func (c *Cache) GetCharacter3DModelers(ctx context.Context) (data []string, code int, err error)
- func (c *Cache) GetCharacterDesigners(ctx context.Context) (data []string, code int, err error)
- func (c *Cache) GetCount(ctx context.Context) (data int, code int, err error)
- func (c *Cache) GetDebutRetireCountMonthly(ctx context.Context) (data []entity.DebutRetireCount, code int, err error)
- func (c *Cache) GetDebutRetireCountYearly(ctx context.Context) (data []entity.DebutRetireCount, code int, err error)
- func (c *Cache) GetDesignerCount(ctx context.Context, top int) (data []entity.DesignerCount, code int, err error)
- func (c *Cache) GetGenderCount(ctx context.Context) (data []entity.GenderCount, code int, err error)
- func (c *Cache) GetInAgencyCount(ctx context.Context) (data *entity.InAgencyCount, code int, err error)
- func (c *Cache) GetModelCount(ctx context.Context) (data *entity.ModelCount, code int, err error)
- func (c *Cache) GetOldActiveIDs(ctx context.Context) ([]int64, int, error)
- func (c *Cache) GetOldRetiredIDs(ctx context.Context) ([]int64, int, error)
- func (c *Cache) GetStatusCount(ctx context.Context) (data *entity.StatusCount, code int, err error)
- func (c *Cache) GetSubscriberCount(ctx context.Context, interval, max int) (data []entity.SubscriberCount, code int, err error)
- func (c *Cache) GetVideoCount(ctx context.Context, top int) (data []entity.VideoCount, code int, err error)
- func (c *Cache) GetVideoCountByDate(ctx context.Context, hourly, daily bool) (data []entity.VideoCountByDate, code int, err error)
- func (c *Cache) GetVideoDuration(ctx context.Context, top int) (data []entity.VideoDuration, code int, err error)
- func (c *Cache) GetZodiacCount(ctx context.Context) (data []entity.ZodiacCount, code int, err error)
- func (c *Cache) IsOld(ctx context.Context, id int64) (bool, int, error)
- func (c *Cache) UpdateByID(ctx context.Context, id int64, data entity.Vtuber) (int, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Cache ¶
type Cache struct {
// contains filtered or unexported fields
}
Cache contains functions for vtuber cache.
func New ¶
func New(cacher cache.Cacher, repo repository.Repository) *Cache
New to create new vtuber cache.
func (*Cache) DeleteByID ¶ added in v0.9.0
DeleteByID to delete by id.
func (*Cache) Get2DModelerCount ¶ added in v0.14.0
func (c *Cache) Get2DModelerCount(ctx context.Context, top int) (data []entity.DesignerCount, code int, err error)
Get2DModelerCount to get character 2d modeler count.
func (*Cache) Get3DModelerCount ¶ added in v0.14.0
func (c *Cache) Get3DModelerCount(ctx context.Context, top int) (data []entity.DesignerCount, code int, err error)
Get3DModelerCount to get character 3d modeler count.
func (*Cache) GetAll ¶ added in v0.5.0
func (c *Cache) GetAll(ctx context.Context, req entity.GetAllRequest) (_ []entity.Vtuber, _ int, code int, err error)
GetAll to get vtuber list.
func (*Cache) GetAllForAgencyTree ¶ added in v0.4.0
func (c *Cache) GetAllForAgencyTree(ctx context.Context) (data []entity.Vtuber, code int, err error)
GetAllForAgencyTree to get all for agency tree.
func (*Cache) GetAllForFamilyTree ¶ added in v0.4.0
func (c *Cache) GetAllForFamilyTree(ctx context.Context) (data []entity.Vtuber, code int, err error)
GetAllForFamilyTree to get all for family tree.
func (*Cache) GetAllImages ¶
func (c *Cache) GetAllImages(ctx context.Context, shuffle bool, limit int) (data []entity.Vtuber, code int, err error)
GetAllImages to get all images.
func (*Cache) GetAverageActiveTime ¶ added in v0.14.0
GetAverageActiveTime to get average active time.
func (*Cache) GetAverageHeight ¶ added in v0.14.0
GetAverageHeight to get average height.
func (*Cache) GetAverageVideoCount ¶ added in v0.14.0
GetAverageVideoCount to get average video count.
func (*Cache) GetAverageVideoDuration ¶ added in v0.14.0
GetAverageVideoDuration to get average video duration.
func (*Cache) GetAverageWeight ¶ added in v0.14.0
GetAverageWeight to get average height.
func (*Cache) GetBirthdayCount ¶ added in v0.14.0
func (c *Cache) GetBirthdayCount(ctx context.Context) (data []entity.BirthdayCount, code int, err error)
GetBirthdayCount to get birthday count.
func (*Cache) GetBloodTypeCount ¶ added in v0.14.0
func (c *Cache) GetBloodTypeCount(ctx context.Context, top int) (data []entity.BloodTypeCount, code int, err error)
GetBloodTypeCount to get blood type count.
func (*Cache) GetChannelTypeCount ¶ added in v0.14.0
func (c *Cache) GetChannelTypeCount(ctx context.Context) (data []entity.ChannelTypeCount, code int, err error)
GetChannelTypeCount to get channel type count.
func (*Cache) GetCharacter2DModelers ¶ added in v0.6.0
GetCharacter2DModelers to get 2d modelers.
func (*Cache) GetCharacter3DModelers ¶ added in v0.6.0
GetCharacter3DModelers to get 3d modelers.
func (*Cache) GetCharacterDesigners ¶ added in v0.6.0
GetCharacterDesigners to get character designers.
func (*Cache) GetDebutRetireCountMonthly ¶ added in v0.14.0
func (c *Cache) GetDebutRetireCountMonthly(ctx context.Context) (data []entity.DebutRetireCount, code int, err error)
GetDebutRetireCountMonthly to get debut & retire count monthly.
func (*Cache) GetDebutRetireCountYearly ¶ added in v0.14.0
func (c *Cache) GetDebutRetireCountYearly(ctx context.Context) (data []entity.DebutRetireCount, code int, err error)
GetDebutRetireCountYearly to get debut & retire count yearly.
func (*Cache) GetDesignerCount ¶ added in v0.14.0
func (c *Cache) GetDesignerCount(ctx context.Context, top int) (data []entity.DesignerCount, code int, err error)
GetDesignerCount to get character designer count.
func (*Cache) GetGenderCount ¶ added in v0.14.0
func (c *Cache) GetGenderCount(ctx context.Context) (data []entity.GenderCount, code int, err error)
GetGenderCount to get gender count.
func (*Cache) GetInAgencyCount ¶ added in v0.14.0
func (c *Cache) GetInAgencyCount(ctx context.Context) (data *entity.InAgencyCount, code int, err error)
GetInAgencyCount to get in agency count.
func (*Cache) GetModelCount ¶ added in v0.14.0
GetModelCount to get 2d & 3d model count.
func (*Cache) GetOldActiveIDs ¶ added in v0.15.0
GetOldActiveIDs to get old active ids.
func (*Cache) GetOldRetiredIDs ¶ added in v0.15.0
GetOldRetiredIDs to get old ids.
func (*Cache) GetStatusCount ¶ added in v0.14.0
GetStatusCount to get status count.
func (*Cache) GetSubscriberCount ¶ added in v0.14.0
func (c *Cache) GetSubscriberCount(ctx context.Context, interval, max int) (data []entity.SubscriberCount, code int, err error)
GetSubscriberCount to get subscriber count.
func (*Cache) GetVideoCount ¶ added in v0.14.0
func (c *Cache) GetVideoCount(ctx context.Context, top int) (data []entity.VideoCount, code int, err error)
GetVideoCount to get video count.
func (*Cache) GetVideoCountByDate ¶ added in v0.14.0
func (c *Cache) GetVideoCountByDate(ctx context.Context, hourly, daily bool) (data []entity.VideoCountByDate, code int, err error)
GetVideoCountByDate to get video count by date.
func (*Cache) GetVideoDuration ¶ added in v0.14.0
func (c *Cache) GetVideoDuration(ctx context.Context, top int) (data []entity.VideoDuration, code int, err error)
GetVideoDuration to get video duration.
func (*Cache) GetZodiacCount ¶ added in v0.14.0
func (c *Cache) GetZodiacCount(ctx context.Context) (data []entity.ZodiacCount, code int, err error)
GetZodiacCount to get zodiac count.