You are here

public function Password::__construct in Simple OAuth (OAuth2) & OpenID Connect 8.2

Same name and namespace in other branches
  1. 8.4 src/Plugin/Oauth2Grant/Password.php \Drupal\simple_oauth\Plugin\Oauth2Grant\Password::__construct()
  2. 8.3 src/Plugin/Oauth2Grant/Password.php \Drupal\simple_oauth\Plugin\Oauth2Grant\Password::__construct()
  3. 5.x src/Plugin/Oauth2Grant/Password.php \Drupal\simple_oauth\Plugin\Oauth2Grant\Password::__construct()

Class constructor.

Overrides PluginBase::__construct

File

src/Plugin/Oauth2Grant/Password.php, line 41

Class

Password
Plugin annotation @Oauth2Grant( id = "password", label = @Translation("Password") )

Namespace

Drupal\simple_oauth\Plugin\Oauth2Grant

Code

public function __construct(array $configuration, $plugin_id, $plugin_definition, UserRepositoryInterface $user_repository, RefreshTokenRepositoryInterface $refresh_token_repository, ConfigFactoryInterface $config_factory) {
  parent::__construct($configuration, $plugin_id, $plugin_definition);
  $this->userRepository = $user_repository;
  $this->refreshTokenRepository = $refresh_token_repository;
  $this->configFactory = $config_factory;
}