You are here

public function ContactEmailer::__construct in Contact Emails 8

Constructor.

Parameters

\Drupal\Core\Mail\MailManagerInterface $plugin_manager_mail: MailManagerInterface.

\Drupal\contact_emails\ContactEmails $contact_emails: ContactEmails.

\Drupal\Core\Session\AccountProxy $current_user: AccountProxy.

\Drupal\Component\Utility\EmailValidatorInterface $email_validator: EmailValidatorInterface.

\Drupal\Core\Messenger\MessengerInterface $messenger: MessengerInterface.

File

src/ContactEmailer.php, line 84

Class

ContactEmailer
Class ContactEmailer.

Namespace

Drupal\contact_emails

Code

public function __construct(MailManagerInterface $plugin_manager_mail, ContactEmails $contact_emails, AccountProxy $current_user, EmailValidatorInterface $email_validator, MessengerInterface $messenger) {
  $this->mailManager = $plugin_manager_mail;
  $this->contactEmails = $contact_emails;
  $this->currentUser = $current_user;
  $this->emailValidator = $email_validator;
  $this->messenger = $messenger;
}