function EmailAction::__construct
Same name in other branches
- 9 core/lib/Drupal/Core/Action/Plugin/Action/EmailAction.php \Drupal\Core\Action\Plugin\Action\EmailAction::__construct()
- 10 core/lib/Drupal/Core/Action/Plugin/Action/EmailAction.php \Drupal\Core\Action\Plugin\Action\EmailAction::__construct()
- 11.x core/lib/Drupal/Core/Action/Plugin/Action/EmailAction.php \Drupal\Core\Action\Plugin\Action\EmailAction::__construct()
Constructs a EmailAction 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.
\Drupal\Core\Utility\Token $token: The token service.
\Drupal\Core\Entity\EntityTypeManagerInterface $entity_type_manager: The entity manager.
\Psr\Log\LoggerInterface $logger: A logger instance.
\Drupal\Core\Mail\MailManagerInterface $mail_manager: The mail manager.
\Drupal\Core\Language\LanguageManagerInterface $language_manager: The language manager.
\Drupal\Component\Utility\EmailValidatorInterface $email_validator: The email validator.
Overrides ConfigurableActionBase::__construct
File
-
core/
lib/ Drupal/ Core/ Action/ Plugin/ Action/ EmailAction.php, line 94
Class
- EmailAction
- Sends an email message.
Namespace
Drupal\Core\Action\Plugin\ActionCode
public function __construct(array $configuration, $plugin_id, $plugin_definition, Token $token, EntityTypeManagerInterface $entity_type_manager, LoggerInterface $logger, MailManagerInterface $mail_manager, LanguageManagerInterface $language_manager, EmailValidatorInterface $email_validator) {
parent::__construct($configuration, $plugin_id, $plugin_definition);
$this->token = $token;
$this->storage = $entity_type_manager->getStorage('user');
$this->logger = $logger;
$this->mailManager = $mail_manager;
$this->languageManager = $language_manager;
$this->emailValidator = $email_validator;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.