gateway

package
v1.2.12 Latest Latest
Warning

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

Go to latest
Published: Apr 23, 2024 License: MIT Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CookieHook

func CookieHook(ctx context.Context, writer http.ResponseWriter, message proto.Message) error

func CustomHTTPError

func CustomHTTPError(ctx context.Context, mux *runtime.ServeMux, marshaler runtime.Marshaler, w http.ResponseWriter, r *http.Request, err error)

func ForwardResponseMessage

func ForwardResponseMessage(ctx *gin.Context, md runtime.ServerMetadata, message proto.Message)

func Gateway

func Gateway(gatewayHandle GatewayHandler) *runtime.ServeMux

func HTTPError

func HTTPError(ctx *gin.Context, err error)

func HTTPStatusFromCode

func HTTPStatusFromCode(code errorcode.ErrCode) int

func ResponseHook

func ResponseHook(ctx context.Context, writer http.ResponseWriter, message proto.Message) error

func RoutingErrorHandler

func RoutingErrorHandler(ctx context.Context, mux *runtime.ServeMux, marshaler runtime.Marshaler, w http.ResponseWriter, r *http.Request, httpStatus int)

Types

type GatewayHandler

type GatewayHandler func(context.Context, *runtime.ServeMux)

type SetCookie

type SetCookie interface {
	GetCookie() string
}

Jump to

Keyboard shortcuts

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