lithium\net\http\Router::_prepareParams PHP Method

_prepareParams() protected static method

Will not attempt to parse strings as shorthand parameters but instead interpret them as normal, non-routed URLs when they are prefixed with a known scheme.
protected static _prepareParams ( array | string $url, Request $context, array $options ) : array | string
$url array | string An array of parameters, shorthand parameter string or URL string.
$context lithium\action\Request
$options array
return array | string Depending on the type of $url either a string or an array.
    protected static function _prepareParams($url, $context, array $options)
    {
        if (is_string($url)) {
            if (strpos($url, '://')) {
                return $url;
            }
            foreach (array('#', '//', 'mailto', 'javascript') as $prefix) {
                if (strpos($url, $prefix) === 0) {
                    return $url;
                }
            }
            if (is_string($url = static::_parseString($url, $context, $options))) {
                return static::_prefix($url, $context, $options);
            }
        }
        $isArray = isset($url[0]) && is_array($params = static::_parseString($url[0], $context, $options));
        if ($isArray) {
            unset($url[0]);
            $url = $params + $url;
        }
        return static::_persist(static::_parseController($url), $context);
    }