function AccountForm::__construct

Same name in other branches
  1. 9 core/modules/user/src/AccountForm.php \Drupal\user\AccountForm::__construct()
  2. 8.9.x core/modules/user/src/AccountForm.php \Drupal\user\AccountForm::__construct()
  3. 11.x core/modules/user/src/AccountForm.php \Drupal\user\AccountForm::__construct()

Constructs a new EntityForm object.

Parameters

\Drupal\Core\Entity\EntityRepositoryInterface $entity_repository: The entity repository.

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

\Drupal\Core\Entity\EntityTypeBundleInfoInterface $entity_type_bundle_info: The entity type bundle service.

\Drupal\Component\Datetime\TimeInterface $time: The time service.

Overrides ContentEntityForm::__construct

File

core/modules/user/src/AccountForm.php, line 47

Class

AccountForm
Form controller for the user account forms.

Namespace

Drupal\user

Code

public function __construct(EntityRepositoryInterface $entity_repository, LanguageManagerInterface $language_manager, ?EntityTypeBundleInfoInterface $entity_type_bundle_info = NULL, ?TimeInterface $time = NULL) {
    parent::__construct($entity_repository, $entity_type_bundle_info, $time);
    $this->languageManager = $language_manager;
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.