public function run($server=null, $stream=null)
	{
		$server = $server ?: $_SERVER;
		$stream = $stream ?: fopen('php://output','w');
		$controller = $this->controller();

		// build up wrappers of middleware
		foreach($this->_middleware as $middleware)
			$controller = new $middleware($controller, $this);

		$requestFactory = new Http\RequestFactory($server);
		$response = $controller->execute($requestFactory->create());
		$sender = new Http\ResponseSender($response, $stream);
		$sender->send();
	}