All Implemented Interfaces:
NamedWriteable, Writeable, PostAnalysisPlanVerificationAware, PostOptimizationPlanVerificationAware, PostOptimizationVerificationAware, RewriteableAware, TranslationAware, Resolvable, EvaluatorMapper, OptionalArgument, ExpressionScoreMapper

public class MatchOperator extends Match
This class performs a MatchQuery using an operator. This is used as a convenience for generating documentation and for error message purposes - it’s a way to represent the match operator in the function syntax. Serialization is provided as a way to pass the corresponding tests - serialization must be done to a Match class.
  • Constructor Details

  • Method Details

    • functionType

      public String functionType()
      Description copied from class: FullTextFunction
      Used to differentiate error messages between functions and operators
      Overrides:
      functionType in class FullTextFunction
      Returns:
      function type for error messages
    • functionName

      public String functionName()
      Overrides:
      functionName in class Function
    • info

      protected NodeInfo<? extends Expression> info()
      Description copied from class: Node
      Normally, you want to use one of the static create methods to implement this.

      For QueryPlans, it is very important that the properties contain all of the expressions and references relevant to this node, and that all the properties are used in the provided constructor; otherwise query plan transformations like QueryPlan#transformExpressionsOnly(Function) will not have an effect.

      Overrides:
      info in class Match
    • replaceChildren

      public Expression replaceChildren(List<Expression> newChildren)
      Overrides:
      replaceChildren in class Match
    • replaceQueryBuilder

      public Expression replaceQueryBuilder(QueryBuilder queryBuilder)
      Description copied from interface: RewriteableAware
      Replaces the current query builder with a rewritten iteration. This happens multiple times through the rewrite phase until the final iteration of the query builder is stored.
      Specified by:
      replaceQueryBuilder in interface RewriteableAware
      Overrides:
      replaceQueryBuilder in class Match
      Parameters:
      queryBuilder - QueryBuilder
      Returns:
      Expression defining the active QueryBuilder