How to listfiles() from jar in a tar by using truezip in Java?
问题 I am trying to list all files in a tar, including files in jar. How can I do this by using truezip in Java or other api? Thanks 回答1: Using TrueZIP 7, you could use something like this: public static void main(String args[]) throws IOException { // Remember to set to add the following dependencies to the class path: // Compile time artifactId(s): truezip-file // Run time artifactId(s): truezip-kernel, truezip-driver-file, truezip-driver-tar, truezip-driver-zip TFile.setDefaultArchiveDetector