Class DefaultedArgumentExpression.DefaultCollationArgument

    • Constructor Detail

      • DefaultCollationArgument

        public DefaultCollationArgument()
    • Method Detail

      • typeCheck

        public Expression typeCheck​(ExpressionVisitor visitor,
                                    ContextItemStaticInfo contextInfo)
                             throws XPathException
        Description copied from class: Expression
        Perform type checking of an expression and its subexpressions. This is the second phase of static optimization.

        This checks statically that the operands of the expression have the correct type; if necessary it generates code to do run-time type checking or type conversion. A static type error is reported only if execution cannot possibly succeed, that is, if a run-time type error is inevitable. The call may return a modified form of the expression.

        This method is called after all references to functions and variables have been resolved to the declaration of the function or variable. However, the types of such functions and variables may not be accurately known if they have not been explicitly declared.

        typeCheck in class Expression
        visitor - an expression visitor
        contextInfo - Information available statically about the context item: whether it is (possibly) absent; its static type; its streaming posture.
        the original expression, rewritten to perform necessary run-time type checks, and to perform other type-related optimizations
        XPathException - if an error is discovered during this phase (typically a type error)