postgres

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Jun 20, 2019 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type UserService

type UserService struct {
	DB *sql.DB
}

func (*UserService) CreateUser

func (s *UserService) CreateUser(u player.User) (*player.User, error)

func (*UserService) UserByID

func (s *UserService) UserByID(id int) (*player.User, error)

func (*UserService) UserByLogin

func (s *UserService) UserByLogin(login string) (*player.User, error)

type VideoListService

type VideoListService struct {
	DB     *sql.DB
	Finder player.VideoFinder
}

func (*VideoListService) Likes

func (s *VideoListService) Likes(user *player.User) (*player.VideoList, error)

func (*VideoListService) Search

func (s *VideoListService) Search(query string) (*player.VideoList, error)

func (*VideoListService) SearchByUser

func (s *VideoListService) SearchByUser(query string, user *player.User) (*player.VideoList, error)

type VideoService

type VideoService struct {
	DB *sql.DB
}

func (*VideoService) Dislike

func (s *VideoService) Dislike(u *player.User, v *player.Video) error

func (*VideoService) IsLiked

func (s *VideoService) IsLiked(u *player.User, v *player.Video) (bool, error)

func (*VideoService) Like

func (s *VideoService) Like(u *player.User, v *player.Video) error

func (*VideoService) Video

func (s *VideoService) Video(id string) (*player.Video, error)

Jump to

Keyboard shortcuts

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