public interface IMethodBodyVisitor extends IVisitor
Modifier and Type | Method and Description |
---|---|
void |
labelCurrent(Label l)
Bind a Label object (not to be confused with the AVM OP_label
instruction) to the last-visited ABC instruction in this method.
|
void |
labelNext(Label l)
Bind a Label object (not to be confused with the AVM OP_label
instruction) to the next ABC instruction that gets visited in this method
|
void |
visit()
Begin processing a method body.
|
int |
visitException(Label from,
Label to,
Label target,
Name exceptionType,
Name catchVar)
Visit an exception handler.
|
void |
visitInstruction(Instruction instruction)
Vist an instruction
|
void |
visitInstruction(int opcode)
Visit an instruction with no operands.
|
void |
visitInstruction(int opcode,
int immediateOperand)
Visit an instruction with an immediate operand.
|
void |
visitInstruction(int opcode,
Object singleOperand)
Visit an instruction with a single operand (convenience method).
|
void |
visitInstruction(int opcode,
Object[] operands)
Visit an instruction.
|
void |
visitInstructionList(InstructionList newList)
Reset the method body's instruction list en bloc.
|
ITraitsVisitor |
visitTraits()
Visit the method body's traits (local variables).
|
void visit()
ITraitsVisitor visitTraits()
void visitInstructionList(InstructionList newList)
void visitInstruction(int opcode)
opcode
- - the instruction's opcode.void visitInstruction(int opcode, int immediateOperand)
opcode
- - the instruction's opcode.immediateOperand
- - the operand.void visitInstruction(int opcode, Object[] operands)
opcode
- - the instruction's opcode.operands
- - the instruction's operands.void visitInstruction(int opcode, Object singleOperand)
opcode
- - the instruction's opcode.singleOperand
- - the instruction's operand.void visitInstruction(Instruction instruction)
instruction
- the Instruction to visitint visitException(Label from, Label to, Label target, Name exceptionType, Name catchVar)
from
- - the label that starts the "try" region.to
- - the label that ends the "try" region.target
- - the "catch" target.exceptionType
- - the type of exception to be handled. "*" is valid
and handles any exception.catchVar
- - the name of the exception variable. May be null if no
exception variable is desired.void labelCurrent(Label l)
void labelNext(Label l)
Copyright © 2016 The Apache Software Foundation. All rights reserved.