net.sf.saffron.sql
Class SqlExplain

java.lang.Object
  |
  +--net.sf.saffron.sql.SqlNode
        |
        +--net.sf.saffron.sql.SqlCall
              |
              +--net.sf.saffron.sql.SqlExplain

public class SqlExplain
extends SqlCall

A SqlExplain is a node of a parse tree which represents an EXPLAIN PLAN statement.


Nested Class Summary
 
Nested classes inherited from class net.sf.saffron.sql.SqlNode
SqlNode.DatabaseMetaDataInvocationHandler
 
Field Summary
static int EXPLICANDUM_OPERAND
           
static int OPERAND_COUNT
           
static int WITH_IMPLEMENTATION_OPERAND
           
 
Fields inherited from class net.sf.saffron.sql.SqlCall
operands, operator
 
Constructor Summary
SqlExplain(SqlSpecialOperator operator, SqlNode explicandum, SqlLiteral withImplementation)
           
 
Method Summary
 SqlNode getExplicandum()
          .
 void unparse(SqlWriter writer, int leftPrec, int rightPrec)
          Writes a SQL representation of this node to a writer.
 boolean withImplementation()
          Get the source SELECT expression for the data to be inserted.
 
Methods inherited from class net.sf.saffron.sql.SqlCall
addOperand, clone, getKind, getOperands, isA, setOperand
 
Methods inherited from class net.sf.saffron.sql.SqlNode
cloneArray, toString, toString
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

EXPLICANDUM_OPERAND

public static final int EXPLICANDUM_OPERAND
See Also:
Constant Field Values

WITH_IMPLEMENTATION_OPERAND

public static final int WITH_IMPLEMENTATION_OPERAND
See Also:
Constant Field Values

OPERAND_COUNT

public static final int OPERAND_COUNT
See Also:
Constant Field Values
Constructor Detail

SqlExplain

public SqlExplain(SqlSpecialOperator operator,
                  SqlNode explicandum,
                  SqlLiteral withImplementation)
Method Detail

getExplicandum

public SqlNode getExplicandum()
.

Returns:
the underlying SQL statement to be explained

withImplementation

public boolean withImplementation()
Get the source SELECT expression for the data to be inserted. It is only safe to call this after non-SELECT source expressions (e.g. VALUES) have been expanded by SqlValidator.createInternalSelect

Returns:
the source SELECT for the data to be inserted

unparse

public void unparse(SqlWriter writer,
                    int leftPrec,
                    int rightPrec)
Description copied from class: SqlNode
Writes a SQL representation of this node to a writer.

Overrides:
unparse in class SqlCall

SourceForge.net_Logo