func (pc *ProxyConfig) InstallInDefaultTransport() error {
	transport, ok := http.DefaultTransport.(*http.Transport)
	if !ok {
		return errors.Errorf("http.DefaultTransport was %T instead of *http.Transport", http.DefaultTransport)
	}
	transport.Proxy = pc.GetProxy
	return nil
}
// InstallInDefaultTransport sets the proxy resolution used by the
// default HTTP transport to use the proxy details stored in this
// ProxyConfig. Requests made without an explicit transport will
// respect these proxy settings.
InstallInDefaultTransport sets the proxy resolution used by the
default HTTP transport to use the proxy details stored in this
ProxyConfig. Requests made without an explicit transport will
respect these proxy settings.
// InstallInDefaultTransport sets the proxy resolution used by the // default HTTP transport to use the proxy details stored in this // ProxyConfig . Requests made without an explicit transport will // respect these proxy settings .
func (pc *ProxyConfig) InstallInDefaultTransport() error {
	transport, ok := http.DefaultTransport.(*http.Transport)
	if !ok {
		return errors.Errorf("http.DefaultTransport was %T instead of *http.Transport", http.DefaultTransport)
	}
	transport.Proxy = pc.GetProxy
	return nil
}
func ( pc * ProxyConfig ) InstallInDefaultTransport ( ) error { transport , ok := http . DefaultTransport . ( * http . Transport ) if ! ok { return errors . Errorf ( " " , http . DefaultTransport ) } transport . Proxy = pc . GetProxy return nil }
InstallInDefaultTransport sets the proxy resolution used by the
default HTTP transport to use the proxy details stored in this
ProxyConfig.
InstallInDefaultTransport sets the proxy resolution used by the default HTTP transport to use the proxy details stored in this ProxyConfig .