protected function addLookups(RouteContract $route): void
    {
        // If the route has a name, we will add it to the name look-up table so that we
        // will quickly be able to find any route associate with a name and not have
        // to iterate through every route every time we need to perform a look-up.
        $action = $route->getAction();

        if (isset($action['as'])) {
            $this->nameList[$action['as']] = $route;
        }

        // When the route is routing to a controller we will also store the action that
        // is used by the route. This will let us reverse route to controllers while
        // processing a request and easily generate URLs to the given controllers.
        if (isset($action['controller'])) {
            $this->actionList[\trim($action['controller'], '\\')] = $route;
        }
    }
protected function addLookups(RouteContract $route): void
    {
        // If the route has a name, we will add it to the name look-up table so that we
        // will quickly be able to find any route associate with a name and not have
        // to iterate through every route every time we need to perform a look-up.
        $action = $route->getAction();

        if (isset($action['as'])) {
            $this->nameList[$action['as']] = $route;
        }

        // When the route is routing to a controller we will also store the action that
        // is used by the route. This will let us reverse route to controllers while
        // processing a request and easily generate URLs to the given controllers.
        if (isset($action['controller'])) {
            $this->actionList[\trim($action['controller'], '\\')] = $route;
        }
    }
protected function addLookups ( RouteContract $ route ) : void { // If the route has a name, we will add it to the name look-up table so that we // will quickly be able to find any route associate with a name and not have // to iterate through every route every time we need to perform a look-up. $ action = $ route -> getAction ( ) ; if ( isset ( $ action [ 'as' ] ) ) { $ this -> nameList [ $ action [ 'as' ] ] = $ route ; } // When the route is routing to a controller we will also store the action that // is used by the route. This will let us reverse route to controllers while // processing a request and easily generate URLs to the given controllers. if ( isset ( $ action [ 'controller' ] ) ) { $ this -> actionList [ \ trim ( $ action [ 'controller' ] , '\\' ) ] = $ route ; } }
Add the route to any look-up tables if necessary.

@param \Viserio\Component\Contract\Routing\Route $route

@return void
Add the route to any look - up tables if necessary .