src/Controller/RoutesController.php
protected function _addRoute($routeType, $routeData)
    {
        switch ($routeType) {
            case RouteTypes::TYPE_DEFAULT_ROUTE:
                $route = $this->_addDefaultRoute($routeData);
                break;
            case RouteTypes::TYPE_REDIRECT_ROUTE:
                $route = $this->_addRedirectRoute($routeData);
                break;
            default:
                throw new BadRequestException();
        }
        return $route;
    }
protected function _addRoute($routeType, $routeData)
    {
        switch ($routeType) {
            case RouteTypes::TYPE_DEFAULT_ROUTE:
                $route = $this->_addDefaultRoute($routeData);
                break;
            case RouteTypes::TYPE_REDIRECT_ROUTE:
                $route = $this->_addRedirectRoute($routeData);
                break;
            default:
                throw new BadRequestException();
        }
        return $route;
    }
protected function _addRoute ( $ routeType , $ routeData ) { switch ( $ routeType ) { case RouteTypes :: TYPE_DEFAULT_ROUTE : $ route = $ this -> _addDefaultRoute ( $ routeData ) ; break ; case RouteTypes :: TYPE_REDIRECT_ROUTE : $ route = $ this -> _addRedirectRoute ( $ routeData ) ; break ; default : throw new BadRequestException ( ) ; } return $ route ; }
Add the given route.

@param string $routeType The route type (default/redirect).
@param array $routeData The route data.
@throws BadRequestException
@return Route
Add the given route .