1
0
Fork 0

Rename *CacheDriver to *Cache because they don't act as driver anymore

This commit is contained in:
Philipp Holzer 2019-08-04 10:26:53 +02:00
commit 86bf2ee45a
No known key found for this signature in database
GPG key ID: D8365C3D36B77D90
38 changed files with 152 additions and 144 deletions

View file

@ -3,7 +3,7 @@
namespace Friendica\Factory;
use Friendica\Core\Cache;
use Friendica\Core\Cache\ICacheDriver;
use Friendica\Core\Cache\ICache;
use Friendica\Core\Config\Configuration;
use Friendica\Database\Database;
use Friendica\Util\BaseURL;
@ -61,7 +61,7 @@ class CacheDriverFactory
/**
* This method creates a CacheDriver for the given cache driver name
*
* @return ICacheDriver The instance of the CacheDriver
* @return ICache The instance of the CacheDriver
* @throws \Exception The exception if something went wrong during the CacheDriver creation
*/
public function create()
@ -70,19 +70,19 @@ class CacheDriverFactory
switch ($driver) {
case 'memcache':
$cache = new Cache\MemcacheCacheDriver($this->hostname, $this->config);
$cache = new Cache\MemcacheCache($this->hostname, $this->config);
break;
case 'memcached':
$cache = new Cache\MemcachedCacheDriver($this->hostname, $this->config, $this->logger);
$cache = new Cache\MemcachedCache($this->hostname, $this->config, $this->logger);
break;
case 'redis':
$cache = new Cache\RedisCacheDriver($this->hostname, $this->config);
$cache = new Cache\RedisCache($this->hostname, $this->config);
break;
case 'apcu':
$cache = new Cache\APCuCache($this->hostname);
break;
default:
$cache = new Cache\DatabaseCacheDriver($this->hostname, $this->dba);
$cache = new Cache\DatabaseCache($this->hostname, $this->dba);
}
$profiling = $this->config->get('system', 'profiling', false);