Replace the default disk cache with PSR-16
masterBy default, imdbphp uses a disk cache in the ./cache folder. You can replace this with any PSR-16 (simple cache) implementation by passing the cache object to the constructor of any imdbphp class.
Note that only the \Imdb\Config::$cache_expire property (which defaults to 1 week) will be used by your custom cache.
$cache = new \Cache\Adapter\PHPArray\ArrayCachePool();
// Pass to TitleSearch
$search = new \Imdb\TitleSearch(null /* config */, null /* logger */, $cache);
$firstResultTitle = $search->search('The Matrix')[0];
// Pass to Title
$title = new \Imdb\Title(335266, null /* config */, null /* logger */, $cache);