Steve Carlin created IMPALA-13840:
-------------------------------------

             Summary: Create enum of StatementType to avoid many awkward 
instanceof calls
                 Key: IMPALA-13840
                 URL: https://issues.apache.org/jira/browse/IMPALA-13840
             Project: IMPALA
          Issue Type: Improvement
            Reporter: Steve Carlin


Within the AnalysisResult class, there are many calls like:
boolean isMergeStmt( return stmt_ instanceof MergeStmt)

boolean isUpdateStmt( return stmt_ instanceof UpdateStmt)

Futhermore, in Frontend.java, there is a huge block of if/else if/else if 
statements which check on the instance of the StatementBase

The code would be cleaner if we can create an enum StatementType.  It would 
remove those "if" calls to a StatementBase.getStmtType() call and also callers 
can use a cleaner case statement instead of the if/else block.



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

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

Reply via email to