Fat-Free Framework: Cache Class Reference

Fat-Free-Framework

Fat-Free Framework  3.1.0 API Reference

Cache engine. More...

Inheritance diagram for Cache:
Prefab

Public Member Functions

 exists ($key, &$val=NULL)
 
 set ($key, $val, $ttl=0)
 
 get ($key)
 
 clear ($key)
 
 reset ($suffix=NULL, $lifetime=0)
 
 load ($dsn)
 
 __construct ($dsn=FALSE)
 

Public Attributes

 $prefix
 Prefix for cache entries.
 
 $ref
 MemCache object.
 

Protected Attributes

 $dsn
 Cache DSN.
 

Additional Inherited Members

- Static Public Member Functions inherited from Prefab
static instance ()
 

Detailed Description

Cache engine.

Constructor & Destructor Documentation

Cache::__construct (   $dsn = FALSE)

Class constructor

Returns
object
Parameters
$dsnbool|string

Member Function Documentation

Cache::clear (   $key)

Delete cache entry

Returns
bool
Parameters
$keystring
Cache::exists (   $key,
$val = NULL 
)

Return timestamp and TTL of cache entry or FALSE if not found

Returns
float|FALSE
Parameters
$keystring
$valmixed
Cache::get (   $key)

Retrieve value of cache entry

Returns
mixed|FALSE
Parameters
$keystring
Cache::load (   $dsn)

Load/auto-detect cache backend

Returns
string
Parameters
$dsnbool|string
Cache::reset (   $suffix = NULL,
  $lifetime = 0 
)

Clear contents of cache backend

Returns
bool
Parameters
$suffixstring
$lifetimeint
Cache::set (   $key,
  $val,
  $ttl = 0 
)

Store value in cache

Returns
mixed|FALSE
Parameters
$keystring
$valmixed
$ttlint

The documentation for this class was generated from the following file:
  • base.php
Generated on Mon Aug 19 2013 21:27:46 for Fat-Free Framework by   doxygen 1.8.4