ILIAS
release_5-3 Revision v5.3.23-19-g915713cf615
◀ ilDoc Overview
CallbackHandler.php
Go to the documentation of this file.
1
<?php
7
namespace
Whoops\Handler
;
8
9
use
InvalidArgumentException
;
10
16
class
CallbackHandler
extends
Handler
17
{
21
protected
$callable
;
22
27
public
function
__construct
(
$callable
)
28
{
29
if
(!is_callable(
$callable
)) {
30
throw
new
InvalidArgumentException
(
31
'Argument to '
. __METHOD__ .
' must be valid callable'
32
);
33
}
34
35
$this->callable =
$callable
;
36
}
37
41
public
function
handle
()
42
{
43
$exception
= $this->
getException
();
44
$inspector
= $this->
getInspector
();
45
$run
= $this->
getRun
();
46
$callable
=
$this->callable
;
47
48
// invoke the callable directly, to get simpler stacktraces (in comparison to call_user_func).
49
// this assumes that $callable is a properly typed php-callable, which we check in __construct().
50
return
$callable
(
$exception
,
$inspector
,
$run
);
51
}
52
}
Whoops\Handler\Handler\$exception
$exception
Definition:
Handler.php:46
Whoops\Handler
Whoops - php errors for cool kids.
Definition:
CallbackHandler.php:7
Whoops\Handler\Handler\getRun
getRun()
Definition:
Handler.php:59
Whoops\Handler\Handler\getException
getException()
Definition:
Handler.php:91
Whoops\Handler\Handler\$run
$run
Definition:
Handler.php:36
Whoops\Handler\CallbackHandler\$callable
$callable
Definition:
CallbackHandler.php:21
Whoops\Handler\Handler\getInspector
getInspector()
Definition:
Handler.php:75
Whoops\Handler\Handler
Abstract implementation of a Handler.
Definition:
Handler.php:15
Whoops\Handler\CallbackHandler\__construct
__construct($callable)
Definition:
CallbackHandler.php:27
Whoops\Handler\CallbackHandler\handle
handle()
Definition:
CallbackHandler.php:41
Whoops\Handler\CallbackHandler
Wrapper for Closures passed as handlers.
Definition:
CallbackHandler.php:16
InvalidArgumentException
Whoops\Handler\Handler\$inspector
$inspector
Definition:
Handler.php:41
libs
composer
vendor
filp
whoops
src
Whoops
Handler
CallbackHandler.php
Generated on Sat Jan 18 2025 19:01:03 for ILIAS by
1.8.13 (using
Doxyfile
)