81 $this->_reader = $reader;
82 $this->_configScope = $configScope;
84 $this->_cacheId = $cacheId;
95 public function get(
$path =
null, $default =
null)
98 return parent::get(
$path, $default);
108 $scope = $this->_configScope->getCurrentScope();
109 if (
false == isset($this->_loadedScopes[$scope])) {
110 if (
false == in_array($scope, $this->_scopePriorityScheme)) {
111 $this->_scopePriorityScheme[] = $scope;
113 foreach ($this->_scopePriorityScheme as $scopeCode) {
114 if (
false == isset($this->_loadedScopes[$scopeCode])) {
115 if ($scopeCode !==
'primary' && (
$data = $this->_cache->load($scopeCode .
'::' . $this->_cacheId))
117 $data = $this->serializer->unserialize(
$data);
119 $data = $this->_reader->read($scopeCode);
120 if ($scopeCode !==
'primary') {
122 $this->serializer->serialize(
$data),
128 $this->_loadedScopes[$scopeCode] =
true;
130 if ($scopeCode == $scope) {
__construct(\Magento\Framework\Config\ReaderInterface $reader, \Magento\Framework\Config\ScopeInterface $configScope, \Magento\Framework\Config\CacheInterface $cache, $cacheId, SerializerInterface $serializer=null)