Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Repository ¶
type Repository interface { SaveUser(ctx context.Context, user *entity.User) error GetUserByEmail(ctx context.Context, email string) (*entity.User, error) SaveLink(ctx context.Context, link *entity.Link) error GetLink(ctx context.Context, slug string) (*entity.Link, error) GetLinks(ctx context.Context, user_id string) ([]entity.Link, error) GetLinksByDescription( ctx context.Context, description, user_id string, ) ([]entity.Link, error) UpdateLink(ctx context.Context, description string, id int) error DeleteLink(ctx context.Context, slug, user_id string) (int64, error) }
Repository is the interface that wraps the basic CRUD operations.
func New ¶
func New(db *sqlx.DB) Repository
Click to show internal directories.
Click to hide internal directories.