Ubiquity  2.0.3
php rapid development framework
PhpFastCacheDriver Class Reference

This class is responsible for storing values with PhpFastCache. More...

+ Inheritance diagram for PhpFastCacheDriver:

Public Member Functions

 __construct ($root, $postfix="", $cacheParams=[])
 Initializes the cache-provider. More...
 
 exists ($key)
 Check if annotation-data for the key has been stored. More...
 
 store ($key, $code, $tag=null, $php=true)
 
 fetch ($key)
 Fetches data stored for the given key. More...
 
 file_get_contents ($key)
 return data stored for the given key. More...
 
 getTimestamp ($key)
 Returns the timestamp of the last cache update for the given key. More...
 
 remove ($key)
 
 clear ()
 
 getCacheFiles ($type)
 
 clearCache ($type)
 
 getCacheInfo ()
 
 getEntryKey ($key)
 
- Public Member Functions inherited from AbstractDataCache
 __construct ($root, $postfix="")
 
 exists ($key)
 Check if annotation-data for the key has been stored. More...
 
 expired ($key, $duration)
 
 store ($key, $code, $tag=null, $php=true)
 Caches the given data with the given key. More...
 
 getRoot ()
 
 fetch ($key)
 Fetches data stored for the given key. More...
 
 file_get_contents ($key)
 return data stored for the given key. More...
 
 getTimestamp ($key)
 Returns the timestamp of the last cache update for the given key. More...
 
 remove ($key)
 
 clear ()
 Clears all cache entries. More...
 
 getCacheFiles ($type)
 
 clearCache ($type)
 
 getCacheInfo ()
 
 getEntryKey ($key)
 

Protected Member Functions

 storeContent ($key, $content, $tag)
 Caches the given data with the given key. More...
 
 getRealKey ($key)
 
 getCacheEntries ($type)
 
- Protected Member Functions inherited from AbstractDataCache
 storeContent ($key, $content, $tag)
 

Private Attributes

 $cacheInstance
 

Additional Inherited Members

- Data Fields inherited from AbstractDataCache
const PHP_TAG ="<?php\n"
 
- Protected Attributes inherited from AbstractDataCache
 $_root
 
 $postfix
 

Detailed Description

This class is responsible for storing values with PhpFastCache.

Definition at line 11 of file PhpFastCacheDriver.php.

Constructor & Destructor Documentation

◆ __construct()

__construct (   $root,
  $postfix = "",
  $cacheParams = [] 
)

Initializes the cache-provider.

Definition at line 19 of file PhpFastCacheDriver.php.

Member Function Documentation

◆ clear()

clear ( )

Definition at line 94 of file PhpFastCacheDriver.php.

◆ clearCache()

clearCache (   $type)

Definition at line 115 of file PhpFastCacheDriver.php.

◆ exists()

exists (   $key)

Check if annotation-data for the key has been stored.

Parameters
string$keycache key
Returns
boolean true if data with the given key has been stored; otherwise false

Definition at line 32 of file PhpFastCacheDriver.php.

◆ fetch()

fetch (   $key)

Fetches data stored for the given key.

Parameters
string$keycache key
Returns
mixed the cached data

Definition at line 64 of file PhpFastCacheDriver.php.

◆ file_get_contents()

file_get_contents (   $key)

return data stored for the given key.

Parameters
string$keycache key
Returns
mixed the cached data

Definition at line 74 of file PhpFastCacheDriver.php.

◆ getCacheEntries()

getCacheEntries (   $type)
protected

Definition at line 98 of file PhpFastCacheDriver.php.

◆ getCacheFiles()

getCacheFiles (   $type)

Definition at line 102 of file PhpFastCacheDriver.php.

◆ getCacheInfo()

getCacheInfo ( )

Definition at line 119 of file PhpFastCacheDriver.php.

◆ getEntryKey()

getEntryKey (   $key)

Definition at line 123 of file PhpFastCacheDriver.php.

◆ getRealKey()

getRealKey (   $key)
protected

Definition at line 54 of file PhpFastCacheDriver.php.

◆ getTimestamp()

getTimestamp (   $key)

Returns the timestamp of the last cache update for the given key.

Parameters
string$keycache key
Returns
int unix timestamp

Definition at line 84 of file PhpFastCacheDriver.php.

◆ remove()

remove (   $key)

Definition at line 89 of file PhpFastCacheDriver.php.

◆ store()

store (   $key,
  $code,
  $tag = null,
  $php = true 
)

Definition at line 36 of file PhpFastCacheDriver.php.

◆ storeContent()

storeContent (   $key,
  $content,
  $tag 
)
protected

Caches the given data with the given key.

Parameters
string$keycache key
string$contentthe source-code to be cached
string$tag

Definition at line 46 of file PhpFastCacheDriver.php.

Field Documentation

◆ $cacheInstance

$cacheInstance
private

Definition at line 15 of file PhpFastCacheDriver.php.


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