- /**
- * Gets a cache key from Criteria instance
- *
- * @param $criteriaInstance An instance of a Criteria class
- * @param $onlyKeys Only use these keys for a cache key
- * @return $cacheKey A cache key suitable for lookup/storage purposes
- */
- protected function getCacheKeyByCriteria (Criteria $criteriaInstance, array $onlyKeys = []) {
- // Generate it
- //* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('BASE-FRAMEWORK-SYSTEM: criteriaInstance=' . $criteriaInstance->__toString() . ',onlyKeys()=' . count($onlyKeys) . ' - CALLED!');
- $cacheKey = sprintf('%s@%s',
- $this->__toString(),
- $criteriaInstance->getCacheKey($onlyKeys)
- );
-
- // And return it
- //* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__, __LINE__)->debugOutput('BASE-FRAMEWORK-SYSTEM: cacheKey=' . $cacheKey . ' - EXIT!');
- return $cacheKey;
- }
-