Package com.strobel.decompiler.languages
Class BytecodeLanguage.InstructionPrinter
java.lang.Object
com.strobel.decompiler.languages.BytecodeLanguage.InstructionPrinter
- All Implemented Interfaces:
InstructionVisitor
- Enclosing class:
BytecodeLanguage
private static final class BytecodeLanguage.InstructionPrinter
extends Object
implements InstructionVisitor
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final MethodBody
private int
private final int[]
private final ITextOutput
private final DecompilerSettings
private static final String
private static final int
private static final String[]
Fields inherited from interface com.strobel.assembler.ir.InstructionVisitor
EMPTY
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprivate
InstructionPrinter
(ITextOutput output, MethodDefinition method, DecompilerSettings settings, int[] lineNumbers) -
Method Summary
Modifier and TypeMethodDescriptionprivate VariableDefinition
findVariable
(OpCode op, int slot, int offset) private void
printOpCode
(OpCode opCode) void
visit
(Instruction instruction) void
void
visitBranch
(OpCode op, Instruction target) void
visitConstant
(OpCode op, double value) void
visitConstant
(OpCode op, float value) void
visitConstant
(OpCode op, int value) void
visitConstant
(OpCode op, long value) void
visitConstant
(OpCode op, MethodHandle value) void
visitConstant
(OpCode op, TypeReference value) void
visitConstant
(OpCode op, String value) void
visitDynamicCallSite
(OpCode op, DynamicCallSite callSite) void
visitEnd()
void
visitField
(OpCode op, FieldReference field) void
visitLabel
(Label label) void
visitMethod
(OpCode op, MethodReference method) void
visitSwitch
(OpCode op, SwitchInfo switchInfo) void
visitType
(OpCode op, TypeReference type) void
visitVariable
(OpCode op, VariableReference variable) void
visitVariable
(OpCode op, VariableReference variable, int operand)
-
Field Details
-
MAX_OPCODE_LENGTH
private static final int MAX_OPCODE_LENGTH -
OPCODE_NAMES
-
LINE_NUMBER_CODE
- See Also:
-
_settings
-
_output
-
_body
-
_lineNumbers
private final int[] _lineNumbers -
_currentOffset
private int _currentOffset
-
-
Constructor Details
-
InstructionPrinter
private InstructionPrinter(ITextOutput output, MethodDefinition method, DecompilerSettings settings, int[] lineNumbers)
-
-
Method Details
-
printOpCode
-
visit
- Specified by:
visit
in interfaceInstructionVisitor
-
visit
- Specified by:
visit
in interfaceInstructionVisitor
-
findVariable
-
visitConstant
- Specified by:
visitConstant
in interfaceInstructionVisitor
-
visitConstant
- Specified by:
visitConstant
in interfaceInstructionVisitor
-
visitConstant
- Specified by:
visitConstant
in interfaceInstructionVisitor
-
visitConstant
- Specified by:
visitConstant
in interfaceInstructionVisitor
-
visitConstant
- Specified by:
visitConstant
in interfaceInstructionVisitor
-
visitConstant
- Specified by:
visitConstant
in interfaceInstructionVisitor
-
visitConstant
- Specified by:
visitConstant
in interfaceInstructionVisitor
-
visitBranch
- Specified by:
visitBranch
in interfaceInstructionVisitor
-
visitVariable
- Specified by:
visitVariable
in interfaceInstructionVisitor
-
visitVariable
- Specified by:
visitVariable
in interfaceInstructionVisitor
-
visitType
- Specified by:
visitType
in interfaceInstructionVisitor
-
visitMethod
- Specified by:
visitMethod
in interfaceInstructionVisitor
-
visitDynamicCallSite
- Specified by:
visitDynamicCallSite
in interfaceInstructionVisitor
-
visitField
- Specified by:
visitField
in interfaceInstructionVisitor
-
visitLabel
- Specified by:
visitLabel
in interfaceInstructionVisitor
-
visitSwitch
- Specified by:
visitSwitch
in interfaceInstructionVisitor
-
visitEnd
public void visitEnd()- Specified by:
visitEnd
in interfaceInstructionVisitor
-