You are here

public function DatabaseBackendFactory::get in Drupal 9

Same name and namespace in other branches
  1. 8 core/lib/Drupal/Core/Cache/DatabaseBackendFactory.php \Drupal\Core\Cache\DatabaseBackendFactory::get()

Gets DatabaseBackend for the specified cache bin.

Parameters

$bin: The cache bin for which the object is created.

Return value

\Drupal\Core\Cache\DatabaseBackend The cache backend object for the specified cache bin.

Overrides CacheFactoryInterface::get

File

core/lib/Drupal/Core/Cache/DatabaseBackendFactory.php, line 58

Class

DatabaseBackendFactory

Namespace

Drupal\Core\Cache

Code

public function get($bin) {
  $max_rows = $this
    ->getMaxRowsForBin($bin);
  return new DatabaseBackend($this->connection, $this->checksumProvider, $bin, $max_rows);
}