\Smarty_CacheResource_Mysql

Summary

Methods
Properties
Constants
No public methods found
No public properties found
No constants found
fetch()
fetchTimestamp()
save()
delete()
No protected properties found
N/A
No private methods found
No private properties found
N/A

Methods

fetch()

fetch(string  $id, string  $name, string  $cache_id, string  $compile_id, string  $content, integer  $mtime) : void

fetch cached content and its modification time from data source

Parameters

string $id

unique cache content identifier

string $name

template name

string $cache_id

cache id

string $compile_id

compile id

string $content

cached content

integer $mtime

cache modification timestamp (epoch)

fetchTimestamp()

fetchTimestamp(string  $id, string  $name, string  $cache_id, string  $compile_id) : integer|boolean

Fetch cached content's modification timestamp from data source

Parameters

string $id

unique cache content identifier

string $name

template name

string $cache_id

cache id

string $compile_id

compile id

Returns

integer|boolean —

timestamp (epoch) the template was modified, or false if not found

save()

save(string  $id, string  $name, string  $cache_id, string  $compile_id, integer|null  $exp_time, string  $content) : boolean

Save content to cache

Parameters

string $id

unique cache content identifier

string $name

template name

string $cache_id

cache id

string $compile_id

compile id

integer|null $exp_time

seconds till expiration time in seconds or null

string $content

content to cache

Returns

boolean —

success

delete()

delete(string  $name, string  $cache_id, string  $compile_id, integer|null  $exp_time) : integer

Delete content from cache

Parameters

string $name

template name

string $cache_id

cache id

string $compile_id

compile id

integer|null $exp_time

seconds till expiration or null

Returns

integer —

number of deleted caches