I'm a beginner developer in java. Anyone knows a code how to extract some files from jar archive? Let's say I'm making a installer. I want to extract some files from the jar of my application.
3 Answers
The jar is just a zip file that contains all the .class files. Open it with any zip software and you can view and extract all the files.
Update
If you want to do unzipping in your Java code. Read this article: http://www.baeldung.com/java-compress-and-uncompress. after unzipping you can do normal file manipulation.
2 Comments
Mato Sustak
Yeah i know, but i wan't to do it in Java. Inside of my application that will extract it.
Ravenix
Ok, that wasn't clear from the question, I've updated my answer.