Magento 2 Documentation  2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
Config.php
Go to the documentation of this file.
1 <?php
8 
11 
15 class Config extends TagScope implements CacheInterface
16 {
20  const TYPE_IDENTIFIER = 'config';
21 
25  const CACHE_TAG = 'CONFIG';
26 
30  private $cacheFrontendPool;
31 
35  public function __construct(\Magento\Framework\App\Cache\Type\FrontendPool $cacheFrontendPool)
36  {
37  $this->cacheFrontendPool = $cacheFrontendPool;
38  }
39 
45  protected function _getFrontend()
46  {
47  $frontend = parent::_getFrontend();
48  if (!$frontend) {
49  $frontend = $this->cacheFrontendPool->get(self::TYPE_IDENTIFIER);
50  $this->setFrontend($frontend);
51  }
52  return $frontend;
53  }
54 
60  public function getTag()
61  {
62  return self::CACHE_TAG;
63  }
64 }
__construct(\Magento\Framework\App\Cache\Type\FrontendPool $cacheFrontendPool)
Definition: Config.php:35
setFrontend(\Magento\Framework\Cache\FrontendInterface $frontend)
Definition: Bare.php:36