Gc\Mvc\Service\CacheService::shouldCacheRequest PHP Method

shouldCacheRequest() protected method

Determine if we should cache the current request
protected shouldCacheRequest ( MvcEvent $e ) : boolean
$e Zend\Mvc\MvcEvent Mvc Event
return boolean
    protected function shouldCacheRequest(MvcEvent $e)
    {
        // Early break if page should not be cached
        $event = new CacheEvent(CacheEvent::EVENT_SHOULDCACHE, $this);
        $this->getEventManager()->trigger($event);
        if ($event->getAbort()) {
            return false;
        }
        if ($this->shouldCache($e)) {
            return true;
        }
        return false;
    }