public function LockrKeyProvider::__construct in Lockr 4.x
Same name and namespace in other branches
- 8.4 src/Plugin/KeyProvider/LockrKeyProvider.php \Drupal\lockr\Plugin\KeyProvider\LockrKeyProvider::__construct()
- 8.2 src/Plugin/KeyProvider/LockrKeyProvider.php \Drupal\lockr\Plugin\KeyProvider\LockrKeyProvider::__construct()
- 8.3 src/Plugin/KeyProvider/LockrKeyProvider.php \Drupal\lockr\Plugin\KeyProvider\LockrKeyProvider::__construct()
Constructs a new LockrKeyProvider.
Parameters
array $configuration: A configuration array containing information about the plugin instance.
string $plugin_id: The plugin_id for the plugin instance.
mixed $plugin_definition: The plugin implementation definition.
ConfigFactoryInterface $config_factory: The simple config factory.
EntityTypeManagerInterface $entity_type_manager: The entity type manager.
Lockr $lockr: The Lockr library client.
LoggerChannelInterface $logger: The lockr Drupal logger channel.
File
- src/
Plugin/ KeyProvider/ LockrKeyProvider.php, line 80 - Contains Drupal\lockr\Plugin\KeyProvider\LockrKeyProvider.
Class
- LockrKeyProvider
- Adds a key provider that allows a key to be stored in Lockr.
Namespace
Drupal\lockr\Plugin\KeyProviderCode
public function __construct(array $configuration, $plugin_id, $plugin_definition, ConfigFactoryInterface $config_factory, EntityTypeManagerInterface $entity_type_manager, Lockr $lockr, LoggerChannelInterface $logger) {
parent::__construct($configuration, $plugin_id, $plugin_definition);
$this->configFactory = $config_factory;
$this->secretStorage = $entity_type_manager
->getStorage('lockr_secret');
$this->lockr = $lockr;
$this->logger = $logger;
}