Start the tracking.

@param  \Illuminate\Http\Request  $request
765152
public function trackRequest(Request $request)
    {
        if ($this->isEnabled()) {
            $this->setRequest($request);

            $this->mergeVisitorActivityData([
                'visitor_id' => $this->getVisitorId(),
                'path_id'    => $this->getPathId(),
                'query_id'   => $this->getQueryId(),
                'referer_id' => $this->getRefererId(),
            ]);

            $id = $this->getVisitorActivityTracker()->track($this->visitorActivityData);
        }
    }
211225
public function run(Request $request) {
    // process the requested action
    ObjectFactory::getInstance('actionMapper')->processAction($request, $this->response);
    return $this->response;
  }
989543
protected function runController(Request $request)
	{
		list($class, $method) = explode('@', $this->action['uses']);

		$parameters = $this->resolveClassMethodDependencies(
			$this->parametersWithoutNulls(), $class, $method
		);

		if ( ! method_exists($instance = $this->container->make($class), $method))
		{
			throw new NotFoundHttpException;
		}

		return call_user_func_array([$instance, $method], $parameters);
	}
73839
protected function _init(Request $request)
    {
        if ($this->_initDone) {
            return;
        }

        $this->_userModel = TableRegistry::get($this->_config['userModel']);
        $this->_profileModel = TableRegistry::get($this->_config['profileModel']);

        $request->session()->start();

        $hybridConfig = Configure::read('HybridAuth');

        if (empty($hybridConfig['base_url'])) {
            $hybridConfig['base_url'] = [
                'plugin' => 'ADmad/HybridAuth',
                'controller' => 'HybridAuth',
                'action' => 'endpoint',
                'prefix' => false
            ];
        }

        $hybridConfig['base_url'] = $this->_appendRedirectQueryString(
            $hybridConfig['base_url'],
            $request->query(static::QUERY_STRING_REDIRECT)
        );

        $hybridConfig['base_url'] = Router::url($hybridConfig['base_url'], true);

        try {
            Hybrid_Auth::initialize($hybridConfig);
        } catch (\Exception $e) {
            if ($e->getCode() < 5) {
                throw new \RuntimeException($e->getMessage());
            } else {
                $this->_registry->Auth->flash($e->getMessage());
                Hybrid_Auth::initialize($hybridConfig);
            }
        }
    }
248807
public function execute(Request $request = null)
    {
        $request = $request ?: $this->request;

        $this->dispatcher->dispatch($request, $this->response);

    }
1339232
public function route($request)
    {
        if (!self::$_cli) {
            $router = $this->get('routing');
            $router->route($request);
        }
    }
