]> git.mxchange.org Git - friendica.git/blob - AbstractCacheDriver.php
15b822dc3b519f8e0fac9412429991a1f06384f7
[friendica.git] / AbstractCacheDriver.php
1 <?php
2
3 namespace Friendica\Core\Cache;
4 use Friendica\BaseObject;
5
6
7 /**
8  * Abstract class for common used functions
9  *
10  * Class AbstractCacheDriver
11  *
12  * @package Friendica\Core\Cache
13  */
14 abstract class AbstractCacheDriver extends BaseObject
15 {
16         /**
17          * @param string $key   The original key
18          * @return string               The cache key used for the cache
19          */
20         protected function getCacheKey($key) {
21                 // We fetch with the hostname as key to avoid problems with other applications
22                 return self::getApp()->get_hostname() . ":" . $key;
23         }
24 }