work with jar file before closing it
This commit is contained in:
@@ -55,9 +55,6 @@ public class Main {
|
||||
Enumeration<JarEntry> entries;
|
||||
try (var jarFile = new JarFile(URLDecoder.decode(cleanPath, StandardCharsets.UTF_8))) {
|
||||
entries = jarFile.entries();
|
||||
} catch (IOException e) {
|
||||
throw new RuntimeException("Kann JAR-Datei zwecks Reflection nicht öffnen:", e);
|
||||
}
|
||||
while (entries.hasMoreElements()) {
|
||||
JarEntry entry = entries.nextElement();
|
||||
if (entry.isDirectory()) {
|
||||
@@ -65,6 +62,9 @@ public class Main {
|
||||
}
|
||||
fileNames.add(entry.getName());
|
||||
}
|
||||
} catch (IOException e) {
|
||||
throw new RuntimeException("Kann JAR-Datei zwecks Reflection nicht öffnen:", e);
|
||||
}
|
||||
var increment = new AtomicInteger();
|
||||
return Collections.unmodifiableSortedMap(new TreeMap<>(
|
||||
fileNames.stream()
|
||||
|
||||
Reference in New Issue
Block a user