Cache
Table of Contents
- __construct() : mixed
- __construct.
- clear() : self
- Clear all caches.
- delete() : self
- Delete item form cache.
- deleteMultiple() : self
- Delete multiples items form cache.
- get() : mixed
- Get the value from cache.
- getAdapter() : string
- Get the adapter of cache.
- getDefaultTtl() : int
- Get default ttl.
- getItemTtl() : int|false
- Get item ttl.
- getMultiple() : mixed
- Get the multiple values from cache.
- has() : bool
- Determine if cache exixts.
- set() : self
- Save item to cache.
- setMultiple() : self
- Save multiple items to cache.
- setProperAdapter() : self
- Set the valid adapter.
Methods
__construct()
__construct.
public
__construct() : mixed
Tags
Return values
mixed —clear()
Clear all caches.
public
clear() : self
Tags
Return values
self —delete()
Delete item form cache.
public
delete((mixed) $key) : self
Parameters
- $key : (mixed)
-
key for cache
Tags
Return values
self —deleteMultiple()
Delete multiples items form cache.
public
deleteMultiple((array) $keys) : self
Parameters
- $keys : (array)
Tags
Return values
self —get()
Get the value from cache.
public
get((mixed) $key[, (mixed) $default = null ]) : mixed
Parameters
- $key : (mixed)
- $default : (mixed) = null
Tags
Return values
mixed —getAdapter()
Get the adapter of cache.
public
getAdapter() : string
Tags
Return values
string —getDefaultTtl()
Get default ttl.
public
getDefaultTtl() : int
Tags
Return values
int —getItemTtl()
Get item ttl.
public
getItemTtl((string) $key) : int|false
Parameters
- $key : (string)
Tags
Return values
int|false —getMultiple()
Get the multiple values from cache.
public
getMultiple((array) $keys[, (mixed) $default = null ]) : mixed
Parameters
- $keys : (array)
- $default : (mixed) = null
Tags
Return values
mixed —has()
Determine if cache exixts.
public
has((mixed) $key) : bool
Parameters
- $key : (mixed)
-
key for cache
Tags
Return values
bool —set()
Save item to cache.
public
set((mixed) $key, (mixed) $value[, (int) $ttl = null ]) : self
Parameters
- $key : (mixed)
-
key for cache
- $value : (mixed)
-
value to be cached
- $ttl : (int) = null
-
time to live for cache
Tags
Return values
self —setMultiple()
Save multiple items to cache.
public
setMultiple((array) $cache) : self
Parameters
- $cache : (array)
-
[key,value,ttl]
Tags
Return values
self —setProperAdapter()
Set the valid adapter.
public
setProperAdapter((string) $adapter) : self
Parameters
- $adapter : (string)