[ 
https://issues.apache.org/jira/browse/CALCITE-7224?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18029908#comment-18029908
 ] 

Zhen Chen commented on CALCITE-7224:
------------------------------------

I understand that creating a Shuttle would still only allow processing all 
functions within RexCall, and—crucially—would require maintaining a centralized 
function list. This is exactly the approach I want to avoid. If another 
developer creates a new function, they might easily forget to add it to this 
list. Therefore, I believe maintaining a function list (or even a switch-case 
structure) is an unsustainable solution.

> Refactor function property system to use a unified flag field
> -------------------------------------------------------------
>
>                 Key: CALCITE-7224
>                 URL: https://issues.apache.org/jira/browse/CALCITE-7224
>             Project: Calcite
>          Issue Type: Improvement
>          Components: core
>    Affects Versions: 1.40.0
>            Reporter: Zhen Chen
>            Priority: Minor
>
> Currently, SqlOperator and its related classes use individual boolean fields 
> (e.g., isDeterministic, isDynamic, maybe isIdempotent) to represent various 
> function properties. This approach has several drawbacks as the number of 
> properties grows:
> * ​​Maintenance Overhead:​​ Adding a new property requires adding a new 
> method and field across multiple classes.
> * ​​API Bloat:​​ The interface becomes cluttered with numerous getter methods.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to