Jamm\Memory\MemcacheObject::save_TTL_table PHP Method

save_TTL_table() protected method

protected save_TTL_table ( array $table ) : void
$table array
return void
    protected function save_TTL_table($table)
    {
        if (!empty($table)) {
            $t = time();
            foreach ($table as $key => $ttl) {
                if ($ttl !== 0 && $ttl < $t) {
                    unset($table[$key]);
                }
            }
        }
        if (false === $this->memcache->set($this->ttl_table_name, $table, null, 0)) {
            $this->ReportError('memcache can not save ttl table', __LINE__);
        }
    }