// URL is defined in simplestreams.DataSource.
174273
func (s *storageSimpleStreamsDataSource) URL(path string) (string, error) {
	return s.storage.URL(s.relpath(path))
}
847006
func (s *ClusterRerouteService) buildURL() (string, url.Values, error) {
	// Build URL
	path := "/_cluster/reroute"

	// Add query string parameters
	params := url.Values{}
	if s.pretty {
		params.Set("pretty", "true")
	}
	if v := s.dryRun; v != nil {
		params.Set("dry_run", fmt.Sprint(*v))
	}
	if v := s.explain; v != nil {
		params.Set("explain", fmt.Sprint(*v))
	}
	if v := s.retryFailed; v != nil {
		params.Set("retry_failed", fmt.Sprint(*v))
	}
	if len(s.metrics) > 0 {
		params.Set("metric", strings.Join(s.metrics, ","))
	}
	if s.masterTimeout != "" {
		params.Set("master_timeout", s.masterTimeout)
	}
	if s.timeout != "" {
		params.Set("timeout", s.timeout)
	}
	if s.pretty {
		params.Set("pretty", "true")
	}
	return path, params, nil
}
38166
func (ns *Namespace) URL(a interface{}) (template.URL, error) {
	s, err := cast.ToStringE(a)
	return template.URL(s), err
}
409072
func (h *AsyncHttpHandler) Url() string {
	h.manager.lock.RLock()
	defer h.manager.lock.RUnlock()

	return h.manager.route + "/" + h.id
}
211992
func LoadURL(url string) (*Node, error) {
	resp, err := http.Get(url)
	if err != nil {
		return nil, err
	}
	defer resp.Body.Close()
	return parse(resp.Body)
}
161214
func (s *StreamAddr) URL() *url.URL {
	return &url.URL{
		Scheme: logDogURLScheme,
		Host:   s.Host,
		Path:   strings.Join([]string{"", string(s.Project), string(s.Path)}, "/"),
	}
}
20235
func getSourceStreamFromURL(urlStr string, encKeyDB map[string][]prefixSSEPair) (reader io.ReadCloser, err *probe.Error) {
	alias, urlStrFull, _, err := expandAlias(urlStr)
	if err != nil {
		return nil, err.Trace(urlStr)
	}
	sse := getSSE(urlStr, encKeyDB[alias])
	reader, _, err = getSourceStream(alias, urlStrFull, false, sse)
	return reader, err
}
233806
func (c *Client) URL(uri string) *Client {
	c.Use(url.URL(uri))
	return c
}
901290
func (q *Query) FindUrl() (url string) {
	return fmt.Sprintf(find_url, q.ClusterId)
}
88190
func (r *Registry) url(pathTemplate string, args ...interface{}) string {
	pathSuffix := fmt.Sprintf(pathTemplate, args...)
	url := fmt.Sprintf("%s%s", r.URL, pathSuffix)
	return url
}
400672
func (r *Request) URL(uri string) *Request {
	r.Use(url.URL(uri))
	return r
}
887356
func (h *Client) DataSource(dataSource string) *Client {
	h.dataSource = dataSource
	h.dataSourceSet = true
	return h
}
382556
func (s *PercolateService) buildURL() (string, url.Values, error) {
	// Build URL
	var path string
	var err error
	if s.id == "" {
		path, err = uritemplates.Expand("/{index}/{type}/_percolate", map[string]string{
			"index": s.index,
			"type":  s.typ,
		})
	} else {
		path, err = uritemplates.Expand("/{index}/{type}/{id}/_percolate", map[string]string{
			"index": s.index,
			"type":  s.typ,
			"id":    s.id,
		})
	}
	if err != nil {
		return "", url.Values{}, err
	}

	// Add query string parameters
	params := url.Values{}
	if s.pretty {
		params.Set("pretty", "1")
	}
	if s.version != nil {
		params.Set("version", fmt.Sprintf("%v", s.version))
	}
	if s.versionType != "" {
		params.Set("version_type", s.versionType)
	}
	if len(s.routing) > 0 {
		params.Set("routing", strings.Join(s.routing, ","))
	}
	if s.preference != "" {
		params.Set("preference", s.preference)
	}
	if s.ignoreUnavailable != nil {
		params.Set("ignore_unavailable", fmt.Sprintf("%v", *s.ignoreUnavailable))
	}
	if s.percolateIndex != "" {
		params.Set("percolate_index", s.percolateIndex)
	}
	if s.percolatePreference != "" {
		params.Set("percolate_preference", s.percolatePreference)
	}
	if s.percolateRouting != "" {
		params.Set("percolate_routing", s.percolateRouting)
	}
	if s.source != "" {
		params.Set("source", s.source)
	}
	if s.allowNoIndices != nil {
		params.Set("allow_no_indices", fmt.Sprintf("%v", *s.allowNoIndices))
	}
	if s.expandWildcards != "" {
		params.Set("expand_wildcards", s.expandWildcards)
	}
	if s.percolateFormat != "" {
		params.Set("percolate_format", s.percolateFormat)
	}
	if s.percolateType != "" {
		params.Set("percolate_type", s.percolateType)
	}
	return path, params, nil
}
475049
func (otp *TOTP) URL(label string) string {
	return otp.OATH.URL(otp.Type(), label)
}
1137244
func URL(addr string) ClientOpt {
	return func(c *Client) {
		if addr == "" {
			addr = "amqp://guest:guest@localhost/"
		}
		c.addr = addr
	}
}
504088
func (o OSS) URL(styles ...string) string {
	url := o.Base.URL(styles...)

	newurl, err := Storage.GetURL(url)
	if err != nil || len(newurl) == 0 {
		return url
	}

	return newurl
}
788958
func (bow *Browser) Url() *url.URL {
	if bow.state.Response == nil {
		// there is a possibility that we issued a request, but for
		// whatever reason the request failed.
		if bow.state.Request != nil {
			return bow.state.Request.URL
		}
		return nil
	}

	return bow.state.Response.Request.URL
}