Package net.bytebuddy.build
Class AccessControllerPlugin.AccessControlWrapper.PrefixingMethodVisitor
java.lang.Object
org.objectweb.asm.MethodVisitor
net.bytebuddy.build.AccessControllerPlugin.AccessControlWrapper.PrefixingMethodVisitor
- Enclosing class:
AccessControllerPlugin.AccessControlWrapper
protected static class AccessControllerPlugin.AccessControlWrapper.PrefixingMethodVisitor
extends org.objectweb.asm.MethodVisitor
A method visitor to implement a weaved method to dispatch to an
java.security.AccessController
, if available.-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final Implementation.Context.FrameGeneration
Indicates the frame generation mode to apply.private final TypeDescription
The instrumented type.private final String
The name of the field.private final int
The base offset of the weaved method.private final MethodDescription.SignatureToken
The target signature of the method declared by the JVM access controller.Fields inherited from class org.objectweb.asm.MethodVisitor
api, mv
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotected
PrefixingMethodVisitor
(org.objectweb.asm.MethodVisitor methodVisitor, TypeDescription instrumentedType, MethodDescription.SignatureToken token, String name, int offset, Implementation.Context.FrameGeneration frameGeneration) Creates a new prefixing method visitor. -
Method Summary
Methods inherited from class org.objectweb.asm.MethodVisitor
getDelegate, visitAnnotableParameterCount, visitAnnotation, visitAnnotationDefault, visitAttribute, visitEnd, visitFieldInsn, visitFrame, visitIincInsn, visitInsn, visitInsnAnnotation, visitIntInsn, visitInvokeDynamicInsn, visitJumpInsn, visitLabel, visitLdcInsn, visitLineNumber, visitLocalVariable, visitLocalVariableAnnotation, visitLookupSwitchInsn, visitMethodInsn, visitMethodInsn, visitMultiANewArrayInsn, visitParameter, visitParameterAnnotation, visitTableSwitchInsn, visitTryCatchAnnotation, visitTryCatchBlock, visitTypeAnnotation, visitTypeInsn, visitVarInsn
-
Field Details
-
instrumentedType
The instrumented type. -
token
The target signature of the method declared by the JVM access controller. -
name
The name of the field. -
offset
private final int offsetThe base offset of the weaved method. -
frameGeneration
Indicates the frame generation mode to apply.
-
-
Constructor Details
-
PrefixingMethodVisitor
protected PrefixingMethodVisitor(org.objectweb.asm.MethodVisitor methodVisitor, TypeDescription instrumentedType, MethodDescription.SignatureToken token, String name, int offset, Implementation.Context.FrameGeneration frameGeneration) Creates a new prefixing method visitor.- Parameters:
methodVisitor
- The method visitor to write to.instrumentedType
- The instrumented type.token
- The target signature of the method declared by the JVM access controller.name
- The name of the field.offset
- The base offset of the instrumented method.frameGeneration
- Indicates the frame generation mode to apply.
-
-
Method Details
-
visitCode
public void visitCode()- Overrides:
visitCode
in classorg.objectweb.asm.MethodVisitor
-
visitMaxs
public void visitMaxs(int stackSize, int localVariableLength) - Overrides:
visitMaxs
in classorg.objectweb.asm.MethodVisitor
-