function ViewExecutable::getCacheTags
Same name in other branches
- 8.9.x core/modules/views/src/ViewExecutable.php \Drupal\views\ViewExecutable::getCacheTags()
- 10 core/modules/views/src/ViewExecutable.php \Drupal\views\ViewExecutable::getCacheTags()
- 11.x core/modules/views/src/ViewExecutable.php \Drupal\views\ViewExecutable::getCacheTags()
Gets the cache tags associated with the executed view.
Note: The cache plugin controls the used tags, so you can override it, if needed.
Return value
string[] An array of cache tags.
File
-
core/
modules/ views/ src/ ViewExecutable.php, line 1567
Class
- ViewExecutable
- Represents a view as a whole.
Namespace
Drupal\viewsCode
public function getCacheTags() {
$this->initDisplay();
/** @var \Drupal\views\Plugin\views\cache\CachePluginBase $cache */
$cache = $this->display_handler
->getPlugin('cache');
return $cache->getCacheTags();
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.