public function TermStorage::resetCache in Drupal 9
Same name and namespace in other branches
- 8 core/modules/taxonomy/src/TermStorage.php \Drupal\taxonomy\TermStorage::resetCache()
Resets the entity cache.
Content entities have both an in-memory static cache and a persistent cache. Use this method to clear all caches. To clear just the in-memory cache, use the 'entity.memory_cache' service.
Parameters
array $ids: (optional) If specified, the cache is reset for the entities with the given ids only.
Overrides ContentEntityStorageBase::resetCache
File
- core/
modules/ taxonomy/ src/ TermStorage.php, line 82
Class
- TermStorage
- Defines a Controller class for taxonomy terms.
Namespace
Drupal\taxonomyCode
public function resetCache(array $ids = NULL) {
$this->ancestors = [];
$this->treeChildren = [];
$this->treeParents = [];
$this->treeTerms = [];
$this->trees = [];
$this->vocabularyHierarchyType = [];
parent::resetCache($ids);
}