public function WebformCommandsBase::__construct in Webform 8.5
Same name and namespace in other branches
- 6.x src/Commands/WebformCommandsBase.php \Drupal\webform\Commands\WebformCommandsBase::__construct()
Constructs a WebformCommandsBase object.
Parameters
\Drupal\webform\Commands\WebformCliServiceInterface $cli_service: The webform CLI service.
File
- src/
Commands/ WebformCommandsBase.php, line 30
Class
- WebformCommandsBase
- Base class for Webform commands for Drush 9.x.
Namespace
Drupal\webform\CommandsCode
public function __construct(WebformCliServiceInterface $cli_service) {
$this->cliService = $cli_service;
// Injecting the WebformCommand into the CLI service so that calls to
// drush functions can be delegatef back the below methods.
// @see \Drupal\webform\Commands\WebformCliService::__call
$this->cliService
->setCommand($this);
}