Package org.objectweb.asm

Examples of org.objectweb.asm.Label


        "(Ljava/lang/String;)V");
  }

  private void produceLocalVariableInfo(Label startLabel,
      JVMLocalDeclaration[] jvmLocalDeclarations) {
    Label varLabel = new Label();
    mv.visitLabel(varLabel);
    for (JVMLocalDeclaration local : jvmLocalDeclarations) {
      mv.visitLocalVariable(local.varName(), local.type()
          .descriptorString(), null, startLabel, varLabel, local
          .index());
View Full Code Here


    return null;
  }

  @Override
  public Void visitAndThenElse_(AndThenElse node) {
    Label falseLabel = new Label();
    Label endLabel = new Label();
    visit_(node.left());
    mv.visitJumpInsn(IFEQ, falseLabel);
    visit_(node.right());
    mv.visitJumpInsn(IFEQ, falseLabel);
    visit_(node.trueFrame());
View Full Code Here

  @Override
  public Void visitIfBooleanObjectThenElse_(IfBooleanObjectThenElse node) {
    mv.visitTypeInsn(CHECKCAST, "java/lang/Boolean");
    mv.visitMethodInsn(INVOKEVIRTUAL, "java/lang/Boolean", "booleanValue",
        "()Z");
    Label elseLabel = new Label();
    mv.visitJumpInsn(IFEQ, elseLabel);
    visit_(node.trueFrame());
    Label end = new Label();
    mv.visitJumpInsn(GOTO, end);
    mv.visitLabel(elseLabel);
    visit_(node.falseFrame());
    mv.visitLabel(end);
    return null;
View Full Code Here

    return null;
  }

  @Override
  public Void visitIfBooleanValueThenElse_(IfBooleanValueThenElse node) {
    Label elseLabel = new Label();
    mv.visitJumpInsn(IFEQ, elseLabel);
    visit_(node.trueFrame());
    Label end = new Label();
    mv.visitJumpInsn(GOTO, end);
    mv.visitLabel(elseLabel);
    visit_(node.falseFrame());
    mv.visitLabel(end);
    return null;
View Full Code Here

    return null;
  }

  @Override
  public Void visitIfObjectIsNullThenElse_(IfObjectIsNullThenElse node) {
    Label elseLabel = new Label();
    mv.visitJumpInsn(IFNONNULL, elseLabel);
    visit_(node.trueFrame());
    Label end = new Label();
    mv.visitJumpInsn(GOTO, end);
    mv.visitLabel(elseLabel);
    visit_(node.falseFrame());
    mv.visitLabel(end);
    return null;
View Full Code Here

    return null;
  }

  @Override
  public Void visitIfObjectsEqualThenElse_(IfObjectsEqualThenElse node) {
    Label elseLabel = new Label();
    mv.visitJumpInsn(IF_ACMPNE, elseLabel);
    visit_(node.trueFrame());
    Label end = new Label();
    mv.visitJumpInsn(GOTO, end);
    mv.visitLabel(elseLabel);
    visit_(node.falseFrame());
    mv.visitLabel(end);
    return null;
View Full Code Here

    return null;
  }

  @Override
  public Void visitLabelLineNumber_(LabelLineNumber node) {
    Label l1 = new Label();
    mv.visitLabel(l1);
    mv.visitLineNumber(node.line(), l1);
    return null;
  }
View Full Code Here

    return null;
  }

  @Override
  public Void visitOrThenElse_(OrThenElse node) {
    Label trueLabel = new Label();
    Label endLabel = new Label();
    visit_(node.left());
    mv.visitJumpInsn(IFNE, trueLabel);
    visit_(node.right());
    mv.visitJumpInsn(IFNE, trueLabel);
    visit_(node.falseFrame());
View Full Code Here

    return null;
  }

  @Override
  public Void visitTryCatch_(TryCatch node) {
    Label nlrTryStart = new Label();
    Label nlrTryEnd = new Label();
    Label nlrTryHandler = new Label();
    mv.visitTryCatchBlock(nlrTryStart, nlrTryEnd, nlrTryHandler, node
        .exception().className());
    mv.visitLabel(nlrTryStart);
    visit_(node.tryFrame());
    mv.visitLabel(nlrTryEnd);
    Label endLabel = new Label();
    if (node.doFrame() != null) {
      visit_(node.doFrame());
    }
    mv.visitJumpInsn(GOTO, endLabel);
    mv.visitLabel(nlrTryHandler);
View Full Code Here

    return null;
  }
 
  @Override
  public Void visitWhileFalseLoop_(WhileFalseLoop node) {
    Label topLabel = new Label();
    Label doLabel = new Label();
    Label endLabel = new Label();
    mv.visitLabel(topLabel);

    visit_(node.testFrame());
    mv.visitJumpInsn(IFEQ, doLabel);
    mv.visitJumpInsn(GOTO, endLabel);
View Full Code Here

TOP

Related Classes of org.objectweb.asm.Label

Copyright © 2018 www.massapicom. 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.