jon-wei commented on a change in pull request #7588: multi-value string column 
support for expressions
URL: https://github.com/apache/incubator-druid/pull/7588#discussion_r290957055
 
 

 ##########
 File path: core/src/main/java/org/apache/druid/math/expr/Expr.java
 ##########
 @@ -56,23 +70,180 @@ default Object getLiteralValue()
     throw new ISE("Not a literal");
   }
 
+  /**
+   * Returns the string identifier of an {@link IdentifierExpr}, else null
+   */
+  @Nullable
+  default String getIdentifierIfIdentifier()
+  {
+    // overridden by things that are identifiers
+    return null;
+  }
+
+  /**
+   * Evaluate the {@link Expr} with the bindings which supply {@link 
IdentifierExpr} with their values, producing an
+   * {@link ExprEval} with the result.
+   */
   @Nonnull
   ExprEval eval(ObjectBinding bindings);
 
+  /**
+   * Programmatically inspect the {@link Expr} tree with a {@link Visitor}. 
Each {@link Expr} is responsible for
+   * ensuring the {@link Visitor} can visit all of it's {@link Expr} children 
before visiting itself.
+   */
+  void visit(Visitor visitor);
+
+  /**
+   * Programatically rewrite the {@link Expr} tree with a {@link Shuttle}.Each 
{@link Expr} is responsible for
+   * ensuring the {@link Shuttle} can visit all of it's {@link Expr} children, 
as well as updating it's children
+   * {@link Expr} with the results from the {@link Shuttle}, before finally 
visiting an updated form of itself.
+   */
+  Expr visit(Shuttle shuttle);
+
+  /**
+   * Examing the usage of {@link IdentifierExpr} children of an {@link Expr}, 
constructing a {@link BindingDetails}
 
 Review comment:
   Examing -> Examine

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to