usecase

package
v0.0.0-...-b6cb40f Latest Latest
Warning

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

Go to latest
Published: Feb 23, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

New creates a new CategoryUsecase instance.

Types

type AddressUsecase

type AddressUsecase struct {
	// contains filtered or unexported fields
}

AddressUsecase is a struct that implements AddressUsecase interface.

func (*AddressUsecase) Create

func (au *AddressUsecase) Create(ctx context.Context, addr *domain.Address) error

Create stores a new Address.

func (*AddressUsecase) Delete

func (au *AddressUsecase) Delete(ctx context.Context, userID, id uint) error

Delete removes the Address with the specified ID.

func (*AddressUsecase) GetAll

func (au *AddressUsecase) GetAll(ctx context.Context, userID uint, title string) ([]domain.Address, error)

GetAll returns all Addresses.

func (*AddressUsecase) GetByID

func (au *AddressUsecase) GetByID(ctx context.Context, userID, id uint) (*domain.Address, error)

GetByID retuns the address with the specified ID.

func (*AddressUsecase) Update

func (au *AddressUsecase) Update(ctx context.Context, addr *domain.Address) error

Update updates the Address with the specified ID.

Jump to

Keyboard shortcuts

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