1359845
public function run(Request $request) {
		$page = $this->getServiceContainer()->getKernel()->getApplication()->getPage();
		$page->setTitle($this->getServiceContainer()->getTranslator()->trans('registration'));

		if ($request->isMethod('POST')) {
			$post = $request->request;
			$prefs = $this->getServiceContainer()->getPreferenceLoader()->getSystemPreferences();
			$translator = $this->getServiceContainer()->getTranslator();

			// check errors first
			$errors = [];

			// username
			if ($prefs->getUserLogin() == SystemPreferences::LOGIN_USERNAME && !$post->has('user-name')) {
				$errors[] = $translator->trans('error.required', [
					'field' => $translator->trans('user_name')
				]);
			}

			// email
			$emailRequired = $prefs->getUserEmail()
				|| $prefs->getUserLogin() == SystemPreferences::LOGIN_EMAIL
				|| $prefs->getUserLogin() == SystemPreferences::LOGIN_USERNAME_EMAIL;

			if ($emailRequired && !$post->has('email')) {
				$errors[] = $translator->trans('error.required', [
					'field' => $translator->trans('email')
				]);
			}

			// given name
			if ($prefs->getUserNames() == SystemPreferences::VALUE_REQUIRED && !$post->has('given-name')) {
				$errors[] = $translator->trans('error.required', [
					'field' => $translator->trans('given_name')
				]);
			}

			// family name
			if ($prefs->getUserNames() == SystemPreferences::VALUE_REQUIRED && !$post->has('family-name')) {
				$errors[] = $translator->trans('error.required', [
					'field' => $translator->trans('family_name')
				]);
			}

			// birth
			if ($prefs->getUserBirth() == SystemPreferences::VALUE_REQUIRED && !$post->has('birth')) {
				$errors[] = $translator->trans('error.required', [
					'field' => $translator->trans('birth')
				]);
			}

			// sex
			if ($prefs->getUserSex() == SystemPreferences::VALUE_REQUIRED && !$post->has('sex')) {
				$errors[] = $translator->trans('error.required', [
					'field' => $translator->trans('sex')
				]);
			}

			// passwords
			if (!$post->has('password') && !$post->has('password_confirm')) {
				$errors[] = $translator->trans('error.required', [
					'field' => $translator->trans('password')
				]);
			}

			if ($post->get('password') != $post->get('password_confirm')) {
				$errors[] = $translator->trans('error.password_nomatch');
			}


			$vars = ['failures' => $errors, 'fields' => $post->all()];
			if (count($errors) == 0) {
				$serializer = User::getSerializer();
				$fields = $serializer->getFields();
				$attribs = [
					'password' => $post->get('password')
				];

				foreach ($fields as $field) {
					if ($post->has($field)) {
						$attribs[$field] = $post->get($field);
					}
				}

				$domain = new UserDomain($this->getServiceContainer());
				$payload = $domain->create(['attributes' => $attribs]);
				if ($payload instanceof NotValid) {
					$payload = new NotValid(array_merge($payload->get(), $vars));
				} else if ($payload instanceof Created) {
					$user = $payload->getModel();

					// send mail
					$prefs = $this->getServiceContainer()->getPreferenceLoader()->getSystemPreferences();
					$localeService = $this->getServiceContainer()->getLocaleService();
					$file = $localeService->findLocaleFile('/keeko/account/locales/{locale}/mail/registration.twig');
					$body = $this->render($file, [
						'user' => $user->getDisplayName(),
						'username' => $user->getUserName(),
						'plattform' => $prefs->getPlattformName(),
					]);

					$mailer = $this->getServiceContainer()->getMailer();
					$message = $this->getServiceContainer()->createMessage();
					$message->setTo($user->getEmail());
					$message->setSubject($translator->trans('registration.subject', [
						'plattform' => $prefs->getPlattformName()
					]));
					$message->setBody($body);
					$mailer->send($message);
				}
			} else {
				$post->remove('password');
				$post->remove('password_confirm');
				$payload = new NotValid($vars);
			}
		} else {
			$payload = new Blank();
		}

		return $this->responder->run($request, $payload);
	}
1110361
public function save(\Illuminate\Http\Request $request)
    {
        $this->setModelAttribute($this->getValueFromRequest($request));
    }
294874
protected function beforeHandleRequest(HTTPRequest $request)
    {
        //Set up the internal dependencies (request, response)
        $this->setRequest($request);
        //Push the current controller to protect against weird session issues
        $this->pushCurrent();
        $this->setResponse(new HTTPResponse());
        //kick off the init functionality
        $this->doInit();
    }
1092506
public function run(Request $request = null)
    {
        if (null === $request) {
            $request = Request::createFromGlobals();
        }

        $response = $this->handle($request);
        $response->send();

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

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

        $this->gateway->execute($status = new GetHumanStatus($model));
        if ($status->isCaptured()) {
            $model['state_override'] = 'refunded';
        }
    }
657091
public function setRequest(Request $request)
    {
        $this->issuer->setRequest($request);
        $this->checker->setRequest($request);
    }
839535
public function run($request)
    {
        $this->start();
        $registered = Config::inst()->get('DocumentationManifest', 'register_entities');
        foreach ($registered as $details) {
            // validate the details provided through the YAML configuration
            $required = array('Path', 'Title');

            // Check required configs
            foreach ($required as $require) {
                if (!isset($details[$require])) {
                    $this->showError("$require is a required key in DocumentationManifest.register_entities");
                }
            }

            // Check path is loaded
            $path = $this->getRealPath($details['Path']);
            if (!$path || !is_dir($path)) {
                $this->showError($details['Path'] . ' is not a valid documentation directory');
            }
        }
        $this->end();
    }
89630
public function update(Request $request)
    {
        $this->cache->tags('categories')->flush();

        $this->categoryOrdener->handle($request->get('categories'));
    }
603033
public function add(Request $request)
    {
        $this->stack = array_slice($this->stack, 0, $this->position + 1);
        $this->stack[] = clone $request;
        $this->position = count($this->stack) - 1;
    }
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();
    }
1283086
public function run(Request $request = null)
    {
        if (null === $request) {
            $request = Request::createFromGlobals();
        }

        $this->registerMiddleware('Phprest\Middleware\ApiVersion');

        $app = $this->stackBuilder->resolve($this);

        $response = $app->handle($request, self::MASTER_REQUEST, false);
        $response->send();

        $app->terminate($request, $response);
    }