Package org.apache.drill.exec.compile
Class RetargetableClassVisitor
java.lang.Object
org.objectweb.asm.ClassVisitor
org.apache.drill.exec.compile.RetargetableClassVisitor
- Direct Known Subclasses:
DrillCheckClassAdapter
public class RetargetableClassVisitor
extends org.objectweb.asm.ClassVisitor
An ASM ClassVisitor that allows for a late-bound delegate.
The ClassVisitor constructor takes an optional ClassVisitor argument
to which all calls will be delegated. However, in some circumstances, ClassVisitor
derivatives may not be able to specify the delegate until after they have called
the ClassVisitor constructor themselves. In other words, they may not be able to
specify the delegate until *after* they have called super(). This version of the
ClassVisitor will support that via the use of the setDelegate(org.objectweb.asm.ClassVisitor)
method.
-
Field Summary
Fields inherited from class org.objectweb.asm.ClassVisitor
api, cv
-
Constructor Summary
ConstructorDescriptionRetargetableClassVisitor
(int api) SeeClassVisitor(int)
.RetargetableClassVisitor
(int api, org.objectweb.asm.ClassVisitor cv) SeeClassVisitor(int, ClassVisitor)
. -
Method Summary
Modifier and TypeMethodDescriptionprotected void
setDelegate
(org.objectweb.asm.ClassVisitor cv) Set the delegate for this ClassVisitor.Methods inherited from class org.objectweb.asm.ClassVisitor
getDelegate, visit, visitAnnotation, visitAttribute, visitEnd, visitField, visitInnerClass, visitMethod, visitModule, visitNestHost, visitNestMember, visitOuterClass, visitPermittedSubclass, visitRecordComponent, visitSource, visitTypeAnnotation
-
Constructor Details
-
RetargetableClassVisitor
public RetargetableClassVisitor(int api) SeeClassVisitor(int)
. -
RetargetableClassVisitor
public RetargetableClassVisitor(int api, org.objectweb.asm.ClassVisitor cv) SeeClassVisitor(int, ClassVisitor)
.
-
-
Method Details
-
setDelegate
protected void setDelegate(org.objectweb.asm.ClassVisitor cv) Set the delegate for this ClassVisitor. Must be called before the visitor is used (i.e., before any other methods are called), and only once.- Parameters:
cv
- the ClassVisitor to delegate calls to
-