handlers

package
v0.0.0-...-8063b4c Latest Latest
Warning

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

Go to latest
Published: Apr 21, 2022 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Initialize

func Initialize(productHandler *ProductHandler, healthCheckHandler *HealthCheckHandler) http.Handler

Initialize ..

Types

type HealthCheckHandler

type HealthCheckHandler struct {
	DbConn *sql.DB
}

HealthCheckHandler ..

func NewHealthCheckHandler

func NewHealthCheckHandler(dbConn *sql.DB) *HealthCheckHandler

NewHealthCheckHandler ..

func (*HealthCheckHandler) GetHealthCheckHandler

func (h *HealthCheckHandler) GetHealthCheckHandler(w http.ResponseWriter, r *http.Request)

GetHealthCheckHandler ..

type ProductHandler

type ProductHandler struct {
	Service product.Service
}

ProductHandler ..

func NewProductHandler

func NewProductHandler(service product.Service) *ProductHandler

NewProductHandler ..

func (*ProductHandler) AddProduct

func (c *ProductHandler) AddProduct(w http.ResponseWriter, r *http.Request)

AddProductItem ..

func (*ProductHandler) GetProductByID

func (c *ProductHandler) GetProductByID(w http.ResponseWriter, r *http.Request)

GetProductItemByID ..

func (*ProductHandler) GetProducts

func (c *ProductHandler) GetProducts(w http.ResponseWriter, r *http.Request)

GetProductItems ..

func (*ProductHandler) RemoveProduct

func (c *ProductHandler) RemoveProduct(w http.ResponseWriter, r *http.Request)

RemoveProductItem ..

func (*ProductHandler) UpdateProduct

func (c *ProductHandler) UpdateProduct(w http.ResponseWriter, r *http.Request)

UpdateProductItem ..

Jump to

Keyboard shortcuts

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