File Manager Lite
Dir:
/home/codewavebd/public_html/vendor/laravel/framework/src/Illuminate/Cache
Upload
[..]
ApcWrapper.php (1.4 KB)
Edit
Rename
Del
Console/
Rename
Del
Events/
Rename
Del
FailoverStore.php (6.69 KB)
Edit
Rename
Del
Limiters/
Rename
Del
MemcachedLock.php (1.4 KB)
Edit
Rename
Del
RateLimiting/
Rename
Del
RedisTagSet.php (3.82 KB)
Edit
Rename
Del
RedisTaggedCache.php (5.79 KB)
Edit
Rename
Del
TagSet.php (2.44 KB)
Edit
Rename
Del
TaggableStore.php (415 B)
Edit
Rename
Del
TaggedCache.php (2.82 KB)
Edit
Rename
Del
Edit: MemcachedLock.php
<?php namespace Illuminate\Cache; class MemcachedLock extends Lock { /** * The Memcached instance. * * @var \Memcached */ protected $memcached; /** * Create a new lock instance. * * @param \Memcached $memcached * @param string $name * @param int $seconds * @param string|null $owner */ public function __construct($memcached, $name, $seconds, $owner = null) { parent::__construct($name, $seconds, $owner); $this->memcached = $memcached; } /** * Attempt to acquire the lock. * * @return bool */ public function acquire() { return $this->memcached->add( $this->name, $this->owner, $this->seconds ); } /** * Release the lock. * * @return bool */ public function release() { if ($this->isOwnedByCurrentProcess()) { return $this->memcached->delete($this->name); } return false; } /** * Releases this lock in disregard of ownership. * * @return void */ public function forceRelease() { $this->memcached->delete($this->name); } /** * Returns the owner value written into the driver for this lock. * * @return mixed */ protected function getCurrentOwner() { return $this->memcached->get($this->name); } }
Simpan