public function ResourceServer::__construct in Simple OAuth (OAuth2) & OpenID Connect 8.2
Same name and namespace in other branches
- 8.4 src/Server/ResourceServer.php \Drupal\simple_oauth\Server\ResourceServer::__construct()
- 8.3 src/Server/ResourceServer.php \Drupal\simple_oauth\Server\ResourceServer::__construct()
- 5.x src/Server/ResourceServer.php \Drupal\simple_oauth\Server\ResourceServer::__construct()
ResourceServer constructor.
File
- src/
Server/ ResourceServer.php, line 33
Class
Namespace
Drupal\simple_oauth\ServerCode
public function __construct(AccessTokenRepositoryInterface $access_token_repository, ConfigFactoryInterface $config_factory, HttpMessageFactoryInterface $message_factory, HttpFoundationFactoryInterface $foundation_factory) {
try {
if ($public_key = $config_factory
->get('simple_oauth.settings')
->get('public_key')) {
$this->subject = new LeageResourceServer($access_token_repository, realpath($public_key));
}
} catch (\LogicException $exception) {
}
$this->messageFactory = $message_factory;
$this->foundationFactory = $foundation_factory;
}