services

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Nov 12, 2022 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CustomerService

type CustomerService interface {
	AddCustomer(*models.CustomerCreateRequest) (*models.CustomerCreateResponse, error)
	GetCustomers() (*models.CustomersGetResponse, error)
	GetCustomer(string) (*models.CustomerGetResponse, error)
	UpdateCustomer(string, *models.CustomerUpdateRequest) (*models.CustomerUpdateResponse, error)
	DeleteCustomer(string) error
}

func NewCustomerService

func NewCustomerService(collection *mongo.Collection, ctx context.Context) CustomerService

type CustomerServiceImpl

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

func (*CustomerServiceImpl) AddCustomer

func (*CustomerServiceImpl) DeleteCustomer

func (cs *CustomerServiceImpl) DeleteCustomer(id string) error

func (*CustomerServiceImpl) GetCustomer

func (cs *CustomerServiceImpl) GetCustomer(id string) (*models.CustomerGetResponse, error)

func (*CustomerServiceImpl) GetCustomers

func (cs *CustomerServiceImpl) GetCustomers() (*models.CustomersGetResponse, error)

func (*CustomerServiceImpl) UpdateCustomer

type HealthService

type HealthService interface {
	CheckHealth() (*models.HealthResponse, error)
}

func NewHealthService

func NewHealthService(client *mongo.Client, ctx context.Context) HealthService

type HealthServiceImpl

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

func (*HealthServiceImpl) CheckHealth

func (hs *HealthServiceImpl) CheckHealth() (*models.HealthResponse, error)

Jump to

Keyboard shortcuts

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