Documentation ¶
Index ¶
- func NewThreadPSQLRepository(ConnectionPool *pgx.ConnPool, Cache *cache.Cache) thread.Repository
- func ReplaceSQL(old, searchPattern string) string
- type ThreadPSQL
- func (t ThreadPSQL) ClearAll() error
- func (t ThreadPSQL) CreatePosts(thread *model.Thread, posts []*model.Post) ([]*model.Post, error)
- func (t ThreadPSQL) CreateThread(newThread *model.NewThread) (*model.Thread, error)
- func (t ThreadPSQL) FindByIdOrSlug(id int, slug string) (*model.Thread, error)
- func (t ThreadPSQL) FindPostId(id string, includeUser, includeForum, includeThread bool) (*model.PostFull, error)
- func (t ThreadPSQL) GetStatus() (*model.Status, error)
- func (t ThreadPSQL) GetThreadPosts(thread *model.Thread, limit, desc, since, sort string) ([]model.Post, error)
- func (t ThreadPSQL) UpdatePost(id string, message string) (*model.Post, error)
- func (t ThreadPSQL) UpdateThread(id int, slug string, threadUpdate *model.ThreadUpdate) (*model.Thread, error)
- func (t ThreadPSQL) Vote(thread *model.Thread, vote *model.Vote) (*model.Thread, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewThreadPSQLRepository ¶
func ReplaceSQL ¶
Types ¶
type ThreadPSQL ¶
func (ThreadPSQL) ClearAll ¶
func (t ThreadPSQL) ClearAll() error
func (ThreadPSQL) CreatePosts ¶
func (ThreadPSQL) CreateThread ¶
func (ThreadPSQL) FindByIdOrSlug ¶
func (ThreadPSQL) FindPostId ¶
func (ThreadPSQL) GetThreadPosts ¶
func (ThreadPSQL) UpdatePost ¶
func (ThreadPSQL) UpdateThread ¶
func (t ThreadPSQL) UpdateThread(id int, slug string, threadUpdate *model.ThreadUpdate) (*model.Thread, error)
Click to show internal directories.
Click to hide internal directories.