You are here

public function CurrentLanguageContext::__construct in Drupal 8

Same name and namespace in other branches
  1. 9 core/lib/Drupal/Core/Language/ContextProvider/CurrentLanguageContext.php \Drupal\Core\Language\ContextProvider\CurrentLanguageContext::__construct()

Constructs a new CurrentLanguageContext.

Parameters

\Drupal\Core\Language\LanguageManagerInterface $language_manager: The language manager.

File

core/lib/Drupal/Core/Language/ContextProvider/CurrentLanguageContext.php, line 32

Class

CurrentLanguageContext
Sets the current language as a context.

Namespace

Drupal\Core\Language\ContextProvider

Code

public function __construct(LanguageManagerInterface $language_manager) {
  $this->languageManager = $language_manager;
}