HTMLPurifier_DefinitionCacheFactory
in package
Responsible for creating definition caches.
Table of Contents
Properties
- $caches : mixed
- $decorators : mixed
- $implementations : mixed
Methods
- addDecorator() : mixed
- Registers a decorator to add to all new cache objects
- create() : mixed
- Factory method that creates a cache object based on configuration
- instance() : HTMLPurifier_DefinitionCacheFactory
- Retrieves an instance of global definition cache factory.
- register() : mixed
- Registers a new definition cache object
- setup() : mixed
- Initialize default decorators
Properties
$caches
protected
mixed
$caches
= array('Serializer' => array())
Tags
$decorators
protected
mixed
$decorators
= array()
Tags
$implementations
protected
mixed
$implementations
= array()
Tags
Methods
addDecorator()
Registers a decorator to add to all new cache objects
public
addDecorator(HTMLPurifier_DefinitionCache_Decorator|string $decorator) : mixed
Parameters
- $decorator : HTMLPurifier_DefinitionCache_Decorator|string
-
An instance or the name of a decorator
create()
Factory method that creates a cache object based on configuration
public
create(string $type, HTMLPurifier_Config $config) : mixed
Parameters
- $type : string
-
Name of definitions handled by cache
- $config : HTMLPurifier_Config
-
Config instance
instance()
Retrieves an instance of global definition cache factory.
public
static instance([HTMLPurifier_DefinitionCacheFactory $prototype = null ]) : HTMLPurifier_DefinitionCacheFactory
Parameters
- $prototype : HTMLPurifier_DefinitionCacheFactory = null
Return values
HTMLPurifier_DefinitionCacheFactoryregister()
Registers a new definition cache object
public
register(string $short, string $long) : mixed
Parameters
- $short : string
-
Short name of cache object, for reference
- $long : string
-
Full class name of cache object, for construction
setup()
Initialize default decorators
public
setup() : mixed