How to Use decompilation tools and plug-ins to view the java *. class file source code and decompilation. class
Java Decompiler [java decompilation]: A decompilation tool is developed to conveniently view the *. class file source code. The following describes how to view the source code: Tools & plug-ins
1. JD-GUI
JD-GUI is displaying the java source code *. class FileGraphical interface tool. DownLoad JD-GUI-DownLoad
After downloading the tool, open the tool and drag the jar package to the display window to view the source code.
Example: View jd-gui.exe package source code through xUtils-2.6.14.jar tools:
However, IDE (Integrated Development Environment) is generally used for Development, such as Eclipse and android studio. IDE is generally rich in Plug-ins to facilitate development efficiency. If IDE still uses a graphical interface tool to view the jar package instead of the plug-in, this is quite drunk. Because I didn't know how to use the plug-in before, it took a long time to get drunk !! No culture is terrible! Computation: in the future, we will "explore more, engage more, and increase the breadth of knowledge! More research, more details, and more depth of knowledge !" . The following describes how to install plug-ins in Eclipse and android studio and view the *. class file of the jar package.
2. JD-Eclipse
(1) download the JD-Eclipse plug-in. After the download, open Eclipse and choose: Help --> Install New Software... --> add -- archive... to perform the following operations:
After installation, restart Eclipse and check the code of the *. class file.
ADD and Archive...
Select the plug-in to install:
Click next, and then restart Eclipse.
The effect is as follows:
3. JD-IntelliJ
JD-Intellij is a plug-in of IntelliJ IDEA. After this plug-in is installed, You can conveniently view the source code of the jar package. Download JD-Intellij
Take android studio as an example: it can be installed offline or online.
(1) offline installation steps:
A、download jd-intellij-0.6.zip;
B. Android studio File-> Settings...-> Plugins --> install plugin from disk .. import the downloaded plug-in.
C. Restart android studio.
(2) Online Installation
Android studio File-> Settings...-> Plugins --> Browse repositores .. search for JD-Intellij
After restarting studio, view the source code of the class file of the jar package:
References:
1. Java DeCompiler
2. Download and description of the plug-in. There are many plug-ins in it. Please download them for trial.
3. Install the JD-Eclipse plug-in Eclipse
4. Several useful tools are recommended.
I have some shortcomings and I want to correct them!