protected function rewriteRouting ($requestCtrlName, $requestActionName) {
		$request = & $this->request;
		$requestedPathFirstWord = $this->rewriteRoutingGetReqPathFirstWord();
		$this->rewriteRoutingProcessPreHandler($requestedPathFirstWord);
		$routes = & $this->rewriteRoutingGetRoutesToMatch($requestedPathFirstWord);
		$requestMethod = $request->GetMethod();
		foreach ($routes as & $route) {
			/** @var $route \MvcCore\Route */
			if ($this->rewriteRoutingCheckRoute($route, [$requestMethod])) continue;
			$allMatchedParams = $route->Matches($request);
			if ($allMatchedParams !== NULL) {
				$this->currentRoute = clone $route;
				$this->currentRoute->SetMatchedParams($allMatchedParams);

				$this->rewriteRoutingSetRequestedAndDefaultParams(
					$allMatchedParams, $requestCtrlName, $requestActionName
				);
				if ($this->rewriteRoutingSetRequestParams($allMatchedParams)) continue;
				
				$this->rewriteRoutingSetUpCurrentRouteByRequest();
				break;
			}
		}
	}
protected function rewriteRouting ($requestCtrlName, $requestActionName) {
		$request = & $this->request;
		$requestedPathFirstWord = $this->rewriteRoutingGetReqPathFirstWord();
		$this->rewriteRoutingProcessPreHandler($requestedPathFirstWord);
		$routes = & $this->rewriteRoutingGetRoutesToMatch($requestedPathFirstWord);
		$requestMethod = $request->GetMethod();
		foreach ($routes as & $route) {
			/** @var $route \MvcCore\Route */
			if ($this->rewriteRoutingCheckRoute($route, [$requestMethod])) continue;
			$allMatchedParams = $route->Matches($request);
			if ($allMatchedParams !== NULL) {
				$this->currentRoute = clone $route;
				$this->currentRoute->SetMatchedParams($allMatchedParams);

				$this->rewriteRoutingSetRequestedAndDefaultParams(
					$allMatchedParams, $requestCtrlName, $requestActionName
				);
				if ($this->rewriteRoutingSetRequestParams($allMatchedParams)) continue;
				
				$this->rewriteRoutingSetUpCurrentRouteByRequest();
				break;
			}
		}
	}
protected function rewriteRouting ( $ requestCtrlName , $ requestActionName ) { $ request = & $ this -> request ; $ requestedPathFirstWord = $ this -> rewriteRoutingGetReqPathFirstWord ( ) ; $ this -> rewriteRoutingProcessPreHandler ( $ requestedPathFirstWord ) ; $ routes = & $ this -> rewriteRoutingGetRoutesToMatch ( $ requestedPathFirstWord ) ; $ requestMethod = $ request -> GetMethod ( ) ; foreach ( $ routes as & $ route ) { /** @var $route \MvcCore\Route */ if ( $ this -> rewriteRoutingCheckRoute ( $ route , [ $ requestMethod ] ) ) continue ; $ allMatchedParams = $ route -> Matches ( $ request ) ; if ( $ allMatchedParams !== NULL ) { $ this -> currentRoute = clone $ route ; $ this -> currentRoute -> SetMatchedParams ( $ allMatchedParams ) ; $ this -> rewriteRoutingSetRequestedAndDefaultParams ( $ allMatchedParams , $ requestCtrlName , $ requestActionName ) ; if ( $ this -> rewriteRoutingSetRequestParams ( $ allMatchedParams ) ) continue ; $ this -> rewriteRoutingSetUpCurrentRouteByRequest ( ) ; break ; } } }
Try to parse first word from request path to get proper routes group.
If there is no first word in request path, get default routes group.

If there is any configured pre-routing handler, execute the handler to
for example load only specific routes from database or anything else.

Go through all chosen routes and check if route is possible to use for
current request. Then try to match route by given request. If route doesn't
match the request, continue to another route and try to complete current
route object. If route matches the request, set up default and request
params and try to process route filtering in. If it is successful, set
up current route object and end route matching process.
@param string|NULL $requestCtrlName		Possible controller name value or `NULL` assigned directly
from request object in `\MvcCore\router::routeDetectStrategy();`
@param string|NULL $requestActionName	Possible action name value or `NULL` assigned directly
from request object in `\MvcCore\router::routeDetectStrategy();`
@throws \LogicException Route configuration property is missing.
@throws \InvalidArgumentException Wrong route pattern format.
@return void
Try to parse first word from request path to get proper routes group . If there is no first word in request path get default routes group .