use of org.gradle.api.internal.artifacts.ivyservice.ivyresolve.strategy.DefaultVersionComparator in project gradle by gradle.
the class DefaultMutableVersionConstraint method doStrict.
private void doStrict() {
// When strict version is used, we need to parse the preferred selector early, in order to compute its complement.
// Hopefully this shouldn't happen too often. If it happens to become a performance problem, we need to reconsider
// how we compute the "reject" clause
DefaultVersionSelectorScheme versionSelectorScheme = new DefaultVersionSelectorScheme(new DefaultVersionComparator());
VersionSelector preferredSelector = versionSelectorScheme.parseSelector(prefer);
VersionSelector rejectedSelector = versionSelectorScheme.complementForRejection(preferredSelector);
this.rejects.clear();
this.rejects.add(rejectedSelector.getSelector());
}
Aggregations