Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Repo ¶
type Repo interface { GetAll(ctx context.Context) ([]*models.Task, error) GetByID(ctx context.Context, id string) (*models.Task, error) GetByNamespace(ctx context.Context, namespace string) ([]*models.Task, error) CreateOne(ctx context.Context, task *models.TaskPayload) (string, error) UpdateStatus(ctx context.Context, id string, paused bool) error Delete(ctx context.Context, id string) error }
Repo is the interface that wraps the required repository methods. Any underlying database repository should implement these methods.
type Service ¶
type Service interface { GetAll(ctx context.Context) ([]*models.Task, error) GetByNamespace(ctx context.Context, namespace string) ([]*models.Task, error) Create(ctx context.Context, task *models.TaskPayload) (string, int, error) ToggleStatus(ctx context.Context, id string) error Delete(ctx context.Context, id string) error }
Service is the interface that wraps tasks service methods.
Click to show internal directories.
Click to hide internal directories.