This is the code:
URL url = new URL("jar:file:/path/my.jar!/META-INF/file.txt"); File file = File.createTempFile("foo", ".txt"); file.deleteOnExit(); FileUtils.copyURLToFile(url, file); String txt = FileUtils.readFileToString(file);
Can I do the same with smaller lines of code?
source share