← All changes
|
includes/sdk/google/guzzlehttp/promises/src/PromiseInterface.php
+7
-7
1.2.7
→
1.4.2
View file →
| @@ -1,8 +1,8 @@ | ||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | 3 | declare (strict_types=1); |
| 4 | -namespace Dudlewebs\WPMCS\GuzzleHttp\Promise; | |
| 4 | +namespace Dudlewebs\WPMCS\GCP\GuzzleHttp\Promise; | |
| 5 | 5 | |
| 6 | 6 | /** |
| 7 | 7 | * A promise represents the eventual result of an asynchronous operation. |
| 8 | 8 | * |
| @@ -23,9 +23,9 @@ | ||
| 23 | 23 | * |
| 24 | 24 | * @param callable $onFulfilled Invoked when the promise fulfills. |
| 25 | 25 | * @param callable $onRejected Invoked when the promise is rejected. |
| 26 | 26 | */ |
| 27 | - public function then(?callable $onFulfilled = null, ?callable $onRejected = null): PromiseInterface; | |
| 27 | + public function then(?callable $onFulfilled = null, ?callable $onRejected = null) : PromiseInterface; | |
| 28 | 28 | /** |
| 29 | 29 | * Appends a rejection handler callback to the promise, and returns a new |
| 30 | 30 | * promise resolving to the return value of the callback if it is called, |
| 31 | 31 | * or to its original fulfillment value if the promise is instead |
| @@ -32,9 +32,9 @@ | ||
| 32 | 32 | * fulfilled. |
| 33 | 33 | * |
| 34 | 34 | * @param callable $onRejected Invoked when the promise is rejected. |
| 35 | 35 | */ |
| 36 | - public function otherwise(callable $onRejected): PromiseInterface; | |
| 36 | + public function otherwise(callable $onRejected) : PromiseInterface; | |
| 37 | 37 | /** |
| 38 | 38 | * Get the state of the promise ("pending", "rejected", or "fulfilled"). |
| 39 | 39 | * |
| 40 | 40 | * The three states can be checked against the constants defined on |
| @@ -39,9 +39,9 @@ | ||
| 39 | 39 | * |
| 40 | 40 | * The three states can be checked against the constants defined on |
| 41 | 41 | * PromiseInterface: PENDING, FULFILLED, and REJECTED. |
| 42 | 42 | */ |
| 43 | - public function getState(): string; | |
| 43 | + public function getState() : string; | |
| 44 | 44 | /** |
| 45 | 45 | * Resolve the promise with the given value. |
| 46 | 46 | * |
| 47 | 47 | * @param mixed $value |
| @@ -47,9 +47,9 @@ | ||
| 47 | 47 | * @param mixed $value |
| 48 | 48 | * |
| 49 | 49 | * @throws \RuntimeException if the promise is already resolved. |
| 50 | 50 | */ |
| 51 | - public function resolve($value): void; | |
| 51 | + public function resolve($value) : void; | |
| 52 | 52 | /** |
| 53 | 53 | * Reject the promise with the given reason. |
| 54 | 54 | * |
| 55 | 55 | * @param mixed $reason |
| @@ -55,15 +55,15 @@ | ||
| 55 | 55 | * @param mixed $reason |
| 56 | 56 | * |
| 57 | 57 | * @throws \RuntimeException if the promise is already resolved. |
| 58 | 58 | */ |
| 59 | - public function reject($reason): void; | |
| 59 | + public function reject($reason) : void; | |
| 60 | 60 | /** |
| 61 | 61 | * Cancels the promise if possible. |
| 62 | 62 | * |
| 63 | 63 | * @see https://github.com/promises-aplus/cancellation-spec/issues/7 |
| 64 | 64 | */ |
| 65 | - public function cancel(): void; | |
| 65 | + public function cancel() : void; | |
| 66 | 66 | /** |
| 67 | 67 | * Waits until the promise completes if possible. |
| 68 | 68 | * |
| 69 | 69 | * Pass $unwrap as true to unwrap the result of the promise, either |