You are here

public function SubscriberMassSubscribeForm::__construct in Simplenews 8.2

Same name and namespace in other branches
  1. 8 src/Form/SubscriberMassSubscribeForm.php \Drupal\simplenews\Form\SubscriberMassSubscribeForm::__construct()
  2. 3.x src/Form/SubscriberMassSubscribeForm.php \Drupal\simplenews\Form\SubscriberMassSubscribeForm::__construct()

Constructs a new SubscriberMassSubscribeForm.

Parameters

\Drupal\Core\Language\LanguageManagerInterface $language_manager: The language manager.

\Drupal\simplenews\Subscription\SubscriptionManagerInterface $subscription_manager: The subscription manager.

\Drupal\Component\Utility\EmailValidatorInterface $email_validator: The email validator.

File

src/Form/SubscriberMassSubscribeForm.php, line 51

Class

SubscriberMassSubscribeForm
Do a mass subscription for a list of email addresses.

Namespace

Drupal\simplenews\Form

Code

public function __construct(LanguageManagerInterface $language_manager, SubscriptionManagerInterface $subscription_manager, EmailValidatorInterface $email_validator) {
  $this->languageManager = $language_manager;
  $this->subscriptionManager = $subscription_manager;
  $this->emailValidator = $email_validator;
}