public __construct ( string | array | ManaPHP\Cache\AdapterInterface $options = [] ) | ||
$options | string | array | ManaPHP\Cache\AdapterInterface |
public function __construct($options = [])
{
if (is_string($options) || is_object($options)) {
$options = ['adapter' => $options];
}
$this->adapter = $options['adapter'];
if (isset($options['prefix'])) {
$this->_prefix = $options['prefix'];
}
}