You are here

public function KeycloakService::__construct in Keycloak OpenID Connect 8

Constructor for Drupal\keycloak\Service\KeycloakService.

Parameters

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

\Drupal\openid_connect\Plugin\OpenIDConnectClientManager $oidc_client_manager: Client plugin manager of the OpenID Connect module.

\Drupal\Core\Language\LanguageManagerInterface $language_manager: A language manager instance.

\Drupal\Core\Session\AccountProxyInterface $current_user: Account proxy for the currently logged-in user.

\Drupal\Core\TempStore\PrivateTempStoreFactory $private_tempstore: A private tempstore factory instance.

\Drupal\Core\Logger\LoggerChannelFactoryInterface $logger: A logger channel factory instance.

Overrides KeycloakServiceInterface::__construct

File

src/Service/KeycloakService.php, line 77

Class

KeycloakService
Keycloak service.

Namespace

Drupal\keycloak\Service

Code

public function __construct(ConfigFactoryInterface $config_factory, OpenIDConnectClientManager $oidc_client_manager, LanguageManagerInterface $language_manager, AccountProxyInterface $current_user, PrivateTempStoreFactory $private_tempstore, LoggerChannelFactoryInterface $logger) {
  $this->config = $config_factory
    ->get(static::OPENID_CONNECT_CONFIG_NAME);
  $this->oidcClientManager = $oidc_client_manager;
  $this->languageManager = $language_manager;
  $this->currentUser = $current_user;
  $this->privateTempstore = $private_tempstore;
  $this->loggerFactory = $logger;
}