static function compile($pattern, array $options = array())
    {
        $route = self::compilePattern($pattern, $options);

        // save compiled pattern
        $route['compiled'] = sprintf("#^%s$#xs", $route['regex']);
        $route['pattern'] = $pattern; // save pattern
        return $route;
    }
static function compile($pattern, array $options = array())
    {
        $route = self::compilePattern($pattern, $options);

        // save compiled pattern
        $route['compiled'] = sprintf("#^%s$#xs", $route['regex']);
        $route['pattern'] = $pattern; // save pattern
        return $route;
    }
static function compile ( $ pattern , array $ options = array ( ) ) { $ route = self :: compilePattern ( $ pattern , $ options ) ; // save compiled pattern $ route [ 'compiled' ] = sprintf ( "#^%s$#xs" , $ route [ 'regex' ] ) ; $ route [ 'pattern' ] = $ pattern ; // save pattern return $ route ; }
Compiles the current route instance.

@param array $route route info

@return array compiled route info, with newly added 'compiled' key.
Compiles the current route instance .