Class ApplyFunction.CartesianMapFunction

java.lang.Object
org.apache.druid.math.expr.ApplyFunction.BaseMapFunction
org.apache.druid.math.expr.ApplyFunction.CartesianMapFunction
All Implemented Interfaces:
ApplyFunction, NamedFunction
Enclosing interface:
ApplyFunction

public static class ApplyFunction.CartesianMapFunction extends ApplyFunction.BaseMapFunction
Map the cartesian product of 'n' array input arguments to an 'n' argument LambdaExpr
  • Constructor Details

    • CartesianMapFunction

      public CartesianMapFunction()
  • Method Details

    • name

      public String name()
      Description copied from interface: NamedFunction
      Name of the function
    • apply

      public ExprEval apply(LambdaExpr lambdaExpr, List<Expr> argsExpr, Expr.ObjectBinding bindings)
      Description copied from interface: ApplyFunction
      Apply LambdaExpr to argument list of Expr given a set of outer Expr.ObjectBinding. These outer bindings will be used to form the scope for the bindings used to evaluate the LambdaExpr, which use the array inputs to supply scalar values to use as bindings for IdentifierExpr in the lambda body.
    • getArrayInputs

      public Set<Expr> getArrayInputs(List<Expr> args)
      Description copied from interface: ApplyFunction
      Get list of input arguments which must evaluate to an array ExprType
    • validateArguments

      public void validateArguments(LambdaExpr lambdaExpr, List<Expr> args)
      Description copied from interface: ApplyFunction
      Validate function arguments. This method is called whenever a ApplyFunctionExpr is created, and should validate everything that is feasible up front. Note that input type information is typically unavailable at the time Expr are parsed, and so this method is incapable of performing complete validation.