Executes the specified request, if it is still waiting.
@param Request $request
@return $this
764744
protected function executeRequest(Request $request)
    {
        $index = array_search($request, $this->waitingRequests);
        if ($index !== false) {
            unset($this->waitingRequests[$index]);
            $this->hydrateCurlFromRequest($request, $request->getCurl())
                 ->triggerCallback($request->getOnInitializeCallback(), $request);

            $this->multiCurl->addCurl($request->getCurl());
            $this->runningRequests[] = $request;
            $this->executeMultiCurl();
        }
        return $this;
    }
1299111
public function run( Request $request )
	{
		try
		{
			if ( !is_string( $this->action['uses'] ) )
				return $this->runCallable( $request );

			return $this->runController( $request );
		}
		catch ( HttpResponseException $e )
		{
			return $e->getResponse();
		}
	}
1344537
public function finish(Request $request) : Response
    {
        if ($this->finished) {
            throw new \LogicException('The response has already finished.');
        }

        $this->request = $request;

        $this->headers->set('content-length', strlen($this->body));
        $this->setEmptyResponse();

        $this->writeHeaders();
        $this->writeBody();

        $this->finished = true;

        return $this;
    }
966462
public function prepareRequest(Request $request)
	{
		if ( ! is_null($this['config']['session.driver']) && ! $request->hasSession())
		{
			$request->setSession($this['session']->driver());
		}

		return $request;
	}
898114
public function execute($request)
    {
        RequestNotSupportedException::assertSupports($this, $request);

        /** @var PaymentInterface $payment */
        $payment = $request->getModel();

        if (in_array($payment->getState(), array(PaymentInterface::STATE_APPROVED, PaymentInterface::STATE_DEPOSITED))) {
            $request->markCaptured();

            return;
        }

        if (in_array($payment->getState(), array(PaymentInterface::STATE_DEPOSITING))) {
            $request->markPending();

            return;
        }

        if (in_array($payment->getState(), array(PaymentInterface::STATE_CANCELED))) {
            $request->markCanceled();

            return;
        }

        if (in_array($payment->getState(), array(PaymentInterface::STATE_EXPIRED))) {
            $request->markExpired();

            return;
        }

        if (in_array($payment->getState(), array(PaymentInterface::STATE_FAILED))) {
            $request->markFailed();

            return;
        }

        if (in_array($payment->getState(), array(PaymentInterface::STATE_NEW, PaymentInterface::STATE_APPROVING))) {
            $request->markNew();

            return;
        }

        $request->markUnknown();
    }
1201574
public function execute($request)
    {
        RequestNotSupportedException::assertSupports($this, $request);

        $details = ArrayObject::ensureArrayObject($request->getModel());

        if (isset($details['RtnCode']) === false) {
            $request->markNew();

            return;
        }

        if ($details['RtnCode'] === '2') {
            $request->markPending();

            return;
        }

        if ($details['RtnCode'] === '1') {
            if (isset($details['Action']) === true) {
                switch ($details['Action']) {
                    case 'C':
                        $request->markCaptured();
                        break;
                    case 'R':
                        $request->markRefunded();
                        break;
                    case 'E':
                    case 'N':
                        $request->markCanceled();
                        break;
                }

                return;
            } else {
                $request->markCaptured();

                return;
            }
        }

        $request->markFailed();
    }
807739
public function process(Request $request)
    {
        $this->validate($request->all(), $this->rules);

        if ($request->has('q')) {
            $this->searchQuery = $request->get('q');
        }
        if ($request->has('sort')) {
            foreach (explode(',', $request->get('sort')) as $sort) {
                $this->processOrderByParams($sort);
            }
        }
        $this->processPageParams($request);

        foreach ($this->parsers as $parser) {
            $parser->parse($request);
        }

        return $this;
    }
808942
public function setRequest(Request $request)
    {
        $this->request = $request;

        $parsedBody = $this->request->getParsedBody();

        if (!empty($parsedBody)) {
            if (is_array($parsedBody)) {
                $this->data = array_map('trim', (array)$parsedBody);
            } else {
                $this->data = $parsedBody;
            }
        }

        return $this;
    }
503662
public function run($request)
    {
        $name = get_class($this);
        $verbose = $request->getVar('verbose');

        // Set new logger
        $logger = $this
            ->getLoggerFactory()
            ->getOutputLogger($name, $verbose);
        $this->setLogger($logger);
    }
211661
public function handle(Request $request) : Response
    {
        try {
            return $this->handleRequest($request);
        } catch (HttpException $e) {
            return $this->handleHttpException($e, $request);
        } catch (\Throwable $e) {
            return $this->handleUncaughtException($e, $request);
        }
    }
1202005
public function execute(Request $request)
    {
        $command = $request->get('command');

        try {
            $result = $this->manager()->execute($command);
        } catch (\Exception $exception) {
            return $this->renderException($exception);
        }

        if (is_string($result) && Str::startsWith($result, ['ERR ', 'WRONGTYPE '])) {
            return $this->renderException(new \Exception($result));
        }

        return $this->getDumpedHtml($result);
    }
1071971
public function execute($request): void
    {
        RequestNotSupportedException::assertSupports($this, $request);

        $request->setResult([
            Constants::FIELD_PAID => false,
        ]);
    }
763116
public function run(Request $request) {
		$prefs = $this->getServiceContainer()->getPreferenceLoader()->getSystemPreferences();
		$auth = $this->getServiceContainer()->getAuthManager();
		$auth->logout();
		return new RedirectResponse($prefs->getAccountUrl());
	}
1059812
public function run(Request $request)
	{
		$this->container = $this->container ?: new Container;

		try
		{
			if ( ! is_string($this->action['uses']))
			{
				return $this->runCallable($request);
			}

			if ($this->customDispatcherIsBound())
			{
				return $this->runWithCustomDispatcher($request);
			}

			return $this->runController($request);
		}
		catch (HttpResponseException $e)
		{
			return $e->getResponse();
		}
	}
121834
final public function run(Request $request)
    {
        $this->request = $request;
        $path = $this->request->getUri()->getPath();
        $this->requestedUri = ($path != "/") ? rtrim($path, "/") : "/";
        $this->requestedMethod = strtoupper($this->request->getMethod());
        $this->requestedRepresentation = $this->request->getAccept();
        $this->verifyRequestMethod();
        $route = $this->findRouteFromRequest();
        $this->prepareResponse($route);
    }
962081
public function dispatch(Request $request)
    {
        // Create the action instance
        $action = $this->resolveAction($request->getHandler());

        return $action->execute($request->getParameters());
    }
1111589
public function run (Request $request)
    {
        try {

            // Define which method we need to handle
            $this->method = $request->getMethod();

            // Set request
            $this->request = $request;

            // Handle all routes
            $numHandled = 0;
            if (isset($this->routes[$this->method]))
                $numHandled = $this->handle($this->routes[$this->method], true);

            // If no route was handled, trigger the 404 (if any)
            if ($numHandled == 0) {
                if ($this->notFound) {
                    //call_user_func($this->notFound);
                    $this->handleMatch($this->notFound, array());
                } else {

                    $request = Response::error('Page not found.', Response::STATUS_NOTFOUND);
                    $request->output();
                }
            }

            // If it originally was a HEAD request, clean up after ourselves by emptying the output buffer
            if ($_SERVER['REQUEST_METHOD'] == 'HEAD') ob_end_clean();

        } catch (ResponseException $e) {
            $e->getResponse()->output();
        }
    }