Package serp.bytecode.visitor
Class BCVisitor
java.lang.Object
serp.bytecode.visitor.BCVisitor
- Direct Known Subclasses:
PrettyPrintVisitor
Base class for visitors on a bytecode entity. The public
visit(serp.bytecode.visitor.VisitAcceptor)
method will traverse the object graph of the given entity, calling the
enter*
and exit*
methods as it visits each
object. The traversal is done depth-first. Subclasses should override
only the methods for visiting the entities they are interested in.
Whenever there is a general method (i.e. enter/exitEntry
) as
well as a more specific one (i.e. enter/exitStringEntry
), the
more general method will be called first, followed by a call on the correct
specific method. Most subclasses will override either the general or
specific cases, but not both.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
void
void
void
void
void
enterAttribute
(Attribute obj) void
enterBCClass
(BCClass obj) void
enterBCField
(BCField obj) void
enterBCMember
(BCMember obj) void
enterBCMethod
(BCMethod obj) void
void
void
void
void
void
void
void
void
void
void
void
enterEntry
(Entry obj) void
void
void
void
void
void
void
void
void
void
void
enterIntEntry
(IntEntry obj) void
void
void
void
void
void
void
void
void
void
void
enterLongEntry
(LongEntry obj) void
void
void
void
void
void
void
void
void
void
void
void
enterProject
(Project obj) void
void
void
void
void
void
void
void
enterSynthetic
(Synthetic obj) void
void
void
enterUTF8Entry
(UTF8Entry obj) void
void
exitAnnotation
(Annotation obj) void
void
void
void
void
exitAttribute
(Attribute obj) void
exitBCClass
(BCClass obj) void
exitBCField
(BCField obj) void
exitBCMember
(BCMember obj) void
exitBCMethod
(BCMethod obj) void
void
exitClassEntry
(ClassEntry obj) void
void
void
void
void
void
void
void
exitDeprecated
(Deprecated obj) void
void
void
void
exitExceptions
(Exceptions obj) void
exitFieldEntry
(FieldEntry obj) void
exitFloatEntry
(FloatEntry obj) void
void
void
void
exitInnerClass
(InnerClass obj) void
void
void
exitIntEntry
(IntEntry obj) void
void
void
void
exitLineNumber
(LineNumber obj) void
void
void
void
void
void
void
exitLongEntry
(LongEntry obj) void
void
void
void
void
void
void
void
void
void
void
void
exitProject
(Project obj) void
void
void
void
exitSourceFile
(SourceFile obj) void
void
void
void
exitSynthetic
(Synthetic obj) void
void
void
exitUTF8Entry
(UTF8Entry obj) void
void
visit
(VisitAcceptor obj) Visit the given entity.
-
Constructor Details
-
BCVisitor
public BCVisitor()
-
-
Method Details
-
visit
Visit the given entity. -
enterProject
-
exitProject
-
enterBCClass
-
exitBCClass
-
enterBCMember
-
exitBCMember
-
enterBCField
-
exitBCField
-
enterBCMethod
-
exitBCMethod
-
enterAttribute
-
exitAttribute
-
enterConstantValue
-
exitConstantValue
-
enterDeprecated
-
exitDeprecated
-
enterExceptions
-
exitExceptions
-
enterInnerClasses
-
exitInnerClasses
-
enterLineNumberTable
-
exitLineNumberTable
-
enterLocalVariableTable
-
exitLocalVariableTable
-
enterLocalVariableTypeTable
-
exitLocalVariableTypeTable
-
enterAnnotations
-
exitAnnotations
-
enterAnnotation
-
exitAnnotation
-
enterAnnotationProperty
-
exitAnnotationProperty
-
enterSourceFile
-
exitSourceFile
-
enterSynthetic
-
exitSynthetic
-
enterUnknownAttribute
-
exitUnknownAttribute
-
enterCode
-
exitCode
-
enterExceptionHandler
-
exitExceptionHandler
-
enterInnerClass
-
exitInnerClass
-
enterLineNumber
-
exitLineNumber
-
enterLocalVariable
-
exitLocalVariable
-
enterLocalVariableType
-
exitLocalVariableType
-
enterInstruction
-
exitInstruction
-
enterArrayLoadInstruction
-
exitArrayLoadInstruction
-
enterArrayStoreInstruction
-
exitArrayStoreInstruction
-
enterClassInstruction
-
exitClassInstruction
-
enterConstantInstruction
-
exitConstantInstruction
-
enterConvertInstruction
-
exitConvertInstruction
-
enterGetFieldInstruction
-
exitGetFieldInstruction
-
enterIIncInstruction
-
exitIIncInstruction
-
enterJumpInstruction
-
exitJumpInstruction
-
enterIfInstruction
-
exitIfInstruction
-
enterLoadInstruction
-
exitLoadInstruction
-
enterLookupSwitchInstruction
-
exitLookupSwitchInstruction
-
enterMathInstruction
-
exitMathInstruction
-
enterMethodInstruction
-
exitMethodInstruction
-
enterMultiANewArrayInstruction
-
exitMultiANewArrayInstruction
-
enterNewArrayInstruction
-
exitNewArrayInstruction
-
enterPutFieldInstruction
-
exitPutFieldInstruction
-
enterRetInstruction
-
exitRetInstruction
-
enterReturnInstruction
-
exitReturnInstruction
-
enterStackInstruction
-
exitStackInstruction
-
enterStoreInstruction
-
exitStoreInstruction
-
enterTableSwitchInstruction
-
exitTableSwitchInstruction
-
enterWideInstruction
-
exitWideInstruction
-
enterMonitorEnterInstruction
-
exitMonitorEnterInstruction
-
enterMonitorExitInstruction
-
exitMonitorExitInstruction
-
enterCmpInstruction
-
exitCmpInstruction
-
enterConstantPool
-
exitConstantPool
-
enterEntry
-
exitEntry
-
enterClassEntry
-
exitClassEntry
-
enterDoubleEntry
-
exitDoubleEntry
-
enterFieldEntry
-
exitFieldEntry
-
enterFloatEntry
-
exitFloatEntry
-
enterIntEntry
-
exitIntEntry
-
enterInterfaceMethodEntry
-
exitInterfaceMethodEntry
-
enterLongEntry
-
exitLongEntry
-
enterMethodEntry
-
exitMethodEntry
-
enterNameAndTypeEntry
-
exitNameAndTypeEntry
-
enterStringEntry
-
exitStringEntry
-
enterUTF8Entry
-
exitUTF8Entry
-
enterInvokeDynamicEntry
-
exitInvokeDynamicEntry
-
enterMethodHandleEntry
-
exitMethodHandleEntry
-
enterMethodTypeEntry
-
exitMethodTypeEntry
-
enterBootstrapMethod
-
exitBootstrapMethod
-