From 00d282324c7c7b2e01a8143e8d4f32d018b8a176 Mon Sep 17 00:00:00 2001 From: Thomas Lallement Date: Sat, 27 Oct 2012 18:46:31 +0300 Subject: [PATCH] Improve comments in ProfilerController --- .../Controller/ProfilerController.php | 30 ++++++++++++++----- 1 file changed, 22 insertions(+), 8 deletions(-) diff --git a/src/Symfony/Bundle/WebProfilerBundle/Controller/ProfilerController.php b/src/Symfony/Bundle/WebProfilerBundle/Controller/ProfilerController.php index 4c97fffcc525..d57f23072e1f 100644 --- a/src/Symfony/Bundle/WebProfilerBundle/Controller/ProfilerController.php +++ b/src/Symfony/Bundle/WebProfilerBundle/Controller/ProfilerController.php @@ -34,6 +34,15 @@ class ProfilerController private $templates; private $toolbarPosition; + /** + * Constructor. + * + * @param UrlGeneratorInterface $generator The Url Generator + * @param Profiler $profiler The profiler + * @param \Twig_Environment $twig The twig environment + * @param array $templates The templates + * @param string $toolbarPosition The toolbar position (top, bottom, normal, or null -- use the configuration) + */ public function __construct(UrlGeneratorInterface $generator, Profiler $profiler, \Twig_Environment $twig, array $templates, $toolbarPosition = 'normal') { $this->generator = $generator; @@ -46,7 +55,7 @@ public function __construct(UrlGeneratorInterface $generator, Profiler $profiler /** * Renders a profiler panel for the given token. * - * @param Request $request The HTTP request + * @param Request $request The current HTTP request * @param string $token The profiler token * * @return Response A Response instance @@ -115,7 +124,7 @@ public function purgeAction() /** * Imports token data. * - * @param Request $request + * @param Request $request The current HTTP Request * * @return Response A Response instance */ @@ -139,7 +148,7 @@ public function importAction(Request $request) /** * Displays information page. * - * @param string $about + * @param string $about The about message * * @return Response A Response instance */ @@ -155,7 +164,7 @@ public function infoAction($about) /** * Renders the Web Debug Toolbar. * - * @param Request $request The current Request + * @param Request $request The current HTTP Request * @param string $token The profiler token * @param string $position The toolbar position (top, bottom, normal, or null -- use the configuration) * @@ -203,7 +212,7 @@ public function toolbarAction(Request $request, $token, $position = null) /** * Renders the profiler search bar. * - * @param Request $request The current Request + * @param Request $request The current HTTP Request * * @return Response A Response instance */ @@ -237,8 +246,8 @@ public function searchBarAction(Request $request) /** * Search results. * - * @param Request $request The current Request - * @param string $token The token + * @param Request $request The current HTTP Request + * @param string $token The token * * @return Response A Response instance */ @@ -268,7 +277,7 @@ public function searchResultsAction(Request $request, $token) /** * Narrow the search bar. * - * @param Request $request The current Request + * @param Request $request The current HTTP Request * * @return Response A Response instance */ @@ -321,6 +330,11 @@ public function phpinfoAction() return new Response($phpinfo); } + /** + * Gets the Template Manager. + * + * @return TemplateManager The Template Manager + */ protected function getTemplateManager() { if (null === $this->templateManager) {