You are here

public function SqlImport::__construct in MongoDB 8.2

MongoDbStorageCommands constructor.

Note that this constructor type-hints on classes instead of interfaces, because this is a migration command relying on actual implementations details, not on the high-level KV interfaces.

Parameters

\Drupal\Core\Database\Connection $database: The database service.

\Drupal\Core\KeyValueStore\KeyValueDatabaseFactory $persistentDbFactory: The database KV factory.

\Drupal\Core\KeyValueStore\KeyValueDatabaseExpirableFactory $expirableDbFactory: The expirable database KV factory.

\Drupal\mongodb_storage\KeyValueFactory $persistentMoFactory: The MongoDB KV factory.

\Drupal\mongodb_storage\KeyValueExpirableFactory $expirableMoFactory: The expirable MongoDB KV factory.

\Drupal\Component\Datetime\TimeInterface $time: The datetime.time service.

File

modules/mongodb_storage/src/Install/SqlImport.php, line 85

Class

SqlImport
Service providing the import of the SQL-based KV storage to MongoDB.

Namespace

Drupal\mongodb_storage\Install

Code

public function __construct(Connection $database, KeyValueDatabaseFactory $persistentDbFactory, KeyValueDatabaseExpirableFactory $expirableDbFactory, KeyValueFactory $persistentMoFactory, KeyValueExpirableFactory $expirableMoFactory, TimeInterface $time) {
  $this->database = $database;
  $this->persistentDbFactory = $persistentDbFactory;
  $this->expirableDbFactory = $expirableDbFactory;
  $this->persistentMoFactory = $persistentMoFactory;
  $this->expirableMoFactory = $expirableMoFactory;
  $this->time = $time;
}