Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.codehaus.aspectwerkz.transform.inlining.weaver
Class MethodCallVisitor

    java.lang.Object
      org.objectweb.asm.ClassAdapter
          org.codehaus.aspectwerkz.transform.inlining.weaver.MethodCallVisitor

All Implemented Interfaces:
  TransformationConstants, org.objectweb.asm.ClassVisitor, org.objectweb.asm.Constants

    public class MethodCallVisitor

extends org.objectweb.asm.ClassAdapter
implements TransformationConstants

Instruments method CALL join points by replacing INVOKEXXX instructions with invocations of the compiled join point.
It calls the JPClass.invoke static method. The signature of the invoke method depends if the target method is static or not as follow:

          invoke(callee, args.., caller) // non static
          invoke(args.., caller) // static

(The reason why is that it simplifies call pointcut stack management)

Author:
  Jonas Bonr , Alexandre Vasseur

Nested Class Summary
`class` | `MethodCallVisitor.ReplaceInvokeInstructionCodeAdapter` Replaces 'INVOKEXXX' instructions with a call to the compiled JoinPoint instance.

Field Summary

Fields inherited from class org.objectweb.asm.ClassAdapter
`cv`

Fields inherited from interface org.codehaus.aspectwerkz.transform.TransformationConstants
`ADD_META_DATA_METHOD_NAME, ADD_META_DATA_METHOD_SIGNATURE, ADVISABLE_CLASS_JAVA_NAME, ADVISABLE_CLASS_NAME, AFTER_ADVICE_ARRAY_CLASS_SIGNATURE, AFTER_ADVICE_CLASS_NAME, AFTER_ADVICE_INVOKE_METHOD_SIGNATURE, AFTER_INTERCEPTORS_FIELD_NAME, AFTER_RETURNING_ADVICE_ARRAY_CLASS_SIGNATURE, AFTER_RETURNING_ADVICE_CLASS_NAME, AFTER_RETURNING_ADVICE_INVOKE_METHOD_SIGNATURE, AFTER_RETURNING_INTERCEPTORS_FIELD_NAME, AFTER_THROWING_ADVICE_ARRAY_CLASS_SIGNATURE, AFTER_THROWING_ADVICE_CLASS_NAME, AFTER_THROWING_ADVICE_INVOKE_METHOD_SIGNATURE, AFTER_THROWING_INTERCEPTORS_FIELD_NAME, ARGUMENT_FIELD, AROUND_ADVICE_ARRAY_CLASS_SIGNATURE, AROUND_ADVICE_CLASS_NAME, AROUND_ADVICE_INVOKE_METHOD_SIGNATURE, AROUND_INTERCEPTORS_FIELD_NAME, ASPECT_FIELD_PREFIX, ASPECT_OF_METHOD_NAME, ASPECT_OF_PER_CLASS_METHOD_SIGNATURE, ASPECT_OF_PER_INSTANCE_METHOD_SIGNATURE, ASPECT_OF_PER_JVM_METHOD_SIGNATURE, ASPECTS_CLASS_NAME, ASPECTWERKZ_PREFIX, BEFORE_ADVICE_ARRAY_CLASS_SIGNATURE, BEFORE_ADVICE_CLASS_NAME, BEFORE_ADVICE_INVOKE_METHOD_SIGNATURE, BEFORE_INTERCEPTORS_FIELD_NAME, BOOLEAN_CLASS_INIT_METHOD_SIGNATURE, BOOLEAN_CLASS_NAME, BOOLEAN_VALUE_METHOD_NAME, BOOLEAN_VALUE_METHOD_SIGNATURE, BYTE_CLASS_INIT_METHOD_SIGNATURE, BYTE_CLASS_NAME, BYTE_VALUE_METHOD_NAME, BYTE_VALUE_METHOD_SIGNATURE, CALLEE_INSTANCE_FIELD_NAME, CALLER_INSTANCE_FIELD_NAME, CHAR_VALUE_METHOD_NAME, CHAR_VALUE_METHOD_SIGNATURE, CHARACTER_CLASS_INIT_METHOD_SIGNATURE, CHARACTER_CLASS_NAME, CLASS_CLASS, CLASS_CLASS_GETCLASSLOADER_METHOD_SIGNATURE, CLASS_CLASS_SIGNATURE, CLASS_LOADER_CLASS_NAME, CLASS_LOADER_REFLECT_CLASS_NAME, CLASS_NOT_FOUND_EXCEPTION_CLASS_NAME, CLINIT_METHOD_NAME, CLINIT_METHOD_SIGNATURE, CONSTRUCTOR_RTTI_IMPL_CLASS_NAME, CONSTRUCTOR_RTTI_IMPL_CLASS_SIGNATURE, CONSTRUCTOR_RTTI_IMPL_INIT_SIGNATURE, CONSTRUCTOR_SIGNATURE_IMPL_CLASS_SIGNATURE, COPY_METHOD_NAME, COPY_METHOD_SIGNATURE, DEFINE_CLASS_METHOD_NAME, DELIMITER, DOUBLE_CLASS_INIT_METHOD_SIGNATURE, DOUBLE_CLASS_NAME, DOUBLE_VALUE_METHOD_NAME, DOUBLE_VALUE_METHOD_SIGNATURE, EMITTED_JOINPOINTS_FIELD_NAME, EMPTY_WRAPPER_ATTRIBUTE_VALUE_EMPTY, EMPTY_WRAPPER_ATTRIBUTE_VALUE_NOTEMPTY, EMTPTY_ARRAY_LIST, ENCLOSING_SJP_FIELD_CLASS_SIGNATURE, ENCLOSING_SJP_FIELD_NAME, FIELD_RTTI_IMPL_CLASS_NAME, FIELD_RTTI_IMPL_CLASS_SIGNATURE, FIELD_RTTI_IMPL_INIT_SIGNATURE, FIELD_SIGNATURE_IMPL_CLASS_SIGNATURE, FLOAT_CLASS_INIT_METHOD_SIGNATURE, FLOAT_CLASS_NAME, FLOAT_VALUE_METHOD_NAME, FLOAT_VALUE_METHOD_SIGNATURE, FOR_NAME_METHOD_NAME, FOR_NAME_METHOD_SIGNATURE, GET_AFTER_ADVICE_METHOD_NAME, GET_AFTER_ADVICE_METHOD_SIGNATURE, GET_AFTER_RETURNING_ADVICE_METHOD_NAME, GET_AFTER_RETURNING_ADVICE_METHOD_SIGNATURE, GET_AFTER_THROWING_ADVICE_METHOD_NAME, GET_AFTER_THROWING_ADVICE_METHOD_SIGNATURE, GET_AROUND_ADVICE_METHOD_NAME, GET_AROUND_ADVICE_METHOD_SIGNATURE, GET_BEFORE_ADVICE_METHOD_NAME, GET_BEFORE_ADVICE_METHOD_SIGNATURE, GET_CALLEE_CLASS_METHOD_NAME, GET_CALLEE_CLASS_METHOD_SIGNATURE, GET_CALLEE_METHOD_NAME, GET_CALLER_CLASS_METHOD_NAME, GET_CALLER_CLASS_METHOD_SIGNATURE, GET_CALLER_METHOD_NAME, GET_CFLOW_STACK_METHOD_NAME, GET_CFLOW_STACK_METHOD_SIGNATURE, GET_ENCLOSING_SJP_METHOD_NAME, GET_ENCLOSING_SJP_METHOD_SIGNATURE, GET_INSTANCE_LEVEL_ASPECT_METHOD_NAME, GET_INSTANCE_LEVEL_ASPECT_METHOD_SIGNATURE, GET_META_DATA_METHOD_NAME, GET_META_DATA_METHOD_SIGNATURE, GET_METHOD_NAME, GET_METHOD_SIGNATURE, GET_RTTI_METHOD_NAME, GET_RTTI_METHOD_SIGNATURE, GET_SIGNATURE_METHOD_NAME, GET_SIGNATURE_METHOD_SIGNATURE, GET_TARGET_CLASS_METHOD_NAME, GET_TARGET_CLASS_METHOD_SIGNATURE, GET_TARGET_METHOD_NAME, GET_THIS_METHOD_NAME, GET_TYPE_METHOD_NAME, GET_TYPE_METHOD_SIGNATURE, GETCLASSLOADER_METHOD_NAME, GETFIELD_WRAPPER_METHOD_PREFIX, HANDLER_RTTI_IMPL_CLASS_NAME, HANDLER_RTTI_IMPL_CLASS_SIGNATURE, HANDLER_RTTI_IMPL_INIT_SIGNATURE, HANDLER_SIGNATURE_IMPL_CLASS_SIGNATURE, HAS_INSTANCE_LEVEL_ASPECT_INTERFACE_NAME, HASH_MAP_CLASS_NAME, I, INDEX_NOTAVAILABLE, INIT_JOIN_POINTS_METHOD_NAME, INIT_METHOD_NAME, INSTANCE_LEVEL_ASPECT_MAP_FIELD_NAME, INSTANCE_LEVEL_ASPECT_MAP_FIELD_SIGNATURE, INT_VALUE_METHOD_NAME, INT_VALUE_METHOD_SIGNATURE, INTEGER_CLASS_INIT_METHOD_SIGNATURE, INTEGER_CLASS_NAME, INTERCEPT_INVOKE_METHOD_NAME, INTERCEPTOR_INDEX_FIELD_NAME, INVOKE_METHOD_NAME, INVOKE_WRAPPER_METHOD_PREFIX, IS_IN_CFLOW_METOD_NAME, IS_IN_CFLOW_METOD_SIGNATURE, JOIN_POINT_CLASS_NAME, JOIN_POINT_CLASS_SIGNATURE, JOIN_POINT_CLASS_SUFFIX, JOIN_POINT_JAVA_CLASS_NAME, JOIN_POINT_MANAGER_CLASS_NAME, L, LOAD_JOIN_POINT_METHOD_NAME, LOAD_JOIN_POINT_METHOD_SIGNATURE, LONG_CLASS_INIT_METHOD_SIGNATURE, LONG_CLASS_NAME, LONG_VALUE_METHOD_NAME, LONG_VALUE_METHOD_SIGNATURE, MAP_CLASS_NAME, MAP_CLASS_SIGNATURE, META_DATA_FIELD_NAME, METHOD_RTTI_IMPL_CLASS_NAME, METHOD_RTTI_IMPL_CLASS_SIGNATURE, METHOD_RTTI_IMPL_INIT_SIGNATURE, METHOD_SIGNATURE_IMPL_CLASS_NAME, METHOD_SIGNATURE_IMPL_CLASS_SIGNATURE, MIXIN_FIELD_NAME, MIXIN_OF_METHOD_NAME, MIXIN_OF_METHOD_PER_CLASS_SIGNATURE, MIXIN_OF_METHOD_PER_INSTANCE_SIGNATURE, MIXIN_OF_METHOD_PER_JVM_SIGNATURE, MIXINS_CLASS_NAME, MODIFIER_INVOKEINTERFACE, NEW_CATCH_CLAUSE_SIGNATURE_METHOD_NAME, NEW_CONSTRUCTOR_SIGNATURE_METHOD_NAME, NEW_CONSTRUCTOR_SIGNATURE_METHOD_SIGNATURE, NEW_ENCLOSING_SJP_METHOD_NAME, NEW_ENCLOSING_SJP_METHOD_SIGNATURE, NEW_FIELD_SIGNATURE_METHOD_NAME, NEW_FIELD_SIGNATURE_METHOD_SIGNATURE, NEW_HANDLER_SIGNATURE_METHOD_SIGNATURE, NEW_METHOD_SIGNATURE_METHOD_NAME, NEW_METHOD_SIGNATURE_METHOD_SIGNATURE, NEW_STATICINITIALIZATION_SIGNATURE_METHOD_NAME, NEW_STATICINITIALIZATION_SIGNATURE_METHOD_SIGNATURE, NO_PARAM_RETURN_VOID_SIGNATURE, NO_PARAMS_RETURN_VOID_METHOD_SIGNATURE, NO_PARAMS_SIGNATURE, NON_OPTIMIZED_JOIN_POINT, NR_OF_AFTER_INTERCEPTORS_FIELD_NAME, NR_OF_AFTER_RETURNING_INTERCEPTORS_FIELD_NAME, NR_OF_AFTER_THROWING_INTERCEPTORS_FIELD_NAME, NR_OF_AROUND_INTERCEPTORS_FIELD_NAME, NR_OF_BEFORE_INTERCEPTORS_FIELD_NAME, OBJECT_CLASS_NAME, OBJECT_CLASS_SIGNATURE, OPTIMIZED_JOIN_POINT, OPTIMIZED_JOIN_POINT_INSTANCE_FIELD_NAME, ORIGINAL_METHOD_PREFIX, PROCEED_METHOD_NAME, PROCEED_METHOD_SIGNATURE, PUT_METHOD_NAME, PUT_METHOD_SIGNATURE, PUTFIELD_WRAPPER_METHOD_PREFIX, RESET_METHOD_NAME, RETURN_VALUE_FIELD_NAME, RUNTIME_EXCEPTION_CLASS_NAME, RUNTIME_EXCEPTION_INIT_METHOD_SIGNATURE, SEMICOLON, SERIAL_VERSION_UID_FIELD_NAME, SET_FIELD_VALUE_METHOD_NAME, SET_FIELD_VALUE_METHOD_SIGNATURE, SET_PARAMETER_VALUE_METHOD_NAME, SET_PARAMETER_VALUE_METHOD_SIGNATURE, SET_PARAMETER_VALUES_METHOD_NAME, SET_PARAMETER_VALUES_METHOD_SIGNATURE, SET_RETURN_VALUE_METHOD_NAME, SET_RETURN_VALUE_METHOD_SIGNATURE, SHORT_CLASS_INIT_METHOD_SIGNATURE, SHORT_CLASS_NAME, SHORT_VALUE_METHOD_NAME, SHORT_VALUE_METHOD_SIGNATURE, SIGNATURE_FACTORY_CLASS, SIGNATURE_FIELD_NAME, STACK_FRAME_COUNTER_FIELD_NAME, STATIC_INITIALIZATION_METHOD_NAME, STATIC_JOIN_POINT_CLASS_NAME, STATIC_JOIN_POINT_JAVA_CLASS_NAME, STATICINITIALIZATION_RTTI_IMPL_CLASS_NAME, STATICINITIALIZATION_RTTI_IMPL_INIT_SIGNATURE, STATICINITIALIZATION_SIGNATURE_IMPL_CLASS_NAME, STATICINITIALIZATION_SIGNATURE_IMPL_CLASS_SIGNATURE, STATICINITIALIZER_WRAPPER_METHOD_KEY, SYNTHETIC_MEMBER_PREFIX, TARGET_CLASS_FIELD_NAME, THROWABLE_CLASS_NAME, WRAPPER_METHOD_PREFIX`

