class ErrorReport

Error reporting functions used to generate and submit error reports

Properties

Template $template

Methods

__construct(HttpRequest $httpRequest, Relation $relation, Template $template)

Constructor

void
setSubmissionUrl(string $submissionUrl)

Set the URL where to submit reports to

array
getData(string $exceptionType = 'js')

Returns the error report data collected from the current configuration or from the request parameters sent by the error reporting js code.

string|null|bool
send(array $report)

Sends report data to the error reporting server

string
getForm()

Generates the error report form to collect user description and preview the report before being sent

Details

at line 50
__construct(HttpRequest $httpRequest, Relation $relation, Template $template)

Constructor

Parameters

HttpRequest $httpRequest HttpRequest instance
Relation $relation Relation instance
Template $template Template instance

at line 63
void setSubmissionUrl(string $submissionUrl)

Set the URL where to submit reports to

Parameters

string $submissionUrl Submission URL

Return Value

void

at line 90
array getData(string $exceptionType = 'js')

Returns the error report data collected from the current configuration or from the request parameters sent by the error reporting js code.

Parameters

string $exceptionType whether exception is 'js' or 'php'

Return Value

array error report if success, Empty Array otherwise

at line 230
string|null|bool send(array $report)

Sends report data to the error reporting server

Parameters

array $report the report info to be sent

Return Value

string|null|bool the reply of the server

at line 272
string getForm()

Generates the error report form to collect user description and preview the report before being sent

Return Value

string the form