Examples of INVOKESPECIAL


Examples of org.apache.bcel.generic.INVOKESPECIAL

  // Manufacture a DecimalFormatSymbols on the stack
  // for call to addDecimalFormat()
  il.append(new NEW(cpg.addClass(DFS_CLASS)));
  il.append(DUP);
  il.append(new INVOKESPECIAL(init));

  String tmp = getAttribute("NaN");
  if ((tmp == null) || (tmp.equals(EMPTYSTRING))) {
      int nan = cpg.addMethodref(DFS_CLASS,
               "setNaN", "(Ljava/lang/String;)V");
View Full Code Here

Examples of org.apache.bcel.generic.INVOKESPECIAL

  // Manufacture a DecimalFormatSymbols on the stack
  // for call to addDecimalFormat()
  il.append(new NEW(cpg.addClass(DFS_CLASS)));
  il.append(DUP);
  il.append(new INVOKESPECIAL(init));

  int nan = cpg.addMethodref(DFS_CLASS,
           "setNaN", "(Ljava/lang/String;)V");
  il.append(DUP);
  il.append(new PUSH(cpg, "NaN"));
View Full Code Here

Examples of org.apache.bcel.generic.INVOKESPECIAL

  compileFilter(classGen, methodGen);
 
  // Create new instance of filter
  il.append(new NEW(cpg.addClass(_className)));
  il.append(DUP);
  il.append(new INVOKESPECIAL(cpg.addMethodref(_className,
                 "<init>", "()V")));

  // Initialize closure variables
  final int length = (_closureVars == null) ? 0 : _closureVars.size();
View Full Code Here

Examples of org.apache.bcel.generic.INVOKESPECIAL

  il.append(new NEW(cpg.addClass(SORT_ITERATOR)));
  il.append(DUP);
        nodesTemp.setEnd(il.append(new ALOAD(nodesTemp.getIndex())));
        sortRecordFactoryTemp.setEnd(
                il.append(new ALOAD(sortRecordFactoryTemp.getIndex())));
  il.append(new INVOKESPECIAL(init));
    }
View Full Code Here

