Documentation ¶
Index ¶
- type SqliteStore
- func (s *SqliteStore) AddFeed(slug string, url string) error
- func (s *SqliteStore) AddPage(url string, html string, content string) error
- func (s *SqliteStore) AddRecord(item internal.Record) (int64, error)
- func (s *SqliteStore) Close() error
- func (s *SqliteStore) FindFeedByUrl(feedUrl string) (internal.Feed, error)
- func (s *SqliteStore) FindRecordsWithNoPage() ([]string, error)
- func (s *SqliteStore) GetAllPages() ([]internal.Page, error)
- func (s *SqliteStore) GetFeedBySlug(slug string) (internal.Feed, error)
- func (s *SqliteStore) GetFeedRecords(feedId string, mdContent bool) ([]internal.Record, error)
- func (s *SqliteStore) GetFeeds() ([]internal.Feed, error)
- func (s *SqliteStore) UpdatePageContent(page *internal.Page, content string) error
- type Store
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type SqliteStore ¶
type SqliteStore struct {
// contains filtered or unexported fields
}
func NewSqliteStore ¶
func NewSqliteStore(dbpath string, logger *log.Logger) (*SqliteStore, error)
func (*SqliteStore) AddPage ¶
func (s *SqliteStore) AddPage(url string, html string, content string) error
func (*SqliteStore) AddRecord ¶
func (s *SqliteStore) AddRecord(item internal.Record) (int64, error)
func (*SqliteStore) Close ¶
func (s *SqliteStore) Close() error
func (*SqliteStore) FindFeedByUrl ¶
func (s *SqliteStore) FindFeedByUrl(feedUrl string) (internal.Feed, error)
func (*SqliteStore) FindRecordsWithNoPage ¶
func (s *SqliteStore) FindRecordsWithNoPage() ([]string, error)
func (*SqliteStore) GetAllPages ¶
func (s *SqliteStore) GetAllPages() ([]internal.Page, error)
func (*SqliteStore) GetFeedBySlug ¶
func (s *SqliteStore) GetFeedBySlug(slug string) (internal.Feed, error)
func (*SqliteStore) GetFeedRecords ¶
func (*SqliteStore) UpdatePageContent ¶
func (s *SqliteStore) UpdatePageContent(page *internal.Page, content string) error
type Store ¶
type Store interface { AddFeed(string, string) error AddPage(string, string, string) error UpdatePageContent(*Page, string) error GetFeedBySlug(string) (Feed, error) FindFeedByUrl(string) (Feed, error) GetFeeds() ([]Feed, error) AddRecord(Record) (int64, error) FindRecordsWithNoPage() ([]string, error) GetAllPages() ([]Page, error) GetFeedRecords(string, bool) ([]Record, error) }
Click to show internal directories.
Click to hide internal directories.