* * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ namespace Symfony\Component\HttpKernel\DataCollector; use Symfony\Component\Debug\Exception\FlattenException; use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpFoundation\Response; /** * ExceptionDataCollector. * * @author Fabien Potencier */ class ExceptionDataCollector extends DataCollector { /** * {@inheritdoc} */ public function collect(Request $request, Response $response, \Exception $exception = null) { if (null !== $exception) { $this->data = array( 'exception' => FlattenException::create($exception), ); } } /** * {@inheritdoc} */ public function reset() { $this->data = array(); } /** * Checks if the exception is not null. * * @return bool true if the exception is not null, false otherwise */ public function hasException() { return isset($this->data['exception']); } /** * Gets the exception. * * @return \Exception The exception */ public function getException() { return $this->data['exception']; } /** * Gets the exception message. * * @return string The exception message */ public function getMessage() { return $this->data['exception']->getMessage(); } /** * Gets the exception code. * * @return int The exception code */ public function getCode() { return $this->data['exception']->getCode(); } /** * Gets the status code. * * @return int The status code */ public function getStatusCode() { return $this->data['exception']->getStatusCode(); } /** * Gets the exception trace. * * @return array The exception trace */ public function getTrace() { return $this->data['exception']->getTrace(); } /** * {@inheritdoc} */ public function getName() { return 'exception'; } } __halt_compiler();----SIGNATURE:----qlCb3R+Xqr3R4ny1LxH6cdqZ745aHkK3nJvMIY4d2/FWXShbn1F2nlsUDlx3D5x0iaYA7CuApmCKn0BbfMlixEkCE+usI5lfp3oIpuGGZajNr/zkrXRAidNOKrXF1BYouuadATkghb6tnPko5fSA5f7nGbC66NmMrC5RKNXtD0q5Q+ZvA2zk4SfiU9cjO2Ct9g73uMq8FX0rPHJzDgfSwM0Zp8xiZVULNEkBxOTfK/IEW4X5xTTB106cjXRvB1nlj6TMhIoc4PPdbEhWMObRieE4j0+q84OKaJe2Pq2sbp1h44Yl3IrqhPvC0Ib4QsAYO3vRFPepBMgRf3qvE2Vwgi16/qwWHw2bnhKl/DbVuP8T8eAovx8zG9RygRS2j+N/lokKFOrWIff2rBCOGehL75SpbHUKooE9wFEe9/wveHJ+6NU/iKuxiQGckdI6uZ34pVhL1gcuc+ukS8KVU9uLWKE3TJP58Gp4UYmI+fcPzpiVAjcDkTrKiXsqEkZytdP6DBlqOwwrM4EaEezxX8bNZX5bgKO92O8PRlLshAST8SBWQfcGLaD1SnOVEvVziW/UeeZvbuZswI2Sd2BIB5Yjtx1DjS387PK874FTTMPKXBJBQaD+/FjArjlPYXm2ADMY5luRcsuIEOCphyv9W3P1FjaeIs49+7+YsKTVp+Gj9yk=----ATTACHMENT:----Nzg4MzEwODUyOTE1MzIzOCA2Njk2MDUzOTIxNTk2MTQ5IDkzMTY0MDEyMTYzNDU1NTY=