Documentation ¶
Index ¶
- type Cache
- func (c *Cache) DeleteByID(ctx context.Context, id int64) (int, error)
- func (c *Cache) GetAll(ctx context.Context, req entity.GetAllRequest) (_ []entity.Manga, _ int, code int, err error)
- func (c *Cache) GetByID(ctx context.Context, id int64) (data *entity.Manga, code int, err error)
- func (c *Cache) GetIDs(ctx context.Context) ([]int64, int, error)
- func (c *Cache) GetMaxID(ctx context.Context) (int64, int, error)
- func (c *Cache) GetOldFinishedIDs(ctx context.Context) ([]int64, int, error)
- func (c *Cache) GetOldNotYetIDs(ctx context.Context) ([]int64, int, error)
- func (c *Cache) GetOldReleasingIDs(ctx context.Context) ([]int64, int, error)
- func (c *Cache) IsOld(ctx context.Context, id int64) (bool, int, error)
- func (c *Cache) Update(ctx context.Context, data entity.Manga) (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 manga cache.
func New ¶
func New(cacher cache.Cacher, repo repository.Repository) *Cache
New to create new manga cache.
func (*Cache) DeleteByID ¶
DeleteByID to delete manga by id.
func (*Cache) GetAll ¶ added in v0.2.0
func (c *Cache) GetAll(ctx context.Context, req entity.GetAllRequest) (_ []entity.Manga, _ int, code int, err error)
GetAll to get manga list.
func (*Cache) GetOldFinishedIDs ¶
GetOldFinishedIDs to get old finished manga ids.
func (*Cache) GetOldNotYetIDs ¶
GetOldNotYetIDs to get old not yet released manga ids.
func (*Cache) GetOldReleasingIDs ¶
GetOldReleasingIDs to get old releasing manga ids.
Click to show internal directories.
Click to hide internal directories.