简体   繁体   中英

Android: Obtain Java source code from jar

I have a jar library that I use for my app and I want to make changes to the source code. After using JD-GUI to obtain the source code from the class files, I put the files in my project in Eclipse. But the source code contains many errors. For example, it says that the constructor does not exists, but the source code clearly has this constructor.

Please provide help. Thank you.

First thing, its never advised to change any built in jars which are provided for developers help.

Secondly, if you do want to make changes to it, use JD-GUI, take out the complete source code into a project, know the code, make the changes, compile the program to make sure all the dependencies before and after changes made, is ok so that no errors pop up. Take the class files from the project and form the new jar and use it.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM