Lines 411-422
Link Here
|
411 |
if (file.isDirectory()) { |
411 |
if (file.isDirectory()) { |
412 |
findClassesInPathsDir(strPath, file, listClasses); |
412 |
findClassesInPathsDir(strPath, file, listClasses); |
413 |
} else if (file.exists()) { |
413 |
} else if (file.exists()) { |
414 |
ZipFile zipFile = new ZipFile(file); |
414 |
ZipFile zipFile = null; |
415 |
Enumeration entries = zipFile.entries(); |
415 |
try { |
416 |
while (entries.hasMoreElements()) { |
416 |
zipFile = new ZipFile(file); |
417 |
String strEntry = entries.nextElement().toString(); |
417 |
Enumeration entries = zipFile.entries(); |
418 |
if (strEntry.endsWith(DOT_CLASS)) { |
418 |
while (entries.hasMoreElements()) { |
419 |
listClasses.add(fixClassName(strEntry)); |
419 |
String strEntry = entries.nextElement().toString(); |
|
|
420 |
if (strEntry.endsWith(DOT_CLASS)) { |
421 |
listClasses.add(fixClassName(strEntry)); |
422 |
} |
423 |
} |
424 |
} catch (Exception e) { |
425 |
log.warn("Can not open the jar " + strPath); |
426 |
} |
427 |
finally { |
428 |
if(zipFile != null) { |
429 |
try {zipFile.close();} catch (Exception e) {} |
420 |
} |
430 |
} |
421 |
} |
431 |
} |
422 |
} |
432 |
} |