SelectiveCacheInterface

Optional extension of CacheInterface for backends that only want to cache some of the cacheable subsystems (for example font subsets but not images).

Table of contents

Namespace: Com\Tecnick\Pdf\Cache

interface SelectiveCacheInterface extends CacheInterface

Extends: CacheInterface

Source: src/Cache/SelectiveCacheInterface.php:40

Optional extension of CacheInterface for backends that only want to cache some of the cacheable subsystems (for example font subsets but not images).

A plain CacheInterface is consulted for every cacheable subsystem. When an implementation also implements this interface, each subsystem is wired only when supports() returns true for its type; unsupported types are disabled and the cache is never queried nor written for them.

Methods

supports()

Whether this cache handles the given cacheable subsystem type.

public supports(CacheInterface::TYPE_* $type): bool

Parameters:

Returns: bool: True to enable caching for the type, false to disable it.

Source: src/Cache/SelectiveCacheInterface.php:49