service

package
v0.0.0-...-09b6e72 Latest Latest
Warning

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

Go to latest
Published: Jun 19, 2020 License: GPL-3.0 Imports: 4 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GuestsService

type GuestsService interface {
	// Add your methods here
	CreateGuest(ctx context.Context, event string, guest model.Guest) (rs string, err error)
	ReadGuest(ctx context.Context, query model.Query) (rs []model.Guest, err error)
	UpdateGuest(ctx context.Context, query model.Query) (rs string, err error)
	DeleteGuest(ctx context.Context, query model.Query) (rs string, err error)

	CreateSponsor(ctx context.Context, event string, sponsor model.Participant) (rs string, err error)
	ReadSponsor(ctx context.Context, query model.Query) (rs []model.Participant, err error)
	UpdateSponsor(ctx context.Context, query model.Query) (rs string, err error)
	DeleteSponsor(ctx context.Context, query model.Query) (rs string, err error)
}

GuestsService describes the service.

func New

func New(middleware []Middleware) GuestsService

New returns a GuestsService with all of the expected middleware wired in.

func NewBasicGuestsService

func NewBasicGuestsService() GuestsService

NewBasicGuestsService returns a naive, stateless implementation of GuestsService.

type Middleware

type Middleware func(GuestsService) GuestsService

Middleware describes a service middleware.

func LoggingMiddleware

func LoggingMiddleware(logger log.Logger) Middleware

LoggingMiddleware takes a logger as a dependency and returns a GuestsService Middleware.

Jump to

Keyboard shortcuts

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