if (locations != null) {
for (int i = 0; i < locations.length; i++) {
File mf = locations[i].getLocation().toFile();
try {
Jar jar = new Jar(mf.getName(), mf);
Verifier verifier = new Verifier(jar);
try {
verifier.verify();
if (verifier.getErrors().size()
+ verifier.getWarnings().size() > 0) {
List<String> info = new ArrayList<String>(verifier.getErrors());
info.addAll(verifier.getWarnings());
Activator.getDefault().error(info);
}
} finally {
jar.close();
verifier.close();
}
} catch (Exception e) {
Activator.getDefault().error(
"While verifying JAR " + locations[i], e);