You are here

public function LanguageSelectionPageConditionType::__construct in Language Selection Page 8.2

Constructs a LanguageSelectionPageConditionType plugin.

Parameters

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

\Symfony\Component\HttpFoundation\RequestStack $request_stack: The request stack.

\Drupal\Core\Routing\RouteMatchInterface $current_route_match: The route match service.

\Drupal\Core\Render\MainContent\MainContentRendererInterface $main_content_renderer: The main content renderer service.

array $configuration: A configuration array containing information about the plugin instance.

string $plugin_id: The plugin_id for the plugin instance.

array $plugin_definition: The plugin implementation definition.

Overrides ConditionPluginBase::__construct

File

src/Plugin/LanguageSelectionPageCondition/LanguageSelectionPageConditionType.php, line 76

Class

LanguageSelectionPageConditionType
Class for the Type condition plugin.

Namespace

Drupal\language_selection_page\Plugin\LanguageSelectionPageCondition

Code

public function __construct(ConfigFactoryInterface $config_factory, RequestStack $request_stack, RouteMatchInterface $current_route_match, MainContentRendererInterface $main_content_renderer, array $configuration, $plugin_id, array $plugin_definition) {
  parent::__construct($configuration, $plugin_id, $plugin_definition);
  $this->configFactory = $config_factory;
  $this->requestStack = $request_stack;
  $this->currentRouteMatch = $current_route_match;
  $this->mainContentRenderer = $main_content_renderer;
}