Webiny\Component\Cache\Cache::Memcache PHP Méthode

Memcache() public static méthode

Create a cache instance with Memcache as cache driver.
public static Memcache ( string $host = '127.0.0.1', integer $port = 11211, array $options = [] ) : CacheStorage
$host string Host where the memcached is running.
$port integer Port where memcached is running.
$options array Cache options.
Résultat CacheStorage
    public static function Memcache($host = '127.0.0.1', $port = 11211, $options = [])
    {
        return new CacheStorage(Storage\Memcache::getInstance($host, $port), $options);
    }

Usage Example

 public function driverSet()
 {
     Cache::setConfig(realpath(__DIR__ . '/' . self::CONFIG));
     return [[Cache::Memcache(self::MEMCACHE_IP)]];
 }