store

package
v0.0.0-...-c266f6d Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 24, 2023 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BaseRepoImpl

type BaseRepoImpl struct {
	// contains filtered or unexported fields
}

func NewBaseImpl

func NewBaseImpl() (BaseRepoImpl, error)

type FavorRepoImpl

type FavorRepoImpl struct {
	BaseRepoImpl
}

func NewFavorRepo

func NewFavorRepo() *FavorRepoImpl

func (*FavorRepoImpl) Create

func (r *FavorRepoImpl) Create(ctx context.Context, favor model.Favor) error

func (*FavorRepoImpl) Del

func (r *FavorRepoImpl) Del(ctx context.Context, f model.Favor) error

func (*FavorRepoImpl) Get

func (r *FavorRepoImpl) Get(ctx context.Context, q *dto.Query) ([]model.Favor, error)

func (*FavorRepoImpl) Sites

func (r *FavorRepoImpl) Sites(ctx context.Context, q *dto.Query) []string

type NodeRepoImpl

type NodeRepoImpl struct {
	BaseRepoImpl
}

func NewNodeRepo

func NewNodeRepo() *NodeRepoImpl

func (*NodeRepoImpl) Create

func (r *NodeRepoImpl) Create(ctx context.Context, node model.Node) error

func (*NodeRepoImpl) Del

func (r *NodeRepoImpl) Del(ctx context.Context, node model.Node) error

func (*NodeRepoImpl) Get

func (r *NodeRepoImpl) Get(ctx context.Context, q *dto.Query) ([]model.Node, error)

func (*NodeRepoImpl) Update

func (r *NodeRepoImpl) Update(ctx context.Context, node model.Node, data map[string]interface{}) error

type SiteRepoImpl

type SiteRepoImpl struct {
	BaseRepoImpl
	// contains filtered or unexported fields
}

func NewSiteRepo

func NewSiteRepo() *SiteRepoImpl

func (*SiteRepoImpl) Create

func (s *SiteRepoImpl) Create(ctx context.Context, site model.Site) error

func (*SiteRepoImpl) Del

func (s *SiteRepoImpl) Del(ctx context.Context, site model.Site) error

func (*SiteRepoImpl) Get

func (r *SiteRepoImpl) Get(ctx context.Context, q *dto.Query) ([]model.Site, error)

func (*SiteRepoImpl) GetNews

func (s *SiteRepoImpl) GetNews(ctx context.Context, k string, kk string) (model.News, error)

func (*SiteRepoImpl) SaveNews

func (s *SiteRepoImpl) SaveNews(ctx context.Context, site string, tag string, data string) error

func (*SiteRepoImpl) Update

func (s *SiteRepoImpl) Update(ctx context.Context, site model.Site, data map[string]interface{}) error

type UserRepoImpl

type UserRepoImpl struct {
	BaseRepoImpl
}

func NewUserRepo

func NewUserRepo() *UserRepoImpl

func (*UserRepoImpl) CreateUser

func (r *UserRepoImpl) CreateUser(ctx context.Context, user model.User) error

func (*UserRepoImpl) GetAll

func (r *UserRepoImpl) GetAll(ctx context.Context) ([]model.User, error)

func (*UserRepoImpl) GetUser

func (r *UserRepoImpl) GetUser(ctx context.Context, query *dto.Query) (model.User, error)

func (*UserRepoImpl) GetUsers

func (r *UserRepoImpl) GetUsers(ctx context.Context, query *dto.Query) ([]model.User, error)

func (*UserRepoImpl) Update

func (r *UserRepoImpl) Update(ctx context.Context, user model.User, data map[string]interface{}) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL