Package org.objectweb.asm

Examples of org.objectweb.asm.CodeVisitor.visitTypeInsn()




    // new StaticInitializationRttiImpl

    cv.visitTypeInsn(NEW, STATICINITIALIZATION_RTTI_IMPL_CLASS_NAME);

    cv.visitInsn(DUP);

    cv.visitFieldInsn(GETSTATIC,
View Full Code Here


     */
    protected void createGetRttiMethod() {
        CodeVisitor cv = m_cw.visitMethod(ACC_PUBLIC, GET_RTTI_METHOD_NAME, GET_RTTI_METHOD_SIGNATURE, null, null);

        // new MethodRttiImpl( .. )
        cv.visitTypeInsn(NEW, METHOD_RTTI_IMPL_CLASS_NAME);
        cv.visitInsn(DUP);
        cv.visitFieldInsn(
                GETSTATIC, m_joinPointClassName, SIGNATURE_FIELD_NAME, METHOD_SIGNATURE_IMPL_CLASS_SIGNATURE
        );
        cv.visitVarInsn(ALOAD, 0);
View Full Code Here



        // new FieldRttiImpl( .. )

        cv.visitTypeInsn(NEW, FIELD_RTTI_IMPL_CLASS_NAME);

        cv.visitInsn(DUP);

        cv.visitFieldInsn(GETSTATIC, m_joinPointClassName, SIGNATURE_FIELD_NAME, FIELD_SIGNATURE_IMPL_CLASS_SIGNATURE);
View Full Code Here



        // new FieldRttiImpl( .. )

        cv.visitTypeInsn(NEW, FIELD_RTTI_IMPL_CLASS_NAME);

        cv.visitInsn(DUP);

        cv.visitFieldInsn(GETSTATIC, m_joinPointClassName, SIGNATURE_FIELD_NAME, FIELD_SIGNATURE_IMPL_CLASS_SIGNATURE);
View Full Code Here

     */
    protected void createGetRttiMethod() {
        CodeVisitor cv = m_cw.visitMethod(ACC_PUBLIC, GET_RTTI_METHOD_NAME, GET_RTTI_METHOD_SIGNATURE, null, null);

        // new MethodRttiImpl( .. )
        cv.visitTypeInsn(NEW, METHOD_RTTI_IMPL_CLASS_NAME);
        cv.visitInsn(DUP);
        cv.visitFieldInsn(
                GETSTATIC, m_joinPointClassName, SIGNATURE_FIELD_NAME, METHOD_SIGNATURE_IMPL_CLASS_SIGNATURE
        );
        cv.visitVarInsn(ALOAD, 0);
View Full Code Here

        Label isNotNull = new Label();

        aspectOf.visitJumpInsn(IFNONNULL, isNotNull);

        aspectOf.visitTypeInsn(NEW, m_className);

        aspectOf.visitInsn(DUP);

        aspectOf.visitMethodInsn(INVOKESPECIAL, m_className, INIT_METHOD_NAME, NO_PARAM_RETURN_VOID_SIGNATURE);
View Full Code Here

                );

                if (!returnType.getClassName().equals(OBJECT_CLASS_SIGNATURE)) {

                    cv.visitTypeInsn(CHECKCAST, returnType.getInternalName());

                }

            }
View Full Code Here

        cv.visitMethodInsn(INVOKEVIRTUAL, "java/lang/Throwable", "printStackTrace", "()V");



        cv.visitTypeInsn(NEW, RUNTIME_EXCEPTION_CLASS_NAME);

        cv.visitInsn(DUP);

        cv.visitLdcInsn("could not load target class using Class.forName() in generated join point base class "
View Full Code Here

       

        // create the metadata map

        cv.visitTypeInsn(NEW, HASH_MAP_CLASS_NAME);

        cv.visitInsn(DUP);

        cv.visitMethodInsn(INVOKESPECIAL, HASH_MAP_CLASS_NAME, INIT_METHOD_NAME, NO_PARAM_RETURN_VOID_SIGNATURE);
View Full Code Here



        // create the static JoinPoint instance

        cv.visitTypeInsn(NEW, m_joinPointClassName);

        cv.visitInsn(DUP);

        cv.visitMethodInsn(INVOKESPECIAL, m_joinPointClassName, INIT_METHOD_NAME, NO_PARAM_RETURN_VOID_SIGNATURE);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.