public function PasswordPolicyValidator::__construct in Password Policy 8.3
PasswordPolicyValidator constructor.
Parameters
\Drupal\Core\Entity\EntityTypeManagerInterface $entityTypeManager: The password policy storage.
\Drupal\password_policy\PasswordConstraintPluginManager $passwordConstraintPluginManager: The password constraint plugin manager.
Throws
\Drupal\Component\Plugin\Exception\InvalidPluginDefinitionException
\Drupal\Component\Plugin\Exception\PluginNotFoundException
File
- src/
PasswordPolicyValidator.php, line 36
Class
Namespace
Drupal\password_policyCode
public function __construct(EntityTypeManagerInterface $entityTypeManager, PasswordConstraintPluginManager $passwordConstraintPluginManager) {
$this->passwordConstraintPluginManager = $passwordConstraintPluginManager;
$this->passwordPolicyStorage = $entityTypeManager
->getStorage('password_policy');
}