done() публичный Метод

public done ( callable $onFulfilled = null, callable $onRejected = null ) : void
$onFulfilled callable
$onRejected callable
Результат void
Пример #1
0
 /**
  * Watches a promise and unwraps it if it is rejected.
  *
  * This method should be used on promises that have assertions inside of them
  * so that their assertions bubble up and are caught by PHPUnit.
  *
  * @param ExtendedPromiseInterface $promise The promise to watch.
  */
 public final function watchPromise(ExtendedPromiseInterface $promise)
 {
     $promise->done(null, function (\Exception $exception) {
         $this->exceptionQueue->enqueue($exception);
     });
 }