public static function onEndBufferContent(&$content) { AppCacheManifest::getInstance()->generate($content); }
public static function checkObsoleteManifest() { $server = \Freetrix\Main\Context::getCurrent()->getServer(); $appCacheUrl = $server->get("HTTP_FX_APPCACHE_URL"); $appCacheParams = $server->get("HTTP_FX_APPCACHE_PARAMS"); if ($appCacheUrl) { $params = json_decode($appCacheParams, true); if (!is_array($params)) { $params = array(); } \Freetrix\Main\Data\AppCacheManifest::clear($appCacheUrl, $params); } }
/** * Gets useAppCache property * @return bool */ public function getUseAppCache() { $appCache = \Freetrix\Main\Data\AppCacheManifest::getInstance(); return $appCache->isEnabled(); }