public static function ProjectCollector::isCompatibleWithNextMajorDrupal in Upgrade Status 8.3
Checks constraint compatibility with the next major Drupal core version.
A customized version of Semver::satisfies(), since that only works for a == condition.
@paran string $constraints Composer compatible constraints from core_version_requirement or drupal/core requirement.
Return value
bool
3 calls to ProjectCollector::isCompatibleWithNextMajorDrupal()
- DeprecationAnalyzer::analyze in src/
DeprecationAnalyzer.php - Analyze the codebase of an extension including all its sub-components.
- ProjectCollector::collateExtensionsIntoProjects in src/
ProjectCollector.php - Finds topmost extension for each extension and keeps only that.
- ProjectCollector::collectProjects in src/
ProjectCollector.php - Collect projects of installed modules grouped by custom and contrib.
File
- src/
ProjectCollector.php, line 531
Class
- ProjectCollector
- Collects projects and their associated metadata collated for Upgrade Status.
Namespace
Drupal\upgrade_statusCode
public static function isCompatibleWithNextMajorDrupal(string $constraints) {
$version_parser = new VersionParser();
$provider = new Constraint('>=', $version_parser
->normalize(self::getDrupalCoreMajorVersion() + 1 . '.0.0'));
$parsed_constraints = $version_parser
->parseConstraints($constraints);
return $parsed_constraints
->matches($provider);
}