return mgr.getProgressIndicator();
}
public static Library findLibrary(final Project pProject, final Artifact pDependency) {
final LibraryTablesRegistrar libTableMgr = LibraryTablesRegistrar.getInstance();
final LibraryTable libTable = libTableMgr.getLibraryTable(pProject);
String libName = pDependency.toString();
Library lib = libTable.getLibraryByName(libName);
if (lib == null) {
String type = pDependency.getType();
if (type == null || type.trim().length() == 0)
type = "jar";
if (libName.endsWith("." + type)) {
final int newLength = libName.length() - 1 - type.length();
libName = libName.substring(0, newLength);
lib = libTable.getLibraryByName(libName);
}
}
return lib;
}