repository

package
v0.0.0-...-d4d3a42 Latest Latest
Warning

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

Go to latest
Published: Jan 5, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BookRepository

type BookRepository interface {
	Save(book *model.Book)
	Delete(book *model.Book)
	FindById(id uuid.UUID) *model.Book
	FindAll() *[]model.Book
}

func NewBookRepository

func NewBookRepository(Db *gorm.DB) BookRepository

type BookRepositoryImpl

type BookRepositoryImpl struct {
	Db *gorm.DB
}

func (*BookRepositoryImpl) Delete

func (b *BookRepositoryImpl) Delete(book *model.Book)

func (*BookRepositoryImpl) FindAll

func (b *BookRepositoryImpl) FindAll() *[]model.Book

FindAll implements BookRepository.

func (*BookRepositoryImpl) FindById

func (b *BookRepositoryImpl) FindById(bookId uuid.UUID) *model.Book

FindById implements BookRepository.

func (*BookRepositoryImpl) Save

func (b *BookRepositoryImpl) Save(book *model.Book)

Save implements BookRepository.

Jump to

Keyboard shortcuts

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