protected ConfigEntityStorage::getFromStaticCache(array $ids)
Gets entities from the static cache.
Parameters
array $ids: If not empty, return entities that match these IDs.
Return value
\Drupal\Core\Entity\EntityInterface[] Array of entities from the entity cache.
Overrides EntityStorageBase::getFromStaticCache
File
- core/lib/Drupal/Core/Config/Entity/ConfigEntityStorage.php, line 328
Class
- ConfigEntityStorage
- Defines the storage class for configuration entities.
Namespace
Drupal\Core\Config\Entity
Code
protected function getFromStaticCache(array $ids) { $entities = array(); // Load any available entities from the internal cache. if ($this->entityType->isStaticallyCacheable() && !empty($this->entities)) { $config_overrides_key = $this->overrideFree ? '' : implode(':', $this->configFactory->getCacheKeys()); foreach ($ids as $id) { if (!empty($this->entities[$id])) { if (isset($this->entities[$id][$config_overrides_key])) { $entities[$id] = $this->entities[$id][$config_overrides_key]; } } } } return $entities; }
Please login to continue.