3

Using javap I can disassemble a java class into byte code. If I want to run this byte code, or a modified version of it, how do I do it? Please spare me the "don't bother" answers as I am doing this for educational reasons. I've googled and looked at other Stack Overflow questions but couldn't find an answer.

  • 2
    Do you want to recompile it? You can already run it. Do you mean you want to interpret the mnemonics directly? – Adam Goode Jul 10 '09 at 13:03
  • 2
    This question doesn't make sense. A java class /is/ byte code. javap is typically used to disassemble into human-readable assembly. – Matthew Flaschen Jul 10 '09 at 13:06

1 Answers1

0

You can use a java dis-assembler to produce java code you can compile (perhaps with some fixing of the code by hand)

You can then modify the code and re-compile it.

Peter Lawrey
  • 525,659
  • 79
  • 751
  • 1,130