Final Class Yiisoft\ErrorHandler\CompositeException
| Inheritance | Yiisoft\ErrorHandler\CompositeException » Exception |
|---|
Aggregate multiple exceptions into one.
Public Methods
Method Details
| public mixed __construct ( Throwable $first, Throwable $rest ) | ||
| $first | Throwable | |
| $rest | Throwable | |
public function __construct(
private readonly Throwable $first,
Throwable ...$rest,
) {
$this->rest = $rest;
parent::__construct($first->getMessage(), (int) $first->getCode(), $first);
}
| public Throwable getFirstException ( ) |
public function getFirstException(): Throwable
{
return $this->first;
}
| public Throwable[] getPreviousExceptions ( ) |
public function getPreviousExceptions(): array
{
return $this->rest;
}
Signup or Login in order to comment.