public function Oauth2ClientService::__construct in OAuth2 Client 8.3
Same name and namespace in other branches
- 8.2 src/Service/Oauth2ClientService.php \Drupal\oauth2_client\Service\Oauth2ClientService::__construct()
Constructs an Oauth2ClientService object.
Parameters
\Drupal\oauth2_client\PluginManager\Oauth2ClientPluginManagerInterface $oauth2ClientPluginManager: The Oauth2 Client plugin manager.
\Drupal\Core\State\StateInterface $state: The Drupal state.
\Drupal\oauth2_client\Service\Grant\Oauth2ClientGrantServiceInterface $authorizationCodeGrantService: The authorization code grant service.
\Drupal\oauth2_client\Service\Grant\Oauth2ClientGrantServiceInterface $clientCredentialsGrantService: The client credentials grant service.
\Drupal\oauth2_client\Service\Grant\Oauth2ClientGrantServiceInterface $refreshTokenGrantService: The refresh token grant service.
\Drupal\oauth2_client\Service\Grant\ResourceOwnersCredentialsGrantService $resourceOwnersCredentialsGrantService: The resource owner's credentials grant service.
File
- src/
Service/ Oauth2ClientService.php, line 46
Class
- Oauth2ClientService
- The OAuth2 Client service.
Namespace
Drupal\oauth2_client\ServiceCode
public function __construct(Oauth2ClientPluginManagerInterface $oauth2ClientPluginManager, StateInterface $state, Oauth2ClientGrantServiceInterface $authorizationCodeGrantService, Oauth2ClientGrantServiceInterface $clientCredentialsGrantService, Oauth2ClientGrantServiceInterface $refreshTokenGrantService, ResourceOwnersCredentialsGrantService $resourceOwnersCredentialsGrantService) {
$this->oauth2ClientPluginManager = $oauth2ClientPluginManager;
$this->state = $state;
$this->grantServices = [
'authorization_code' => $authorizationCodeGrantService,
'client_credentials' => $clientCredentialsGrantService,
'refresh_token' => $refreshTokenGrantService,
'resource_owner' => $resourceOwnersCredentialsGrantService,
];
}