DONE
DONE = 16
Abstract implementation of a Handler.
$run : \Whoops\RunInterface
$inspector : \Whoops\Exception\Inspector
$templateHelper : \Whoops\Util\TemplateHelper
setRun(\Whoops\RunInterface $run) : void
\Whoops\RunInterface | $run |
setInspector(\Whoops\Exception\Inspector $inspector) : void
\Whoops\Exception\Inspector | $inspector |
addDataTableCallback(string $label, callable $callback)
Lazily adds an entry to the list of tables displayed in the table.
The supplied callback argument will be called when the error is rendered, it should produce a simple associative array. Any nested arrays will be flattened with print_r.
string | $label | |
callable | $callback | Callable returning an associative array |
If $callback is not callable
getDataTables(string|null $label = null) : array<mixed,array>|callable
Returns all the extra data tables registered with this handler.
Optionally accepts a 'label' parameter, to only return the data table under that label.
string|null | $label |
addEditor(string $identifier, string $resolver)
Adds an editor resolver, identified by a string name, and that may be a string path, or a callable resolver. If the callable returns a string, it will be set as the file reference's href attribute.
string | $identifier | |
string | $resolver |
** File not found : $run->addEditor('macvim', **
** File not found : $run->addEditor('remove-it', **
setEditor(string|callable $editor)
Set the editor to use to open referenced files, by a string identifier, or a callable that will be executed for every file reference, with a $file and $line argument, and should return a string.
string|callable | $editor |
If invalid argument identifier provided
** File not found : $run->setEditor(function($file, **
** File not found : $run->setEditor('sublime'); **
getEditorHref(string $filePath, integer $line) : string|boolean
Given a string file path, and an integer file line, executes the editor resolver and returns, if available, a string that may be used as the href property for that file reference.
string | $filePath | |
integer | $line |
If editor resolver does not return a string
getEditorAjax(string $filePath, integer $line) : boolean
Given a boolean if the editor link should act as an Ajax request. The editor must be a valid callable function/closure
string | $filePath | |
integer | $line |
If editor resolver does not return a boolean
None found |
None found |
setApplicationPaths(array $applicationPaths)
Set the application paths.
array | $applicationPaths |
None found |
setApplicationRootPath(string $applicationRootPath)
Set the application root path.
string | $applicationRootPath |
None found |
blacklist( $superGlobalName, $key)
blacklist a sensitive value within one of the superglobal arrays.
$superGlobalName | string the name of the superglobal array, e.g. '_GET' |
|
$key | string the key within the superglobal |
None found |
getRun() : \Whoops\RunInterface
None found |
getInspector() : \Whoops\Exception\Inspector
None found |
None found |
getExceptionFrames() : \Whoops\Exception\FrameCollection;
Get the stack trace frames of the exception that is currently being handled.
None found |
getExceptionCode() : string
Get the code of the exception that is currently being handled.
None found |
getEditor(string $filePath, integer $line) : array
Given a boolean if the editor link should act as an Ajax request. The editor must be a valid callable function/closure
string | $filePath | |
integer | $line |
None found |
getResource(string $resource) : string
Finds a resource, by its relative path, in all available search paths.
The search is performed starting at the last search path, and all the way back to the first, enabling a cascading-type system of overrides for all resources.
string | $resource |
If resource cannot be found in any of the available paths
None found |
masked( $superGlobal, $superGlobalName) : array
Checks all values within the given superGlobal array.
Blacklisted values will be replaced by a equal length string cointaining only '*' characters.
We intentionally dont rely on $GLOBALS as it depends on 'auto_globals_jit' php.ini setting.
$superGlobal | array One of the superglobal arrays |
|
$superGlobalName | string the name of the superglobal array, e.g. '_GET' |
$values without sensitive data
None found |