PHP Класс Smarty_CacheResource_Newscoop

Наследование: extends Smarty_CacheResource_Custom
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
__construct ( )
populateTimestamp ( Smarty_Template_Cached $cached ) : void populate Cached Object with timestamp and exists from Resource
writeCachedContent ( Smarty_Internal_Template $_template, string $content ) : boolean Write the rendered template output to cache

Защищенные методы

Метод Описание
delete ( string $tpl_name, string $cache_id, string $compile_id, integer | null $exp_time ) : integer Delete content from cache
fetch ( string $id, string $tpl_name, string $cache_id, string $compile_id, string &$content, integer &$mtime, integer $cacheLifetime ) : void fetch cached content and its modification time from data source
save ( string $id, string $tpl_name, string $cache_id, string $compile_id, integer | null $exp_time, string $content, array $campsiteVector = [] ) : boolean Save content to cache

Описание методов

__construct() публичный Метод

public __construct ( )

delete() защищенный Метод

Delete content from cache
protected delete ( string $tpl_name, string $cache_id, string $compile_id, integer | null $exp_time ) : integer
$tpl_name string template name
$cache_id string cache id
$compile_id string compile id
$exp_time integer | null seconds till expiration time in seconds or null
Результат integer number of deleted caches

fetch() защищенный Метод

fetch cached content and its modification time from data source
protected fetch ( string $id, string $tpl_name, string $cache_id, string $compile_id, string &$content, integer &$mtime, integer $cacheLifetime ) : void
$id string unique cache content identifier
$tpl_name string template name
$cache_id string cache id
$compile_id string compile id
$content string cached content
$mtime integer cache modification timestamp (epoch)
$cacheLifetime integer cache lifetime in seconds
Результат void

populateTimestamp() публичный Метод

populate Cached Object with timestamp and exists from Resource
public populateTimestamp ( Smarty_Template_Cached $cached ) : void
$cached Smarty_Template_Cached
Результат void

save() защищенный Метод

Save content to cache
protected save ( string $id, string $tpl_name, string $cache_id, string $compile_id, integer | null $exp_time, string $content, array $campsiteVector = [] ) : boolean
$id string unique cache content identifier
$tpl_name string template name
$cache_id string cache id
$compile_id string compile id
$exp_time integer | null seconds till expiration or null
$content string content to cache
$campsiteVector array Newscoop's CampsiteVector for defining which page is being cached
Результат boolean success

writeCachedContent() публичный Метод

Write the rendered template output to cache
public writeCachedContent ( Smarty_Internal_Template $_template, string $content ) : boolean
$_template Smarty_Internal_Template template object
$content string content to cache
Результат boolean success