videomanager

package
v0.0.0-...-83f3c07 Latest Latest
Warning

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

Go to latest
Published: Apr 9, 2023 License: MIT Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewController

func NewController(svc *videoService) videoController

func NewService

func NewService(repository *VideoRepository) videoService

func RegisterRoutes

func RegisterRoutes(r *chi.Mux)

Types

type CustomizedVideo

type CustomizedVideo struct {
	Id        uint
	Name      string
	Url       string
	UserId    uint
	CreatedAt time.Time
	UpdatedAt time.Time
}

type Video

type Video struct {
	Id         uint
	Name       string
	Url        string
	Categories []videoCategory
	CreatedAt  time.Time
	UpdatedAt  time.Time
}

type VideoRepository

type VideoRepository interface {
	GetAllVideos() []videoModel
	CreateVideo(name string, path string, categories []uint) (id uint, err error)
}

func NewPostgresRepository

func NewPostgresRepository(db *sql.DB) VideoRepository

Jump to

Keyboard shortcuts

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