/** * @Web\Route("", name="_advanced_profiler") */ public function indexAction() { $this->init(); $tokens = $this->profiler->find(null, null, PHP_INT_MAX, null, null, null); /** @var Profile[] $profiles */ $profiles = []; foreach ($tokens as $token) { $profiles[] = $this->profiler->loadProfile($token['token']); } return $this->render('YchuAdvancedProfilerBundle:Default:index.html.twig', ['requests' => $profiles]); }
public function testFindWorksWithInvalidDates() { $profiler = new Profiler($this->storage); $this->assertCount(0, $profiler->find(null, null, null, null, 'some string', '')); }
public function testFindWorksWithStatusCode() { $profiler = new Profiler($this->storage); $this->assertCount(0, $profiler->find(null, null, null, null, null, null, '204')); }
/** * @param string $ip * @param string $url * @param int $limit * @param string $method * @param string $start * @param string $end * @return array */ public function find($ip = null, $url = null, $limit = null, $method = null, $start = null, $end = null) { $limit = $limit ?: $this->defaultLimit; return $this->profiler->find($ip, $url, $limit, $method, $start, $end); }