protected function registerRoute(RouteCollection $router, \ReflectionClass $class, \ReflectionMethod $method, $docblock) { if ($docblock instanceof Route) { $this->addVersionToRoute($docblock); $router->addRoute($docblock->method, $docblock->path, '\\' . $class->getName() . '::' . $method->getName()); } }