API Documentation

Zend/Cache/Manager.php

Show: inherited
Table of Contents

Zend Framework

LICENSE

This source file is subject to the new BSD license that is bundled with this package in the file LICENSE.txt. It is also available through the world-wide-web at this URL: http://framework.zend.com/license/new-bsd If you did not receive a copy of the license and are unable to obtain it through the world-wide-web, please send an email to license@zend.com so we can send you a copy immediately.

Category
Zend  
Copyright
Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)  
License
New BSD License  
Package
Zend_Cache  
Version
$Id: Manager.php 24594 2012-01-05 21:27:01Z matthew $  

\Zend_Cache_Manager

Package: Zend\Cache

Category
Zend  
Copyright
Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)  
License
New BSD License  

Constants

Constant  PAGECACHE = 'page'

Constant holding reserved name for default Page Cache

Constant  PAGETAGCACHE = 'pagetag'

Constant holding reserved name for default Page Tag Cache

Properties

Propertyprotectedarray  $_caches= 'array()'

Array of caches stored by the Cache Manager instance

Default valuearray()Details
Type
array
Propertyprotectedarray  $_optionTemplates= 'array( // Simple Common Default 'default' => array( 'frontend' => array( 'name' => 'Core''

Array of ready made configuration templates for lazy loading caches.

Default valuearray( // Simple Common Default 'default' => array( 'frontend' => array( 'name' => 'Core'Details
Type
array

Methods

methodprotected_mergeOptions( array $current, array $options ) : array

Simple method to merge two configuration arrays

Parameters
Name Type Description
$current array
$options array
Returns
Type Description
array
methodpublicgetCache( string $name ) : \Zend_Cache_Core

Fetch the named cache object, or instantiate and return a cache object using a named configuration template

Parameters
Name Type Description
$name string
Returns
Type Description
\Zend_Cache_Core
methodpublicgetCacheTemplate( string $name ) : array

Get the named configuration template

Parameters
Name Type Description
$name string
Returns
Type Description
array
methodpublicgetCaches( ) : array

Fetch all available caches

Returns
Type Description
array An array of all available caches with it's names as key
methodpublichasCache( string $name ) : bool

Check if the Cache Manager contains the named cache object, or a named configuration template to lazy load the cache object

Parameters
Name Type Description
$name string
Returns
Type Description
bool
methodpublichasCacheTemplate( string $name ) : bool

Check if the named configuration template

Parameters
Name Type Description
$name string
Returns
Type Description
bool
methodpublicsetCache( string $name, \Zend_Cache_Core $cache ) : \Zend_Cache_Manager

Set a new cache for the Cache Manager to contain

Parameters
Name Type Description
$name string
$cache \Zend_Cache_Core
Returns
Type Description
\Zend_Cache_Manager
methodpublicsetCacheTemplate( string $name, array $options ) : \Zend_Cache_Manager

Set a named configuration template from which a cache object can later be lazy loaded

Parameters
Name Type Description
$name string
$options array
Returns
Type Description
\Zend_Cache_Manager
methodpublicsetTemplateOptions( string $name, array $options ) : \Zend_Cache_Manager

Pass an array containing changes to be applied to a named configuration template

Parameters
Name Type Description
$name string
$options array
Returns
Type Description
\Zend_Cache_Manager
Throws
Exception Description
\Zend_Cache_Exception for invalid options format or if option templates do not have $name
Documentation was generated by DocBlox 0.15.1.