sqlite

package
v2.0.0-...-244f2e3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 17, 2026 License: AGPL-3.0-or-later Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MustOpen

func MustOpen(path string) *sql.DB

Types

type Store

type Store struct {
	// contains filtered or unexported fields
}

func New

func New(ctx *sql.DB, optimizeForLitestream bool) Store

func (Store) CountUsers

func (s Store) CountUsers() (uint, error)

func (Store) DeleteComment

func (s Store) DeleteComment(cid screenjournal.CommentID) error

func (Store) DeleteReaction

func (s Store) DeleteReaction(id screenjournal.ReactionID) error

func (Store) DeleteReview

func (s Store) DeleteReview(id screenjournal.ReviewID) error

func (Store) DeleteSignupInvitation

func (s Store) DeleteSignupInvitation(code screenjournal.InviteCode) error

func (Store) InsertComment

func (Store) InsertMovie

func (s Store) InsertMovie(m screenjournal.Movie) (screenjournal.MovieID, error)

func (Store) InsertPasswordResetEntry

func (s Store) InsertPasswordResetEntry(request screenjournal.PasswordResetEntry) error

func (Store) InsertReaction

func (Store) InsertReview

func (s Store) InsertReview(r screenjournal.Review) (screenjournal.ReviewID, error)

func (Store) InsertSignupInvitation

func (s Store) InsertSignupInvitation(invite screenjournal.SignupInvitation) error

func (Store) InsertTvShow

func (s Store) InsertTvShow(t screenjournal.TvShow) (screenjournal.TvShowID, error)

func (Store) InsertUser

func (s Store) InsertUser(user screenjournal.User) error

func (Store) ReadComment

func (Store) ReadCommentSubscribers

func (s Store) ReadCommentSubscribers(
	reviewID screenjournal.ReviewID,
	commentAuthor screenjournal.Username,
) ([]screenjournal.EmailSubscriber, error)

func (Store) ReadComments

func (s Store) ReadComments(rid screenjournal.ReviewID) ([]screenjournal.ReviewComment, error)

func (Store) ReadLatestPasswordResetEntryForUser

func (s Store) ReadLatestPasswordResetEntryForUser(username screenjournal.Username) (screenjournal.PasswordResetEntry, error)

func (Store) ReadMovie

func (s Store) ReadMovie(id screenjournal.MovieID) (screenjournal.Movie, error)

func (Store) ReadMovieByTmdbID

func (s Store) ReadMovieByTmdbID(tmdbID screenjournal.TmdbID) (screenjournal.Movie, error)

func (Store) ReadNotificationPreferences

func (s Store) ReadNotificationPreferences(username screenjournal.Username) (screenjournal.NotificationPreferences, error)

func (Store) ReadPasswordResetEntry

func (s Store) ReadPasswordResetEntry(token screenjournal.PasswordResetToken) (screenjournal.PasswordResetEntry, error)

func (Store) ReadReaction

func (Store) ReadReactions

func (s Store) ReadReactions(rid screenjournal.ReviewID) ([]screenjournal.ReviewReaction, error)

func (Store) ReadReview

func (s Store) ReadReview(id screenjournal.ReviewID) (screenjournal.Review, error)

func (Store) ReadReviewSubscribers

func (s Store) ReadReviewSubscribers() ([]screenjournal.EmailSubscriber, error)

func (Store) ReadReviews

func (s Store) ReadReviews(opts ...store.ReadReviewsOption) ([]screenjournal.Review, error)

func (Store) ReadSignupInvitation

func (s Store) ReadSignupInvitation(code screenjournal.InviteCode) (screenjournal.SignupInvitation, error)

func (Store) ReadSignupInvitations

func (s Store) ReadSignupInvitations() ([]screenjournal.SignupInvitation, error)

func (Store) ReadTvShow

func (s Store) ReadTvShow(id screenjournal.TvShowID) (screenjournal.TvShow, error)

func (Store) ReadTvShowByTmdbID

func (s Store) ReadTvShowByTmdbID(tmdbID screenjournal.TmdbID) (screenjournal.TvShow, error)

func (Store) ReadUser

func (s Store) ReadUser(username screenjournal.Username) (screenjournal.User, error)

func (Store) ReadUserByEmail

func (s Store) ReadUserByEmail(email screenjournal.Email) (screenjournal.User, error)

func (Store) ReadUsersPublicMeta

func (s Store) ReadUsersPublicMeta() ([]screenjournal.UserPublicMeta, error)

func (Store) UpdateComment

func (s Store) UpdateComment(rc screenjournal.ReviewComment) error

func (Store) UpdateMovie

func (s Store) UpdateMovie(m screenjournal.Movie) error

func (Store) UpdateNotificationPreferences

func (s Store) UpdateNotificationPreferences(username screenjournal.Username, prefs screenjournal.NotificationPreferences) error

func (Store) UpdateReview

func (s Store) UpdateReview(r screenjournal.Review) error

func (Store) UpdateTvShow

func (s Store) UpdateTvShow(t screenjournal.TvShow) error

func (Store) UpdateUserPassword

func (s Store) UpdateUserPassword(username screenjournal.Username, newPasswordHash screenjournal.PasswordHash) error

func (Store) UsePasswordResetEntry

func (s Store) UsePasswordResetEntry(
	username screenjournal.Username,
	token screenjournal.PasswordResetToken,
	newPasswordHash screenjournal.PasswordHash,
	now time.Time,
) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL