| 1 | <?php |
||
| 18 | trait MakesPromisesTrait |
||
| 19 | { |
||
| 20 | /** |
||
| 21 | * @var PromiseFactoryInterface |
||
| 22 | */ |
||
| 23 | private $promiseFactory; |
||
| 24 | |||
| 25 | /** |
||
| 26 | * @param callable $resolver |
||
| 27 | * @param callable|null $canceller |
||
| 28 | * |
||
| 29 | * @return PromiseInterface |
||
| 30 | */ |
||
| 31 | protected function createPromise(callable $resolver, callable $canceller = null) |
||
| 35 | |||
| 36 | /** |
||
| 37 | * @param PromiseFactoryInterface $promiseFactory |
||
| 38 | */ |
||
| 39 | public function setPromiseFactory($promiseFactory) |
||
| 43 | |||
| 44 | /** |
||
| 45 | * @return PromiseFactoryInterface |
||
| 46 | */ |
||
| 47 | public function getPromiseFactory() |
||
| 55 | } |
||
| 56 |