for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace SCI;
/**
* @license GNU GPL v2+
* @since 1.0
*
* @author mwjames
*/
class CacheKeyProvider {
* Update the version to force a recache for all items due to
* required changes
const VERSION = '1.2';
* @var string
private $cachePrefix = '';
* @param string $cachePrefix
public function setCachePrefix( $cachePrefix ) {
$this->cachePrefix = $cachePrefix;
}
* @param string $hash
* @return string
public function getCacheKeyForCitationReference( $hash ) {
return $this->cachePrefix . ':sci:ref:' . md5( $hash . self::VERSION );
public function getCacheKeyForReferenceList( $hash ) {
return $this->cachePrefix . ':sci:reflist:' . md5( $hash . self::VERSION );