Table of contents
Namespace: Com\Tecnick\Pdf\Font
interface FontSubsetCacheInterface
Source: src/FontSubsetCacheInterface.php:41
Optional cache contract for reusing TrueType font subset programs.
Implementations are injected into Output and consulted before the subsetting is performed. The cached value is the raw subset font program returned by Subset::getSubsetFont(), before any compression or encryption.
The library never evicts entries: expiration and size limits are up to the implementation.
Methods
get()
Return the cached subset font program for the given key, or null on miss.
public get(string $key): ?string
Parameters:
$key(string): Cache key identifying the font subset.
Returns: ?string
Source: src/FontSubsetCacheInterface.php:48
set()
Store the subset font program for the given key.
public set(string $key, string $subsetFont): void
Parameters:
$key(string): Cache key identifying the font subset.$subsetFont(string): Raw subset font program (uncompressed).