Class ErrorHandler
Default error handler for PHPCap. PHPCap will call
the throwException method of this class when
an error occurs.
-
IU\PHPCap\ErrorHandler
implements
IU\PHPCap\ErrorHandlerInterface
Methods summary
public
|
+/-
throwException( string $message, integer $code, integer $connectionErrorNumber = null, integer $httpStatusCode = null, Throwable $previousException = null )
Throw an exception for the specified values.
Throw an exception for the specified values.
Parameters
- $message
- message describing the error that occurred.
- $code
- the error code.
- $connectionErrorNumber
the error number from the underlying connection used,
of null if no connection error occurred.
For example, if cURL is being used (the default) this will be the cURL error number
if a connection error occurs.
- $httpStatusCode
https status code, which would typcially be set if
an error occurs with the http response from the REDCap API.
- $previousException
the previous exception that occurred that
caused this exception, if any.
See
Implementation of
|
Constants inherited from IU\PHPCap\ErrorHandlerInterface
CA_CERTIFICATE_FILE_NOT_FOUND,
CA_CERTIFICATE_FILE_UNREADABLE,
CONNECTION_ERROR,
INPUT_FILE_ERROR,
INPUT_FILE_NOT_FOUND,
INPUT_FILE_UNREADABLE,
INVALID_ARGUMENT,
INVALID_URL,
JSON_ERROR,
OUTPUT_FILE_ERROR,
REDCAP_API_ERROR,
TOO_MANY_ARGUMENTS
|