middleware

package
v1.3.2 Latest Latest
Warning

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

Go to latest
Published: Sep 12, 2024 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Invoke

func Invoke[Req any, Resp any](_ context.Context, req Req) (Resp, error)

Types

type Invoker

type Invoker[Req any, Resp any] func(ctx context.Context, req Req) (Resp, error)

type Middleware

type Middleware[Req any, Resp any] func(ctx context.Context, req Req, invoker Invoker[Req, Resp]) (Resp, error)

func Chain

func Chain[Req any, Resp any](middlewares ...Middleware[Req, Resp]) Middleware[Req, Resp]

Jump to

Keyboard shortcuts

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