You are here

public function LanguageCookieConditionPathIsValid::__construct in Language Cookie 8

Constructs a LanguageCookieConditionPath plugin.

Parameters

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

\Drupal\Core\Path\CurrentPathStack $current_path: The current path.

\Drupal\Core\Path\PathValidatorInterface $path_validator: The path validator.

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/LanguageCookieCondition/LanguageCookieConditionPathIsValid.php, line 60

Class

LanguageCookieConditionPathIsValid
Class for LanguageCookieConditionPathIsValid.

Namespace

Drupal\language_cookie\Plugin\LanguageCookieCondition

Code

public function __construct(RequestStack $request_stack, CurrentPathStack $current_path, PathValidatorInterface $path_validator, array $configuration, $plugin_id, array $plugin_definition) {
  parent::__construct($configuration, $plugin_id, $plugin_definition);
  $this->requestStack = $request_stack;
  $this->currentPath = $current_path;
  $this->pathValidator = $path_validator;
}