* php 7.x APCu cache support

This commit is contained in:
slawkens1
2017-12-26 21:47:53 +01:00
parent a95c93cd5b
commit c415cf5ffb
4 changed files with 61 additions and 1 deletions

View File

@@ -23,6 +23,11 @@ class Cache
self::$instance = new Cache_APC($prefix);
break;
case 'apcu':
require('cache_apcu.php');
self::$instance = new Cache_APCu($prefix);
break;
case 'eaccelerator':
require('cache_eaccelerator.php');
self::$instance = new Cache_eAccelerator($prefix);
@@ -55,6 +60,8 @@ class Cache
{
if(function_exists('apc_fetch'))
return 'apc';
else if(function_exists('apcu_fetch'))
return 'apcu';
else if(function_exists('eaccelerator_get'))
return 'eaccelerator';
else if(function_exists('xcache_get') && ini_get('xcache.var_size'))