Class Disassembler
java.lang.Object
org.aspectj.org.eclipse.jdt.core.util.ClassFileBytesDisassembler
org.aspectj.org.eclipse.jdt.internal.core.util.Disassembler
Disassembler of .class files. It generates an output in the Writer that looks close to
the javap output.
-
Field Summary
Fields inherited from class org.aspectj.org.eclipse.jdt.core.util.ClassFileBytesDisassembler
COMPACT, DEFAULT, DETAILED, SYSTEM, WORKING_COPY
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptiondisassemble(byte[] classFileBytes, String lineSeparator)
Answers back the disassembled string of the classfile bytes using the default mode.disassemble(byte[] classFileBytes, String lineSeparator, int mode)
Answers back the disassembled string of the classfile bytes according to the mode.disassemble(IClassFileReader classFileReader, String lineSeparator)
disassemble(IClassFileReader classFileReader, String lineSeparator, int mode)
Answers back the disassembled string of the IClassFileReader according to the mode.static String
escapeString(String s)
Answers a readable short description of this disassembler
-
Constructor Details
-
Disassembler
public Disassembler()
-
-
Method Details
-
escapeString
-
disassemble
Description copied from class:ClassFileBytesDisassembler
Answers back the disassembled string of the classfile bytes using the default mode. This is an output quite similar to the javap tool, using DEFAULT mode.- Specified by:
disassemble
in classClassFileBytesDisassembler
- Parameters:
classFileBytes
- The bytes of the classfilelineSeparator
- the line separator to use.- Returns:
- the disassembled string of the IClassFileReader using the default mode.
- Throws:
ClassFormatException
- if the classfile bytes are ill-formed- See Also:
ClassFileBytesDisassembler.disassemble(byte[], java.lang.String)
-
disassemble
public String disassemble(byte[] classFileBytes, String lineSeparator, int mode) throws ClassFormatExceptionDescription copied from class:ClassFileBytesDisassembler
Answers back the disassembled string of the classfile bytes according to the mode. This is an output quite similar to the javap tool.- Specified by:
disassemble
in classClassFileBytesDisassembler
- Parameters:
classFileBytes
- The bytes of the classfilelineSeparator
- the line separator to use.mode
- the mode used to disassemble the IClassFileReader- Returns:
- the disassembled string of the IClassFileReader according to the mode
- Throws:
ClassFormatException
- if the classfile bytes are ill-formed- See Also:
ClassFileBytesDisassembler.disassemble(byte[], java.lang.String, int)
-
disassemble
-
disassemble
Answers back the disassembled string of the IClassFileReader according to the mode. This is an output quite similar to the javap tool.- Parameters:
classFileReader
- The classFileReader to be disassembledlineSeparator
- the line separator to use.mode
- the mode used to disassemble the IClassFileReader- Returns:
- the disassembled string of the IClassFileReader according to the mode
-
getDescription
Description copied from class:ClassFileBytesDisassembler
Answers a readable short description of this disassembler- Specified by:
getDescription
in classClassFileBytesDisassembler
- Returns:
- String - a string description of the disassembler
- See Also:
ClassFileBytesDisassembler.getDescription()
-