public function sitemap() { $class = $this->request->get('type'); $page = $this->request->get('id', 0); if (!in_array($class, $this->getSupportedTypes())) { throw new ActionNotFoundException($this); } $cache = new OutputCache('sitemap', $this->request->get('route')); if ($cache->isCached() && $cache->getAge() < 86400 && false) { return new RawResponse($cache->getData()); } $this->setCache($cache); $f = $this->getSelectFilter($class); $entries = array(); foreach ($this->getPage($class, $page, $f, $this->getClassFields($class)) as $row) { $entries[] = $this->getEntryData($class, $row); } return new ActionResponse('entries', $entries); }