Fields inherited from interface org.objectweb.asm.Constants
`AALOAD, AASTORE, ACC_ABSTRACT, ACC_ANNOTATION, ACC_BRIDGE, ACC_DEPRECATED, ACC_ENUM, ACC_FINAL, ACC_INTERFACE, ACC_NATIVE, ACC_PRIVATE, ACC_PROTECTED, ACC_PUBLIC, ACC_STATIC, ACC_STRICT, ACC_SUPER, ACC_SYNCHRONIZED, ACC_SYNTHETIC, ACC_TRANSIENT, ACC_VARARGS, ACC_VOLATILE, ACONST_NULL, ALOAD, ANEWARRAY, ARETURN, ARRAYLENGTH, ASTORE, ATHROW, BALOAD, BASTORE, BIPUSH, CALOAD, CASTORE, CHECKCAST, D2F, D2I, D2L, DADD, DALOAD, DASTORE, DCMPG, DCMPL, DCONST_0, DCONST_1, DDIV, DLOAD, DMUL, DNEG, DREM, DRETURN, DSTORE, DSUB, DUP, DUP_X1, DUP_X2, DUP2, DUP2_X1, DUP2_X2, F2D, F2I, F2L, FADD, FALOAD, FASTORE, FCMPG, FCMPL, FCONST_0, FCONST_1, FCONST_2, FDIV, FLOAD, FMUL, FNEG, FREM, FRETURN, FSTORE, FSUB, GETFIELD, GETSTATIC, GOTO, I2B, I2C, I2D, I2F, I2L, I2S, IADD, IALOAD, IAND, IASTORE, ICONST_0, ICONST_1, ICONST_2, ICONST_3, ICONST_4, ICONST_5, ICONST_M1, IDIV, IF_ACMPEQ, IF_ACMPNE, IF_ICMPEQ, IF_ICMPGE, IF_ICMPGT, IF_ICMPLE, IF_ICMPLT, IF_ICMPNE, IFEQ, IFGE, IFGT, IFLE, IFLT, IFNE, IFNONNULL, IFNULL, IINC, ILOAD, IMUL, INEG, INSTANCEOF, INVOKEINTERFACE, INVOKESPECIAL, INVOKESTATIC, INVOKEVIRTUAL, IOR, IREM, IRETURN, ISHL, ISHR, ISTORE, ISUB, IUSHR, IXOR, JSR, L2D, L2F, L2I, LADD, LALOAD, LAND, LASTORE, LCMP, LCONST_0, LCONST_1, LDC, LDIV, LLOAD, LMUL, LNEG, LOOKUPSWITCH, LOR, LREM, LRETURN, LSHL, LSHR, LSTORE, LSUB, LUSHR, LXOR, MONITORENTER, MONITOREXIT, MULTIANEWARRAY, NEW, NEWARRAY, NOP, POP, POP2, PUTFIELD, PUTSTATIC, RET, RETURN, SALOAD, SASTORE, SIPUSH, SWAP, T_BOOLEAN, T_BYTE, T_CHAR, T_DOUBLE, T_FLOAT, T_INT, T_LONG, T_SHORT, TABLESWITCH, V1_1, V1_2, V1_3, V1_4, V1_5`

