PHP Class Microweber\Utils\Adapters\Cache\CacheStore

Afficher le fichier Open project: microweber/microweber

Méthodes publiques

Свойство Type Description
$adapter Microweber\Utils\Adapters\Cache\Storage\FileStorage

Méthodes publiques

Méthode Description
__construct ( $prefix = '' )
decrement ( string $key, mixed $value = 1 ) Increment the value of an item in the cache.
flush ( $all = false ) Remove all items from the cache.
forever ( string $key, mixed $value ) Store an item in the cache indefinitely.
forget ( string $key ) Remove an item from the cache.
forgetTags ( string $string ) Remove an item from the cache by tags.
get ( string $key ) : mixed Retrieve an item from the cache by key.
increment ( string $key, mixed $value = 1 ) Increment the value of an item in the cache.
put ( string $key, mixed $value, integer $minutes ) Store an item in the cache for a given number of minutes.
remember ( string $key, DateTime | integer $minutes, Closure $callback ) : mixed Get an item from the cache, or store the default value.
rememberForever ( string $key, Closure $callback ) : mixed Get an item from the cache, or store the default value forever.
setAdapter ( $adapter )
tags ( $tags ) : object Tags for cache.

Method Details

__construct() public méthode

public __construct ( $prefix = '' )

decrement() public méthode

Increment the value of an item in the cache.
public decrement ( string $key, mixed $value = 1 )
$key string
$value mixed

flush() public méthode

Remove all items from the cache.
public flush ( $all = false )

forever() public méthode

Store an item in the cache indefinitely.
public forever ( string $key, mixed $value )
$key string
$value mixed

forget() public méthode

Remove an item from the cache.
public forget ( string $key )
$key string

forgetTags() public méthode

Remove an item from the cache by tags.
public forgetTags ( string $string )
$string string

get() public méthode

Retrieve an item from the cache by key.
public get ( string $key ) : mixed
$key string
Résultat mixed

increment() public méthode

Increment the value of an item in the cache.
public increment ( string $key, mixed $value = 1 )
$key string
$value mixed

put() public méthode

Store an item in the cache for a given number of minutes.
public put ( string $key, mixed $value, integer $minutes )
$key string
$value mixed
$minutes integer

remember() public méthode

Get an item from the cache, or store the default value.
public remember ( string $key, DateTime | integer $minutes, Closure $callback ) : mixed
$key string
$minutes DateTime | integer
$callback Closure
Résultat mixed

rememberForever() public méthode

Get an item from the cache, or store the default value forever.
public rememberForever ( string $key, Closure $callback ) : mixed
$key string
$callback Closure
Résultat mixed

setAdapter() public méthode

public setAdapter ( $adapter )

tags() public méthode

Tags for cache.
public tags ( $tags ) : object
Résultat object

Property Details

$adapter public_oe property

public FileStorage,Microweber\Utils\Adapters\Cache\Storage $adapter
Résultat Microweber\Utils\Adapters\Cache\Storage\FileStorage