Package net.sf.joafip.asm

Examples of net.sf.joafip.asm.MethodVisitor.visitTypeInsn()


      mv.visitLabel(l2);
      mv.visitFrame(Opcodes.F_NEW, 2, new Object[] { "java/lang/Object",
          "java/lang/Object" }, 1,
          new Object[] { "java/lang/Exception" });
      mv.visitVarInsn(ASTORE, 2);
      mv.visitTypeInsn(NEW,
          "net/sf/joafip/store/service/proxy/JoafipObjectException");
      mv.visitInsn(DUP);
      mv.visitVarInsn(ALOAD, 2);
      mv.visitMethodInsn(INVOKESPECIAL,
          "net/sf/joafip/store/service/proxy/JoafipObjectException",
View Full Code Here


    }
    {
      mv = cw.visitMethod(ACC_PUBLIC, "toString", "()Ljava/lang/String;",
          null, null);
      mv.visitCode();
      mv.visitTypeInsn(NEW, "java/lang/StringBuilder");
      mv.visitInsn(DUP);
      mv.visitMethodInsn(INVOKESPECIAL, "java/lang/StringBuilder",
          "<init>", "()V");
      mv.visitVarInsn(ALOAD, 0);
      mv.visitMethodInsn(INVOKEVIRTUAL, "java/lang/Object", "getClass",
View Full Code Here

      mv.visitVarInsn(LLOAD, 1);
      mv.visitInsn(LCONST_0);
      mv.visitInsn(LCMP);
      Label l0 = new Label();
      mv.visitJumpInsn(IFGE, l0);
      mv.visitTypeInsn(NEW, "java/lang/IllegalArgumentException");
      mv.visitInsn(DUP);
      mv.visitLdcInsn("timeout value is negative");
      mv.visitMethodInsn(INVOKESPECIAL,
          "java/lang/IllegalArgumentException", "<init>",
          "(Ljava/lang/String;)V");
View Full Code Here

      Label l2 = new Label();
      mv.visitJumpInsn(IF_ICMPLE, l2);
      mv.visitLabel(l1);
      mv.visitFrame(Opcodes.F_NEW, 3, new Object[] { "java/lang/Object",
          Opcodes.LONG, Opcodes.INTEGER }, 0, new Object[] {});
      mv.visitTypeInsn(NEW, "java/lang/IllegalArgumentException");
      mv.visitInsn(DUP);
      mv.visitLdcInsn("nanosecond timeout value out of range");
      mv.visitMethodInsn(INVOKESPECIAL,
          "java/lang/IllegalArgumentException", "<init>",
          "(Ljava/lang/String;)V");
View Full Code Here

      mv.visitFieldInsn(GETFIELD,
          "net/sf/joafip/store/service/proxy/JoafipObject",
          "proxyCallBack",
          "Lnet/sf/joafip/store/service/proxy/IProxyCallBackToImplement;");
      mv.visitJumpInsn(IFNULL, l0);
      mv.visitTypeInsn(NEW, "java/lang/IllegalStateException");
      mv.visitInsn(DUP);
      mv.visitTypeInsn(NEW, "java/lang/StringBuilder");
      mv.visitInsn(DUP);
      mv.visitLdcInsn("for ");
      mv.visitMethodInsn(INVOKESPECIAL, "java/lang/StringBuilder",
View Full Code Here

          "proxyCallBack",
          "Lnet/sf/joafip/store/service/proxy/IProxyCallBackToImplement;");
      mv.visitJumpInsn(IFNULL, l0);
      mv.visitTypeInsn(NEW, "java/lang/IllegalStateException");
      mv.visitInsn(DUP);
      mv.visitTypeInsn(NEW, "java/lang/StringBuilder");
      mv.visitInsn(DUP);
      mv.visitLdcInsn("for ");
      mv.visitMethodInsn(INVOKESPECIAL, "java/lang/StringBuilder",
          "<init>", "(Ljava/lang/String;)V");
      mv.visitVarInsn(ALOAD, 0);
View Full Code Here

      mv.visitLabel(l0);
      mv.visitFrame(Opcodes.F_SAME, 0, null, 0, null);
      mv.visitVarInsn(ALOAD, 1);
      Label l1 = new Label();
      mv.visitJumpInsn(IFNONNULL, l1);
      mv.visitTypeInsn(NEW, "java/lang/IllegalArgumentException");
      mv.visitInsn(DUP);
      mv.visitLdcInsn("argument can not be null");
      mv.visitMethodInsn(INVOKESPECIAL,
          "java/lang/IllegalArgumentException", "<init>",
          "(Ljava/lang/String;)V");
View Full Code Here

      mv.visitFieldInsn(PUTFIELD,
          "net/sf/joafip/store/service/proxy/JoafipObject",
          "proxyCallBack",
          "Lnet/sf/joafip/store/service/proxy/IProxyCallBackToImplement;");
      mv.visitVarInsn(ALOAD, 0);
      mv.visitTypeInsn(NEW, "java/lang/Exception");
      mv.visitInsn(DUP);
      mv.visitLdcInsn("setted proxy call back trace");
      mv.visitMethodInsn(INVOKESPECIAL, "java/lang/Exception", "<init>",
          "(Ljava/lang/String;)V");
      mv.visitFieldInsn(PUTFIELD,
View Full Code Here

      mv.visitJumpInsn(GOTO, l3);
      mv.visitLabel(l2);
      mv.visitFrame(Opcodes.F_SAME1, 0, null, 1,
          new Object[] { "java/lang/Exception" });
      mv.visitVarInsn(ASTORE, 2);
      mv.visitTypeInsn(NEW,
          "net/sf/joafip/store/service/proxy/JoafipObjectException");
      mv.visitInsn(DUP);
      mv.visitVarInsn(ALOAD, 2);
      mv.visitMethodInsn(INVOKESPECIAL,
          "net/sf/joafip/store/service/proxy/JoafipObjectException",
View Full Code Here

          "(Ljava/lang/String;)Ljava/lang/Class;");
      mv.visitVarInsn(ASTORE, 3);
      mv.visitVarInsn(ALOAD, 3);
      mv.visitVarInsn(ALOAD, 2);
      mv.visitInsn(ICONST_1);
      mv.visitTypeInsn(ANEWARRAY, "java/lang/Class");
      mv.visitInsn(DUP);
      mv.visitInsn(ICONST_0);
      mv.visitLdcInsn(Type.getType("Ljava/lang/Object;"));
      mv.visitInsn(AASTORE);
      mv.visitMethodInsn(INVOKEVIRTUAL, "java/lang/Class", "getMethod",
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.