book

package
v0.0.0-...-587043a Latest Latest
Warning

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

Go to latest
Published: Jun 22, 2024 License: MIT Imports: 8 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 interface {
	CreateBook(book *entities.Book) (*entities.Book, error)
	DeleteBook(bookID string) error
	GetBook(bookID string) (*entities.Book, error)
	GetBooks() ([]*entities.Book, error)
	GetBooksByID(bookIDList []string) ([]*entities.Book, error)
}

func NewRepo

func NewRepo(db *pgx.Conn) Repository

type Service

type Service interface {
	InsertBook(book *entities.Book) (*entities.Book, error)
	DeleteBook(bookID string) error
	GetBook(bookID string) (*entities.Book, error)
	GetBooks() ([]*entities.Book, error)
	GetBooksByID(bookIDList []string) ([]*entities.Book, error)
}

func NewService

func NewService(r Repository) Service

Jump to

Keyboard shortcuts

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