gianm commented on a change in pull request #8047: optimize single input column 
multi-value expressions
URL: https://github.com/apache/incubator-druid/pull/8047#discussion_r309002377
 
 

 ##########
 File path: core/src/main/java/org/apache/druid/math/expr/ApplyFunction.java
 ##########
 @@ -60,6 +60,17 @@
    */
   Set<Expr> getArrayInputs(List<Expr> args);
 
+  /**
+   * Returns true if apply function produces an array output
+   */
+  default boolean hasArrayOutput()
+  {
+    return false;
 
 Review comment:
   What if a function might sometimes return an array and might sometimes 
return a scalar? Is that:
   
   - Not allowed (functions should not differ in their return types in this way)
   - Allowed, and `hasArrayOutput` should be `true`
   - Allowed, and `hasArrayOutput` should be `false`
   
   Please adjust the javadocs appropriately.

----------------------------------------------------------------
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