function MemoryCounterBackend::get

Same name and namespace in other branches
  1. 9 core/lib/Drupal/Core/Cache/MemoryCounterBackend.php \Drupal\Core\Cache\MemoryCounterBackend::get()
  2. 8.9.x core/lib/Drupal/Core/Cache/MemoryCounterBackend.php \Drupal\Core\Cache\MemoryCounterBackend::get()
  3. 10 core/lib/Drupal/Core/Cache/MemoryCounterBackend.php \Drupal\Core\Cache\MemoryCounterBackend::get()

Overrides MemoryBackend::get

File

core/lib/Drupal/Core/Cache/MemoryCounterBackend.php, line 25

Class

MemoryCounterBackend
Defines a memory cache implementation that counts set and get calls.

Namespace

Drupal\Core\Cache

Code

public function get($cid, $allow_invalid = FALSE) {
    $this->increaseCounter(__FUNCTION__, $cid);
    return parent::get($cid, $allow_invalid);
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.