HumHub Documentation (unofficial)

FilesystemCache
in package
implements CacheInterface

Implements a cache on the filesystem.

Tags
author

Andrew Tch andrew@noop.lv

Table of Contents

Interfaces

CacheInterface
Interface implemented by cache classes.

Constants

FORCE_BYTECODE_INVALIDATION  = 1

Properties

$directory  : mixed
$options  : mixed

Methods

__construct()  : mixed
generateKey()  : string
Generates a cache key for the given template class name.
getTimestamp()  : int
Returns the modification timestamp of a key.
load()  : void
Loads a template from the cache.
write()  : void
Writes the compiled template to cache.

Constants

FORCE_BYTECODE_INVALIDATION

public mixed FORCE_BYTECODE_INVALIDATION = 1

Properties

Methods

__construct()

public __construct(string $directory[, int $options = 0 ]) : mixed
Parameters
$directory : string
$options : int = 0

generateKey()

Generates a cache key for the given template class name.

public generateKey(string $name, string $className) : string
Parameters
$name : string
$className : string
Return values
string

getTimestamp()

Returns the modification timestamp of a key.

public getTimestamp(string $key) : int
Parameters
$key : string
Return values
int

load()

Loads a template from the cache.

public load(string $key) : void
Parameters
$key : string

write()

Writes the compiled template to cache.

public write(string $key, string $content) : void
Parameters
$key : string
$content : string

The template representation as a PHP class


        
On this page

Search results