README ¶ todo A simple TODO management sample implementation. This module is created for learning and demonstration purposes. License MIT Expand ▾ Collapse ▴ Documentation ¶ Index ¶ Variables type Server func NewServer() *Server func (s *Server) Delete(id uuid.UUID) (*Task, error) func (s *Server) Get(id uuid.UUID) (*Task, error) func (s *Server) List(limit int, filter func(task *Task) bool) ([]*Task, error) func (s *Server) Save(task *Task) error type Task func (t *Task) Clone() *Task Constants ¶ This section is empty. Variables ¶ View Source var ( ErrNotFound = errors.New("not found") ErrTitleTooLong = errors.New("the title too long") ErrContentsTooLong = errors.New("the contents too long") ) Functions ¶ This section is empty. Types ¶ type Server ¶ type Server struct { // contains filtered or unexported fields } func NewServer ¶ func NewServer() *Server func (*Server) Delete ¶ func (s *Server) Delete(id uuid.UUID) (*Task, error) func (*Server) Get ¶ func (s *Server) Get(id uuid.UUID) (*Task, error) func (*Server) List ¶ func (s *Server) List(limit int, filter func(task *Task) bool) ([]*Task, error) func (*Server) Save ¶ func (s *Server) Save(task *Task) error type Task ¶ type Task struct { ID uuid.UUID Title string Contents string Done bool CreateTime time.Time UpdateTime time.Time } func (*Task) Clone ¶ func (t *Task) Clone() *Task Source Files ¶ View all Source files todo.go Click to show internal directories. Click to hide internal directories.