You are here

public function GotoAction::__construct in Drupal 10

Same name and namespace in other branches
  1. 8 core/lib/Drupal/Core/Action/Plugin/Action/GotoAction.php \Drupal\Core\Action\Plugin\Action\GotoAction::__construct()
  2. 9 core/lib/Drupal/Core/Action/Plugin/Action/GotoAction.php \Drupal\Core\Action\Plugin\Action\GotoAction::__construct()

Constructs a GotoAction object.

Parameters

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

string $plugin_id: The plugin ID for the plugin instance.

mixed $plugin_definition: The plugin implementation definition.

\Symfony\Contracts\EventDispatcher\EventDispatcherInterface $dispatcher: The tempstore factory.

\Drupal\Core\Utility\UnroutedUrlAssemblerInterface $url_assembler: The unrouted URL assembler service.

File

core/lib/Drupal/Core/Action/Plugin/Action/GotoAction.php, line 56

Class

GotoAction
Redirects to a different URL.

Namespace

Drupal\Core\Action\Plugin\Action

Code

public function __construct(array $configuration, $plugin_id, $plugin_definition, EventDispatcherInterface $dispatcher, UnroutedUrlAssemblerInterface $url_assembler) {
  parent::__construct($configuration, $plugin_id, $plugin_definition);
  $this->dispatcher = $dispatcher;
  $this->unroutedUrlAssembler = $url_assembler;
}