Examples of org.apache.bcel.generic.INVOKESPECIAL

        sortTypeTemp.setEnd(il.append(new ALOAD(sortTypeTemp.getIndex())));
        sortLangTemp.setEnd(il.append(new ALOAD(sortLangTemp.getIndex())));
        sortCaseOrderTemp.setEnd(
                il.append(new ALOAD(sortCaseOrderTemp.getIndex())));

  il.append(new INVOKESPECIAL(
      cpg.addMethodref(sortRecordFactoryClass, "<init>",
    "(" + DOM_INTF_SIG
        + STRING_SIG
        + TRANSLET_INTF_SIG
        + "[" + STRING_SIG
View Full Code Here

Examples of org.apache.bcel.generic.INVOKESPECIAL

  il.append(new ALOAD(3));
  il.append(new ALOAD(4));
  il.append(new ALOAD(5));
  il.append(new ALOAD(6));
  il.append(new ALOAD(7));
  il.append(new INVOKESPECIAL(cpg.addMethodref(NODE_SORT_FACTORY,
      "<init>",
      "(" + DOM_INTF_SIG
    + STRING_SIG
    + TRANSLET_INTF_SIG
    + "[" + STRING_SIG
    + "[" + STRING_SIG
    + "[" + STRING_SIG
    + "[" + STRING_SIG + ")V")));
  il.append(RETURN);

  // Override the definition of makeNodeSortRecord()
  il = new InstructionList();
  final MethodGenerator makeNodeSortRecord =
      new MethodGenerator(ACC_PUBLIC,
    Util.getJCRefType(NODE_SORT_RECORD_SIG),
    new org.apache.bcel.generic.Type[] {
        org.apache.bcel.generic.Type.INT,
        org.apache.bcel.generic.Type.INT },
    new String[] { "node", "last" }, "makeNodeSortRecord",
    className, il, cpg);

  il.append(ALOAD_0);
  il.append(ILOAD_1);
  il.append(ILOAD_2);
  il.append(new INVOKESPECIAL(cpg.addMethodref(NODE_SORT_FACTORY,
      "makeNodeSortRecord", "(II)" + NODE_SORT_RECORD_SIG)));
  il.append(DUP);
  il.append(new CHECKCAST(cpg.addClass(sortRecordClass)));

  // Initialize closure in record class
View Full Code Here

Examples of org.apache.bcel.generic.INVOKESPECIAL

        null, null, "<init>", className,
        il, cpg);

  // Call the constructor in the NodeSortRecord superclass
  il.append(ALOAD_0);
  il.append(new INVOKESPECIAL(cpg.addMethodref(NODE_SORT_RECORD,
                 "<init>", "()V")));

 

  il.append(RETURN);
View Full Code Here

Examples of org.apache.bcel.generic.INVOKESPECIAL

        null, null, "<init>",
        _className, il, cpg);

  // Call the constructor in the AbstractTranslet superclass
  il.append(classGen.loadTranslet());
  il.append(new INVOKESPECIAL(cpg.addMethodref(TRANSLET_CLASS,
                 "<init>", "()V")));
 
        constructor.markChunkStart();
  il.append(classGen.loadTranslet());
  il.append(new GETSTATIC(cpg.addFieldref(_className,
View Full Code Here

Examples of org.apache.bcel.generic.INVOKESPECIAL

  if (isMultiDocument()) {
      final int init = cpg.addMethodref(MULTI_DOM_CLASS,
                "<init>",
                "("+DOM_INTF_SIG+")V");
      il.append(new INVOKESPECIAL(init));
      // MultiDOM is on the stack
  }
 
  //store to _dom variable
  il.append(new PUTFIELD(domField));
View Full Code Here

Examples of org.apache.bcel.generic.INVOKESPECIAL

                il.append(DUP);
                iteratorTemp.setEnd(
                        il.append(new ALOAD(iteratorTemp.getIndex())));
                predicateValueTemp.setEnd(
                        il.append(new ILOAD(predicateValueTemp.getIndex())));
                il.append(new INVOKESPECIAL(nthIteratorIdx));
            } else {
                // Translate predicates from right to left
                final int initCNLI =
                                 cpg.addMethodref(CURRENT_NODE_LIST_ITERATOR,
                                                 "<init>",
                                                 "("+NODE_ITERATOR_SIG+"Z"+
                                                 CURRENT_NODE_LIST_FILTER_SIG +
                                                 NODE_SIG+TRANSLET_SIG+")V");

                // Backwards branches are prohibited if an uninitialized object
                // is on the stack by section 4.9.4 of the JVM Specification,
                // 2nd Ed.  We don't know whether this code might contain
                // backwards branches, so we mustn't create the new object
                // until after we've created the suspect arguments to its
                // constructor.  Instead we calculate the values of the
                // arguments to the constructor first, store them in temporary
                // variables, create the object and reload the arguments from
                // the temporaries to avoid the problem.


                LocalVariableGen nodeIteratorTemp =
                    methodGen.addLocalVariable("filter_expr_tmp1",
                                           Util.getJCRefType(NODE_ITERATOR_SIG),
                                           null, null);
                nodeIteratorTemp.setStart(
                        il.append(new ASTORE(nodeIteratorTemp.getIndex())));

                predicate.translate(classGen, methodGen);
                LocalVariableGen filterTemp =
                    methodGen.addLocalVariable("filter_expr_tmp2",
                              Util.getJCRefType(CURRENT_NODE_LIST_FILTER_SIG),
                              null, null);
                filterTemp.setStart(
                        il.append(new ASTORE(filterTemp.getIndex())));

                // Create a CurrentNodeListIterator
                il.append(new NEW(cpg.addClass(CURRENT_NODE_LIST_ITERATOR)));
                il.append(DUP);
           
                // Initialize CurrentNodeListIterator
                nodeIteratorTemp.setEnd(
                        il.append(new ALOAD(nodeIteratorTemp.getIndex())));
                il.append(ICONST_1);
                filterTemp.setEnd(il.append(new ALOAD(filterTemp.getIndex())));
                il.append(methodGen.loadCurrentNode());
                il.append(classGen.loadTranslet());
                il.append(new INVOKESPECIAL(initCNLI));
      }
  }
    }
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.