Ubiquity 2.5.2
php rapid development framework
Loading...
Searching...
No Matches
MemoryCache Class Reference

Ubiquity\cache\database$MemoryCache This class is part of Ubiquity. More...

+ Inheritance diagram for MemoryCache:

Public Member Functions

 __construct ()
 
 fetch ($tableName, $condition)
 Fetches data stored for the given condition in table.
 
 store ($tableName, $condition, $result)
 Caches the given data with the given key (tableName+md5(condition)).
 
 delete ($tableName, $condition)
 Deletes the entry corresponding to $condition apply to $table.
 
- Public Member Functions inherited from DbCache
 __construct ($cacheSystem=ArrayCache::class, $config=[])
 
 clear ($matches='')
 
 remove ($key)
 
 setActive ($value=true)
 
 storeDeferred ()
 

Protected Attributes

 $memoryCache
 
- Protected Attributes inherited from DbCache
 $cache
 
 $memoryCache
 
 $storeDeferred
 
 $toStore = [ ]
 

Additional Inherited Members

- Static Public Attributes inherited from DbCache
static $active = false
 
- Protected Member Functions inherited from DbCache
 getKey ($tableName, $condition)
 
 getMemoryCache ($key)
 

Detailed Description

Ubiquity\cache\database$MemoryCache This class is part of Ubiquity.

Author
jcheron myadd.nosp@m.ress.nosp@m.mail@.nosp@m.gmai.nosp@m.l.com
Version
1.0.1

Definition at line 13 of file MemoryCache.php.

Constructor & Destructor Documentation

◆ __construct()

__construct ( )

Definition at line 20 of file MemoryCache.php.

Member Function Documentation

◆ delete()

delete (   $tableName,
  $condition 
)

Deletes the entry corresponding to $condition apply to $table.

Parameters
string$tableName
string$condition
Returns
boolean true if the entry is deleted

Reimplemented from DbCache.

Definition at line 35 of file MemoryCache.php.

◆ fetch()

fetch (   $tableName,
  $condition 
)

Fetches data stored for the given condition in table.

Parameters
string$tableName
string$condition
Returns
mixed the cached datas

Reimplemented from DbCache.

Definition at line 23 of file MemoryCache.php.

◆ store()

store (   $tableName,
  $condition,
  $result 
)

Caches the given data with the given key (tableName+md5(condition)).

Parameters
string$tableName
string$condition
array$resultthe datas to store

Reimplemented from DbCache.

Definition at line 31 of file MemoryCache.php.

Field Documentation

◆ $memoryCache

$memoryCache
protected

Definition at line 18 of file MemoryCache.php.


The documentation for this class was generated from the following file: