Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## gudusoft.gsqlparser.nodes
Class TCaseExpression

    java.lang.Object
      gudusoft.gsqlparser.nodes.TParseTreeNode
          gudusoft.gsqlparser.nodes.TCaseExpression

All Implemented Interfaces:
  Visitable

    public class TCaseExpression

extends TParseTreeNode

CASE expressions let you use IF ... THEN ... ELSE logic in SQL statements without having to invoke procedures.

Syntax:

simple case expression:

>     CASE input_expr {WHEN comparison_expr THEN return_expr}[...n] [ELSE else_expr] END

searched case expression:

>     CASE  {WHEN comparison_expr THEN return_expr}[...n] [ELSE else_expr] END

plsql case statement

>     CASE input_expr {WHEN comparison_expr THEN statement}[...n] [ELSE else_statement_list] END

Constructor Summary
`TCaseExpression()`

Method Summary
`void` | `accept(TParseTreeVisitor v)`
`void` | `doParse(TCustomSqlStatement psql, ESqlClause plocation)` analyze this node
`TExpression` | `getElse_expr()`
`TStatementList` | `getElse_statement_list()`
`TStatementListSqlNode` | `getElse_statement_node_list()`
`TExpression` | `getInput_expr()`
`TWhenClauseItemList` | `getWhenClauseItemList()`
`void` | `init(java.lang.Object arg1, java.lang.Object arg2, java.lang.Object arg3)`

Methods inherited from class gudusoft.gsqlparser.nodes.TParseTreeNode
`addAllMyTokensToTokenList, getColumnNo, getDummyTag, getEndToken, getGsqlparser, getLineNo, getNodeType, getStartToken, init, init, init, init, init, setDummyTag, setEndToken, setEndToken, setGsqlparser, setNodeType, setStartToken, setStartToken, setString, toString`

Methods inherited from class java.lang.Object
`equals, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Constructor Detail

### TCaseExpression

    public TCaseExpression()

Method Detail

### getElse_expr

    public TExpression getElse_expr()

### getInput_expr

    public TExpression getInput_expr()

### getWhenClauseItemList

    public TWhenClauseItemList getWhenClauseItemList()

  Returns:
    List of When...Then... clause.

### getElse_statement_node_list

    public TStatementListSqlNode getElse_statement_node_list()

### getElse_statement_list

    public TStatementList getElse_statement_list()

  Returns:
    else statement list in plsql case statement.

### init

    public void init(java.lang.Object arg1,
                     java.lang.Object arg2,
                     java.lang.Object arg3)

  Overrides:
    `init` in class `TParseTreeNode`

### doParse

    public void doParse(TCustomSqlStatement psql,
                        ESqlClause plocation)

  Description copied from class: `TParseTreeNode`
  analyze this node

  Overrides:
    `doParse` in class `TParseTreeNode`

### accept

    public void accept(TParseTreeVisitor v)

  Specified by:
    `accept` in interface `Visitable`
  Overrides:
    `accept` in class `TParseTreeNode`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD