throw new MissingDependencyException("Unable to download dependency "+artifact);
}
if(monitor != null) {
monitor.setTotalBytes(-1); // Just to be sure
}
URL repository = (URL) list.removeFirst();
URL url = artifact == null ? repository : getURL(artifact, repository);
log.debug("Attempting to download "+artifact+" from "+url);
in = connect(url, username, password, monitor);
if(in != null) {
return new OpenResult(artifact, in, monitor == null ? -1 : monitor.getTotalBytes());