public function SpoolStorage::__construct in Simplenews 8
Same name and namespace in other branches
- 8.2 src/Spool/SpoolStorage.php \Drupal\simplenews\Spool\SpoolStorage::__construct()
- 3.x src/Spool/SpoolStorage.php \Drupal\simplenews\Spool\SpoolStorage::__construct()
Creates a SpoolStorage object.
Parameters
\Drupal\Core\Database\Connection $connection: The database connection.
\Drupal\Core\Lock\LockBackendInterface $lock: The lock.
\Drupal\Core\Config\ConfigFactoryInterface $config_factory: The config factory.
\Drupal\Core\Extension\ModuleHandlerInterface: The module handler.
File
- src/
Spool/ SpoolStorage.php, line 49
Class
- SpoolStorage
- Default database spool storage.
Namespace
Drupal\simplenews\SpoolCode
public function __construct(Connection $connection, LockBackendInterface $lock, ConfigFactoryInterface $config_factory, ModuleHandlerInterface $module_handler) {
$this->connection = $connection;
$this->lock = $lock;
$this->config = $config_factory
->get('simplenews.settings');
$this->moduleHandler = $module_handler;
}