// FromURL returns a Dialer given a URL specification and an underlying
// Dialer for it to make network requests.
429206
func FromURL(u *url.URL, forward Dialer) (Dialer, error) {
	var auth *Auth
	if u.User != nil {
		auth = new(Auth)
		auth.User = u.User.Username()
		if p, ok := u.User.Password(); ok {
			auth.Password = p
		}
	}

	switch u.Scheme {
	case "socks5":
		return SOCKS5("tcp", u.Host, auth, forward)
	}

	// If the scheme doesn't match any of the built-in schemes, see if it
	// was registered by another package.
	if proxySchemes != nil {
		if f, ok := proxySchemes[u.Scheme]; ok {
			return f(u, forward)
		}
	}

	return nil, errors.New("proxy: unknown scheme: " + u.Scheme)
}
329477
func (s *CreateOriginEndpointOutput) SetUrl(v string) *CreateOriginEndpointOutput {
	s.Url = &v
	return s
}
491440
func (otp *HOTP) URL(label string) string {
	return otp.OATH.URL(otp.Type(), label)
}
1183339
func (s *OutputDestinationSettings) SetUrl(v string) *OutputDestinationSettings {
	s.Url = &v
	return s
}
851124
func URL(key string, fallback *url.URL) *url.URL {
	return DefaultClient.URL(key, fallback)
}
386895
func (nc *Conn) ConnectedUrl() string {
	if nc == nil {
		return _EMPTY_
	}

	nc.mu.RLock()
	defer nc.mu.RUnlock()

	if nc.status != CONNECTED {
		return _EMPTY_
	}
	return nc.current.url.String()
}
605654
func (s *Server) URL() (u *url.URL, err error) {
	if s.Scheme == "" {
		return u, fmt.Errorf("Server %s:%d has no scheme, cannot make a URL", s.Host, s.Port)
	}

	ustring := fmt.Sprintf("%s://%s:%d", s.Scheme, s.Host, s.Port)

	u, err = url.Parse(ustring)
	if err != nil {
		return u, fmt.Errorf("Could not parse %s: %s", ustring, err)
	}

	return
}
1152306
func FromHTTP(f http.Handler) ContextHandler {
	return HandlerFunc(func(_ context.Context, rw http.ResponseWriter, r *http.Request) {
		f.ServeHTTP(rw, r)
	})
}
1323678
func (s *EstimateTemplateCostOutput) SetUrl(v string) *EstimateTemplateCostOutput {
	s.Url = &v
	return s
}
1294534
func (c *AppPackageDeleteCall) Url(url string) *AppPackageDeleteCall {
	c.urlParams_.Set("url", url)
	return c
}
717250
func URL(url string) {
	switch def := dslengine.CurrentDefinition().(type) {
	case *design.ContactDefinition:
		def.URL = url
	case *design.LicenseDefinition:
		def.URL = url
	case *design.DocsDefinition:
		def.URL = url
	default:
		dslengine.IncompatibleDSL()
	}
}
624591
func (s *GetOpenIDConnectProviderOutput) SetUrl(v string) *GetOpenIDConnectProviderOutput {
	s.Url = &v
	return s
}
757160
func (s *StaticKeyProvider) SetUrl(v string) *StaticKeyProvider {
	s.Url = &v
	return s
}
475049
func (otp *TOTP) URL(label string) string {
	return otp.OATH.URL(otp.Type(), label)
}
204324
func (s *CreateOpenIDConnectProviderInput) SetUrl(v string) *CreateOpenIDConnectProviderInput {
	s.Url = &v
	return s
}
63907
func proxy_FromEnvironment() proxy_Dialer {
	allProxy := proxy_allProxyEnv.Get()
	if len(allProxy) == 0 {
		return proxy_Direct
	}

	proxyURL, err := url.Parse(allProxy)
	if err != nil {
		return proxy_Direct
	}
	proxy, err := proxy_FromURL(proxyURL, proxy_Direct)
	if err != nil {
		return proxy_Direct
	}

	noProxy := proxy_noProxyEnv.Get()
	if len(noProxy) == 0 {
		return proxy
	}

	perHost := proxy_NewPerHost(proxy, proxy_Direct)
	perHost.AddFromString(noProxy)
	return perHost
}
899109
func (s *Message) SetUrl(v string) *Message {
	s.Url = &v
	return s
}