. */ namespace Doctrine\ORM\Cache; use Doctrine\ORM\Query\ResultSetMapping; /** * Defines the contract for caches capable of storing query results. * These caches should only concern themselves with storing the matching result ids. * * @since 2.5 * @author Fabio B. Silva */ interface QueryCache { /** * @return boolean */ public function clear(); /** * @param \Doctrine\ORM\Cache\QueryCacheKey $key * @param \Doctrine\ORM\Query\ResultSetMapping $rsm * @param array $result * * @return boolean */ public function put(QueryCacheKey $key, ResultSetMapping $rsm, array $result); /** * @param \Doctrine\ORM\Cache\QueryCacheKey $key * @param \Doctrine\ORM\Query\ResultSetMapping $rsm * * @return void */ public function get(QueryCacheKey $key, ResultSetMapping $rsm); /** * @return \Doctrine\ORM\Cache\Region */ public function getRegion(); }