Interface IExpression

    • Method Detail

      • getChildren

        @NonNull
        List<? extends IExpressiongetChildren()
        Retrieve the child expressions associated with this expression.
        Returns:
        a list of expressions, which may be empty
      • getBaseResultType

        @NonNull
        default Class<? extends IItemgetBaseResultType()
        The minimum expected result type to be produced when evaluating the expression. The result may be a sub-class or sub-interface of this value.
        Returns:
        the base result type
      • getStaticResultType

        @NonNull
        default Class<? extends IItemgetStaticResultType()
        The expected result type produced by evaluating the expression. The result must be the same or a sub-class or sub-interface of the value provided by getBaseResultType().

        This method can be overloaded to provide static analysis of the expression to determine a more specific result type.

        Returns:
        the result type
      • toASTString

        @NonNull
        default String toASTString()
        Produce a string representation of this expression including the expression's name.

        This method can be overloaded to provide a more appropriate representation of the expression.

        Returns:
        a string representing the data elements of the expression
      • accept

        @NonNull
        ISequence<? extends IItemaccept​(@NonNull
                                          DynamicContext dynamicContext,
                                          @NonNull
                                          ISequence<?> focus)
        Provides a double dispatch callback for visitor handling.
        Parameters:
        dynamicContext - the dynamic evaluation context
        focus - the outer focus of the expression
        Returns:
        the result of evaluation
      • accept

        <RESULT,​CONTEXT> RESULT accept​(@NonNull
                                             gov.nist.secauto.metaschema.core.metapath.IExpressionVisitor<RESULT,​CONTEXT> visitor,
                                             @NonNull
                                             CONTEXT context)
        Provides a double dispatch callback for visitor handling.
        Type Parameters:
        RESULT - the type of the evaluation result
        CONTEXT - the type of the visitor context
        Parameters:
        visitor - the visitor calling this method
        context - the visitor context
        Returns:
        the result of evaluation