Class FilterExpressionAdjunct

  • All Implemented Interfaces:

    public class FilterExpressionAdjunct
    extends FilteringAdjunct
    Generate streaming code for a filter expression (when not part of a Watch).
    • Constructor Detail

      • FilterExpressionAdjunct

        public FilterExpressionAdjunct()
    • Method Detail

      • setExpression

        public void setExpression​(Expression expression)
        Set the expression being processed by this StreamingAdjunct
        setExpression in class StreamingAdjunct
        expression - the expression being processed
      • computeStreamability

        public PostureAndSweep computeStreamability​(ContextItemStaticInfoEE contextInfo,
                                                    java.util.List<java.lang.String> reasons)
        Description copied from class: StreamingAdjunct
        Compute the posture and sweep of this expression as defined in the W3C streamability specifications. This must be implemented in all subclasses that don't use the general streamability rules. The implementation should have the side-effect of computing the streamability of all subexpressions, recursively.
        computeStreamability in class StreamingAdjunct
        contextInfo - Information about the context item type and posture
        reasons - the caller may supply a list, in which case the implementation may add to this; the contents are human-readable messages explaining why the expression is not streamable.
        the posture and sweep of the expression
      • toStreamingPattern

        public Pattern toStreamingPattern​(Configuration config)
        Convert this expression to a streaming pattern (a pattern used internally to match nodes during push processing of an event stream)
        toStreamingPattern in class StreamingAdjunct
        config - the Saxon configuration
        the equivalent pattern if conversion succeeds; otherwise null
      • getFeedMaker

        public FeedMaker getFeedMaker​(int arg)
                               throws XPathException
        Description copied from class: StreamingAdjunct
        Get a FeedMaker, a factory class that creates a Feed to evaluate this expression in streaming mode. In many cases the StreamingAdjunct is itself a FeedMaker, in which case it returns itself. But where an expression has several operands, it will typically create different feeds depending on which argument is the streamed input, and in such cases the individual StreamingAdjunct makes the decision which feed to use, by returning an appropriate FeedMaker.
        getFeedMaker in class StreamingAdjunct
        arg - identifies the argument with respect to which the expression is to be inverted: usually 0 to indicate the first argument is the value that is streamed. Argument numbering is the same as the sequence of arguments/operands returned by the method Expression.operands()
        a FeedMaker to evaluate the expression, or null if it is not streamable with respect to the specificed argument.
        XPathException - in the event of a failure