Esempio n. 1
0
 /**
  * Constructor.
  *
  * @param   int   $ttl     The Time To Live (TTL) of an item
  * @param   mixed $options An options array, or an object that implements \ArrayAccess
  *
  * @throws \RuntimeException
  * @since   2.0
  */
 public function __construct($ttl = null, $options = array())
 {
     if (!extension_loaded('xcache') || !is_callable('xcache_get')) {
         throw new \RuntimeException('XCache not supported.');
     }
     parent::__construct($ttl, $options);
 }
 /**
  * Constructor.
  *
  * @param   int     $path
  * @param   string  $group
  * @param   bool    $denyAccess
  * @param   int     $ttl
  * @param   mixed   $options An options array, or an object that implements \ArrayAccess
  *
  * @since   2.0
  */
 public function __construct($path, $group = '', $denyAccess = false, $ttl = null, $options = array())
 {
     $this->path = $path;
     $this->group = $group;
     $this->denyAccess = $denyAccess;
     $options = array_merge($this->options, $options);
     $this->checkFilePath($path);
     parent::__construct($ttl, $options);
 }