Package com.ibm.wala.shrikeBT
Class Disassembler
- java.lang.Object
-
- com.ibm.wala.shrikeBT.Disassembler
-
public class Disassembler extends Object
This is a very simple component to disassemble a ShrikeBT method. The disassembly is just the list of ShrikeBT instructions, annotated with exception handler blocks and the mapping back to the original bytecodes.
-
-
Constructor Summary
Constructors Constructor Description Disassembler(IInstruction[] instructions, ExceptionHandler[][] handlers, int[] instructionsToBytecodes)
Create a disassembler for a method.Disassembler(MethodData data)
Create a disassembler for a method.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
disassembleTo(Writer w)
Write the disassembly to a stream.void
disassembleTo(String prefix, Writer w)
Write the disassembly to a stream.
-
-
-
Constructor Detail
-
Disassembler
public Disassembler(IInstruction[] instructions, ExceptionHandler[][] handlers, int[] instructionsToBytecodes)
Create a disassembler for a method.
-
Disassembler
public Disassembler(MethodData data) throws NullPointerException
Create a disassembler for a method.- Throws:
NullPointerException
- if data is null
-
-
Method Detail
-
disassembleTo
public void disassembleTo(String prefix, Writer w) throws IOException
Write the disassembly to a stream. Each line is prefixed with 'prefix'.- Throws:
IOException
-
disassembleTo
public void disassembleTo(Writer w) throws IOException
Write the disassembly to a stream.- Throws:
IOException
-
-