Package com.sun.org.apache.bcel.internal.generic

Examples of com.sun.org.apache.bcel.internal.generic.ConstantPoolGen.addInterfaceMethodref()


  // node, we simply ask the DOM for the node type.
  if (_typeTest) {
      final ConstantPoolGen cpg = classGen.getConstantPool();
      final InstructionList il = methodGen.getInstructionList();

      final int idx = cpg.addInterfaceMethodref(DOM_INTF,
                  "getExpandedTypeID",
                                                      "(I)I");
      il.append(new SIPUSH((short)((Step)_left).getNodeType()));
      il.append(methodGen.loadDOM());
      il.append(methodGen.loadContextNode());
View Full Code Here


  final ConstantPoolGen cpg = classGen.getConstantPool();
  final InstructionList il = methodGen.getInstructionList();

  if (!_ignore) {
      // Turn off character escaping if so is wanted.
      final int esc = cpg.addInterfaceMethodref(OUTPUT_HANDLER,
                  "setEscaping", "(Z)Z");
      if (!_escaping) {
    il.append(methodGen.loadHandler());
    il.append(new PUSH(cpg, false));
    il.append(new INVOKEINTERFACE(esc, 2));
View Full Code Here

            il.append(methodGen.loadHandler());

            // Call characters(String) or characters(char[],int,int), as
            // appropriate.
            if (!canLoadAsArrayOffsetLength()) {
                final int characters = cpg.addInterfaceMethodref(OUTPUT_HANDLER,
                                                           "characters",
                                                           "("+STRING_SIG+")V");
                il.append(new PUSH(cpg, _text));
                il.append(new INVOKEINTERFACE(characters, 2));
            } else {
View Full Code Here

                                                           "characters",
                                                           "("+STRING_SIG+")V");
                il.append(new PUSH(cpg, _text));
                il.append(new INVOKEINTERFACE(characters, 2));
            } else {
                final int characters = cpg.addInterfaceMethodref(OUTPUT_HANDLER,
                                                                 "characters",
                                                                 "([CII)V");
                loadAsArrayOffsetLength(classGen, methodGen);
          il.append(new INVOKEINTERFACE(characters, 4));
            }
View Full Code Here

        MethodGenerator methodGen) {
  final ConstantPoolGen cpg = classGen.getConstantPool();
  final InstructionList il = methodGen.getInstructionList();

  // Returns the string value for a node in the DOM
  final int getNamespace = cpg.addInterfaceMethodref(DOM_INTF,
                 "getNamespaceName",
                 "(I)"+STRING_SIG);
  super.translate(classGen, methodGen);
  il.append(new INVOKEINTERFACE(getNamespace, 2));
    }
View Full Code Here

        int buildKeyIndex) {
  final ConstantPoolGen cpg = classGen.getConstantPool();
  final InstructionList il = methodGen.getInstructionList();

  // DOM.getStringValueX(nodeIndex) => String
  final int getNodeValue = cpg.addInterfaceMethodref(DOM_INTF,
                 GET_NODE_VALUE,
                 "(I)"+STRING_SIG);
                
  final int getNodeIdent = cpg.addInterfaceMethodref(DOM_INTF,
                 "getNodeIdent",
View Full Code Here

  // DOM.getStringValueX(nodeIndex) => String
  final int getNodeValue = cpg.addInterfaceMethodref(DOM_INTF,
                 GET_NODE_VALUE,
                 "(I)"+STRING_SIG);
                
  final int getNodeIdent = cpg.addInterfaceMethodref(DOM_INTF,
                 "getNodeIdent",
                 "(I)"+NODE_SIG)
                
  // AbstractTranslet.SetKeyIndexDom(name, Dom) => void
  final int keyDom = cpg.addMethodref(TRANSLET_CLASS,
View Full Code Here

  // AbstractTranslet.SetKeyIndexDom(name, Dom) => void
  final int keyDom = cpg.addMethodref(TRANSLET_CLASS,
           "setKeyIndexDom",
           "("+STRING_SIG+DOM_INTF_SIG+")V");
          
  final int getNodeIdent = cpg.addInterfaceMethodref(DOM_INTF,
                 "getNodeIdent",
                 "(I)"+NODE_SIG);                   

  // DOM.getAxisIterator(root) => NodeIterator
  final int git = cpg.addInterfaceMethodref(DOM_INTF,
View Full Code Here

  final int getNodeIdent = cpg.addInterfaceMethodref(DOM_INTF,
                 "getNodeIdent",
                 "(I)"+NODE_SIG);                   

  // DOM.getAxisIterator(root) => NodeIterator
  final int git = cpg.addInterfaceMethodref(DOM_INTF,
              "getAxisIterator",
              "(I)"+NODE_ITERATOR_SIG);

  il.append(methodGen.loadCurrentNode());
  il.append(methodGen.loadIterator());
View Full Code Here

  // Create new instance of DOM class (with RTF_INITIAL_SIZE nodes)
  //int index = cpg.addMethodref(DOM_IMPL, "<init>", "(I)V");
  //il.append(new NEW(cpg.addClass(DOM_IMPL)));
 
  il.append(methodGen.loadDOM());
  int index = cpg.addInterfaceMethodref(DOM_INTF,
         "getResultTreeFrag",
         "(IIZ)" + DOM_INTF_SIG);
  il.append(new PUSH(cpg, RTF_INITIAL_SIZE));
  il.append(new PUSH(cpg, rtfType));
  il.append(new PUSH(cpg, stylesheet.callsNodeset()));
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.