Updated Drupal to 8.6. This goes with the following updates because it's possible...
[yaffs-website] / web / core / modules / views / src / Plugin / views / cache / Tag.php
1 <?php
2
3 namespace Drupal\views\Plugin\views\cache;
4
5 use Drupal\Core\Cache\CacheBackendInterface;
6
7 /**
8  * Simple caching of query results for Views displays.
9  *
10  * @ingroup views_cache_plugins
11  *
12  * @ViewsCache(
13  *   id = "tag",
14  *   title = @Translation("Tag based"),
15  *   help = @Translation("Tag based caching of data. Caches will persist until any related cache tags are invalidated.")
16  * )
17  */
18 class Tag extends CachePluginBase {
19
20   /**
21    * {@inheritdoc}
22    */
23   public function summaryTitle() {
24     return $this->t('Tag');
25   }
26
27   /**
28    * {@inheritdoc}
29    */
30   protected function cacheExpire($type) {
31     return FALSE;
32   }
33
34   /**
35    * {@inheritdoc}
36    */
37   protected function getDefaultCacheMaxAge() {
38     return CacheBackendInterface::CACHE_PERMANENT;
39   }
40
41 }