You are here

public function ContentHubInternalRequest::__construct in Acquia Content Hub 8

Public Constructor.

Parameters

\Symfony\Component\HttpKernel\HttpKernelInterface $kernel: The HttpKernel.

\Drupal\acquia_contenthub\ContentHubSubscription $contenthub_subscription: The Content Hub Subscription.

\Drupal\Core\Session\AccountSwitcherInterface $account_switcher: The Account Switcher Service.

\Drupal\Core\Config\ConfigFactoryInterface $config_factory: The config factory.

\Drupal\Core\Logger\LoggerChannelFactoryInterface $logger_factory: The logger factory.

\Symfony\Component\HttpFoundation\RequestStack $request_stack: The Request Stack.

File

src/ContentHubInternalRequest.php, line 79

Class

ContentHubInternalRequest
Provides a method to do internal sub-requests to obtain an entity CDF.

Namespace

Drupal\acquia_contenthub

Code

public function __construct(HttpKernelInterface $kernel, ContentHubSubscription $contenthub_subscription, AccountSwitcherInterface $account_switcher, ConfigFactoryInterface $config_factory, LoggerChannelFactoryInterface $logger_factory, RequestStack $request_stack) {
  $this->kernel = $kernel;
  $this->contentHubSubscription = $contenthub_subscription;
  $this->accountSwitcher = $account_switcher;
  $this->loggerFactory = $logger_factory;
  $this->renderUser = new ContentHubUserSession($config_factory
    ->get('acquia_contenthub.entity_config')
    ->get('user_role'));
  $this->requestStack = $request_stack;
}