createOrGet(moduleVersion.getId(), moduleVersion.getSelectionReason(), moduleVersion.getComponentId());
}
public void resolvedConfiguration(ModuleVersionIdentifier id, Collection<? extends InternalDependencyResult> dependencies) {
for (InternalDependencyResult d : dependencies) {
DefaultResolvedComponentResult from = modules.get(id);
DependencyResult dependency;
if (d.getFailure() != null) {
dependency = dependencyResultFactory.createUnresolvedDependency(d.getRequested(), from, d.getReason(), d.getFailure());
} else {
DefaultResolvedComponentResult selected = modules.get(d.getSelected());
dependency = dependencyResultFactory.createResolvedDependency(d.getRequested(), from, selected);
selected.addDependent((ResolvedDependencyResult) dependency);
}
from.addDependency(dependency);
}
}