Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type HackableRoundTripper ¶
type HackableRoundTripper struct {
// contains filtered or unexported fields
}
HackableRoundTripper is a round tripper that allows for interceptor injection.
func NewHackableRoundTripper ¶
func NewHackableRoundTripper(inner http.RoundTripper) *HackableRoundTripper
func (*HackableRoundTripper) SetInterceptor ¶
func (h *HackableRoundTripper) SetInterceptor(rt http.RoundTripper)
SetInterceptor sets an interceptor, requests are directed to the interceptor instead of the inner round tripper. If interceptor RoundTrip returns nil for both response and error the process falls back to inner round tripper.
Click to show internal directories.
Click to hide internal directories.