IMemcache¶
-
interface
OCP\IMemcache¶ - This interface defines method for accessing the file based user cache.
Implemented by: OC\Memcache\MemcachedOC\Memcache\APCuOC\Memcache\ArrayCacheOC\Memcache\NullCacheSource: lib/public/IMemcache.php#41 Parent: OCP\ICache
Methods¶
-
public
OCP\IMemcache::add($key, $value, $ttl=0)¶ - Set a value in the cache if it’s not already stored
Source: Parameters: - $key (string)
- $value (mixed)
- $ttl (int) Time To Live in seconds. Defaults to 60*60*24
Returns: bool
Since: 8.1.0
-
public
OCP\IMemcache::inc($key, $step=1)¶ - Increase a stored number
Source: Parameters: - $key (string)
- $step (int)
Returns: int | bool
Since: 8.1.0
-
public
OCP\IMemcache::dec($key, $step=1)¶ - Decrease a stored number
Source: Parameters: - $key (string)
- $step (int)
Returns: int | bool
Since: 8.1.0
-
public
OCP\IMemcache::cas($key, $old, $new)¶ - Compare and set
Source: Parameters: - $key (string)
- $old (mixed)
- $new (mixed)
Returns: bool
Since: 8.1.0
-
public
OCP\IMemcache::cad($key, $old)¶ - Compare and delete
Source: Parameters: - $key (string)
- $old (mixed)
Returns: bool
Since: 8.1.0