class ChainCacheClearer implements CacheClearerInterface

ChainCacheClearer.

Properties

protected $clearers

Methods

__construct(array $clearers = [])

Constructs a new instance of ChainCacheClearer.

clear(string $cacheDir)

Clears any caches necessary.

add(CacheClearerInterface $clearer) deprecated

Adds a cache clearer to the aggregate.

Details

at line 30
__construct(array $clearers = [])

Constructs a new instance of ChainCacheClearer.

Parameters

array $clearers The initial clearers

at line 38
clear(string $cacheDir)

Clears any caches necessary.

Parameters

string $cacheDir The cache directory

at line 50
add(CacheClearerInterface $clearer) deprecated

deprecated since version 3.4, to be removed in 4.0, inject the list of clearers as a constructor argument instead.

Adds a cache clearer to the aggregate.

Parameters

CacheClearerInterface $clearer