Open Journal Systems  3.3.0
CacheManager Class Reference

Public Member Functions

 flush ($context=null, $type=CACHE_TYPE_FILE)
 
 getCache ($context, $cacheId, $fallback, $type=CACHE_TYPE_FILE)
 
 getCacheImplementation ($type)
 
 getFileCache ($context, $cacheId, $fallback)
 
 getObjectCache ($context, $cacheId, $fallback)
 

Static Public Member Functions

static getFileCachePath ()
 
static getManager ()
 

Detailed Description

Definition at line 22 of file CacheManager.inc.php.

Member Function Documentation

◆ flush()

CacheManager::flush (   $context = null,
  $type = CACHE_TYPE_FILE 
)

Flush an entire context, if specified, or the whole cache.

Parameters
$contextstring The context to flush, if only one is to be flushed
$typestring The type of cache to flush

Definition at line 122 of file CacheManager.inc.php.

References getCache(), getCacheImplementation(), and getFileCachePath().

◆ getCache()

CacheManager::getCache (   $context,
  $cacheId,
  $fallback,
  $type = CACHE_TYPE_FILE 
)

Get a cache.

Parameters
$contextstring
$cacheIdstring
$fallbackcallback
$typestring Type of cache: CACHE_TYPE_...
Returns
object Cache

Definition at line 69 of file CacheManager.inc.php.

References getCacheImplementation(), getFileCache(), and Config\getVar().

Referenced by flush(), and getObjectCache().

◆ getCacheImplementation()

CacheManager::getCacheImplementation (   $type)

Definition at line 53 of file CacheManager.inc.php.

References CACHE_TYPE_FILE, CACHE_TYPE_OBJECT, and Config\getVar().

Referenced by flush(), and getCache().

◆ getFileCache()

CacheManager::getFileCache (   $context,
  $cacheId,
  $fallback 
)

Get a file cache.

Parameters
$contextstring
$cacheIdstring
$fallbackcallback
Returns
object FileCache

Definition at line 42 of file CacheManager.inc.php.

References getFileCachePath().

Referenced by getCache().

◆ getFileCachePath()

static CacheManager::getFileCachePath ( )
static

Get the path in which file caches will be stored.

Returns
string The full path to the file cache directory

Definition at line 112 of file CacheManager.inc.php.

References Core\getBaseDir().

Referenced by PKPTemplateManager\__construct(), PKPTemplateManager\clearCssCache(), flush(), PKPTemplateManager\getCachedLessFilePath(), getFileCache(), and DAO\setCacheDir().

◆ getManager()

◆ getObjectCache()

CacheManager::getObjectCache (   $context,
  $cacheId,
  $fallback 
)

Definition at line 49 of file CacheManager.inc.php.

References CACHE_TYPE_OBJECT, and getCache().


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