protected function getRouteQueryString(array $parameters): string
    {
        // First we will get all of the string parameters that are remaining after we
        // have replaced the route wildcards. We'll then build a query string from
        // these string parameters then use it as a starting point for the rest.
        if (\count($parameters) === 0 || \in_array(null, $parameters, true)) {
            return '';
        }

        $query = \http_build_query(
            $keyed = $this->getStringParameters($parameters),
            '',
            '&',
            \PHP_QUERY_RFC3986
        );

        // Lastly, if there are still parameters remaining, we will fetch the numeric
        // parameters that are in the array and add them to the query string or we
        // will make the initial query string if it wasn't started with strings.
        if (\count($keyed) < \count($parameters)) {
            $query .= '&' . \implode(
                '&',
                $this->getNumericParameters($parameters)
            );
        }

        // "/" and "?" can be left decoded for better user experience, see
        // http://tools.ietf.org/html/rfc3986#section-3.4
        return '?' . \trim(\strtr($query, ['%2F' => '/']), '&');
    }
protected function getRouteQueryString(array $parameters): string
    {
        // First we will get all of the string parameters that are remaining after we
        // have replaced the route wildcards. We'll then build a query string from
        // these string parameters then use it as a starting point for the rest.
        if (\count($parameters) === 0 || \in_array(null, $parameters, true)) {
            return '';
        }

        $query = \http_build_query(
            $keyed = $this->getStringParameters($parameters),
            '',
            '&',
            \PHP_QUERY_RFC3986
        );

        // Lastly, if there are still parameters remaining, we will fetch the numeric
        // parameters that are in the array and add them to the query string or we
        // will make the initial query string if it wasn't started with strings.
        if (\count($keyed) < \count($parameters)) {
            $query .= '&' . \implode(
                '&',
                $this->getNumericParameters($parameters)
            );
        }

        // "/" and "?" can be left decoded for better user experience, see
        // http://tools.ietf.org/html/rfc3986#section-3.4
        return '?' . \trim(\strtr($query, ['%2F' => '/']), '&');
    }
protected function getRouteQueryString ( array $ parameters ) : string { // First we will get all of the string parameters that are remaining after we // have replaced the route wildcards. We'll then build a query string from // these string parameters then use it as a starting point for the rest. if ( \ count ( $ parameters ) === 0 || \ in_array ( null , $ parameters , true ) ) { return '' ; } $ query = \ http_build_query ( $ keyed = $ this -> getStringParameters ( $ parameters ) , '' , '&' , \ PHP_QUERY_RFC3986 ) ; // Lastly, if there are still parameters remaining, we will fetch the numeric // parameters that are in the array and add them to the query string or we // will make the initial query string if it wasn't started with strings. if ( \ count ( $ keyed ) < \ count ( $ parameters ) ) { $ query .= '&' . \ implode ( '&' , $ this -> getNumericParameters ( $ parameters ) ) ; } // "/" and "?" can be left decoded for better user experience, see // http://tools.ietf.org/html/rfc3986#section-3.4 return '?' . \ trim ( \ strtr ( $ query , [ '%2F' => '/' ] ) , '&' ) ; }
Get the query string for a given route.

@param array $parameters

@return string
Get the query string for a given route .