Documentation
¶
Index ¶
- Variables
- func NewLeafRepo(data *Data, logger log.Logger, AppConfig *conf.App) biz.LeafRepo
- func NewShortUrlRepo(data *Data, logger log.Logger) biz.ShortUrlRepo
- type Data
- type LeafRepo
- func (lf *LeafRepo) CountByBizTag(ctx context.Context, tag string) (int, error)
- func (lf *LeafRepo) Find(ctx context.Context, id int64) (*biz.Leaf, error)
- func (lf *LeafRepo) FindByBizTag(ctx context.Context, tag string) (*biz.Leaf, error)
- func (lf *LeafRepo) ListAll(ctx context.Context) ([]*biz.Leaf, error)
- func (lf *LeafRepo) Save(ctx context.Context, leaf *biz.Leaf) (int64, error)
- func (lf *LeafRepo) Update(ctx context.Context, id int64, leaf *biz.Leaf) error
- func (lf *LeafRepo) UpdateBuffer(ctx context.Context, bizId int64) ([]int64, error)
- type ShortUrlRepo
- func (sr *ShortUrlRepo) Find(ctx context.Context, id int64) (*biz.ShortUrl, error)
- func (sr *ShortUrlRepo) FindByShort(ctx context.Context, short string) (*biz.ShortUrl, error)
- func (sr *ShortUrlRepo) ListAll(ctx context.Context) ([]*biz.ShortUrl, error)
- func (sr *ShortUrlRepo) Save(ctx context.Context, url *biz.ShortUrl) (err error)
- func (sr *ShortUrlRepo) Update(ctx context.Context, id int64, ShortUrl *biz.ShortUrl) error
- func (sr *ShortUrlRepo) UpdateUrlCount(ctx context.Context, id int64, added int64) error
Constants ¶
This section is empty.
Variables ¶
View Source
var ProviderSet = wire.NewSet(NewData, NewLeafRepo, NewShortUrlRepo)
ProviderSet is data providers.
Functions ¶
func NewLeafRepo ¶
NewLeafRepo .
func NewShortUrlRepo ¶
func NewShortUrlRepo(data *Data, logger log.Logger) biz.ShortUrlRepo
NewShortUrlRepo creates a new instance of ShortUrlRepo.
Types ¶
type LeafRepo ¶
type LeafRepo struct {
// contains filtered or unexported fields
}
func (*LeafRepo) CountByBizTag ¶
func (*LeafRepo) FindByBizTag ¶
type ShortUrlRepo ¶
type ShortUrlRepo struct {
// contains filtered or unexported fields
}
func (*ShortUrlRepo) FindByShort ¶
func (*ShortUrlRepo) UpdateUrlCount ¶
Click to show internal directories.
Click to hide internal directories.