/** * Redirect the handles from oldList to newList. "This" flow list * is assumed to be relative to oldList. */ public FlowList copyAndRedirect(InstructionList oldList, InstructionList newList) { final FlowList result = new FlowList(); if (_elements == null) { return result; } final int n = _elements.size(); final Iterator oldIter = oldList.iterator(); final Iterator newIter = newList.iterator(); while (oldIter.hasNext()) { final InstructionHandle oldIh = (InstructionHandle) oldIter.next(); final InstructionHandle newIh = (InstructionHandle) newIter.next(); for (int i = 0; i < n; i++) { if (_elements.elementAt(i) == oldIh) { result.add(newIh); } } } return result; } }
/** * Expects an integer on the stack and translates it to a non-synthesized * boolean. It does not push a 0 or a 1 but instead returns branchhandle * list to be appended to the false list. * * @see org.apache.xalan.xsltc.compiler.util.Type#translateToDesynthesized */ public FlowList translateToDesynthesized(ClassGenerator classGen, MethodGenerator methodGen, BooleanType type) { final InstructionList il = methodGen.getInstructionList(); return new FlowList(il.append(new IFEQ(null))); }
/** * Translates a node into a non-synthesized boolean. It does not push a * 0 or a 1 but instead returns branchhandle list to be appended to the * false list. * * @see org.apache.xalan.xsltc.compiler.util.Type#translateToDesynthesized */ public FlowList translateToDesynthesized(ClassGenerator classGen, MethodGenerator methodGen, BooleanType type) { final InstructionList il = methodGen.getInstructionList(); return new FlowList(il.append(new IFEQ(null))); }
/** * Translates a node-set into a non-synthesized boolean. It does not * push a 0 or a 1 but instead returns branchhandle list to be appended * to the false list. * * @see org.apache.xalan.xsltc.compiler.util.Type#translateToDesynthesized */ public FlowList translateToDesynthesized(ClassGenerator classGen, MethodGenerator methodGen, BooleanType type) { final InstructionList il = methodGen.getInstructionList(); getFirstNode(classGen, methodGen); return new FlowList(il.append(new IFLT(null))); }
/** * Expects a reference on the stack and translates it to a non-synthesized * boolean. It does not push a 0 or a 1 but instead returns branchhandle * list to be appended to the false list. * * @see org.apache.xalan.xsltc.compiler.util.Type#translateToDesynthesized */ public FlowList translateToDesynthesized(ClassGenerator classGen, MethodGenerator methodGen, BooleanType type) { InstructionList il = methodGen.getInstructionList(); translateTo(classGen, methodGen, type); return new FlowList(il.append(new IFEQ(null))); }
/** * Translates a result tree into a non-synthesized boolean. * It does not push a 0 or a 1 but instead returns branchhandle list * to be appended to the false list. * * @param classGen A BCEL class generator * @param methodGen A BCEL method generator * @param type An instance of BooleanType (any) * @see org.apache.xalan.xsltc.compiler.util.Type#translateToDesynthesized */ public FlowList translateToDesynthesized(ClassGenerator classGen, MethodGenerator methodGen, BooleanType type) { final InstructionList il = methodGen.getInstructionList(); translateTo(classGen, methodGen, Type.Boolean); return new FlowList(il.append(new IFEQ(null))); }
/** * Translates a string into a non-synthesized boolean. It does not push a * 0 or a 1 but instead returns branchhandle list to be appended to the * false list. * * @see org.apache.xalan.xsltc.compiler.util.Type#translateToDesynthesized */ public FlowList translateToDesynthesized(ClassGenerator classGen, MethodGenerator methodGen, BooleanType type) { final ConstantPoolGen cpg = classGen.getConstantPool(); final InstructionList il = methodGen.getInstructionList(); il.append(new INVOKEVIRTUAL(cpg.addMethodref(STRING_CLASS, "length", "()I"))); return new FlowList(il.append(new IFEQ(null))); }
BooleanType type) { LocalVariableGen local; final FlowList flowlist = new FlowList(); final ConstantPoolGen cpg = classGen.getConstantPool(); final InstructionList il = methodGen.getInstructionList();
/** * Expects an integer on the stack and translates it to a non-synthesized * boolean. It does not push a 0 or a 1 but instead returns branchhandle * list to be appended to the false list. * * @see org.apache.xalan.xsltc.compiler.util.Type#translateToDesynthesized */ public FlowList translateToDesynthesized(ClassGenerator classGen, MethodGenerator methodGen, BooleanType type) { final InstructionList il = methodGen.getInstructionList(); return new FlowList(il.append(new IFEQ(null))); }
/** * Expects an integer on the stack and translates it to a non-synthesized * boolean. It does not push a 0 or a 1 but instead returns branchhandle * list to be appended to the false list. * * @see org.apache.xalan.xsltc.compiler.util.Type#translateToDesynthesized */ public FlowList translateToDesynthesized(ClassGenerator classGen, MethodGenerator methodGen, BooleanType type) { final InstructionList il = methodGen.getInstructionList(); return new FlowList(il.append(new IFEQ(null))); }
/** * Translates a node into a non-synthesized boolean. It does not push a * 0 or a 1 but instead returns branchhandle list to be appended to the * false list. * * @see org.apache.xalan.xsltc.compiler.util.Type#translateToDesynthesized */ public FlowList translateToDesynthesized(ClassGenerator classGen, MethodGenerator methodGen, BooleanType type) { final InstructionList il = methodGen.getInstructionList(); return new FlowList(il.append(new IFEQ(null))); }
/** * Translates a node into a non-synthesized boolean. It does not push a * 0 or a 1 but instead returns branchhandle list to be appended to the * false list. * * @see org.apache.xalan.xsltc.compiler.util.Type#translateToDesynthesized */ public FlowList translateToDesynthesized(ClassGenerator classGen, MethodGenerator methodGen, BooleanType type) { final InstructionList il = methodGen.getInstructionList(); return new FlowList(il.append(new IFEQ(null))); }
/** * Expects an integer on the stack and translates it to a non-synthesized * boolean. It does not push a 0 or a 1 but instead returns branchhandle * list to be appended to the false list. * * @see org.apache.xalan.xsltc.compiler.util.Type#translateToDesynthesized */ public FlowList translateToDesynthesized(ClassGenerator classGen, MethodGenerator methodGen, BooleanType type) { final InstructionList il = methodGen.getInstructionList(); return new FlowList(il.append(new IFEQ(null))); }
/** * Translates a node into a non-synthesized boolean. It does not push a * 0 or a 1 but instead returns branchhandle list to be appended to the * false list. * * @see org.apache.xalan.xsltc.compiler.util.Type#translateToDesynthesized */ public FlowList translateToDesynthesized(ClassGenerator classGen, MethodGenerator methodGen, BooleanType type) { final InstructionList il = methodGen.getInstructionList(); return new FlowList(il.append(new IFEQ(null))); }
/** * Expects a reference on the stack and translates it to a non-synthesized * boolean. It does not push a 0 or a 1 but instead returns branchhandle * list to be appended to the false list. * * @see org.apache.xalan.xsltc.compiler.util.Type#translateToDesynthesized */ public FlowList translateToDesynthesized(ClassGenerator classGen, MethodGenerator methodGen, BooleanType type) { InstructionList il = methodGen.getInstructionList(); translateTo(classGen, methodGen, type); return new FlowList(il.append(new IFEQ(null))); }
/** * Translates a node-set into a non-synthesized boolean. It does not * push a 0 or a 1 but instead returns branchhandle list to be appended * to the false list. * * @see org.apache.xalan.xsltc.compiler.util.Type#translateToDesynthesized */ public FlowList translateToDesynthesized(ClassGenerator classGen, MethodGenerator methodGen, BooleanType type) { final InstructionList il = methodGen.getInstructionList(); getFirstNode(classGen, methodGen); return new FlowList(il.append(new IFLT(null))); }
/** * Translates a node-set into a non-synthesized boolean. It does not * push a 0 or a 1 but instead returns branchhandle list to be appended * to the false list. * * @see org.apache.xalan.xsltc.compiler.util.Type#translateToDesynthesized */ public FlowList translateToDesynthesized(ClassGenerator classGen, MethodGenerator methodGen, BooleanType type) { final InstructionList il = methodGen.getInstructionList(); getFirstNode(classGen, methodGen); return new FlowList(il.append(new IFLT(null))); }
/** * Expects a reference on the stack and translates it to a non-synthesized * boolean. It does not push a 0 or a 1 but instead returns branchhandle * list to be appended to the false list. * * @see org.apache.xalan.xsltc.compiler.util.Type#translateToDesynthesized */ public FlowList translateToDesynthesized(ClassGenerator classGen, MethodGenerator methodGen, BooleanType type) { InstructionList il = methodGen.getInstructionList(); translateTo(classGen, methodGen, type); return new FlowList(il.append(new IFEQ(null))); }
/** * Translates a node-set into a non-synthesized boolean. It does not * push a 0 or a 1 but instead returns branchhandle list to be appended * to the false list. * * @see org.apache.xalan.xsltc.compiler.util.Type#translateToDesynthesized */ public FlowList translateToDesynthesized(ClassGenerator classGen, MethodGenerator methodGen, BooleanType type) { final InstructionList il = methodGen.getInstructionList(); getFirstNode(classGen, methodGen); return new FlowList(il.append(new IFLT(null))); }
/** * Expects a reference on the stack and translates it to a non-synthesized * boolean. It does not push a 0 or a 1 but instead returns branchhandle * list to be appended to the false list. * * @see org.apache.xalan.xsltc.compiler.util.Type#translateToDesynthesized */ public FlowList translateToDesynthesized(ClassGenerator classGen, MethodGenerator methodGen, BooleanType type) { InstructionList il = methodGen.getInstructionList(); translateTo(classGen, methodGen, type); return new FlowList(il.append(new IFEQ(null))); }