Cache
final class Cache
| internal |
Caching of compiled templates.
Properties
| $directory | |||
| $autoRefresh |
Methods
void
string
generateFilePath(Engine $engine, string $name)
Returns the file path where compiled template will be cached.
static bool
isCacheFile(string $file)
No description
array
generateRefreshSignature(Engine $engine, string $name)
Returns values used to detect if cached template needs recompilation when autoRefresh is enabled.
Details
at line 30
void
loadOrCreate(Engine $engine, string $name)
Loads existing cache or compiles template if needed.
Uses file locking to ensure atomic operations and prevent race conditions.
at line 109
string
generateFilePath(Engine $engine, string $name)
Returns the file path where compiled template will be cached.
Different configurations produce different file paths.
at line 121
static bool
isCacheFile(string $file)
No description
at line 131
protected array
generateRefreshSignature(Engine $engine, string $name)
Returns values used to detect if cached template needs recompilation when autoRefresh is enabled.
Triggers recompilation when template code, Latte engine, or any extension changes.