http_v1

package
v0.0.0-...-32a9906 Latest Latest
Warning

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

Go to latest
Published: Oct 30, 2024 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MapBookingRoutes

func MapBookingRoutes(
	router *gin.RouterGroup,
	controller BookingControllerInterface,
)

func MapEventRoutes

func MapEventRoutes(
	router *gin.RouterGroup,
	controller EventControllerInterface,
)

func MapHealthCheckRoutes

func MapHealthCheckRoutes(
	router *gin.RouterGroup,
	controller HealthCheckInterface,
)

Types

type BookingController

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

func (*BookingController) CreateBooking

func (b *BookingController) CreateBooking(c *gin.Context)

func (*BookingController) DeleteBooking

func (b *BookingController) DeleteBooking(c *gin.Context)

func (*BookingController) GetBooking

func (b *BookingController) GetBooking(c *gin.Context)

type BookingControllerInterface

type BookingControllerInterface interface {
	CreateBooking(c *gin.Context)
	GetBooking(c *gin.Context)
	DeleteBooking(c *gin.Context)
}

func NewBookingController

func NewBookingController(
	logger logger.Logger,
	bookingSrv service.BookingServiceInterface,
) BookingControllerInterface

type ControllerFactory

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

func NewControllerFactory

func NewControllerFactory(
	db *sqlx.DB,
	logger logger.Logger,
	redis *redis.Client,
) *ControllerFactory

func (*ControllerFactory) NewBookingController

func (f *ControllerFactory) NewBookingController() BookingControllerInterface

func (*ControllerFactory) NewEventController

func (f *ControllerFactory) NewEventController() EventControllerInterface

func (*ControllerFactory) NewHealthCheckController

func (f *ControllerFactory) NewHealthCheckController() HealthCheckInterface

type EventController

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

func (*EventController) CreateEvent

func (e *EventController) CreateEvent(c *gin.Context)

func (*EventController) DeleteEvent

func (e *EventController) DeleteEvent(c *gin.Context)

func (*EventController) GetEvent

func (e *EventController) GetEvent(c *gin.Context)

type EventControllerInterface

type EventControllerInterface interface {
	CreateEvent(c *gin.Context)
	GetEvent(c *gin.Context)
	DeleteEvent(c *gin.Context)
}

Controller for testing data, should be in another service

func NewEventController

func NewEventController(
	logger logger.Logger,
	eventSrv service.EventServiceInterface,
) EventControllerInterface

type HealthCheckController

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

func (*HealthCheckController) GetHealthCheck

func (h *HealthCheckController) GetHealthCheck(c *gin.Context)

type HealthCheckInterface

type HealthCheckInterface interface {
	GetHealthCheck(c *gin.Context)
}

func NewHealthCheckController

func NewHealthCheckController(
	logger logger.Logger,
	redis *redis.Client,
	db *sqlx.DB,
) HealthCheckInterface

Jump to

Keyboard shortcuts

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