Documentation
¶
Index ¶
- Variables
- func InitDB(dbFile string) (*sql.DB, error)
- type DeadlineFilter
- type GetAllFilters
- type ListStore
- type SQLiteStore
- func (s *SQLiteStore) CreateList(list *model.List) error
- func (s *SQLiteStore) CreateTask(task *model.Task) error
- func (s *SQLiteStore) DeleteList(id string) error
- func (s *SQLiteStore) DeleteTask(id string) error
- func (s *SQLiteStore) GetAllLists() ([]model.List, error)
- func (s *SQLiteStore) GetAllTasks(filters GetAllFilters) ([]model.Task, int, error)
- func (s *SQLiteStore) GetDB() *sql.DB
- func (s *SQLiteStore) GetListByID(id string) (*model.List, error)
- func (s *SQLiteStore) GetTaskByID(id string) (*model.Task, error)
- func (s *SQLiteStore) UpdateList(list *model.List) error
- func (s *SQLiteStore) UpdateTask(task *model.Task) error
- type TaskStore
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrDuplicateListName = errors.New("a list with this name already exists")
)
Functions ¶
Types ¶
type DeadlineFilter ¶ added in v0.3.0
type DeadlineFilter string
const ( DeadlineToday DeadlineFilter = "today" DeadlineOverdue DeadlineFilter = "overdue" DeadlineThisWeek DeadlineFilter = "this-week" )
type GetAllFilters ¶
type SQLiteStore ¶
type SQLiteStore struct {
// contains filtered or unexported fields
}
func NewSQLiteStore ¶
func NewSQLiteStore(db *sql.DB) *SQLiteStore
func (*SQLiteStore) CreateList ¶ added in v0.2.0
func (s *SQLiteStore) CreateList(list *model.List) error
func (*SQLiteStore) CreateTask ¶ added in v0.2.0
func (s *SQLiteStore) CreateTask(task *model.Task) error
func (*SQLiteStore) DeleteList ¶ added in v0.2.0
func (s *SQLiteStore) DeleteList(id string) error
func (*SQLiteStore) DeleteTask ¶ added in v0.2.0
func (s *SQLiteStore) DeleteTask(id string) error
func (*SQLiteStore) GetAllLists ¶ added in v0.2.0
func (s *SQLiteStore) GetAllLists() ([]model.List, error)
func (*SQLiteStore) GetAllTasks ¶ added in v0.2.0
func (s *SQLiteStore) GetAllTasks(filters GetAllFilters) ([]model.Task, int, error)
func (*SQLiteStore) GetDB ¶ added in v0.2.0
func (s *SQLiteStore) GetDB() *sql.DB
func (*SQLiteStore) GetListByID ¶ added in v0.2.0
func (s *SQLiteStore) GetListByID(id string) (*model.List, error)
func (*SQLiteStore) GetTaskByID ¶ added in v0.2.0
func (s *SQLiteStore) GetTaskByID(id string) (*model.Task, error)
func (*SQLiteStore) UpdateList ¶ added in v0.2.0
func (s *SQLiteStore) UpdateList(list *model.List) error
func (*SQLiteStore) UpdateTask ¶ added in v0.2.0
func (s *SQLiteStore) UpdateTask(task *model.Task) error
Click to show internal directories.
Click to hide internal directories.