����JFIF��x�x����'
| Server IP : 78.140.185.180 / Your IP : 216.73.216.170 Web Server : LiteSpeed System : Linux cpanel13.v.fozzy.com 4.18.0-513.11.1.lve.el8.x86_64 #1 SMP Thu Jan 18 16:21:02 UTC 2024 x86_64 User : builderbox ( 1072) PHP Version : 7.3.33 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : OFF Directory : /proc/self/root/proc/1630575/root/home/builderbox/./public_html/vendor/torann/geoip/src/ |
Upload File : |
<?php
namespace Torann\GeoIP;
use Illuminate\Cache\CacheManager;
class Cache
{
/**
* Instance of cache manager.
*
* @var \Illuminate\Cache\CacheManager
*/
protected $cache;
/**
* Lifetime of the cache.
*
* @var int
*/
protected $expires;
/**
* Create a new cache instance.
*
* @param CacheManager $cache
* @param array $tags
* @param int $expires
*/
public function __construct(CacheManager $cache, $tags, $expires = 30)
{
$this->cache = $tags ? $cache->tags($tags) : $cache;
$this->expires = $expires;
}
/**
* Get an item from the cache.
*
* @param string $name
*
* @return Location|null
*/
public function get($name)
{
$value = $this->cache->get($name);
return is_array($value)
? new Location($value)
: null;
}
/**
* Store an item in cache.
*
* @param string $name
* @param Location $location
*
* @return bool
*/
public function set($name, Location $location)
{
return $this->cache->put($name, $location->toArray(), $this->expires);
}
/**
* Flush cache for tags.
*
* @return bool
*/
public function flush()
{
return $this->cache->flush();
}
}