D
D
dearname2015-02-17 17:13:21
Java
dearname, 2015-02-17 17:13:21

How to unpack jar project?

I have a jar file, I need to unpack it and already work with classes directly.
I'm importing into a JAVA project, but when the classes are opened, it says:
There is no source file attached to the class file AddressDAO.class.

Answer the question

In order to leave comments, you need to log in

6 answer(s)
O
one pavel, 2015-02-17
@onepavel

Rename .jar to .zip and extract

I
Igor Kalashnikov, 2015-02-19
@zo0m

jd.benow.ca
download the JD-GUI and open the .jar in it.
It will decompile and display the content beautifully. I often use it for assessment (otherwise it is often not clear what kind of codebase was uploaded to the server). Necessary thing.

V
Vitaly Drach, 2015-02-17
@rusitch

It has no sources, it can only be included as a library
You can take the IL disassembler of the Java code and try to restore the sources

N
Nikolai Pavlov, 2015-02-17
@gurinderu

jar -xvf archive name
However class files are compiled classes, you will need JAD to view them. Rarely in jar packages put source codes.

S
Shultc, 2015-02-17
@Shultc

If you have .jsp files inside, then just an archiver, and you can change what you want to change right inside.
If you have classes there, then they will be compiled, and you will need to sweat with them.

O
oktv, 2020-03-04
@oktv

I use this tool dst.in.ua/jarexp/index.html?l=ru. A very powerful thing. It allows not only unpacking, but also decompiling classes, searching for contents in files, and some files can even be edited right in the archive!

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question