Versions in this module Expand all Collapse all v1 v1.0.46 Jul 22, 2023 Changes in this version + type CertificateCache struct + func NewCertificateCache(storage *Storage) *CertificateCache + func (c *CertificateCache) Delete(ctx context.Context, key string) error + func (c *CertificateCache) Get(ctx context.Context, key string) ([]byte, error) + func (c *CertificateCache) Put(ctx context.Context, key string, data []byte) error + type EntryPaginationBuilder struct + func NewEntryPaginationBuilder(store *Storage, userID, entryID int64, order, direction string) *EntryPaginationBuilder + func (e *EntryPaginationBuilder) Entries() (*model.Entry, *model.Entry, error) + func (e *EntryPaginationBuilder) WithCategoryID(categoryID int64) + func (e *EntryPaginationBuilder) WithFeedID(feedID int64) + func (e *EntryPaginationBuilder) WithGloballyVisible() + func (e *EntryPaginationBuilder) WithSearchQuery(query string) + func (e *EntryPaginationBuilder) WithStarred() + func (e *EntryPaginationBuilder) WithStatus(status string) + type EntryQueryBuilder struct + func NewAnonymousQueryBuilder(store *Storage) *EntryQueryBuilder + func NewEntryQueryBuilder(store *Storage, userID int64) *EntryQueryBuilder + func (e *EntryQueryBuilder) AfterDate(date time.Time) *EntryQueryBuilder + func (e *EntryQueryBuilder) AfterEntryID(entryID int64) *EntryQueryBuilder + func (e *EntryQueryBuilder) BeforeDate(date time.Time) *EntryQueryBuilder + func (e *EntryQueryBuilder) BeforeEntryID(entryID int64) *EntryQueryBuilder + func (e *EntryQueryBuilder) CountEntries() (count int, err error) + func (e *EntryQueryBuilder) GetEntries() (model.Entries, error) + func (e *EntryQueryBuilder) GetEntry() (*model.Entry, error) + func (e *EntryQueryBuilder) GetEntryIDs() ([]int64, error) + func (e *EntryQueryBuilder) WithCategoryID(categoryID int64) *EntryQueryBuilder + func (e *EntryQueryBuilder) WithEntryID(entryID int64) *EntryQueryBuilder + func (e *EntryQueryBuilder) WithEntryIDs(entryIDs []int64) *EntryQueryBuilder + func (e *EntryQueryBuilder) WithFeedID(feedID int64) *EntryQueryBuilder + func (e *EntryQueryBuilder) WithGloballyVisible() *EntryQueryBuilder + func (e *EntryQueryBuilder) WithLimit(limit int) *EntryQueryBuilder + func (e *EntryQueryBuilder) WithOffset(offset int) *EntryQueryBuilder + func (e *EntryQueryBuilder) WithSearchQuery(query string) *EntryQueryBuilder + func (e *EntryQueryBuilder) WithShareCode(shareCode string) *EntryQueryBuilder + func (e *EntryQueryBuilder) WithShareCodeNotEmpty() *EntryQueryBuilder + func (e *EntryQueryBuilder) WithSorting(column, direction string) *EntryQueryBuilder + func (e *EntryQueryBuilder) WithStarred(starred bool) *EntryQueryBuilder + func (e *EntryQueryBuilder) WithStatus(status string) *EntryQueryBuilder + func (e *EntryQueryBuilder) WithStatuses(statuses []string) *EntryQueryBuilder + func (e *EntryQueryBuilder) WithTags(tags []string) *EntryQueryBuilder + func (e *EntryQueryBuilder) WithoutStatus(status string) *EntryQueryBuilder + type FeedQueryBuilder struct + func NewFeedQueryBuilder(store *Storage, userID int64) *FeedQueryBuilder + func (f *FeedQueryBuilder) GetFeed() (*model.Feed, error) + func (f *FeedQueryBuilder) GetFeeds() (model.Feeds, error) + func (f *FeedQueryBuilder) WithCategoryID(categoryID int64) *FeedQueryBuilder + func (f *FeedQueryBuilder) WithCounters() *FeedQueryBuilder + func (f *FeedQueryBuilder) WithFeedID(feedID int64) *FeedQueryBuilder + func (f *FeedQueryBuilder) WithLimit(limit int) *FeedQueryBuilder + func (f *FeedQueryBuilder) WithOffset(offset int) *FeedQueryBuilder + func (f *FeedQueryBuilder) WithSorting(column, direction string) *FeedQueryBuilder + type Storage struct + func NewStorage(db *sql.DB) *Storage + func (s *Storage) APIKeyExists(userID int64, description string) bool + func (s *Storage) APIKeys(userID int64) (model.APIKeys, error) + func (s *Storage) AnotherCategoryExists(userID, categoryID int64, title string) bool + func (s *Storage) AnotherFeedURLExists(userID, feedID int64, feedURL string) bool + func (s *Storage) AnotherUserExists(userID int64, username string) bool + func (s *Storage) AnotherUserWithFieldExists(userID int64, field, value string) bool + func (s *Storage) AppSession(id string) (*model.Session, error) + func (s *Storage) ArchiveEntries(status string, days, limit int) (int64, error) + func (s *Storage) Categories(userID int64) (model.Categories, error) + func (s *Storage) CategoriesWithFeedCount(userID int64) (model.Categories, error) + func (s *Storage) Category(userID, categoryID int64) (*model.Category, error) + func (s *Storage) CategoryByTitle(userID int64, title string) (*model.Category, error) + func (s *Storage) CategoryIDExists(userID, categoryID int64) bool + func (s *Storage) CategoryTitleExists(userID int64, title string) bool + func (s *Storage) CheckPassword(username, password string) error + func (s *Storage) CleanOldSessions(days int) int64 + func (s *Storage) CleanOldUserSessions(days int) int64 + func (s *Storage) CountAllEntries() map[string]int64 + func (s *Storage) CountAllFeeds() map[string]int64 + func (s *Storage) CountAllFeedsWithErrors() int + func (s *Storage) CountFeeds(userID int64) int + func (s *Storage) CountUnreadEntries(userID int64) int + func (s *Storage) CountUserFeedsWithErrors(userID int64) int + func (s *Storage) CountUsers() int + func (s *Storage) CreateAPIKey(apiKey *model.APIKey) error + func (s *Storage) CreateAppSession() (*model.Session, error) + func (s *Storage) CreateAppSessionWithUserPrefs(userID int64) (*model.Session, error) + func (s *Storage) CreateCategory(userID int64, request *model.CategoryRequest) (*model.Category, error) + func (s *Storage) CreateFeed(feed *model.Feed) error + func (s *Storage) CreateFeedIcon(feedID int64, icon *model.Icon) error + func (s *Storage) CreateIcon(icon *model.Icon) error + func (s *Storage) CreateUser(userCreationRequest *model.UserCreationRequest) (*model.User, error) + func (s *Storage) CreateUserSessionFromUsername(username, userAgent, ip string) (sessionID string, userID int64, err error) + func (s *Storage) DBStats() sql.DBStats + func (s *Storage) DatabaseVersion() string + func (s *Storage) EntryShareCode(userID int64, entryID int64) (shareCode string, err error) + func (s *Storage) EntryURLExists(feedID int64, entryURL string) bool + func (s *Storage) FeedByID(userID, feedID int64) (*model.Feed, error) + func (s *Storage) FeedExists(userID, feedID int64) bool + func (s *Storage) FeedURLExists(userID int64, feedURL string) bool + func (s *Storage) Feeds(userID int64) (model.Feeds, error) + func (s *Storage) FeedsByCategoryWithCounters(userID, categoryID int64) (model.Feeds, error) + func (s *Storage) FeedsWithCounters(userID int64) (model.Feeds, error) + func (s *Storage) FetchCounters(userID int64) (model.FeedCounters, error) + func (s *Storage) FirstCategory(userID int64) (*model.Category, error) + func (s *Storage) FlushAllSessions() (err error) + func (s *Storage) FlushHistory(userID int64) error + func (s *Storage) GetEnclosure(enclosureID int64) (*model.Enclosure, error) + func (s *Storage) GetEnclosures(entryID int64) (model.EnclosureList, error) + func (s *Storage) GetReadTime(entry *model.Entry, feed *model.Feed) int + func (s *Storage) GoogleReaderUserCheckPassword(username, password string) error + func (s *Storage) GoogleReaderUserGetIntegration(username string) (*model.Integration, error) + func (s *Storage) HasDuplicateFeverUsername(userID int64, feverUsername string) bool + func (s *Storage) HasDuplicateGoogleReaderUsername(userID int64, googleReaderUsername string) bool + func (s *Storage) HasIcon(feedID int64) bool + func (s *Storage) HasPassword(userID int64) (bool, error) + func (s *Storage) HasSaveEntry(userID int64) (result bool) + func (s *Storage) IconByFeedID(userID, feedID int64) (*model.Icon, error) + func (s *Storage) IconByHash(icon *model.Icon) error + func (s *Storage) IconByID(iconID int64) (*model.Icon, error) + func (s *Storage) Icons(userID int64) (model.Icons, error) + func (s *Storage) Integration(userID int64) (*model.Integration, error) + func (s *Storage) MarkAllAsRead(userID int64) error + func (s *Storage) MarkCategoryAsRead(userID, categoryID int64, before time.Time) error + func (s *Storage) MarkFeedAsRead(userID, feedID int64, before time.Time) error + func (s *Storage) MarkGloballyVisibleFeedsAsRead(userID int64) error + func (s *Storage) NewBatch(batchSize int) (jobs model.JobList, err error) + func (s *Storage) NewCategoryBatch(userID int64, categoryID int64, batchSize int) (jobs model.JobList, err error) + func (s *Storage) NewEntryQueryBuilder(userID int64) *EntryQueryBuilder + func (s *Storage) NewUserBatch(userID int64, batchSize int) (jobs model.JobList, err error) + func (s *Storage) Ping() error + func (s *Storage) RefreshFeedEntries(userID, feedID int64, entries model.Entries, updateExistingEntries bool) (err error) + func (s *Storage) RemoveAPIKey(userID, keyID int64) error + func (s *Storage) RemoveAndReplaceCategoriesByName(userid int64, titles []string) error + func (s *Storage) RemoveCategory(userID, categoryID int64) error + func (s *Storage) RemoveFeed(userID, feedID int64) error + func (s *Storage) RemoveUser(userID int64) error + func (s *Storage) RemoveUserAsync(userID int64) + func (s *Storage) RemoveUserSessionByID(userID, sessionID int64) error + func (s *Storage) RemoveUserSessionByToken(userID int64, token string) error + func (s *Storage) ResetFeedErrors() error + func (s *Storage) SetAPIKeyUsedTimestamp(userID int64, token string) error + func (s *Storage) SetEntriesBookmarkedState(userID int64, entryIDs []int64, starred bool) error + func (s *Storage) SetEntriesStatus(userID int64, entryIDs []int64, status string) error + func (s *Storage) SetEntriesStatusCount(userID int64, entryIDs []int64, status string) (int, error) + func (s *Storage) SetLastLogin(userID int64) error + func (s *Storage) Timezones() (map[string]string, error) + func (s *Storage) ToggleBookmark(userID int64, entryID int64) error + func (s *Storage) UnshareEntry(userID int64, entryID int64) (err error) + func (s *Storage) UpdateAppSessionField(sessionID, field string, value interface{}) error + func (s *Storage) UpdateCategory(category *model.Category) error + func (s *Storage) UpdateEnclosure(enclosure *model.Enclosure) error + func (s *Storage) UpdateEntryContent(entry *model.Entry) error + func (s *Storage) UpdateFeed(feed *model.Feed) (err error) + func (s *Storage) UpdateFeedError(feed *model.Feed) (err error) + func (s *Storage) UpdateIntegration(integration *model.Integration) error + func (s *Storage) UpdateUser(user *model.User) error + func (s *Storage) UserByAPIKey(token string) (*model.User, error) + func (s *Storage) UserByFeverToken(token string) (*model.User, error) + func (s *Storage) UserByField(field, value string) (*model.User, error) + func (s *Storage) UserByID(userID int64) (*model.User, error) + func (s *Storage) UserByUsername(username string) (*model.User, error) + func (s *Storage) UserExists(username string) bool + func (s *Storage) UserLanguage(userID int64) (language string) + func (s *Storage) UserSessionByToken(token string) (*model.UserSession, error) + func (s *Storage) UserSessions(userID int64) (model.UserSessions, error) + func (s *Storage) Users() (model.Users, error) + func (s *Storage) WeeklyFeedEntryCount(userID, feedID int64) (int, error)