Constructor Summary
`MethodCallVisitor(org.objectweb.asm.ClassVisitor cv, ClassLoader loader, ClassInfo classInfo, Context ctx)` Creates a new instance.

Method Summary
`org.objectweb.asm.CodeVisitor` | `visitMethod(int access, String name, String desc, String[] exceptions, org.objectweb.asm.Attribute attrs)` Visits the caller methods.

Methods inherited from class org.objectweb.asm.ClassAdapter
`visit, visitAttribute, visitEnd, visitField, visitInnerClass`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### MethodCallVisitor

    public MethodCallVisitor(org.objectweb.asm.ClassVisitor cv,
                             ClassLoader loader,
                             ClassInfo classInfo,
                             Context ctx)

  Creates a new instance.

  Parameters:
    `cv` -
    `loader` -
    `classInfo` -
    `ctx` -

Method Detail

### visitMethod

    public org.objectweb.asm.CodeVisitor visitMethod(int access,
                                                     String name,
                                                     String desc,
                                                     String[] exceptions,
                                                     org.objectweb.asm.Attribute attrs)

  Visits the caller methods.

  Specified by:
    `visitMethod` in interface `org.objectweb.asm.ClassVisitor`
  Overrides:
    `visitMethod` in class `org.objectweb.asm.ClassAdapter`
  Parameters:
    `access` -
    `name` -
    `desc` -
    `exceptions` -
    `attrs` -
  Returns:

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2002-2005 Jonas Bonér, Alexandre Vasseur. All Rights Reserved.