presenter

package
v0.0.0-...-e38139c Latest Latest
Warning

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

Go to latest
Published: Mar 26, 2021 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DummyInterceptor

func DummyInterceptor(ctx context.Context,
	req interface{},
	info *grpc.UnaryServerInfo,
	handler grpc.UnaryHandler) (interface{}, error)

DummyInterceptor is a dummy, showcasing interceptor chaining

func ErrRepackagingInterceptor

func ErrRepackagingInterceptor(ctx context.Context,
	req interface{},
	info *grpc.UnaryServerInfo,
	handler grpc.UnaryHandler) (resp interface{}, err error)

ErrRepackagingInterceptor logs and then repackages errors to be returned to the user

func UnaryInterceptorChainer

func UnaryInterceptorChainer(interceptors ...grpc.UnaryServerInterceptor) grpc.UnaryServerInterceptor

UnaryInterceptorChainer is shamelessly copied from go-grpc-middleware.ChainUnaryServer

Types

type Server

type Server struct {
}

Server represents the gRPC server

func (*Server) C2F

func (s *Server) C2F(ctx context.Context, req *api.ConversionMsg) (cm *api.ConversionMsg, err error)

C2F calculates temperature in F from C

func (*Server) F2C

func (s *Server) F2C(ctx context.Context, req *api.ConversionMsg) (cm *api.ConversionMsg, err error)

F2C calculates temperature in C from F

Jump to

Keyboard shortcuts

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