So, I have third party library, which is a .jar file. There are some classes in that jar. The problem is, there is one bug in one class in that .jar. I know it because I can decompile the jar file, to look at the java code, which is I am pretty sure, that class is the source of my program bug.
The idea is, I delete the class and replace it with my own class, but I dont know how.
There are multiple ways to do this:
Try to use winrar. You can open your jar in it, explore the directory containing the class file. You can delete and add class files.
If you don't want to use winrar then do like this:
Extract the jar using this command
jar -xvf yourjar.jar
It will explode the jar. Delete the old class file and add your updated class file
Recreate the jar using the following command
jar -cvf yourjar.jar directoryofexploderjar/