src/Graviton/AnalyticsBundle/Manager/ServiceManager.php
public function getData()
    {
        $serviceRoute = $this->requestStack->getCurrentRequest()
                                           ->get('service');

        // Locate the model definition
        $model = $this->getAnalyticModel($serviceRoute);

        $cacheTime = $model->getCacheTime();
        $cacheKey = $this->getCacheKey($model);

        //Cached data if configured
        if ($cacheTime &&
            !$this->requestStack->getCurrentRequest()->headers->has($this->skipCacheHeaderName) &&
            $cache = $this->cacheProvider->fetch($cacheKey)
        ) {
            return $cache;
        }

        $data = $this->analyticsManager->getData($model, $this->getServiceParameters($model));

        if ($cacheTime) {
            $this->cacheProvider->save($cacheKey, $data, $cacheTime);
        }

        return $data;
    }
public function getData()
    {
        $serviceRoute = $this->requestStack->getCurrentRequest()
                                           ->get('service');

        // Locate the model definition
        $model = $this->getAnalyticModel($serviceRoute);

        $cacheTime = $model->getCacheTime();
        $cacheKey = $this->getCacheKey($model);

        //Cached data if configured
        if ($cacheTime &&
            !$this->requestStack->getCurrentRequest()->headers->has($this->skipCacheHeaderName) &&
            $cache = $this->cacheProvider->fetch($cacheKey)
        ) {
            return $cache;
        }

        $data = $this->analyticsManager->getData($model, $this->getServiceParameters($model));

        if ($cacheTime) {
            $this->cacheProvider->save($cacheKey, $data, $cacheTime);
        }

        return $data;
    }
public function getData ( ) { $ serviceRoute = $ this -> requestStack -> getCurrentRequest ( ) -> get ( 'service' ) ; // Locate the model definition $ model = $ this -> getAnalyticModel ( $ serviceRoute ) ; $ cacheTime = $ model -> getCacheTime ( ) ; $ cacheKey = $ this -> getCacheKey ( $ model ) ; //Cached data if configured if ( $ cacheTime && ! $ this -> requestStack -> getCurrentRequest ( ) -> headers -> has ( $ this -> skipCacheHeaderName ) && $ cache = $ this -> cacheProvider -> fetch ( $ cacheKey ) ) { return $ cache ; } $ data = $ this -> analyticsManager -> getData ( $ model , $ this -> getServiceParameters ( $ model ) ) ; if ( $ cacheTime ) { $ this -> cacheProvider -> save ( $ cacheKey , $ data , $ cacheTime ) ; } return $ data ; }
Will map and find data for defined route

@return array
Will map and find data for defined route