protected function PlaceholderingRenderCache::getFromPlaceholderResultsCache in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/lib/Drupal/Core/Render/PlaceholderingRenderCache.php \Drupal\Core\Render\PlaceholderingRenderCache::getFromPlaceholderResultsCache()
Retrieves an auto-placeholdered renderable array from the static cache.
Parameters
array $elements: A renderable array.
Return value
array|false A renderable array, with the original element and all its children pre- rendered, or FALSE if no cached copy of the element is available.
1 call to PlaceholderingRenderCache::getFromPlaceholderResultsCache()
- PlaceholderingRenderCache::get in core/
lib/ Drupal/ Core/ Render/ PlaceholderingRenderCache.php - Gets the cached, pre-rendered element of a renderable element from cache.
File
- core/
lib/ Drupal/ Core/ Render/ PlaceholderingRenderCache.php, line 174 - Contains \Drupal\Core\Render\PlaceholderingRenderCache.
Class
- PlaceholderingRenderCache
- Adds automatic placeholdering to the RenderCache.
Namespace
Drupal\Core\RenderCode
protected function getFromPlaceholderResultsCache(array $elements) {
$placeholder_element = $this->placeholderGenerator
->createPlaceholder($elements);
$placeholder = (string) $placeholder_element['#markup'];
if (isset($this->placeholderResultsCache[$placeholder])) {
return $this->placeholderResultsCache[$placeholder];
}
return FALSE;
}