926fd37548ece764faa7e0e87432.php 8.5KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203
  1. <?php
  2. /* WebProfilerBundle:Collector:events.html.twig */
  3. class __TwigTemplate_ca6c926fd37548ece764faa7e0e87432 extends Twig_Template
  4. {
  5. protected $parent;
  6. public function __construct(Twig_Environment $env)
  7. {
  8. parent::__construct($env);
  9. $this->parent = array();
  10. $this->blocks = array(
  11. 'menu' => array($this, 'block_menu'),
  12. 'panel' => array($this, 'block_panel'),
  13. );
  14. }
  15. public function getParent(array $context)
  16. {
  17. $parent = "WebProfilerBundle:Profiler:layout.html.twig";
  18. if ($parent instanceof Twig_Template) {
  19. $name = $parent->getTemplateName();
  20. $this->parent[$name] = $parent;
  21. $parent = $name;
  22. } elseif (!isset($this->parent[$parent])) {
  23. $this->parent[$parent] = $this->env->loadTemplate($parent);
  24. }
  25. return $this->parent[$parent];
  26. }
  27. protected function doDisplay(array $context, array $blocks = array())
  28. {
  29. $context = array_merge($this->env->getGlobals(), $context);
  30. // line 3
  31. $context['__internal_ca6c926fd37548ece764faa7e0e87432_1'] = $this;
  32. $this->getParent($context)->display($context, array_merge($this->blocks, $blocks));
  33. }
  34. // line 5
  35. public function block_menu($context, array $blocks = array())
  36. {
  37. // line 6
  38. echo "<span class=\"label\">
  39. <span class=\"icon\"><img src=\"";
  40. // line 7
  41. echo twig_escape_filter($this->env, $this->env->getExtension('assets')->getAssetUrl("bundles/webprofiler/images/profiler/events.png"), "html");
  42. echo "\" alt=\"Events\" /></span>
  43. <strong>Events</strong>
  44. </span>
  45. ";
  46. }
  47. // line 12
  48. public function block_panel($context, array $blocks = array())
  49. {
  50. // line 13
  51. echo " <h2>Called Listeners</h2>
  52. <table>
  53. <tr>
  54. <th>Event name</th>
  55. <th>Listener</th>
  56. </tr>
  57. ";
  58. // line 20
  59. $context['_parent'] = (array) $context;
  60. $context['_seq'] = twig_ensure_traversable($this->getAttribute($this->getContext($context, 'collector'), "calledlisteners", array(), "any", false));
  61. foreach ($context['_seq'] as $context['_key'] => $context['listener']) {
  62. // line 21
  63. echo " <tr>
  64. <td><code>";
  65. // line 22
  66. echo twig_escape_filter($this->env, $this->getAttribute($this->getContext($context, 'listener'), "event", array(), "any", false), "html");
  67. echo "</code></td>
  68. <td><code>";
  69. // line 23
  70. echo twig_escape_filter($this->env, $this->getAttribute($context['__internal_ca6c926fd37548ece764faa7e0e87432_1'], "display_listener", array($this->getContext($context, 'listener'), ), "method", false), "html");
  71. echo "</code></td>
  72. </tr>
  73. ";
  74. }
  75. $_parent = $context['_parent'];
  76. unset($context['_seq'], $context['_iterated'], $context['_key'], $context['listener'], $context['_parent'], $context['loop']);
  77. $context = array_merge($_parent, array_intersect_key($context, $_parent));
  78. // line 26
  79. echo " </table>
  80. ";
  81. // line 28
  82. if ($this->getAttribute($this->getContext($context, 'collector'), "notcalledlisteners", array(), "any", false)) {
  83. // line 29
  84. echo " <h2>Not Called Listeners</h2>
  85. <table>
  86. <tr>
  87. <th>Event name</th>
  88. <th>Listener</th>
  89. </tr>
  90. ";
  91. // line 36
  92. $context['listeners'] = $this->getAttribute($this->getContext($context, 'collector'), "notcalledlisteners", array(), "any", false);
  93. // line 37
  94. echo " ";
  95. $context['_parent'] = (array) $context;
  96. $context['_seq'] = twig_ensure_traversable(twig_sort_filter(twig_get_array_keys_filter($this->getContext($context, 'listeners'))));
  97. foreach ($context['_seq'] as $context['_key'] => $context['listener']) {
  98. // line 38
  99. echo " <tr>
  100. <td><code>";
  101. // line 39
  102. echo twig_escape_filter($this->env, $this->getAttribute($this->getAttribute($this->getContext($context, 'listeners'), $this->getContext($context, 'listener'), array(), "array", false), "event", array(), "any", false), "html");
  103. echo "</code></td>
  104. <td><code>";
  105. // line 40
  106. echo twig_escape_filter($this->env, $this->getAttribute($context['__internal_ca6c926fd37548ece764faa7e0e87432_1'], "display_listener", array($this->getAttribute($this->getContext($context, 'listeners'), $this->getContext($context, 'listener'), array(), "array", false), ), "method", false), "html");
  107. echo "</code></td>
  108. </tr>
  109. ";
  110. }
  111. $_parent = $context['_parent'];
  112. unset($context['_seq'], $context['_iterated'], $context['_key'], $context['listener'], $context['_parent'], $context['loop']);
  113. $context = array_merge($_parent, array_intersect_key($context, $_parent));
  114. // line 43
  115. echo " </table>
  116. ";
  117. }
  118. }
  119. // line 47
  120. public function getdisplay_listener($listener = null)
  121. {
  122. $context = array_merge($this->env->getGlobals(), array(
  123. "listener" => $listener,
  124. ));
  125. ob_start();
  126. try {
  127. // line 48
  128. echo " ";
  129. if (($this->getAttribute($this->getContext($context, 'listener'), "type", array(), "any", false) == "Closure")) {
  130. // line 49
  131. echo " Closure
  132. ";
  133. } elseif (($this->getAttribute($this->getContext($context, 'listener'), "type", array(), "any", false) == "Function")) {
  134. // line 51
  135. echo " ";
  136. $context['link'] = $this->env->getExtension('code')->getFileLink($this->getAttribute($this->getContext($context, 'listener'), "file", array(), "any", false), $this->getAttribute($this->getContext($context, 'listener'), "line", array(), "any", false));
  137. // line 52
  138. echo " ";
  139. if ($this->getContext($context, 'link')) {
  140. echo "<a href=\"";
  141. echo twig_escape_filter($this->env, $this->getContext($context, 'link'), "html");
  142. echo "\">";
  143. echo twig_escape_filter($this->env, $this->getAttribute($this->getContext($context, 'listener'), "function", array(), "any", false), "html");
  144. echo "</a>";
  145. } else {
  146. echo twig_escape_filter($this->env, $this->getAttribute($this->getContext($context, 'listener'), "function", array(), "any", false), "html");
  147. }
  148. // line 53
  149. echo " ";
  150. } elseif (($this->getAttribute($this->getContext($context, 'listener'), "type", array(), "any", false) == "Method")) {
  151. // line 54
  152. echo " ";
  153. $context['link'] = $this->env->getExtension('code')->getFileLink($this->getAttribute($this->getContext($context, 'listener'), "file", array(), "any", false), $this->getAttribute($this->getContext($context, 'listener'), "line", array(), "any", false));
  154. // line 55
  155. echo " ";
  156. echo $this->env->getExtension('code')->abbrClass($this->getAttribute($this->getContext($context, 'listener'), "class", array(), "any", false));
  157. echo "::";
  158. if ($this->getContext($context, 'link')) {
  159. echo "<a href=\"";
  160. echo twig_escape_filter($this->env, $this->getContext($context, 'link'), "html");
  161. echo "\">";
  162. echo twig_escape_filter($this->env, $this->getAttribute($this->getContext($context, 'listener'), "method", array(), "any", false), "html");
  163. echo "</a>";
  164. } else {
  165. echo twig_escape_filter($this->env, $this->getAttribute($this->getContext($context, 'listener'), "method", array(), "any", false), "html");
  166. }
  167. // line 56
  168. echo " ";
  169. }
  170. } catch(Exception $e) {
  171. ob_end_clean();
  172. throw $e;
  173. }
  174. return ob_get_clean();
  175. }
  176. public function getTemplateName()
  177. {
  178. return "WebProfilerBundle:Collector:events.html.twig";
  179. }
  180. public function isTraitable()
  181. {
  182. return false;
  183. }
  184. }