src/Chiron/Routing/Router.php
private function addRoute(array $httpMethod, string $routePath, string $routeId): void
    {
        $routeDatas = $this->parser->parse($routePath);
        foreach ($httpMethod as $method) {
            foreach ($routeDatas as $routeData) {
                $this->generator->addRoute($method, $routeData, $routeId);
            }
        }
    }
private function addRoute(array $httpMethod, string $routePath, string $routeId): void
    {
        $routeDatas = $this->parser->parse($routePath);
        foreach ($httpMethod as $method) {
            foreach ($routeDatas as $routeData) {
                $this->generator->addRoute($method, $routeData, $routeId);
            }
        }
    }
private function addRoute ( array $ httpMethod , string $ routePath , string $ routeId ) : void { $ routeDatas = $ this -> parser -> parse ( $ routePath ) ; foreach ( $ httpMethod as $ method ) { foreach ( $ routeDatas as $ routeData ) { $ this -> generator -> addRoute ( $ method , $ routeData , $ routeId ) ; } } }
Adds a route to the collection.

The syntax used in the $route string depends on the used route parser.

@param string[] $httpMethod
@param string   $routePath
@param string   $routeId
Adds a route to the collection .