Documentation ¶
Index ¶
Constants ¶
View Source
const DefaultTitle = "Quotes"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Storage ¶
type Storage interface { // AddBook adds a new book to the storage. If the book already exists, it returns the // existing book. AddBook(ctx context.Context, title, author, source string) (Book, error) // AddHighlight adds a new highlight to the storage. If the highlight already exists, // it returns the existing highlight. AddHighlight(ctx context.Context, b Book, text, note, chapter string, location int, url string) (Highlight, error) // ListBooks returns a list of books from the storage. ListBooks(ctx context.Context, lt, gt time.Time) ([]Book, error) // ListHighlights returns a list of highlights from the storage. ListHighlights(ctx context.Context, lt, gt time.Time) ([]Highlight, error) }
Click to show internal directories.
Click to hide internal directories.