/** * Check to ensure that this expression does not contain any updating subexpressions. * This check is overridden for those expressions that permit updating subexpressions. * * @throws net.sf.saxon.trans.XPathException * if the expression has a non-permitted updateing subexpression */ public void checkForUpdatingSubexpressions() throws XPathException { sequence.checkForUpdatingSubexpressions(); action.checkForUpdatingSubexpressions(); }
/** * Check to ensure that this expression does not contain any updating subexpressions. * This check is overridden for those expressions that permit updating subexpressions. * * @throws net.sf.saxon.trans.XPathException * if the expression has a non-permitted updateing subexpression */ public void checkForUpdatingSubexpressions() throws XPathException { getSequence().checkForUpdatingSubexpressions(); getAction().checkForUpdatingSubexpressions(); }
/** * Check to ensure that this expression does not contain any inappropriate updating subexpressions. * This check is overridden for those expressions that permit updating subexpressions. * * @throws net.sf.saxon.trans.XPathException * if the expression has a non-permitted updating subexpression */ @Override public void checkForUpdatingSubexpressions() throws XPathException { getChild().checkForUpdatingSubexpressions(); }
/** * Check to ensure that this expression does not contain any inappropriate updating subexpressions. * This check is overridden for those expressions that permit updating subexpressions. * * @throws net.sf.saxon.trans.XPathException * if the expression has a non-permitted updating subexpression */ @Override public void checkForUpdatingSubexpressions() throws XPathException { getChild().checkForUpdatingSubexpressions(); }
/** * Check to ensure that this expression does not contain any updating subexpressions. * This check is overridden for those expressions that permit updating subexpressions. * * @throws net.sf.saxon.trans.XPathException * if the expression has a non-permitted updateing subexpression */ public void checkForUpdatingSubexpressions() throws XPathException { getSequence().checkForUpdatingSubexpressions(); getAction().checkForUpdatingSubexpressions(); }
/** * Check to ensure that this expression does not contain any inappropriate updating subexpressions. * This check is overridden for those expressions that permit updating subexpressions. * * @throws net.sf.saxon.trans.XPathException * if the expression has a non-permitted updateing subexpression */ public void checkForUpdatingSubexpressions() throws XPathException { sequence.checkForUpdatingSubexpressions(); if (sequence.isUpdatingExpression()) { XPathException err = new XPathException( "Updating expression appears in a context where it is not permitted", "XUST0001"); err.setLocator(sequence); throw err; } action.checkForUpdatingSubexpressions(); }
/** * Check to ensure that this expression does not contain any inappropriate updating subexpressions. * This check is overridden for those expressions that permit updating subexpressions. * @throws XPathException if the expression has a non-permitted updating subexpression */ public void checkForUpdatingSubexpressions() throws XPathException { for (Iterator iter = iterateSubExpressions(); iter.hasNext();) { Expression sub = (Expression)iter.next(); sub.checkForUpdatingSubexpressions(); if (sub.isUpdatingExpression()) { XPathException err = new XPathException( "Updating expression appears in a context where it is not permitted", "XUST0001"); err.setLocator(sub); throw err; } } }
/** * Check to ensure that this expression does not contain any inappropriate updating subexpressions. * This check is overridden for those expressions that permit updating subexpressions. * * @throws net.sf.saxon.trans.XPathException * if the expression has a non-permitted updateing subexpression */ public void checkForUpdatingSubexpressions() throws XPathException { OperandProcessor processor = op -> { op.getChildExpression().checkForUpdatingSubexpressions(); if (op.getChildExpression().isUpdatingExpression()) { throw new XPathException( "An updating expression cannot be used in a clause of a FLWOR expression", "XUST0001"); } }; for (Clause c : clauses) { c.processOperands(processor); } getReturnClause().checkForUpdatingSubexpressions(); }
/** * Check to ensure that this expression does not contain any inappropriate updating subexpressions. * This check is overridden for those expressions that permit updating subexpressions. * * @throws net.sf.saxon.trans.XPathException * if the expression has a non-permitted updateing subexpression */ public void checkForUpdatingSubexpressions() throws XPathException { OperandProcessor processor = op -> { op.getChildExpression().checkForUpdatingSubexpressions(); if (op.getChildExpression().isUpdatingExpression()) { throw new XPathException( "An updating expression cannot be used in a clause of a FLWOR expression", "XUST0001"); } }; for (Clause c : clauses) { c.processOperands(processor); } getReturnClause().checkForUpdatingSubexpressions(); }
/** * Check to ensure that this expression does not contain any inappropriate updating subexpressions. * This check is overridden for those expressions that permit updating subexpressions. * * @throws net.sf.saxon.trans.XPathException * if the expression has a non-permitted updateing subexpression */ public void checkForUpdatingSubexpressions() throws XPathException { getSequence().checkForUpdatingSubexpressions(); if (getSequence().isUpdatingExpression()) { XPathException err = new XPathException( "An updating expression cannot be used to initialize a variable", "XUST0001"); err.setLocator(getSequence().getLocation()); throw err; } getAction().checkForUpdatingSubexpressions(); }
/** * Check to ensure that this expression does not contain any inappropriate updating subexpressions. * This check is overridden for those expressions that permit updating subexpressions. * * @throws net.sf.saxon.trans.XPathException * if the expression has a non-permitted updateing subexpression */ public void checkForUpdatingSubexpressions() throws XPathException { getSequence().checkForUpdatingSubexpressions(); if (getSequence().isUpdatingExpression()) { XPathException err = new XPathException( "An updating expression cannot be used to initialize a variable", "XUST0001"); err.setLocator(getSequence().getLocation()); throw err; } getAction().checkForUpdatingSubexpressions(); }
/** * Check to ensure that this expression does not contain any inappropriate updating subexpressions. * This check is overridden for those expressions that permit updating subexpressions. * * @throws XPathException if the expression has a non-permitted updating subexpression */ public void checkForUpdatingSubexpressions() throws XPathException { for (Operand o : operands()) { Expression sub = o.getChildExpression(); if (sub == null) { throw new NullPointerException(); } sub.checkForUpdatingSubexpressions(); if (sub.isUpdatingExpression()) { XPathException err = new XPathException( "Updating expression appears in a context where it is not permitted", "XUST0001"); err.setLocation(sub.getLocation()); throw err; } } }
/** * Check to ensure that this expression does not contain any inappropriate updating subexpressions. * This check is overridden for those expressions that permit updating subexpressions. * * @throws XPathException if the expression has a non-permitted updating subexpression */ public void checkForUpdatingSubexpressions() throws XPathException { for (Operand o : operands()) { Expression sub = o.getChildExpression(); if (sub == null) { throw new NullPointerException(); } sub.checkForUpdatingSubexpressions(); if (sub.isUpdatingExpression()) { XPathException err = new XPathException( "Updating expression appears in a context where it is not permitted", "XUST0001"); err.setLocation(sub.getLocation()); throw err; } } }
conditions[c].checkForUpdatingSubexpressions(); if (conditions[c].isUpdatingExpression()) { XPathException err = new XPathException( for (int i=0; i<actions.length; i++) { Expression act = actions[i]; act.checkForUpdatingSubexpressions(); if (!ExpressionTool.isAllowedInUpdatingContext(act)) { if (updating) {
for (Operand o : conditions()) { Expression condition = o.getChildExpression(); condition.checkForUpdatingSubexpressions(); if (condition.isUpdatingExpression()) { XPathException err = new XPathException( for (Operand o : actions()) { Expression act = o.getChildExpression(); act.checkForUpdatingSubexpressions(); if (ExpressionTool.isNotAllowedInUpdatingContext(act)) { if (updating) {
for (Operand o : conditions()) { Expression condition = o.getChildExpression(); condition.checkForUpdatingSubexpressions(); if (condition.isUpdatingExpression()) { XPathException err = new XPathException( for (Operand o : actions()) { Expression act = o.getChildExpression(); act.checkForUpdatingSubexpressions(); if (ExpressionTool.isNotAllowedInUpdatingContext(act)) { if (updating) {
body.checkForUpdatingSubexpressions(); if (isUpdating) { if (!ExpressionTool.isAllowedInUpdatingContext(body)) {
visitor.setExecutable(exec); exp = visitor.simplify(exp); exp.checkForUpdatingSubexpressions(); exp = visitor.typeCheck(exp, mainModule.getUserQueryContext().getRequiredContextItemType());
Expression value = getSelectExpression(); if (value != null) { value.checkForUpdatingSubexpressions(); if (value.isUpdatingExpression()) { throw new XPathException(
visitor.setOptimizeForStreaming(streaming); exp = exp.simplify(); exp.checkForUpdatingSubexpressions(); ContextItemStaticInfo cit = config.makeContextItemStaticInfo(mainModule.getUserQueryContext().getRequiredContextItemType(), true); Expression e2 = exp.typeCheck(visitor, cit);