class Is
Hierarchy
- class \GuzzleHttp\Promise\Is
Expanded class hierarchy of Is
23 string references to 'Is'
- Assert::uniqueValues in vendor/
webmozart/ assert/ src/ Assert.php - Does non strict comparisons on the items, so ['3', 3] will not pass the assertion.
- AssertTypeSpecifyingExtensionHelper::trimName in vendor/
phpstan/ phpstan-phpunit/ src/ Type/ PHPUnit/ Assert/ AssertTypeSpecifyingExtensionHelper.php - ConditionalTypeForParameterNode::__toString in vendor/
phpstan/ phpdoc-parser/ src/ Ast/ Type/ ConditionalTypeForParameterNode.php - ConditionalTypeNode::__toString in vendor/
phpstan/ phpdoc-parser/ src/ Ast/ Type/ ConditionalTypeNode.php - ConfigValidator::validate in vendor/
composer/ composer/ src/ Composer/ Util/ ConfigValidator.php - Validates the config, and returns the result.
File
-
vendor/
guzzlehttp/ promises/ src/ Is.php, line 7
Namespace
GuzzleHttp\PromiseView source
final class Is {
/**
* Returns true if a promise is pending.
*/
public static function pending(PromiseInterface $promise) : bool {
return $promise->getState() === PromiseInterface::PENDING;
}
/**
* Returns true if a promise is fulfilled or rejected.
*/
public static function settled(PromiseInterface $promise) : bool {
return $promise->getState() !== PromiseInterface::PENDING;
}
/**
* Returns true if a promise is fulfilled.
*/
public static function fulfilled(PromiseInterface $promise) : bool {
return $promise->getState() === PromiseInterface::FULFILLED;
}
/**
* Returns true if a promise is rejected.
*/
public static function rejected(PromiseInterface $promise) : bool {
return $promise->getState() === PromiseInterface::REJECTED;
}
}
Members
Title Sort descending | Modifiers | Object type | Summary |
---|---|---|---|
Is::fulfilled | public static | function | Returns true if a promise is fulfilled. |
Is::pending | public static | function | Returns true if a promise is pending. |
Is::rejected | public static | function | Returns true if a promise is rejected. |
Is::settled | public static | function | Returns true if a promise is fulfilled or rejected. |