function CacheFactory::__construct

Same name in other branches
  1. 9 core/lib/Drupal/Core/Cache/CacheFactory.php \Drupal\Core\Cache\CacheFactory::__construct()
  2. 10 core/lib/Drupal/Core/Cache/CacheFactory.php \Drupal\Core\Cache\CacheFactory::__construct()
  3. 11.x core/lib/Drupal/Core/Cache/CacheFactory.php \Drupal\Core\Cache\CacheFactory::__construct()

Constructs CacheFactory object.

Parameters

\Drupal\Core\Site\Settings $settings: The site settings.

array $default_bin_backends: (optional) A mapping of bin to backend service name. Mappings in $settings take precedence over this.

File

core/lib/Drupal/Core/Cache/CacheFactory.php, line 45

Class

CacheFactory

Namespace

Drupal\Core\Cache

Code

public function __construct(Settings $settings, array $default_bin_backends = []) {
    $this->settings = $settings;
    $this->defaultBinBackends = $default_bin_backends;
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.