Bundle/TwigBundle/Controller/ExceptionController.php
protected function forward($controller, array $path = [], array $query = [])
    {
        $path['_controller'] = $controller;
        $subRequest = $this->request->duplicate($query, null, $path);

        return $this->kernel->handle($subRequest, HttpKernelInterface::SUB_REQUEST);
    }
protected function forward($controller, array $path = [], array $query = [])
    {
        $path['_controller'] = $controller;
        $subRequest = $this->request->duplicate($query, null, $path);

        return $this->kernel->handle($subRequest, HttpKernelInterface::SUB_REQUEST);
    }
protected function forward ( $ controller , array $ path = [ ] , array $ query = [ ] ) { $ path [ '_controller' ] = $ controller ; $ subRequest = $ this -> request -> duplicate ( $ query , null , $ path ) ; return $ this -> kernel -> handle ( $ subRequest , HttpKernelInterface :: SUB_REQUEST ) ; }
Forwards the request to another controller.

@param string $controller The controller name (a string like BlogBundle:Post:index)
@param array  $path       An array of path parameters
@param array  $query      An array of query parameters

@return Response A Response instance
Forwards the request to another controller .