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

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


        case NodeTest.COMMENT:
        case NodeTest.ATTRIBUTE:
        case NodeTest.PI:
            il.append(methodGen.loadDOM());
            il.append(SWAP); // dom ref must be below node index
            index = cpg.addInterfaceMethodref(DOM_INTF,
                                              GET_NODE_VALUE,
                                              GET_NODE_VALUE_SIG);
            il.append(new INVOKEINTERFACE(index, 2));
            break;
View Full Code Here


        il.append(methodGen.loadDOM());
        il.append(SWAP);                // dom ref must be below node index

        if (className.equals("org.w3c.dom.Node") ||
            className.equals("java.lang.Object")) {
            int index = cpg.addInterfaceMethodref(DOM_INTF,
                                                  MAKE_NODE,
                                                  MAKE_NODE_SIG);
            il.append(new INVOKEINTERFACE(index, 2));
        }
        else if (className.equals("org.w3c.dom.NodeList")) {
View Full Code Here

                                                  MAKE_NODE,
                                                  MAKE_NODE_SIG);
            il.append(new INVOKEINTERFACE(index, 2));
        }
        else if (className.equals("org.w3c.dom.NodeList")) {
            int index = cpg.addInterfaceMethodref(DOM_INTF,
                                                  MAKE_NODE_LIST,
                                                  MAKE_NODE_LIST_SIG);
            il.append(new INVOKEINTERFACE(index, 2));
        }
        else {
View Full Code Here

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

        if (_nodeType == DTM.ELEMENT_NODE) {
            final int check = cpg.addInterfaceMethodref(DOM_INTF,
                                                        "isElement", "(I)Z");
            il.append(methodGen.loadDOM());
            il.append(SWAP);
            il.append(new INVOKEINTERFACE(check, 2));
View Full Code Here

            final BranchHandle icmp = il.append(new IFNE(null));
            _falseList.add(il.append(new GOTO_W(null)));
            icmp.setTarget(il.append(NOP));
        }
        else if (_nodeType == DTM.ATTRIBUTE_NODE) {
            final int check = cpg.addInterfaceMethodref(DOM_INTF,
                                                        "isAttribute", "(I)Z");
            il.append(methodGen.loadDOM());
            il.append(SWAP);
            il.append(new INVOKEINTERFACE(check, 2));
View Full Code Here

            _falseList.add(il.append(new GOTO_W(null)));
            icmp.setTarget(il.append(NOP));
        }
        else {
            // context node is on the stack
            final int getEType = cpg.addInterfaceMethodref(DOM_INTF,
                                                          "getExpandedTypeID",
                                                          "(I)I");
            il.append(methodGen.loadDOM());
            il.append(SWAP);
            il.append(new INVOKEINTERFACE(getEType, 2));
View Full Code Here

        il.append(new INVOKESPECIAL(index));

        // Get the parent of the matching node
        il.append(methodGen.loadDOM());
        il.append(new ILOAD(match.getIndex()));
        index = cpg.addInterfaceMethodref(DOM_INTF, GET_PARENT, GET_PARENT_SIG);
        il.append(new INVOKEINTERFACE(index, 2));

        // Start the iterator with the parent
        il.append(methodGen.setStartNode());
View Full Code Here

        }

        // Get the parent of the node on the stack
        il.append(methodGen.loadDOM());
        il.append(new ILOAD(node.getIndex()));
        int index = cpg.addInterfaceMethodref(DOM_INTF,
                                              GET_PARENT, GET_PARENT_SIG);
        il.append(new INVOKEINTERFACE(index, 2));

        // Initialize the iterator with the parent
        il.append(new ALOAD(iter.getIndex()));
View Full Code Here

                il.append(methodGen.loadDOM());
                il.append(SWAP);
            }
        }

        final int getParent = cpg.addInterfaceMethodref(DOM_INTF,
                                                        GET_PARENT,
                                                        GET_PARENT_SIG);
        il.append(new INVOKEINTERFACE(getParent, 2));

        final SyntaxTreeNode p = getParent();
View Full Code Here

        il.append(methodGen.loadDOM());
        il.append(SWAP);

        if (className.equals("org.w3c.dom.Node")) {
            int index = cpg.addInterfaceMethodref(DOM_INTF,
                                                  MAKE_NODE,
                                                  MAKE_NODE_SIG2);
            il.append(new INVOKEINTERFACE(index, 2));
        }
        else if (className.equals("org.w3c.dom.NodeList") ||
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.