Store provides todo persistence.
| 39 | |
| 40 | // Store provides todo persistence. |
| 41 | type Store interface { |
| 42 | // Store stores a todo. |
| 43 | Store(ctx context.Context, todo Todo) error |
| 44 | |
| 45 | // All returns all todos. |
| 46 | All(ctx context.Context) ([]Todo, error) |
| 47 | |
| 48 | // Get returns a single todo by its ID. |
| 49 | Get(ctx context.Context, id string) (Todo, error) |
| 50 | } |
| 51 | |
| 52 | // NotFoundError is returned if a todo cannot be found. |
| 53 | type NotFoundError struct { |
no outgoing calls
no test coverage detected