1 | <?php |
||
19 | class Promise extends AbstractPromise |
||
20 | { |
||
21 | /** |
||
22 | * @var DeferredInterface |
||
23 | */ |
||
24 | private $deferred; |
||
25 | |||
26 | /** |
||
27 | * @param callable $exportResolve |
||
28 | * @param callable $exportReject |
||
29 | * @param callable $exportNotify |
||
30 | */ |
||
31 | public function __construct( |
||
48 | |||
49 | /** |
||
50 | * {@inheritdoc} |
||
51 | */ |
||
52 | public function then(callable $onFulfilled = null, callable $onRejected = null, callable $onNotify = null) |
||
56 | |||
57 | /** |
||
58 | * {@inheritdoc} |
||
59 | */ |
||
60 | public function done(callable $onFulfilled = null, callable $onRejected = null, callable $onNotify = null) |
||
64 | |||
65 | /** |
||
66 | * {@inheritdoc} |
||
67 | */ |
||
68 | public function state() |
||
72 | |||
73 | /** |
||
74 | * @param mixed $value |
||
75 | */ |
||
76 | protected function resolve($value = null) |
||
80 | |||
81 | /** |
||
82 | * @param mixed $reason |
||
83 | */ |
||
84 | protected function reject($reason = null) |
||
88 | |||
89 | /** |
||
90 | * @param mixed $state |
||
91 | */ |
||
92 | protected function notify($state = null) |
||
96 | } |
||
97 |