You are here

public function AutosaveFormValidator::__construct in Autosave Form 8

Constructs a AutosaveFormValidator object.

Parameters

\Drupal\Core\Form\FormValidatorInterface $form_validator: The form validator service.

\Symfony\Component\HttpFoundation\RequestStack $request_stack: The request stack.

\Drupal\Core\StringTranslation\TranslationInterface $string_translation: The string translation service.

\Drupal\Core\Access\CsrfTokenGenerator $csrf_token: The CSRF token generator.

\Psr\Log\LoggerInterface $logger: A logger instance.

\Drupal\Core\Form\FormErrorHandlerInterface $form_error_handler: The form error handler.

Overrides FormValidator::__construct

File

src/Form/AutosaveFormValidator.php, line 44

Class

AutosaveFormValidator
Provides validation of form submissions with AutosaveForm enabled.

Namespace

Drupal\autosave_form\Form

Code

public function __construct(FormValidatorInterface $form_validator, RequestStack $request_stack, TranslationInterface $string_translation, CsrfTokenGenerator $csrf_token, LoggerInterface $logger, FormErrorHandlerInterface $form_error_handler) {
  $this->formValidator = $form_validator;
  parent::__construct($request_stack, $string_translation, $csrf_token, $logger, $form_error_handler);
}