private function generateHost(ParsedRoute $route, &$values) : string
    {
        $host = '';

        if (!empty($route->getRawHost())) {
            $host = $this->generateUrlPart($route->getRawHost(), $route->getHostRegex(), $route->getName(), $values);
            // Prefix the URL with the protocol
            $host = 'http' . ($route->isSecure() ? 's' : '') . '://' . $host;
        }

        return $host;
    }
private function generateHost(ParsedRoute $route, &$values) : string
    {
        $host = '';

        if (!empty($route->getRawHost())) {
            $host = $this->generateUrlPart($route->getRawHost(), $route->getHostRegex(), $route->getName(), $values);
            // Prefix the URL with the protocol
            $host = 'http' . ($route->isSecure() ? 's' : '') . '://' . $host;
        }

        return $host;
    }
private function generateHost ( ParsedRoute $ route , & $ values ) : string { $ host = '' ; if ( ! empty ( $ route -> getRawHost ( ) ) ) { $ host = $ this -> generateUrlPart ( $ route -> getRawHost ( ) , $ route -> getHostRegex ( ) , $ route -> getName ( ) , $ values ) ; // Prefix the URL with the protocol $ host = 'http' . ( $ route -> isSecure ( ) ? 's' : '' ) . '://' . $ host ; } return $ host ; }
Generates the host portion of a URL for a route

@param ParsedRoute $route The route whose URL we're generating
@param mixed|array $values The value or list of values to fill the route with
@return string The generated host value
@throws URLException Thrown if the generated host is not valid
Generates the host portion of a URL for a route