public String getDescription() {
return null;
}
public String getName() {
ComponentSelector requested = dependency.getRequested();
ComponentSelector attempted = dependency.getAttempted();
if(requested.equals(attempted)) {
return requested.getDisplayName();
}
if(requested instanceof ModuleComponentSelector && attempted instanceof ModuleComponentSelector) {
ModuleComponentSelector requestedSelector = (ModuleComponentSelector)requested;
ModuleComponentSelector attemptedSelector = (ModuleComponentSelector)attempted;
if(requestedSelector.getGroup().equals(attemptedSelector.getGroup())
&& requestedSelector.getModule().equals(attemptedSelector.getModule())
&& !requestedSelector.getVersion().equals(attemptedSelector.getVersion())) {
return requested.getDisplayName() + " -> " + ((ModuleComponentSelector) attempted).getVersion();
}
}
return requested.getDisplayName() + " -> " + attempted.getDisplayName();
}