container = $container; } /** * @param $name * @return mixed|null * @throws \Interop\Container\Exception\ContainerException */ public function __get($name) { if ($this->container->has($name)) { return $this->container->get($name); } return null; } /** * @param Request $request * @param Response $response * @param callable $next */ public abstract function __invoke(Request $request, Response $response, callable $next); }