target = $target; $this->methodMap = $methodMap; } /** * Return the instance mapping methods to middleware for this route. * * @return MethodMapInterface */ public function getMethodMap() { return $this->methodMap; } /** * @return string */ public function getTarget() { return $this->target; } public function dispatch(ServerRequestInterface $request, ResponseInterface &$response) { $this->methodMap->dispatch($request, $response); } }