repository

package
v0.0.0-...-a7107f1 Latest Latest
Warning

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

Go to latest
Published: Jun 14, 2020 License: BSD-3-Clause Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Repository

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

func NewRepository

func NewRepository(db *pgxpool.Pool) Repository

func (Repository) CreatePostsInThread

func (repo Repository) CreatePostsInThread(thread models.Thread,
	posts models.Posts) (insertedPosts models.Posts, err error)

func (Repository) GetPostByID

func (repo Repository) GetPostByID(id int64) (models.Post, error)

func (Repository) GetSortedPostsByThreadSlugOrID

func (repo Repository) GetSortedPostsByThreadSlugOrID(threadID int32, sincePostID *int64,
	sort post.PostsSortType, desc bool, limit int64) (models.Posts, error)

func (Repository) UpdatePostByID

func (repo Repository) UpdatePostByID(post models.Post) (models.Post, error)

Jump to

Keyboard shortcuts

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