Reference documentation and code samples for the Stackdriver Error Reporting Client class Bootstrap.
Static methods for bootstrapping Stackdriver Error Reporting.
Methods
prependFileLocation
Return the full path of the prepend file.
Returns | |
---|---|
Type | Description |
string |
init
Register hooks for error reporting.
Parameter | |
---|---|
Name | Description |
psrLogger |
Google\Cloud\Logging\PsrLogger
|
Returns | |
---|---|
Type | Description |
void |
getErrorPrefix
Return a string prefix for the given error level.
Parameter | |
---|---|
Name | Description |
level |
int
|
Returns | |
---|---|
Type | Description |
string | A string prefix for reporting the error. |
getErrorLevelString
Return an error level string for the given PHP error level.
Parameter | |
---|---|
Name | Description |
level |
int
|
Returns | |
---|---|
Type | Description |
string | An error level string. |
exceptionHandler
Parameter | |
---|---|
Name | Description |
ex |
mixed
\Throwable (PHP 7) or \Exception (PHP 5) |
errorHandler
Parameters | |
---|---|
Name | Description |
level |
int
The error level. |
message |
string
The error message. |
file |
string
The filename that the error was raised in. |
line |
int
The line number that the error was raised at. |
shutdownHandler
Called at exit, to check there's a fatal error and report the error if any.
Constants
DEFAULT_LOGNAME
Value: 'app-error'