greeterservice

package
v0.0.0-...-cb8cfd3 Latest Latest
Warning

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

Go to latest
Published: Oct 15, 2022 License: MIT Imports: 2 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GreeterService

type GreeterService struct{}

GreeterService implementation of the Service interface.

func (GreeterService) Greeting

func (GreeterService) Greeting(name string) (greeting string)

Greeting implementation of the Service.

func (GreeterService) Health

func (GreeterService) Health() bool

Health implementation of the Service.

type Service

type Service interface {
	Health() bool
	Greeting(name string) string
}

Service describe greetings service.

type ServiceMiddleware

type ServiceMiddleware func(Service) Service

ServiceMiddleware describes a service middleware.

func LoggingMiddleware

func LoggingMiddleware(logger log.Logger) ServiceMiddleware

LoggingMiddleware takes a logger as a dependency and returns a ServiceMiddleware.

Jump to

Keyboard shortcuts

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