Class JCacheStorage

Description

Abstract cache storage handler

  • since: 11.1

Located in /libraries/joomla/cache/storage.php (line 19)


	
			
Direct descendents
Class Description
JCacheStorageApc APC cache storage handler
JCacheStorageFile File cache storage handler
JCacheStorageWincache WINCACHE cache storage handler
JCacheStorageCachelite Cache lite storage handler
JCacheStorageXcache XCache cache storage handler
JCacheStorageEaccelerator eAccelerator cache storage handler
JCacheStorageMemcache Memcache cache storage handler
Variable Summary
string $rawname
string $_application
string $_hash
string $_language
integer $_lifetime
boolean $_locking
datetime $_now
Method Summary
static array addIncludePath ([string $path = ''])
static JCacheStorageHandler getInstance ([string $handler = null], [array $options = array()])
static boolean test ()
JCacheStorage __construct ([array $options = array()])
boolean clean (string $group, [string $mode = null])
boolean gc ()
mixed get (string $id, string $group, [boolean $checkTime = true])
mixed getAll ()
boolean lock (string $id, string $group, integer $locktime)
boolean remove (string $id, string $group)
boolean store (string $id, string $group, string $data)
boolean unlock (string $id, [string $group = null])
string _getCacheId (string $id, string $group)
Variables
string $rawname (line 25)
  • var: Rawname
  • since: 11.1
  • access: protected
string $_application (line 55)
  • var: Application name.
  • since: 11.1
  • access: public
string $_hash (line 61)
  • var: Hash
  • since: 11.1
  • access: public
string $_language (line 49)
  • var: Language
  • since: 11.1
  • access: public
integer $_lifetime (line 37)
  • var: Cache lifetime
  • since: 11.1
  • access: public
boolean $_locking (line 43)
  • var: Locking
  • since: 11.1
  • access: public
datetime $_now (line 31)
  • var: Now
  • since: 11.1
  • access: public
Methods
static method addIncludePath (line 310)

Add a directory where JCacheStorage should search for handlers. You may either pass a string or an array of directories.

  • return: An array with directory elements
  • since: 11.1
  • access: public
static array addIncludePath ([string $path = ''])
  • string $path: A path to search.
static method getInstance (line 105)

Returns a cache storage handler object, only creating it if it doesn't already exist.

  • return: A JCacheStorageHandler object
  • since: 11.1
  • access: public
static JCacheStorageHandler getInstance ([string $handler = null], [array $options = array()])
  • string $handler: The cache storage handler to instantiate
  • array $options: Array of handler options
static method test (line 247)

Test to see if the storage handler is available.

  • return: True on success, false otherwise
  • since: 11.1.
  • access: public
static boolean test ()

Redefined in descendants as:
Constructor __construct (line 70)

Constructor

  • since: 11.1
  • access: public
JCacheStorage __construct ([array $options = array()])
  • array $options: Optional parameters

Redefined in descendants as:
clean (line 223)

Clean cache for a group given a mode.

  • return: True on success, false otherwise
  • since: 11.1
  • access: public
boolean clean (string $group, [string $mode = null])
  • string $group: The cache data group
  • string $mode: The mode for cleaning cache [group|notgroup] group mode : cleans all cache in the group notgroup mode : cleans all cache not in the group

Redefined in descendants as:
gc (line 235)

Garbage collect expired cache data

  • return: True on success, false otherwise.
  • since: 11.1
  • access: public
boolean gc ()

Redefined in descendants as:
get (line 159)

Get cached data by id and group

  • return: Boolean false on failure or a cached data object
  • since: 11.1
  • access: public
mixed get (string $id, string $group, [boolean $checkTime = true])
  • string $id: The cache data id
  • string $group: The cache data group
  • boolean $checkTime: True to verify cache time expiration threshold

Redefined in descendants as:
getAll (line 171)

Get all cached data

  • return: Boolean false on failure or a cached data object
  • since: 11.1
  • access: public
mixed getAll ()

Redefined in descendants as:
lock (line 263)

Lock cached item

  • return: True on success, false otherwise.
  • since: 11.1
  • access: public
boolean lock (string $id, string $group, integer $locktime)
  • string $id: The cache data id
  • string $group: The cache data group
  • integer $locktime: Cached item max lock time

Redefined in descendants as:
remove (line 206)

Remove a cached data entry by id and group

  • return: True on success, false otherwise
  • since: 11.1
  • access: public
boolean remove (string $id, string $group)
  • string $id: The cache data id
  • string $group: The cache data group

Redefined in descendants as:
store (line 191)

Store the data to cache by id and group

  • return: True on success, false otherwise
  • since: 11.1
  • access: public
boolean store (string $id, string $group, string $data)
  • string $id: The cache data id
  • string $group: The cache data group
  • string $data: The data to store in cache

Redefined in descendants as:
unlock (line 278)

Unlock cached item

  • return: True on success, false otherwise.
  • since: 11.1
  • access: public
boolean unlock (string $id, [string $group = null])
  • string $id: The cache data id
  • string $group: The cache data group

Redefined in descendants as:
_getCacheId (line 293)

Get a cache_id string from an id/group pair

  • return: The cache_id string
  • since: 11.1
  • access: protected
string _getCacheId (string $id, string $group)
  • string $id: The cache data id
  • string $group: The cache data group

Documentation generated on Mon, 25 Jun 2012 13:59:47 -0500 by phpDocumentor 1.4.4