class ExceptionController
ExceptionController renders error or exception pages for a given FlattenException.
__construct(Environment $twig, bool $debug) | ||
Response | showAction(Request $request, FlattenException $exception, DebugLoggerInterface $logger = null) Converts an Exception to a Response. |
Environment | $twig | |
bool | $debug | Show error (false) or exception (true) pages by default |
Converts an Exception to a Response.
A "showException" request parameter can be used to force display of an error page (when set to false) or the exception page (when true). If it is not present, the "debug" value passed into the constructor will be used.
Request | $request | |
FlattenException | $exception | |
DebugLoggerInterface | $logger |
Response |
InvalidArgumentException | When the exception template does not exist |
© 2004–2017 Fabien Potencier
Licensed under the MIT License.
http://api.symfony.com/4.0/Symfony/Bundle/TwigBundle/Controller/ExceptionController.html