- Модуль: webdav
- Путь к файлу: ~/bitrix/modules/webdav/classes/iblock.php
- Класс: CWebDavIblock
- Вызов: CWebDavIblock::ClearCache
function ClearCache($path, $mode=false)
{
if ($mode == false)
{
if ($path == "section")
{
BXClearCache(true, $this->CACHE_PATH."root_section");
BXClearCache(true, $this->CACHE_PATH."section");
BXClearCache(true, $this->CACHE_PATH."sections_tree");
BXClearCache(true, $this->CACHE_PATH."nav_chain");
}
}
elseif ($mode == 'local')
{
foreach ($this->CACHE as $method=>$arCache)
{
if (!is_array($path))
$path = array($path);
foreach ($path as $v)
{
$cache_id = $this->_get_element_cacheID($v, true);
if (isset($this->CACHE[$method][$cache_id]))
unset($this->CACHE[$method][$cache_id]);
$cache_id = $this->_get_element_cacheID($v, false);
if (isset($this->CACHE[$method][$cache_id]))
unset($this->CACHE[$method][$cache_id]);
}
}
}
}