Documentation
¶
Index ¶
- Variables
- type WriterRepo
- func (w *WriterRepo) CreateWriter(ctx context.Context, args model.Writer) (model.Writer, error)
- func (w *WriterRepo) DeleteWriter(ctx context.Context, id int64) error
- func (w *WriterRepo) GetWriter(ctx context.Context, id int64) (model.Writer, error)
- func (w *WriterRepo) ListWriters(ctx context.Context) ([]model.Writer, error)
- func (w *WriterRepo) UpdateWriter(ctx context.Context, args model.Writer) (model.Writer, error)
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrWriterNotFound = errors.Wrap(errors.ErrNotFound, "writer is not found") ErrWriterAlreadyExists = errors.Wrap(errors.ErrAlreadyExists, "writer already exists") )
Functions ¶
This section is empty.
Types ¶
type WriterRepo ¶
type WriterRepo struct {
// contains filtered or unexported fields
}
func New ¶
func New(db *sqlx.DB) *WriterRepo
func (*WriterRepo) CreateWriter ¶
func (*WriterRepo) DeleteWriter ¶
func (w *WriterRepo) DeleteWriter(ctx context.Context, id int64) error
func (*WriterRepo) ListWriters ¶
func (*WriterRepo) UpdateWriter ¶
Click to show internal directories.
Click to hide internal directories.