Interface FilterFunction

    • Method Detail

      • isValid

        boolean isValid​(FunctionCallExpression expr)
        Check whether the function, as it is used, is valid. Checking arguments here will return errors to clients at the time invalid selectors are initially specified, rather than waiting until the selector is applied to a message.
        Parameters:
        expr - - the full expression of the function call, as used.
        Returns:
        true - if the function call is valid; false - otherwise.
      • returnsBoolean

        boolean returnsBoolean​(FunctionCallExpression expr)
        Determine whether the function, as it will be called, returns a boolean value. Called during expression parsing after the full expression for the function call, including its arguments, has been parsed. This allows functions with variable return types to function as boolean expressions in selectors without sacrificing parse-time checking.
        Parameters:
        expr - - the full expression of the function call, as used.
        Returns:
        true - if the function returns a boolean value for its use in the given expression; false - otherwise.
      • evaluate

        Object evaluate​(FunctionCallExpression expr,
                        MessageEvaluationContext message)
                 throws JMSException
        Evaluate the function call in the given context. The arguments must be evaluated, as-needed, by the function. Note that boolean expressions must return Boolean objects.
        Parameters:
        expr - - the full expression of the function call, as used.
        message - - the context within which to evaluate the call.
        Throws:
        JMSException