protected function calculateChecksum(array
$tags) { $checksum = 0;
$query_tags =
array_diff($tags,
array_keys($this->tagCache
));
if ($query_tags) { $tag_invalidations =
$this->
getTagInvalidationCounts($query_tags);
$this->tagCache +=
$tag_invalidations;
// Fill static cache with empty objects for tags not found in the storage.
$this->tagCache +=
array_fill_keys(array_diff($query_tags,
array_keys($tag_invalidations)), 0
);
} foreach ($tags as $tag) { $checksum +=
$this->tagCache
[$tag];
} return $checksum;
}