1 | <?php |
||
13 | class Handler implements ExceptionHandlerContract |
||
14 | { |
||
15 | protected $parentHandler; |
||
16 | |||
17 | public function __construct(ExceptionHandlerContract $parentHandler) |
||
21 | |||
22 | /** |
||
23 | * Report or log an exception. |
||
24 | * |
||
25 | * @param \Exception $exception |
||
26 | * |
||
27 | * @return void |
||
28 | * @throws \Exception |
||
29 | */ |
||
30 | public function report(Exception $exception) |
||
34 | |||
35 | /** |
||
36 | * Render an exception into a response. |
||
37 | * |
||
38 | * @param \Illuminate\Http\Request $request |
||
39 | * @param \Exception $exception |
||
40 | * |
||
41 | * @return \Symfony\Component\HttpFoundation\Response |
||
42 | */ |
||
43 | public function render($request, Exception $exception) |
||
61 | |||
62 | /** |
||
63 | * Render an exception to the console. |
||
64 | * |
||
65 | * @param \Symfony\Component\Console\Output\OutputInterface $output |
||
66 | * @param \Exception $exception |
||
67 | * |
||
68 | * @return void |
||
69 | */ |
||
70 | public function renderForConsole($output, Exception $exception) |
||
74 | |||
75 | /** |
||
76 | * Prepare exception for rendering. |
||
77 | * |
||
78 | * @param \Exception $exception |
||
79 | * |
||
80 | * @return \Exception |
||
81 | */ |
||
82 | protected function prepareException(Exception $exception) |
||
92 | |||
93 | /** |
||
94 | * Convert an authentication exception into an unauthenticated response. |
||
95 | * |
||
96 | * @param \Illuminate\Http\Request $request |
||
97 | * @param \Illuminate\Auth\AuthenticationException $exception |
||
98 | * |
||
99 | * @return \Illuminate\Http\Response |
||
100 | */ |
||
101 | protected function unauthenticated($request, AuthenticationException $exception) |
||
111 | |||
112 | /** |
||
113 | * Render the given HttpException. |
||
114 | * |
||
115 | * @param \Illuminate\Http\Request $request |
||
116 | * @param \Symfony\Component\HttpKernel\Exception\HttpException $exception |
||
117 | * |
||
118 | * @return \Symfony\Component\HttpFoundation\Response |
||
119 | */ |
||
120 | protected function renderHttpException($request, HttpException $exception) |
||
130 | |||
131 | protected function isAdmin($request) |
||
135 | |||
136 | /** |
||
137 | * @param \Illuminate\Http\Request $request |
||
138 | * @param \Sco\Admin\Exceptions\AdminException $exception |
||
139 | * |
||
140 | * @return \Illuminate\Contracts\Routing\ResponseFactory|\Symfony\Component\HttpFoundation\Response |
||
141 | */ |
||
142 | protected function renderAdminException($request, AdminException $exception) |
||
148 | } |
||
149 |
This check looks from parameters that have been defined for a function or method, but which are not used in the method body.