//
pkg.gl
Category
github.com/ibiscum/Go-Programming-Cookbook-Second-Edition
chapter07
internal
decorator
package
0.0.0-20241212173216-745cb4b42230
Repository:
https://github.com/ibiscum/go-programming-cookbook-second-edition.git
Documentation:
pkg.go.dev
Overview
Versions
1
Dependencies
5
Dependents
1
Files
64 SLOC
#
Functions
BasicAuth
BasicAuth is another of our 'middleware' decorators.
Decorate
Decorate is a helper to wrap all the middleware.
Exec
Exec creates a client, calls google.com then prints the response.
Logger
Logger is one of our 'middleware' decorators.
Setup
Setup initializes our ClientInterface.
#
Type aliases
Decorator
Decorator is a convenience function to represent our middleware inner function.
TransportFunc
TransportFunc implements the RountTripper interface.