com.akiban.sql.parser
Class CreateTriggerNode
java.lang.Object
com.akiban.sql.parser.QueryTreeNode
com.akiban.sql.parser.StatementNode
com.akiban.sql.parser.DDLStatementNode
com.akiban.sql.parser.CreateTriggerNode
- All Implemented Interfaces:
- Visitable
public class CreateTriggerNode
- extends DDLStatementNode
A CreateTriggerNode is the root of a QueryTree
that represents a CREATE TRIGGER
statement.
|
Method Summary |
void |
copyFrom(QueryTreeNode node)
Fill this node with a deep copy of the given node. |
void |
init(Object triggerName,
Object tableName,
Object triggerEventMask,
Object triggerCols,
Object isBefore,
Object isRow,
Object isEnabled,
Object refClause,
Object whenClause,
Object whenText,
Object whenOffset,
Object actionNode,
Object actionText,
Object actionOffset)
Initializer for a CreateTriggerNode |
void |
printSubNodes(int depth)
Prints the sub-nodes of this object. |
String |
statementToString()
|
String |
toString()
Convert this object to a String. |
| Methods inherited from class com.akiban.sql.parser.QueryTreeNode |
accept, convertDefaultNode, debugFlush, debugPrint, formatNodeString, getBeginOffset, getDebugOutput, getEndOffset, getNodeFactory, getNodeType, getNullNode, getParserContext, getStatementType, getUserData, init, init, init, init, init, init, init, init, init, init, init, init, isInstanceOf, makeTableName, makeTableName, nodeHeader, printLabel, setBeginOffset, setDebugOutput, setEndOffset, setNodeType, setParserContext, setUserData, stackPrint, treePrint, treePrint, treePrint |
TRIGGER_EVENT_UPDATE
public static final int TRIGGER_EVENT_UPDATE
- See Also:
- Constant Field Values
TRIGGER_EVENT_DELETE
public static final int TRIGGER_EVENT_DELETE
- See Also:
- Constant Field Values
TRIGGER_EVENT_INSERT
public static final int TRIGGER_EVENT_INSERT
- See Also:
- Constant Field Values
CreateTriggerNode
public CreateTriggerNode()
init
public void init(Object triggerName,
Object tableName,
Object triggerEventMask,
Object triggerCols,
Object isBefore,
Object isRow,
Object isEnabled,
Object refClause,
Object whenClause,
Object whenText,
Object whenOffset,
Object actionNode,
Object actionText,
Object actionOffset)
throws StandardException
- Initializer for a CreateTriggerNode
- Overrides:
init in class QueryTreeNode
- Parameters:
triggerName - name of the triggertableName - name of the table which the trigger is declared upontriggerEventMask - TRIGGER_EVENT_XXXtriggerCols - columns trigger is to fire upon. Valid for UPDATE case only.isBefore - is before trigger (false for after)isRow - true for row trigger, false for statementisEnabled - true if enabledrefClause - the referencing clausewhenClause - the WHEN clause treewhenText - the text of the WHEN clausewhenOffset - offset of start of WHEN clauseactionNode - the trigger action treeactionText - the text of the trigger actionactionOffset - offset of start of action clause
- Throws:
StandardException - Thrown on error
copyFrom
public void copyFrom(QueryTreeNode node)
throws StandardException
- Fill this node with a deep copy of the given node.
- Overrides:
copyFrom in class DDLStatementNode
- Throws:
StandardException
statementToString
public String statementToString()
- Specified by:
statementToString in class StatementNode
printSubNodes
public void printSubNodes(int depth)
- Prints the sub-nodes of this object. See QueryTreeNode.java for
how tree printing is supposed to work.
- Overrides:
printSubNodes in class QueryTreeNode
- Parameters:
depth - The depth of this node in the tree
toString
public String toString()
- Convert this object to a String. See comments in QueryTreeNode.java
for how this should be done for tree printing.
- Overrides:
toString in class DDLStatementNode
- Returns:
- This object as a String
Copyright © 2013 Akiban Technologies, Inc. All rights reserved.