package
0.0.0-20240619081448-a25b4f51b4f4
Repository: https://github.com/root-gg/plik.git
Documentation: pkg.go.dev

# Functions

Adapt add context to a middleware so it can be added to the chain.
NewChain creates a new contextMiddleware chain.
TestBadRequest is a helper to test a httptest.ResponseRecorder status.
TestFail is a helper to test a httptest.ResponseRecorder status.
TestForbidden is a helper to test a httptest.ResponseRecorder status.
TestInternalServerError is a helper to test a httptest.ResponseRecorder status.
TestInvalidParameter is a helper to test a httptest.ResponseRecorder status.
TestMissingParameter is a helper to test a httptest.ResponseRecorder status.
TestNotFound is a helper to test a httptest.ResponseRecorder status.
TestOK is a helper to test a httptest.ResponseRecorder status.
TestPanic is a helper to test a httptest.ResponseRecorder status.
TestUnauthorized is a helper to test a httptest.ResponseRecorder status.

# Structs

Chain link context middleware to each other.
ChainHandler holds a chain and a final handler.
Context to be propagated throughout the middleware chain.

# Type aliases

Handler is a constructor to close a Context into a http.Handler.
HandlerFunc is a constructor to close a Context into a http.HandlerFunc.
Middleware is a constructor to close a Context into a middleware.