repositories

package
v0.0.0-...-7c9d44d Latest Latest
Warning

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

Go to latest
Published: Oct 10, 2022 License: ISC Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type JobRepository

type JobRepository interface {
	Insert(job *domain.Job) (*domain.Job, error)
	Find(id string) (*domain.Job, error)
	Update(job *domain.Job) (*domain.Job, error)
}

type JobRepositoryDb

type JobRepositoryDb struct {
	Db *gorm.DB
}

func (JobRepositoryDb) Find

func (repo JobRepositoryDb) Find(id string) (*domain.Job, error)

func (JobRepositoryDb) Insert

func (repo JobRepositoryDb) Insert(job *domain.Job) (*domain.Job, error)

func (JobRepositoryDb) Update

func (repo JobRepositoryDb) Update(job *domain.Job) (*domain.Job, error)

type VideoRepository

type VideoRepository interface {
	Insert(video *domain.Video) (*domain.Video, error)
	Find(id string) (*domain.Video, error)
}

type VideoRepositoryDb

type VideoRepositoryDb struct {
	Db *gorm.DB
}

func NewVideoRepository

func NewVideoRepository(db *gorm.DB) *VideoRepositoryDb

func (VideoRepositoryDb) Find

func (repo VideoRepositoryDb) Find(id string) (*domain.Video, error)

func (VideoRepositoryDb) Insert

func (repo VideoRepositoryDb) Insert(video *domain.Video) (*domain.Video, error)

Jump to

Keyboard shortcuts

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