Class RejectionException
- Exception
- RuntimeException
- GuzzleHttp\Promise\RejectionException
- Namespace: GuzzleHttp\Promise
- Located at RejectionException.php
A special exception that is thrown when waiting on a rejected promise.
The reason value is available via the getReason() method.
Direct known subclasses
GuzzleHttp\Promise\AggregateException
,
GuzzleHttp\Promise\CancellationException
Methods Summary
- __construct ( mixed $reason, string $description = null )
-
getReason ( )
Returns the rejection reason.
Methods inherited from Exception
__toString()
,
__wakeup()
,
getCode()
,
getFile()
,
getLine()
,
getMessage()
,
getPrevious()
,
getTrace()
,
getTraceAsString()
Methods Details
__construct ( mixed $reason, string $description = null )
Parameters
mixed | $reason | Rejection reason. |
string | $description = null | Optional description |
Overrides
Exception::__construct
mixed getReason ( )
Returns the rejection reason.
Returns
mixed |