Build the absolute URI based on supplied URI and parameters.

@param $uri
An absolute URI.
@param $params
Parameters to be append as GET.

@return
An absolute URI with supplied parameters.

@ingroup oauth2_section_4
492361
private function buildUri($uri, $params)
    {
        $parse_url = parse_url($uri);

        // Add our params to the parsed uri
        foreach ( $params as $k => $v ) {
            if (isset($parse_url[$k])) {
                $parse_url[$k] .= "&" . http_build_query($v);
            } else {
                $parse_url[$k] = http_build_query($v);
            }
        }

        // Put humpty dumpty back together
        return
            ((isset($parse_url["scheme"])) ? $parse_url["scheme"] . "://" : "")
            . ((isset($parse_url["user"])) ? $parse_url["user"]
            . ((isset($parse_url["pass"])) ? ":" . $parse_url["pass"] : "") . "@" : "")
            . ((isset($parse_url["host"])) ? $parse_url["host"] : "")
            . ((isset($parse_url["port"])) ? ":" . $parse_url["port"] : "")
            . ((isset($parse_url["path"])) ? $parse_url["path"] : "")
            . ((isset($parse_url["query"])) ? "?" . $parse_url["query"] : "")
            . ((isset($parse_url["fragment"])) ? "#" . $parse_url["fragment"] : "")
        ;
    }
577834
private function buildUrlParams(
        string $url,
        array $params
    ) {
        array_walk($params, function (&$value, $key) {
            $value = "$key=$value";
        });

        return $url.'?'.implode('&', $params);
    }
451258
public function getUrl(string $path = null, array $params = []): Uri
    {
        $pathParams = $this->getPathParams($params);
        # get the path parameters
        $queryParams = $this->getQueryParams($params);
        # get the query parameters
        $path .= !empty($pathParams) ? '/' . $pathParams : '';
        # append the rest of the path
        if (!empty($path) && $path[0] !== '/') {
            $path = '/' . $path;
        }
        return $this->uri->withPath($path)->withQuery($queryParams);
    }
782962
private function uriConstruct($slug, $params) {
		$uri = self::API_HOST . '/' . $slug;
		if ($params) {
			$queryData = http_build_query($params);
			$uri .= '?' . $queryData;
		}

		return $uri;
	}
587437
private static function buildQuery ($url, $params = array())
    {
        $full_url = $url;

        if (count($params) > 0)
        {
            $full_url .= "?" . implode("&", $params);
        }

        return $full_url;
    }
1329981
public function signUri($uri, $secret, $paramName, $params)
    {
        $join = (bool) parse_url($uri, PHP_URL_QUERY) ? '&' : '?';

        return $uri.$join.$paramName.'='.$this->createSignature($secret, $params);
    }
203076
def _append_params_to_uri(cls, uri, params):
        

        if params:
            return uri + cls._DELIMITER_URL_QUERY + urlencode(params)

        return uri
113312
public static function make($uri, $params = [], $queryDelimeter = '?')
    {
        $uri .= (strstr($uri, $queryDelimeter) === false) ? $queryDelimeter : '&';

        return $uri.http_build_query($params);
    }
1323436
public static function replace($uri, $parameters = [])
    {
        $parameters = (array) $parameters;

        $uri = static::replaceRouteParameters($uri, $parameters);
        $uri = str_replace('//', '/', $uri);

        return $uri;
    }
874255
protected function executeRequest(Uri $uri, array $params = null)
    {
        $guzzle = new GuzzleClient(['verify' => $this->connection->getVerifySsl()]);

        return $guzzle->request(
            $this->connection->getHttpMethod(),
            $uri,
            null !== $params ? ['form_params' => $params] : []
        );
    }
109724
public function build($uri)
	{
		// Create the URI object
		$uri = $this->createUri($uri);

		// Process the uri information based on custom defined rules
		foreach ($this->rules['build'] as $rule)
		{
			$uri = $rule($uri);
		}

		return $uri;
	}
775559
public function get( $uri, array $params = array() )
    {
        $this->_client->setMethod('GET');
        return $this->_request($uri, $params);
    }
1009026
public static function make($uri, array $queryParameters = [])
    {
        $uri = ($uri instanceof UriInterface) ? $uri : new Uri($uri);
        if ($queryParameters) {
            $uri = static::addQueryParameters($uri, $queryParameters);
        }
        return $uri;
    }
536827
public static function createAbsolute($url, array $params = array())
    {
        $url = self::addParams($url, $params);
        $url = ltrim($url, '/');
        $baseUrl = app()->request->getBaseUrl();

        return $baseUrl.'/'.$url;
    }
713294
def build_absolute_uri(request, relative_url):
    """"""
    webroot = getattr(settings, 'WEBROOT', '')
    if webroot.endswith("/") and relative_url.startswith("/"):
        webroot = webroot[:-1]

    return request.build_absolute_uri(webroot + relative_url)
269298
public function buildQuery($params)
	{
		if (!is_array($params) || count($params) == 0)
		{
			return false;
		}

		return urldecode(http_build_query($params, '', '&'));
	}
290633
public function post( $uri, array $params = array() )
    {
        $this->_client->setMethod('POST');
        return $this->_request($uri, $params);
    }