private When readWhen(Step parent, XdmNode node) { checkAttributes(node, new String[] { "test" }, false); String stepName = checkNCName(node.getAttributeValue(px_name)); String testExpr = node.getAttributeValue(new QName("test")); When step = new When(runtime, node, stepName); checkExtensionAttributes(node, step); step.setTest(testExpr); step.setParentDecl((DeclareStep) parent); step.parent = parent; Vector<XdmNode> rest = readSignature(step); if (rest == null) { throw XProcException.staticError(15, node, "A p:when must contain a subpipeline."); } for (XdmNode substepNode : rest) { Step substep = readStep(step, substepNode); step.addStep(substep); } step.checkPrimaryIO(); return step; }
private When readWhen(Step parent, XdmNode node) { checkAttributes(node, new String[] { "test" }, false); String stepName = checkNCName(node.getAttributeValue(px_name)); String testExpr = node.getAttributeValue(new QName("test")); When step = new When(runtime, node, stepName); checkExtensionAttributes(node, step); step.setTest(testExpr); step.setParentDecl((DeclareStep) parent); step.parent = parent; Vector<XdmNode> rest = readSignature(step); if (rest == null) { throw XProcException.staticError(15, node, "A p:when must contain a subpipeline."); } for (XdmNode substepNode : rest) { Step substep = readStep(step, substepNode); step.addStep(substep); } step.checkPrimaryIO(); return step; }