db-derby-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d..@apache.org
Subject svn commit: r1506827 [2/4] - in /db/derby/code/trunk/java/engine/org/apache/derby: iapi/services/context/ impl/sql/compile/
Date Thu, 25 Jul 2013 07:12:49 GMT
Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CreateSequenceNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CreateSequenceNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CreateSequenceNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CreateSequenceNode.java Thu Jul 25 07:12:46 2013
@@ -28,7 +28,6 @@ import org.apache.derby.iapi.sql.diction
 import org.apache.derby.iapi.types.DataTypeDescriptor;
 import org.apache.derby.iapi.reference.SQLState;
 import org.apache.derby.iapi.services.context.ContextManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.types.TypeId;
 
 
@@ -75,7 +74,6 @@ class CreateSequenceNode extends DDLStat
          ) throws StandardException {
 
         super(sequenceName, cm);
-        setNodeType(C_NodeTypes.CREATE_SEQUENCE_NODE);
         this._sequenceName = sequenceName;
 
         if (dataType != null) {

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CreateTableNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CreateTableNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CreateTableNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CreateTableNode.java Thu Jul 25 07:12:46 2013
@@ -30,7 +30,6 @@ import org.apache.derby.iapi.services.co
 import org.apache.derby.iapi.services.io.FormatableBitSet;
 import org.apache.derby.iapi.services.property.PropertyUtil;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.CompilerContext;
 import org.apache.derby.iapi.sql.compile.Visitor;
 import org.apache.derby.iapi.sql.conn.Authorizer;
@@ -81,7 +80,6 @@ class CreateTableNode extends DDLStateme
             ContextManager   cm) throws StandardException
 	{
         super(tableName, cm);
-        setNodeType(C_NodeTypes.CREATE_TABLE_NODE);
         this.tableType = TableDescriptor.BASE_TABLE_TYPE;
         this.lockGranularity = lockGranularity;
         this.implicitCreateSchema = true;
@@ -124,7 +122,6 @@ class CreateTableNode extends DDLStateme
 		throws StandardException
 	{
         super(tempTableSchemaNameCheck(tableName), cm);
-        setNodeType(C_NodeTypes.CREATE_TABLE_NODE);
 
         this.tableType = TableDescriptor.GLOBAL_TEMPORARY_TABLE_TYPE;
         this.onCommitDeleteRows = onCommitDeleteRows;
@@ -158,7 +155,6 @@ class CreateTableNode extends DDLStateme
             ContextManager cm) throws StandardException
 	{
         super(tableName, cm);
-        setNodeType(C_NodeTypes.CREATE_TABLE_NODE);
         this.tableType = TableDescriptor.BASE_TABLE_TYPE;
         this.lockGranularity = TableDescriptor.DEFAULT_LOCK_GRANULARITY;
         this.implicitCreateSchema = true;

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CreateTriggerNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CreateTriggerNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CreateTriggerNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CreateTriggerNode.java Thu Jul 25 07:12:46 2013
@@ -25,14 +25,12 @@ import java.sql.Timestamp;
 import java.util.Collections;
 import java.util.Comparator;
 import java.util.HashSet;
-import java.util.Iterator;
 import java.util.List;
 import org.apache.derby.catalog.UUID;
 import org.apache.derby.iapi.error.StandardException;
 import org.apache.derby.iapi.reference.SQLState;
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.CompilerContext;
 import org.apache.derby.iapi.sql.conn.Authorizer;
 import org.apache.derby.iapi.sql.conn.LanguageConnectionContext;
@@ -257,7 +255,7 @@ class CreateTriggerNode extends DDLState
 	) throws StandardException
 	{
         super(triggerName, cm);
-        setNodeType(C_NodeTypes.CREATE_TRIGGER_NODE);
+
         this.triggerName = triggerName;
         this.tableName = tableName;
         this.triggerEventMask = triggerEventMask;

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CreateViewNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CreateViewNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CreateViewNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CreateViewNode.java Thu Jul 25 07:12:46 2013
@@ -27,7 +27,6 @@ import org.apache.derby.iapi.reference.L
 import org.apache.derby.iapi.reference.SQLState;
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.CompilerContext;
 import org.apache.derby.iapi.sql.compile.OptimizerFactory;
 import org.apache.derby.iapi.sql.compile.Visitor;
@@ -90,7 +89,6 @@ class CreateViewNode extends DDLStatemen
 		throws StandardException
 	{
         super(viewName, cm);
-        setNodeType(C_NodeTypes.CREATE_VIEW_NODE);
         this.resultColumns = resultColumns;
         this.queryExpression = queryExpression;
         this.checkOption = checkOption;

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CurrentDatetimeOperatorNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CurrentDatetimeOperatorNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CurrentDatetimeOperatorNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CurrentDatetimeOperatorNode.java Thu Jul 25 07:12:46 2013
@@ -28,7 +28,6 @@ import org.apache.derby.iapi.services.co
 import org.apache.derby.iapi.services.compiler.MethodBuilder;
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.CompilerContext;
 import org.apache.derby.iapi.store.access.Qualifier;
 import org.apache.derby.iapi.types.DataTypeDescriptor;
@@ -59,7 +58,6 @@ class CurrentDatetimeOperatorNode extend
 
     CurrentDatetimeOperatorNode(int whichType, ContextManager cm) {
         super(cm);
-        setNodeType(C_NodeTypes.CURRENT_DATETIME_OPERATOR_NODE);
         this.whichType = whichType;
 
         if (SanityManager.DEBUG) {
@@ -174,16 +172,16 @@ class CurrentDatetimeOperatorNode extend
 		}
 	}
         
-        /**
-         * {@inheritDoc}
-         */
-	protected boolean isEquivalent(ValueNode o)
+    /**
+     * {@inheritDoc}
+     */
+    boolean isEquivalent(ValueNode o)
 	{
-		if (isSameNodeType(o)) 
-		{
+        if (isSameNodeKind(o)) {
 			CurrentDatetimeOperatorNode other = (CurrentDatetimeOperatorNode)o;
 			return other.whichType == whichType;
 		}
+
 		return false;
 	}
 }

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CurrentOfNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CurrentOfNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CurrentOfNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CurrentOfNode.java Thu Jul 25 07:12:46 2013
@@ -30,7 +30,6 @@ import org.apache.derby.iapi.services.co
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
 import org.apache.derby.iapi.sql.Activation;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.CostEstimate;
 import org.apache.derby.iapi.sql.compile.Optimizable;
 import org.apache.derby.iapi.sql.compile.OptimizablePredicateList;
@@ -79,7 +78,6 @@ public final class CurrentOfNode extends
                   ContextManager cm)
 	{
         super(correlationName, tableProperties, cm);
-        setNodeType(C_NodeTypes.CURRENT_OF_NODE);
         cursorName = cursor;
 	}
 

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CurrentRowLocationNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CurrentRowLocationNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CurrentRowLocationNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CurrentRowLocationNode.java Thu Jul 25 07:12:46 2013
@@ -29,7 +29,6 @@ import org.apache.derby.iapi.services.cl
 import org.apache.derby.iapi.services.compiler.LocalField;
 import org.apache.derby.iapi.services.compiler.MethodBuilder;
 import org.apache.derby.iapi.services.context.ContextManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.types.DataTypeDescriptor;
 import org.apache.derby.iapi.types.TypeId;
 
@@ -45,7 +44,6 @@ class CurrentRowLocationNode extends Val
 
     CurrentRowLocationNode(ContextManager cm) {
         super(cm);
-        setNodeType(C_NodeTypes.CURRENT_ROW_LOCATION_NODE);
     }
 
 	/**
@@ -157,7 +155,7 @@ class CurrentRowLocationNode extends Val
 		mbex.callMethod(VMOpcode.INVOKEVIRTUAL, (String) null, mb.getName(), ClassName.DataValueDescriptor, 0);
 	}
 	
-	protected boolean isEquivalent(ValueNode o)
+    boolean isEquivalent(ValueNode o)
 	{
 		return false;
 	}

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CursorNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CursorNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CursorNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/CursorNode.java Thu Jul 25 07:12:46 2013
@@ -29,7 +29,6 @@ import org.apache.derby.iapi.reference.S
 import org.apache.derby.iapi.services.compiler.MethodBuilder;
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.Visitor;
 import org.apache.derby.iapi.sql.conn.Authorizer;
 import org.apache.derby.iapi.sql.dictionary.DataDictionary;
@@ -114,7 +113,6 @@ public class CursorNode extends DMLState
                ContextManager cm)
 	{
         super(resultSet, cm);
-        setNodeType(C_NodeTypes.CURSOR_NODE);
         this.name = name;
         this.statementType = statementType;
         this.orderByList = orderByList;

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DB2LengthOperatorNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DB2LengthOperatorNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DB2LengthOperatorNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DB2LengthOperatorNode.java Thu Jul 25 07:12:46 2013
@@ -31,7 +31,6 @@ import org.apache.derby.iapi.services.cl
 import org.apache.derby.iapi.services.compiler.LocalField;
 import org.apache.derby.iapi.services.compiler.MethodBuilder;
 import org.apache.derby.iapi.services.context.ContextManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.types.DataTypeDescriptor;
 import org.apache.derby.iapi.types.TypeId;
 
@@ -50,7 +49,6 @@ public final class DB2LengthOperatorNode
     DB2LengthOperatorNode(ValueNode operand, ContextManager cm)
             throws StandardException {
         super(operand, "length", "getDB2Length", cm);
-        setNodeType(C_NodeTypes.DB2_LENGTH_OPERATOR_NODE);
     }
 
     /**

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DefaultNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DefaultNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DefaultNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DefaultNode.java Thu Jul 25 07:12:46 2013
@@ -27,7 +27,6 @@ import org.apache.derby.iapi.error.Stand
 import org.apache.derby.iapi.services.compiler.MethodBuilder;
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.CompilerContext;
 import org.apache.derby.iapi.sql.compile.Parser;
 import org.apache.derby.iapi.sql.compile.Visitable;
@@ -52,7 +51,6 @@ public  class DefaultNode extends ValueN
      */
     DefaultNode(ContextManager cm) {
         super(cm);
-        setNodeType(C_NodeTypes.DEFAULT_NODE);
     }
 
     /**
@@ -66,7 +64,6 @@ public  class DefaultNode extends ValueN
                 String defaultText,
                 ContextManager cm) {
         super(cm);
-        setNodeType(C_NodeTypes.DEFAULT_NODE);
         this.defaultTree = defaultTree;
         this.defaultText = defaultText;
 	}
@@ -77,7 +74,6 @@ public  class DefaultNode extends ValueN
 	 */
     DefaultNode(String columnName, ContextManager cm) {
         super(cm);
-        setNodeType(C_NodeTypes.DEFAULT_NODE);
         this.columnName = columnName;
 	}
 
@@ -300,7 +296,7 @@ public  class DefaultNode extends ValueN
     /**
      * @inheritDoc
      */
-	protected boolean isEquivalent(ValueNode other)
+    boolean isEquivalent(ValueNode other)
     {
 		return false;
     }

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DeleteNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DeleteNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DeleteNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DeleteNode.java Thu Jul 25 07:12:46 2013
@@ -40,7 +40,6 @@ import org.apache.derby.iapi.services.io
 import org.apache.derby.iapi.services.sanity.SanityManager;
 import org.apache.derby.iapi.sql.ResultDescription;
 import org.apache.derby.iapi.sql.StatementType;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.conn.Authorizer;
 import org.apache.derby.iapi.sql.dictionary.ColumnDescriptor;
 import org.apache.derby.iapi.sql.dictionary.ColumnDescriptorList;
@@ -92,7 +91,6 @@ class DeleteNode extends DMLModStatement
                ResultSetNode queryExpression,
                ContextManager cm) {
         super(queryExpression, cm);
-        setNodeType(C_NodeTypes.DELETE_NODE);
         this.targetTableName = targetTableName;
 	}
 

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DistinctNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DistinctNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DistinctNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DistinctNode.java Thu Jul 25 07:12:46 2013
@@ -29,7 +29,6 @@ import org.apache.derby.iapi.services.cl
 import org.apache.derby.iapi.services.compiler.MethodBuilder;
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.CostEstimate;
 import org.apache.derby.iapi.sql.compile.Optimizable;
 import org.apache.derby.iapi.sql.compile.OptimizablePredicate;
@@ -72,7 +71,6 @@ class DistinctNode extends SingleChildRe
                  ContextManager cm) throws StandardException
 	{
         super(childResult, tableProperties, cm);
-        setNodeType(C_NodeTypes.DISTINCT_NODE);
 
 		if (SanityManager.DEBUG)
 		{

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropAliasNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropAliasNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropAliasNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropAliasNode.java Thu Jul 25 07:12:46 2013
@@ -26,7 +26,6 @@ import org.apache.derby.iapi.error.Stand
 import org.apache.derby.iapi.reference.SQLState;
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.dictionary.AliasDescriptor;
 import org.apache.derby.iapi.sql.dictionary.DataDictionary;
 import org.apache.derby.iapi.sql.dictionary.SchemaDescriptor;
@@ -55,7 +54,6 @@ class DropAliasNode extends DDLStatement
 				throws StandardException
 	{
         super(dropAliasName, cm);
-        setNodeType(C_NodeTypes.DROP_ALIAS_NODE);
         this.aliasType = aliasType;
 	
 		switch (this.aliasType)

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropIndexNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropIndexNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropIndexNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropIndexNode.java Thu Jul 25 07:12:46 2013
@@ -24,7 +24,6 @@ package	org.apache.derby.impl.sql.compil
 import org.apache.derby.iapi.error.StandardException;
 import org.apache.derby.iapi.reference.SQLState;
 import org.apache.derby.iapi.services.context.ContextManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.CompilerContext;
 import org.apache.derby.iapi.sql.dictionary.ConglomerateDescriptor;
 import org.apache.derby.iapi.sql.dictionary.ConstraintDescriptor;
@@ -46,7 +45,6 @@ class DropIndexNode extends DDLStatement
 
     DropIndexNode(TableName index, ContextManager cm) {
         super(index, cm);
-        setNodeType(C_NodeTypes.DROP_INDEX_NODE);
     }
 
     String statementToString()

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropRoleNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropRoleNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropRoleNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropRoleNode.java Thu Jul 25 07:12:46 2013
@@ -25,7 +25,6 @@ import org.apache.derby.iapi.error.Stand
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
 import org.apache.derby.iapi.sql.compile.CompilerContext;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.conn.Authorizer;
 import org.apache.derby.iapi.sql.execute.ConstantAction;
 
@@ -50,7 +49,6 @@ class DropRoleNode extends DDLStatementN
     {
         super(null, cm);
         this.roleName = roleName;
-        setNodeType(C_NodeTypes.DROP_ROLE_NODE);
     }
 
     @Override

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropSchemaNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropSchemaNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropSchemaNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropSchemaNode.java Thu Jul 25 07:12:46 2013
@@ -25,7 +25,6 @@ import org.apache.derby.iapi.error.Stand
 import org.apache.derby.iapi.reference.SQLState;
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.conn.Authorizer;
 import org.apache.derby.iapi.sql.conn.LanguageConnectionContext;
 import org.apache.derby.iapi.sql.conn.StatementContext;
@@ -53,7 +52,6 @@ class DropSchemaNode extends DDLStatemen
     DropSchemaNode(String schemaName, int dropBehavior, ContextManager cm)
 	{
         super(null, cm);
-        setNodeType(C_NodeTypes.DROP_SCHEMA_NODE);
         this.schemaName = schemaName;
         this.dropBehavior = dropBehavior;
 	}

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropSequenceNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropSequenceNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropSequenceNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropSequenceNode.java Thu Jul 25 07:12:46 2013
@@ -25,7 +25,6 @@ import org.apache.derby.iapi.sql.execute
 import org.apache.derby.iapi.reference.SQLState;
 import org.apache.derby.iapi.error.StandardException;
 import org.apache.derby.iapi.services.context.ContextManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.dictionary.DataDictionary;
 import org.apache.derby.iapi.sql.dictionary.SchemaDescriptor;
 import org.apache.derby.iapi.sql.dictionary.SequenceDescriptor;
@@ -46,7 +45,6 @@ class DropSequenceNode extends DDLStatem
      */
     DropSequenceNode(TableName dropSequenceName, ContextManager cm) {
         super(dropSequenceName, cm);
-        setNodeType(C_NodeTypes.DROP_SEQUENCE_NODE);
         dropItem = dropSequenceName;
     }
 

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropTableNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropTableNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropTableNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropTableNode.java Thu Jul 25 07:12:46 2013
@@ -24,7 +24,6 @@ package	org.apache.derby.impl.sql.compil
 import org.apache.derby.iapi.error.StandardException;
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.CompilerContext;
 import org.apache.derby.iapi.sql.dictionary.ConglomerateDescriptor;
 import org.apache.derby.iapi.sql.dictionary.TableDescriptor;
@@ -55,7 +54,6 @@ class DropTableNode extends DDLStatement
 	{
         super(dropObjectName, cm);
         this.dropBehavior = dropBehavior;
-        setNodeType(C_NodeTypes.DROP_TABLE_NODE);
 	}
 
 	/**

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropTriggerNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropTriggerNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropTriggerNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropTriggerNode.java Thu Jul 25 07:12:46 2013
@@ -24,7 +24,6 @@ package	org.apache.derby.impl.sql.compil
 import org.apache.derby.iapi.error.StandardException;
 import org.apache.derby.iapi.reference.SQLState;
 import org.apache.derby.iapi.services.context.ContextManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.CompilerContext;
 import org.apache.derby.iapi.sql.dictionary.DataDictionary;
 import org.apache.derby.iapi.sql.dictionary.SchemaDescriptor;
@@ -43,7 +42,6 @@ class DropTriggerNode extends DDLStateme
 
     DropTriggerNode(TableName trigger, ContextManager cm) {
         super(trigger, cm);
-        setNodeType(C_NodeTypes.DROP_TRIGGER_NODE);
     }
 
     String statementToString()

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropViewNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropViewNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropViewNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/DropViewNode.java Thu Jul 25 07:12:46 2013
@@ -23,7 +23,6 @@ package	org.apache.derby.impl.sql.compil
 
 import org.apache.derby.iapi.error.StandardException;
 import org.apache.derby.iapi.services.context.ContextManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.CompilerContext;
 import org.apache.derby.iapi.sql.dictionary.DataDictionary;
 import org.apache.derby.iapi.sql.dictionary.TableDescriptor;
@@ -48,7 +47,6 @@ class DropViewNode extends DDLStatementN
     DropViewNode(TableName view, ContextManager cm)
 	{
         super(view, cm);
-        setNodeType(C_NodeTypes.DROP_VIEW_NODE);
 	}
 
     String statementToString()

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/ExecSPSNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/ExecSPSNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/ExecSPSNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/ExecSPSNode.java Thu Jul 25 07:12:46 2013
@@ -27,7 +27,6 @@ import org.apache.derby.iapi.services.co
 import org.apache.derby.iapi.services.loader.GeneratedClass;
 import org.apache.derby.iapi.services.sanity.SanityManager;
 import org.apache.derby.iapi.sql.ResultDescription;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.dictionary.DataDictionary;
 import org.apache.derby.iapi.sql.dictionary.SPSDescriptor;
 import org.apache.derby.iapi.sql.dictionary.SchemaDescriptor;
@@ -67,7 +66,6 @@ class ExecSPSNode extends StatementNode
     ExecSPSNode(TableName newObjectName,
                 ContextManager cm) {
         super(cm);
-        setNodeType(C_NodeTypes.EXEC_SPS_NODE);
         this.name = newObjectName;
 	}
 

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/ExtractOperatorNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/ExtractOperatorNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/ExtractOperatorNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/ExtractOperatorNode.java Thu Jul 25 07:12:46 2013
@@ -27,7 +27,6 @@ import org.apache.derby.iapi.error.Stand
 import org.apache.derby.iapi.reference.SQLState;
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.TypeCompiler;
 import org.apache.derby.iapi.types.DataTypeDescriptor;
 import org.apache.derby.iapi.types.DateTimeDataValue;
@@ -55,7 +54,6 @@ static private final String fieldName[] 
                 "EXTRACT " + fieldName[field],
                 fieldMethod[field],
                 cm);
-        setNodeType(C_NodeTypes.EXTRACT_OPERATOR_NODE);
         this.extractField = field;
     }
 

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/FKConstraintDefinitionNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/FKConstraintDefinitionNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/FKConstraintDefinitionNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/FKConstraintDefinitionNode.java Thu Jul 25 07:12:46 2013
@@ -26,7 +26,6 @@ import org.apache.derby.iapi.reference.S
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
 import org.apache.derby.iapi.sql.StatementType;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.conn.Authorizer;
 import org.apache.derby.iapi.sql.dictionary.ColumnDescriptor;
 import org.apache.derby.iapi.sql.dictionary.DataDictionary;
@@ -64,7 +63,6 @@ public final class FKConstraintDefinitio
               StatementType.DROP_DEFAULT,
               DataDictionary.DROP_CONSTRAINT,
               cm);
-        setNodeType(C_NodeTypes.FK_CONSTRAINT_DEFINITION_NODE);
 
         this.refRcl = refRcl;
         this.refTableName = refTableName;

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/FromBaseTable.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/FromBaseTable.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/FromBaseTable.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/FromBaseTable.java Thu Jul 25 07:12:46 2013
@@ -41,11 +41,9 @@ import org.apache.derby.iapi.services.pr
 import org.apache.derby.iapi.services.sanity.SanityManager;
 import org.apache.derby.iapi.sql.LanguageProperties;
 import org.apache.derby.iapi.sql.compile.AccessPath;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.CompilerContext;
 import org.apache.derby.iapi.sql.compile.CostEstimate;
 import org.apache.derby.iapi.sql.compile.JoinStrategy;
-import org.apache.derby.iapi.sql.compile.Optimizable;
 import org.apache.derby.iapi.sql.compile.OptimizablePredicate;
 import org.apache.derby.iapi.sql.compile.OptimizablePredicateList;
 import org.apache.derby.iapi.sql.compile.Optimizer;
@@ -209,7 +207,6 @@ class FromBaseTable extends FromTable
                   ContextManager cm)
     {
         super(correlationName, tableProperties, cm);
-        setNodeType(C_NodeTypes.FROM_BASE_TABLE);
         this.tableName = tableName;
         resultColumns = derivedRCL;
         setOrigTableName(this.tableName);
@@ -232,7 +229,6 @@ class FromBaseTable extends FromTable
                   ContextManager cm)
 	{
         super(correlationName, null, cm);
-        setNodeType(C_NodeTypes.FROM_BASE_TABLE);
         this.tableName = tableName;
         this.updateOrDelete = updateOrDelete;
         resultColumns = derivedRCL;

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/FromList.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/FromList.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/FromList.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/FromList.java Thu Jul 25 07:12:46 2013
@@ -28,7 +28,6 @@ import org.apache.derby.iapi.error.Stand
 import org.apache.derby.iapi.reference.SQLState;
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.Optimizable;
 import org.apache.derby.iapi.sql.compile.OptimizableList;
 import org.apache.derby.iapi.sql.compile.Optimizer;
@@ -82,7 +81,6 @@ class FromList extends    QueryTreeNodeV
     FromList(ContextManager cm) {
         super(ResultSetNode.class, cm);
         this.isTransparent = false;
-        setNodeType(C_NodeTypes.FROM_LIST);
     }
 
     /**
@@ -120,7 +118,6 @@ class FromList extends    QueryTreeNodeV
     private void constructorMinion(boolean optimizeJoinOrder) {
         this.fixedJoinOrder = !optimizeJoinOrder;
         this.isTransparent = false;
-        setNodeType(C_NodeTypes.FROM_LIST);
     }
 	/*
 	 * OptimizableList interface

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/FromSubquery.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/FromSubquery.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/FromSubquery.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/FromSubquery.java Thu Jul 25 07:12:46 2013
@@ -25,7 +25,6 @@ import java.util.Properties;
 import org.apache.derby.iapi.error.StandardException;
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.CompilerContext;
 import org.apache.derby.iapi.sql.compile.Visitor;
 import org.apache.derby.iapi.sql.dictionary.DataDictionary;
@@ -81,7 +80,6 @@ class FromSubquery extends FromTable
                  ContextManager cm)
 	{
         super(correlationName, tableProperties, cm);
-        setNodeType(C_NodeTypes.FROM_SUBQUERY);
         this.subquery = subquery;
         this.orderByList = orderByList;
         this.offset = offset;

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/FromVTI.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/FromVTI.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/FromVTI.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/FromVTI.java Thu Jul 25 07:12:46 2013
@@ -48,7 +48,6 @@ import org.apache.derby.iapi.services.io
 import org.apache.derby.iapi.services.io.FormatableHashtable;
 import org.apache.derby.iapi.services.loader.ClassInspector;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.CostEstimate;
 import org.apache.derby.iapi.sql.compile.Optimizable;
 import org.apache.derby.iapi.sql.compile.OptimizablePredicate;
@@ -182,7 +181,6 @@ class FromVTI extends FromTable implemen
             ResultColumnList derivedRCL,
             TableName exposedTableName) {
 
-        setNodeType(C_NodeTypes.FROM_VTI);
         this.methodCall = invocation;
         this.resultColumns = derivedRCL;
         this.subqueryList = new SubqueryList(getContextManager());

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GenerationClauseNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GenerationClauseNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GenerationClauseNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GenerationClauseNode.java Thu Jul 25 07:12:46 2013
@@ -27,7 +27,6 @@ import org.apache.derby.iapi.reference.S
 import org.apache.derby.iapi.services.compiler.MethodBuilder;
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.depend.ProviderList;
 
 /**
@@ -66,7 +65,6 @@ class GenerationClauseNode extends Value
                           ContextManager cm)
     {
         super(cm);
-        setNodeType(C_NodeTypes.GENERATION_CLAUSE_NODE);
         _generationExpression = generationExpression;
         _expressionText = expressionText;
 	}
@@ -120,10 +118,12 @@ class GenerationClauseNode extends Value
         throw StandardException.newException( SQLState.HEAP_UNIMPLEMENTED_FEATURE );
 	}
 
-	protected boolean isEquivalent(ValueNode other)
+    boolean isEquivalent(ValueNode other)
 		throws StandardException
     {
-        if ( !( other instanceof GenerationClauseNode) ) { return false; }
+        if (! isSameNodeKind(other)) {
+            return false;
+        }
 
         GenerationClauseNode    that = (GenerationClauseNode) other;
 

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GetCurrentConnectionNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GetCurrentConnectionNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GetCurrentConnectionNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GetCurrentConnectionNode.java Thu Jul 25 07:12:46 2013
@@ -27,7 +27,6 @@ import org.apache.derby.iapi.reference.C
 import org.apache.derby.iapi.services.classfile.VMOpcode;
 import org.apache.derby.iapi.services.compiler.MethodBuilder;
 import org.apache.derby.iapi.services.context.ContextManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.CompilerContext;
 import org.apache.derby.iapi.store.access.Qualifier;
 import org.apache.derby.iapi.util.JBitSet;
@@ -49,7 +48,6 @@ public final class GetCurrentConnectionN
     GetCurrentConnectionNode(ContextManager cm)
 	{
         super(cm);
-        setNodeType(C_NodeTypes.GET_CURRENT_CONNECTION_NODE);
 		/*
 		** The result type of getCurrentConnection is
 		** java.sql.Connection

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GrantNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GrantNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GrantNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GrantNode.java Thu Jul 25 07:12:46 2013
@@ -27,7 +27,6 @@ import java.util.List;
 import org.apache.derby.iapi.error.StandardException;
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.depend.Provider;
 import org.apache.derby.iapi.sql.execute.ConstantAction;
 
@@ -51,7 +50,6 @@ class GrantNode extends DDLStatementNode
               ContextManager cm)
     {
         super(cm);
-        setNodeType(C_NodeTypes.GRANT_NODE);
         this.privileges = privileges;
         this.grantees = grantees;
     }

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GrantRoleNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GrantRoleNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GrantRoleNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GrantRoleNode.java Thu Jul 25 07:12:46 2013
@@ -25,7 +25,6 @@ import java.util.List;
 import org.apache.derby.iapi.error.StandardException;
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.execute.ConstantAction;
 
 /**
@@ -49,7 +48,6 @@ class GrantRoleNode extends DDLStatement
         super(null, cm);
         this.roles = roles;
         this.grantees = grantees;
-        setNodeType(C_NodeTypes.GRANT_ROLE_NODE);
     }
 
 

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GroupByColumn.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GroupByColumn.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GroupByColumn.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GroupByColumn.java Thu Jul 25 07:12:46 2013
@@ -26,7 +26,6 @@ import org.apache.derby.iapi.error.Stand
 import org.apache.derby.iapi.reference.SQLState;
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.CompilerContext;
 import org.apache.derby.iapi.sql.compile.Visitor;
 import org.apache.derby.iapi.types.TypeId;
@@ -49,7 +48,6 @@ class GroupByColumn extends OrderedColum
                   ContextManager cm)
 	{
         super(cm);
-        setNodeType(C_NodeTypes.GROUP_BY_COLUMN);
         this.columnExpression = colRef;
 	}
 

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GroupByList.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GroupByList.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GroupByList.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GroupByList.java Thu Jul 25 07:12:46 2013
@@ -27,7 +27,6 @@ import org.apache.derby.iapi.reference.L
 import org.apache.derby.iapi.reference.SQLState;
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 
 /**
  * A GroupByList represents the list of expressions in a GROUP BY clause in
@@ -42,7 +41,6 @@ class GroupByList extends OrderedColumnL
 
     public GroupByList(ContextManager cm) {
         super(GroupByColumn.class, cm);
-        setNodeType(C_NodeTypes.GROUP_BY_LIST);
     }
 
 

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GroupByNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GroupByNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GroupByNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/GroupByNode.java Thu Jul 25 07:12:46 2013
@@ -37,7 +37,6 @@ import org.apache.derby.iapi.services.sa
 import org.apache.derby.iapi.sql.LanguageFactory;
 import org.apache.derby.iapi.sql.ResultColumnDescriptor;
 import org.apache.derby.iapi.sql.compile.AccessPath;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.CostEstimate;
 import org.apache.derby.iapi.sql.compile.Optimizable;
 import org.apache.derby.iapi.sql.compile.OptimizablePredicate;
@@ -135,7 +134,6 @@ class GroupByNode extends SingleChildRes
 			throws StandardException
 	{
         super(bottomPR, null /* tableProperties */, cm);
-        setNodeType(C_NodeTypes.GROUP_BY_NODE);
         setLevel(nestingLevel);
         this.havingClause = havingClause;
         this.havingSubquerys = havingSubquerys;

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/HalfOuterJoinNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/HalfOuterJoinNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/HalfOuterJoinNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/HalfOuterJoinNode.java Thu Jul 25 07:12:46 2013
@@ -26,7 +26,6 @@ import org.apache.derby.iapi.error.Stand
 import org.apache.derby.iapi.services.compiler.MethodBuilder;
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.CostEstimate;
 import org.apache.derby.iapi.sql.compile.Optimizable;
 import org.apache.derby.iapi.sql.compile.OptimizablePredicate;
@@ -75,7 +74,6 @@ class HalfOuterJoinNode extends JoinNode
 				tableProperties,
                 null,
                 cm);
-        setNodeType(C_NodeTypes.HALF_OUTER_JOIN_NODE);
         this.rightOuterJoin = rightOuterJoin;
 
 		/* We can only flatten an outer join
@@ -690,7 +688,8 @@ private boolean isNullRejecting (
 			ValueNode left = and.getLeftOperand();
 
 			/* Skip IS NULL predicates as they are not null intolerant */
-			if (left.isInstanceOf(C_NodeTypes.IS_NULL_NODE))
+            if (left.getClass().equals(IsNullNode.class) &&
+                ((IsNullNode)left).isNullNode())
 			{
 				vn = and.getRightOperand();
 				continue;

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/HashTableNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/HashTableNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/HashTableNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/HashTableNode.java Thu Jul 25 07:12:46 2013
@@ -31,7 +31,6 @@ import org.apache.derby.iapi.services.co
 import org.apache.derby.iapi.services.io.FormatableArrayHolder;
 import org.apache.derby.iapi.services.io.FormatableIntHolder;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.CostEstimate;
 import org.apache.derby.iapi.sql.compile.Optimizable;
 import org.apache.derby.iapi.sql.compile.Optimizer;
@@ -79,7 +78,6 @@ class HashTableNode extends SingleChildR
                   ContextManager cm)
 	{
         super(childResult, tableProperties, cm);
-        setNodeType(C_NodeTypes.HASH_TABLE_NODE);
         this.resultColumns = resultColumns;
         this.searchPredicateList = searchPredicateList;
         this.joinPredicateList = joinPredicateList;

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/InListOperatorNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/InListOperatorNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/InListOperatorNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/InListOperatorNode.java Thu Jul 25 07:12:46 2013
@@ -30,7 +30,6 @@ import org.apache.derby.iapi.services.co
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.loader.ClassFactory;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.Optimizable;
 import org.apache.derby.iapi.types.DataTypeDescriptor;
 import org.apache.derby.iapi.types.DataValueDescriptor;
@@ -57,7 +56,6 @@ public final class InListOperatorNode ex
             ValueNodeList rightOperandList,
             ContextManager cm) throws StandardException {
         super(leftOperand, rightOperandList, "IN", "in", cm);
-        setNodeType(C_NodeTypes.IN_LIST_OPERATOR_NODE);
     }
 
     /**
@@ -135,11 +133,11 @@ public final class InListOperatorNode ex
 		{
 			BinaryComparisonOperatorNode equal = 
                 new BinaryRelationalOperatorNode(
-						C_NodeTypes.BINARY_EQUALS_OPERATOR_NODE,
-						leftOperand, 
-                        rightOperandList.elementAt(0),
-                        false,
-						getContextManager());
+                    BinaryRelationalOperatorNode.K_EQUALS,
+                    leftOperand,
+                    rightOperandList.elementAt(0),
+                    false,
+                    getContextManager());
 			/* Set type info for the operator node */
 			equal.bindComparisonOperator();
 			return equal;
@@ -274,7 +272,7 @@ public final class InListOperatorNode ex
 				{
 					BinaryComparisonOperatorNode equal = 
                         new BinaryRelationalOperatorNode(
-							C_NodeTypes.BINARY_EQUALS_OPERATOR_NODE,
+                            BinaryRelationalOperatorNode.K_EQUALS,
 							leftOperand, 
 							minValue,
                             false,
@@ -341,7 +339,7 @@ public final class InListOperatorNode ex
 			 */
 			BinaryComparisonOperatorNode equal = 
                 new BinaryRelationalOperatorNode(
-					C_NodeTypes.BINARY_EQUALS_OPERATOR_NODE,
+                    BinaryRelationalOperatorNode.K_EQUALS,
 					leftOperand, 
 					pNode,
 					this,
@@ -435,11 +433,11 @@ public final class InListOperatorNode ex
 		 */
 		ValueNode leftClone = (leftOperand instanceof ColumnReference) ? leftOperand.getClone() : leftOperand;
         leftBCO = new BinaryRelationalOperatorNode(
-						C_NodeTypes.BINARY_NOT_EQUALS_OPERATOR_NODE,
-						leftClone,
-                        rightOperandList.elementAt(0),
-                        false,
-						getContextManager());
+                BinaryRelationalOperatorNode.K_NOT_EQUALS,
+                leftClone,
+                rightOperandList.elementAt(0),
+                false,
+                getContextManager());
 		/* Set type info for the operator node */
 		leftBCO.bindComparisonOperator();
 
@@ -451,11 +449,11 @@ public final class InListOperatorNode ex
 			/* leftO <> rightOList.elementAt(elemsDone) */
 			leftClone = (leftOperand instanceof ColumnReference) ? leftOperand.getClone() : leftOperand;
             rightBCO = new BinaryRelationalOperatorNode(
-							C_NodeTypes.BINARY_NOT_EQUALS_OPERATOR_NODE,
-							leftClone,
-                            rightOperandList.elementAt(elemsDone),
-                            false,
-							getContextManager());
+                    BinaryRelationalOperatorNode.K_NOT_EQUALS,
+                    leftClone,
+                    rightOperandList.elementAt(elemsDone),
+                    false,
+                    getContextManager());
 			/* Set type info for the operator node */
 			rightBCO.bindComparisonOperator();
 

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/IndexToBaseRowNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/IndexToBaseRowNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/IndexToBaseRowNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/IndexToBaseRowNode.java Thu Jul 25 07:12:46 2013
@@ -31,7 +31,6 @@ import org.apache.derby.iapi.services.co
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.io.FormatableBitSet;
 import org.apache.derby.iapi.sql.compile.AccessPath;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.CostEstimate;
 import org.apache.derby.iapi.sql.compile.Optimizable;
 import org.apache.derby.iapi.sql.compile.RequiredRowOrdering;
@@ -70,7 +69,6 @@ class IndexToBaseRowNode extends FromTab
             ContextManager   cm)
 	{
         super(null, tableProperties, cm);
-        setNodeType(C_NodeTypes.INDEX_TO_BASE_ROW_NODE);
         this.source = source;
         this.baseCD = baseCD;
         this.resultColumns = resultColumns;

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/InsertNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/InsertNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/InsertNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/InsertNode.java Thu Jul 25 07:12:46 2013
@@ -32,7 +32,6 @@ import org.apache.derby.iapi.services.co
 import org.apache.derby.iapi.services.io.FormatableBitSet;
 import org.apache.derby.iapi.services.sanity.SanityManager;
 import org.apache.derby.iapi.sql.StatementType;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.CompilerContext;
 import org.apache.derby.iapi.sql.compile.Visitor;
 import org.apache.derby.iapi.sql.conn.Authorizer;
@@ -125,7 +124,6 @@ public final class InsertNode extends DM
 		 * right statementType for a bulk insert replace.
 		 */
         super(queryExpression, getStatementType(targetProperties), cm);
-        setNodeType(C_NodeTypes.INSERT_NODE);
         setTarget(targetName);
         targetColumnList = insertColumns;
         this.targetProperties = targetProperties;

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/IntersectOrExceptNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/IntersectOrExceptNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/IntersectOrExceptNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/IntersectOrExceptNode.java Thu Jul 25 07:12:46 2013
@@ -30,7 +30,6 @@ import org.apache.derby.iapi.services.cl
 import org.apache.derby.iapi.services.compiler.MethodBuilder;
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.CostEstimate;
 import org.apache.derby.iapi.sql.compile.Optimizable;
 import org.apache.derby.iapi.sql.compile.OptimizablePredicateList;
@@ -97,7 +96,6 @@ public class IntersectOrExceptNode exten
                           ContextManager cm) throws StandardException {
 
         super(leftResult, rightResult, all, tableProperties, cm);
-        setNodeType(C_NodeTypes.INTERSECT_OR_EXCEPT_NODE);
         this.opType = opType;
     }
 

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/IsNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/IsNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/IsNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/IsNode.java Thu Jul 25 07:12:46 2013
@@ -27,7 +27,6 @@ import org.apache.derby.iapi.reference.C
 import org.apache.derby.iapi.services.classfile.VMOpcode;
 import org.apache.derby.iapi.services.compiler.MethodBuilder;
 import org.apache.derby.iapi.services.context.ContextManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 
 class IsNode extends BinaryLogicalOperatorNode
 {
@@ -49,7 +48,6 @@ class IsNode extends BinaryLogicalOperat
 	{
 		// the false for shortCir
         super(leftOperand, rightOperand, "is", cm );
-        setNodeType(C_NodeTypes.IS_NODE);
         this.notMe = notMe;
 	}
 

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/IsNullNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/IsNullNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/IsNullNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/IsNullNode.java Thu Jul 25 07:12:46 2013
@@ -27,7 +27,6 @@ import org.apache.derby.iapi.reference.C
 import org.apache.derby.iapi.services.compiler.MethodBuilder;
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.Optimizable;
 import org.apache.derby.iapi.store.access.ScanController;
 import org.apache.derby.iapi.types.DataTypeDescriptor;
@@ -44,49 +43,25 @@ import org.apache.derby.iapi.types.TypeI
 public final class IsNullNode extends UnaryComparisonOperatorNode
 						implements RelationalOperator
 {
-    enum Sign {IS_NULL, IS_NOT_NULL};
 	private DataValueDescriptor nullValue;
 
-    IsNullNode(ValueNode operand, Sign t, ContextManager cm)
+    /**
+     * If {@code true}, this node represents a NOT NULL node rather than a
+     * NULL node. Note that this state is mutable, cf {@link #getNegation}.
+     */
+    private boolean notNull;
+
+    IsNullNode(ValueNode operand, boolean notNull, ContextManager cm)
             throws StandardException {
         super(operand, cm);
-        setNodeType(
-            t == Sign.IS_NOT_NULL ?
-                C_NodeTypes.IS_NOT_NULL_NODE :
-                C_NodeTypes.IS_NULL_NODE);
+        this.notNull = notNull;
+        updateOperatorDetails();
     }
 
-    @Override
-    void setNodeType(int nodeType)
+    private void updateOperatorDetails()
 	{
-        String op;
-        String methodNam;
-
-		if (nodeType == C_NodeTypes.IS_NULL_NODE)
-		{
-			/* By convention, the method name for the is null operator is "isNull" */
-            op = "is null";
-            methodNam = "isNullOp";
-		}
-		else
-		{
-			if (SanityManager.DEBUG)
-			{
-				if (nodeType != C_NodeTypes.IS_NOT_NULL_NODE)
-				{
-					SanityManager.THROWASSERT(
-						"Unexpected nodeType = " + nodeType);
-				}
-			}
-			/* By convention, the method name for the is not null operator is 
-			 * "isNotNull" 
-			 */
-            op = "is not null";
-            methodNam = "isNotNull";
-		}
-        setOperator(op);
-        setMethodName(methodNam);
-		super.setNodeType(nodeType);
+        setOperator(notNull ? "is not null" : "is null");
+        setMethodName(notNull ? "isNotNull" : "isNullOp");
 	}
 
 	/**
@@ -101,30 +76,14 @@ public final class IsNullNode extends Un
 	UnaryOperatorNode getNegation(ValueNode operand)
 				throws StandardException
 	{
-		UnaryOperatorNode negation;
-
 		if (SanityManager.DEBUG)
 		{
 			SanityManager.ASSERT(getTypeServices() != null,
 						"dataTypeServices is expected to be non-null");
 		}
 
-		if (isNullNode())
-		{
-			setNodeType(C_NodeTypes.IS_NOT_NULL_NODE);
-		}
-		else
-		{
-			if (SanityManager.DEBUG)
-			{
-				if (! isNotNullNode())
-				{
-					SanityManager.THROWASSERT(
-						"Unexpected nodeType = " + getNodeType());
-				}
-			}
-			setNodeType(C_NodeTypes.IS_NULL_NODE);
-		}
+        notNull = !notNull;
+        updateOperatorDetails();
 		return this;
 	}
 
@@ -166,30 +125,28 @@ public final class IsNullNode extends Un
 	}
 
 	/** @see RelationalOperator#getStartOperator */
+    @Override
 	public int getStartOperator(Optimizable optTable)
 	{
-		if (SanityManager.DEBUG)
-		{
-			if (! isNullNode())
-			{
-				SanityManager.THROWASSERT(
-					"getNodeType() not expected to return " + getNodeType());
+        if (SanityManager.DEBUG) {
+            if (notNull) {
+                SanityManager.THROWASSERT("NOT NULL not expected here");
 			}
 		}
+
 		return ScanController.GE;
 	}
 
 	/** @see RelationalOperator#getStopOperator */
+    @Override
 	public int getStopOperator(Optimizable optTable)
 	{
-		if (SanityManager.DEBUG)
-		{
-			if (! isNullNode())
-			{
-				SanityManager.THROWASSERT(
-					"getNodeType() not expected to return " + getNodeType());
+        if (SanityManager.DEBUG) {
+            if (notNull) {
+                SanityManager.THROWASSERT("NOT NULL not expected here");
 			}
 		}
+
 		return ScanController.GT;
 	}
 
@@ -204,31 +161,13 @@ public final class IsNullNode extends Un
 	public void generateNegate(MethodBuilder mb,
 										Optimizable optTable)
 	{
-		mb.push(isNotNullNode());
+        mb.push(notNull);
 	}
 
 	/** @see RelationalOperator#getOperator */
 	public int getOperator()
 	{
-        int op;
-		if (isNullNode())
-		{
-            op = IS_NULL_RELOP;
-		}
-		else
-		{
-			if (SanityManager.DEBUG)
-			{
-				if (! isNotNullNode())
-				{
-					SanityManager.THROWASSERT(
-						"Unexpected nodeType = " + getNodeType());
-				}
-			}
-            op = IS_NOT_NULL_RELOP;
-		}
-
-        return op;
+        return notNull ? IS_NOT_NULL_RELOP : IS_NULL_RELOP;
 	}
 
 	/** @see RelationalOperator#compareWithKnownConstant */
@@ -256,14 +195,14 @@ public final class IsNullNode extends Un
 	/** @see RelationalOperator#equalsComparisonWithConstantExpression */
 	public boolean equalsComparisonWithConstantExpression(Optimizable optTable)
 	{
-		boolean retval = false;
-
 		// Always return false for NOT NULL
-		if (isNotNullNode())
+        if (notNull)
 		{
 			return false;
 		}
 
+        boolean retval = false;
+
 		/*
 		** Is the operand a column in the given table?
 		*/
@@ -288,11 +227,7 @@ public final class IsNullNode extends Un
 	public RelationalOperator getTransitiveSearchClause(ColumnReference otherCR)
 		throws StandardException
 	{
-        return new IsNullNode(otherCR,
-                getNodeType() == C_NodeTypes.IS_NULL_NODE ?
-                Sign.IS_NULL :
-                Sign.IS_NOT_NULL,
-                getContextManager());
+        return new IsNullNode(otherCR, notNull, getContextManager());
 	}
 
 	/**
@@ -304,39 +239,23 @@ public final class IsNullNode extends Un
 	    return ClassName.DataValueDescriptor;
 	}
 
-	/** IS NULL is like =, so should have the same selectivity */
     @Override
 	public double selectivity(Optimizable optTable) 
 	{
-		if (isNullNode())
-		{
-			return 0.1d;
-		}
-		else
-		{
-			if (SanityManager.DEBUG)
-			{
-				if (! isNotNullNode())
-				{
-					SanityManager.THROWASSERT(
-						"Unexpected nodeType = " + getNodeType());
-				}
-			}
-			/* IS NOT NULL is like <>, so should have same selectivity */
+        if (notNull) {
+            /* IS NOT NULL is like <>, so should have same selectivity */
 			return 0.9d;
-		}
+        } else {
+            /** IS NULL is like =, so should have the same selectivity */
+            return 0.1d;
+        }
 	}
 
-	private boolean isNullNode()
+    boolean isNullNode()
 	{
-		return getNodeType() == C_NodeTypes.IS_NULL_NODE;
+        return !notNull;
 	}
 
-	private boolean isNotNullNode()
-	{
-		return getNodeType() == C_NodeTypes.IS_NOT_NULL_NODE;
-	}
-	
 	/** @see ValueNode#isRelationalOperator */
     @Override
     boolean isRelationalOperator()

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/JavaToSQLValueNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/JavaToSQLValueNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/JavaToSQLValueNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/JavaToSQLValueNode.java Thu Jul 25 07:12:46 2013
@@ -30,7 +30,6 @@ import org.apache.derby.iapi.services.co
 import org.apache.derby.iapi.services.compiler.MethodBuilder;
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.TypeCompiler;
 import org.apache.derby.iapi.sql.compile.Visitor;
 import org.apache.derby.iapi.types.DataTypeDescriptor;
@@ -55,7 +54,6 @@ class JavaToSQLValueNode extends ValueNo
     JavaToSQLValueNode(JavaValueNode value, ContextManager cm)
 	{
         super(cm);
-        setNodeType(C_NodeTypes.JAVA_TO_SQL_VALUE_NODE);
         this.javaNode = value;
 	}
 
@@ -356,9 +354,9 @@ class JavaToSQLValueNode extends ValueNo
 	/**
 	 * {@inheritDoc}
 	 */
-    protected boolean isEquivalent(ValueNode o)
+    boolean isEquivalent(ValueNode o)
     {
-    	// anything in the java domain is not equiavlent.
+        // anything in the java domain is not equivalent.
     	return false;
     }
 }

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/JoinNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/JoinNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/JoinNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/JoinNode.java Thu Jul 25 07:12:46 2013
@@ -31,7 +31,6 @@ import org.apache.derby.iapi.services.cl
 import org.apache.derby.iapi.services.compiler.MethodBuilder;
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.CompilerContext;
 import org.apache.derby.iapi.sql.compile.CostEstimate;
 import org.apache.derby.iapi.sql.compile.Optimizable;
@@ -111,7 +110,6 @@ class JoinNode extends TableOperatorNode
              ContextManager   cm) throws StandardException {
 
         super(leftResult, rightResult, tableProperties, cm);
-        setNodeType(C_NodeTypes.JOIN_NODE);
         this.resultColumns = selectList;
         this.joinClause = onClause;
         this.joinClauseNormalized = false;
@@ -879,11 +877,11 @@ class JoinNode extends TableOperatorNode
 
 				/* Create and insert the new = condition */
                 equalsNode = new BinaryRelationalOperatorNode(
-										C_NodeTypes.BINARY_EQUALS_OPERATOR_NODE,
-										leftCR,
-										rightCR,
-                                        false,
-                                        cm);
+                        BinaryRelationalOperatorNode.K_EQUALS,
+                        leftCR,
+                        rightCR,
+                        false,
+                        cm);
 				equalsNode.bindComparisonOperator();
 
                 // Create a new join clause by ANDing the new = condition and

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/LengthOperatorNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/LengthOperatorNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/LengthOperatorNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/LengthOperatorNode.java Thu Jul 25 07:12:46 2013
@@ -28,7 +28,6 @@ import org.apache.derby.iapi.reference.C
 import org.apache.derby.iapi.reference.SQLState;
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.types.DataTypeDescriptor;
 import org.apache.derby.iapi.types.TypeId;
 
@@ -45,33 +44,14 @@ public final class LengthOperatorNode ex
     LengthOperatorNode(ValueNode operator, ContextManager cm)
             throws StandardException {
         super(operator, cm);
-        setNodeType(C_NodeTypes.CHAR_LENGTH_OPERATOR_NODE);
-    }
 
-    @Override
-    void setNodeType(int nodeType)
-	{
-        String op = null;
-        String methodNam = null;
+        String op = "char_length";
+        String methodNam = "charLength";
+        parameterType = Types.VARCHAR;
+        parameterWidth = TypeId.VARCHAR_MAXWIDTH;
 
-		if (nodeType == C_NodeTypes.CHAR_LENGTH_OPERATOR_NODE)
-		{
-                op = "char_length";
-                methodNam = "charLength";
-				parameterType = Types.VARCHAR;
-				parameterWidth = TypeId.VARCHAR_MAXWIDTH;
-		}
-		else
-		{
-				if (SanityManager.DEBUG)
-				{
-					SanityManager.THROWASSERT(
-						"Unexpected nodeType = " + nodeType);
-				}
-		}
         setOperator(op);
         setMethodName(methodNam);
-		super.setNodeType(nodeType);
 	}
 
 	/**

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/LikeEscapeOperatorNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/LikeEscapeOperatorNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/LikeEscapeOperatorNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/LikeEscapeOperatorNode.java Thu Jul 25 07:12:46 2013
@@ -29,8 +29,6 @@ import org.apache.derby.iapi.reference.S
 import org.apache.derby.iapi.services.classfile.VMOpcode;
 import org.apache.derby.iapi.services.compiler.MethodBuilder;
 import org.apache.derby.iapi.services.context.ContextManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
-import org.apache.derby.iapi.sql.compile.TypeCompiler;
 import org.apache.derby.iapi.types.DataTypeDescriptor;
 import org.apache.derby.iapi.types.Like;
 import org.apache.derby.iapi.types.StringDataValue;
@@ -119,10 +117,8 @@ public final class LikeEscapeOperatorNod
         super(receiver,
               leftOperand,
               rightOperand,
-              TernaryOperatorNode.LIKE,
-              -1, // default trimType
+              TernaryOperatorNode.K_LIKE,
               cm);
-        setNodeType(C_NodeTypes.LIKE_ESCAPE_OPERATOR_NODE);
     }
 
     /**
@@ -135,6 +131,7 @@ public final class LikeEscapeOperatorNod
      *
      * @exception StandardException thrown on failure
      */
+    @Override
     ValueNode bindExpression(
     FromList fromList, SubqueryList subqueryList, List<AggregateNode> aggregates)
         throws StandardException
@@ -381,7 +378,7 @@ public final class LikeEscapeOperatorNod
                     //  column  'Derby'
                     BinaryComparisonOperatorNode equals = 
                         new BinaryRelationalOperatorNode(
-                            C_NodeTypes.BINARY_EQUALS_OPERATOR_NODE,
+                            BinaryRelationalOperatorNode.K_EQUALS,
                             leftClone, 
                             new CharConstantNode(newPattern,
                                                  getContextManager()),
@@ -496,7 +493,7 @@ public final class LikeEscapeOperatorNod
     * @exception StandardException  Thrown on error
     */
     @Override
-    public ValueNode preprocess(
+    ValueNode preprocess(
     int             numTables,
     FromList        outerFromList,
     SubqueryList    outerSubqueryList,
@@ -652,7 +649,7 @@ public final class LikeEscapeOperatorNod
 
             BinaryComparisonOperatorNode lessThan = 
                 new BinaryRelationalOperatorNode(
-                    C_NodeTypes.BINARY_LESS_THAN_OPERATOR_NODE,
+                    BinaryRelationalOperatorNode.K_LESS_THAN,
                     receiver.getClone(), 
                     likeLTopt,
                     false,
@@ -705,7 +702,7 @@ public final class LikeEscapeOperatorNod
         //  reciever pattern
         BinaryComparisonOperatorNode greaterEqual = 
             new BinaryRelationalOperatorNode(
-                C_NodeTypes.BINARY_GREATER_EQUALS_OPERATOR_NODE,
+                BinaryRelationalOperatorNode.K_GREATER_EQUALS,
                 receiver.getClone(), 
                 likeGEopt,
                 false,

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/LockTableNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/LockTableNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/LockTableNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/LockTableNode.java Thu Jul 25 07:12:46 2013
@@ -25,7 +25,6 @@ import org.apache.derby.iapi.error.Stand
 import org.apache.derby.iapi.reference.SQLState;
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.compile.CompilerContext;
 import org.apache.derby.iapi.sql.conn.Authorizer;
 import org.apache.derby.iapi.sql.dictionary.ConglomerateDescriptor;
@@ -58,7 +57,6 @@ class LockTableNode extends Miscellaneou
         super(cm);
         this.tableName = tableName;
         this.exclusiveMode = exclusiveMode;
-        setNodeType(C_NodeTypes.LOCK_TABLE_NODE);
     }
 
     /**

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/MaterializeResultSetNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/MaterializeResultSetNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/MaterializeResultSetNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/MaterializeResultSetNode.java Thu Jul 25 07:12:46 2013
@@ -28,7 +28,6 @@ import org.apache.derby.iapi.services.cl
 import org.apache.derby.iapi.services.compiler.MethodBuilder;
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 
 /**
  * A MaterializeResultSetNode represents a materialization result set for any 
@@ -52,7 +51,6 @@ class MaterializeResultSetNode extends S
                              Properties tableProperties,
                              ContextManager cm) {
         super(childResult, tableProperties, cm);
-        setNodeType(C_NodeTypes.MATERIALIZE_RESULT_SET_NODE);
         resultColumns = rcl;
 	}
 

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/MaterializeSubqueryNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/MaterializeSubqueryNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/MaterializeSubqueryNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/MaterializeSubqueryNode.java Thu Jul 25 07:12:46 2013
@@ -27,7 +27,6 @@ import org.apache.derby.iapi.services.cl
 import org.apache.derby.iapi.services.compiler.LocalField;
 import org.apache.derby.iapi.services.compiler.MethodBuilder;
 import org.apache.derby.iapi.services.context.ContextManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 
 
 /**
@@ -42,7 +41,6 @@ class MaterializeSubqueryNode extends Re
 
     MaterializeSubqueryNode(LocalField lf, ContextManager cm) {
         super(cm);
-        setNodeType(C_NodeTypes.MATERIALIZE_RESULT_SET_NODE);
 		this.lf = lf;
 	}
 

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/ModifyColumnNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/ModifyColumnNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/ModifyColumnNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/ModifyColumnNode.java Thu Jul 25 07:12:46 2013
@@ -27,7 +27,6 @@ import org.apache.derby.iapi.error.Stand
 import org.apache.derby.iapi.reference.SQLState;
 import org.apache.derby.iapi.services.context.ContextManager;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.dictionary.ColumnDescriptor;
 import org.apache.derby.iapi.sql.dictionary.ConstraintDescriptor;
 import org.apache.derby.iapi.sql.dictionary.ConstraintDescriptorList;
@@ -49,15 +48,30 @@ class ModifyColumnNode extends ColumnDef
 	int		columnPosition = -1;
 	UUID	oldDefaultUUID;
 
-    ModifyColumnNode(int type,
+    // Allowed kinds
+    final static int K_MODIFY_COLUMN_TYPE = 0;
+    final static int K_MODIFY_COLUMN_DEFAULT = 1;
+    final static int K_MODIFY_COLUMN_CONSTRAINT = 2;
+    final static int K_MODIFY_COLUMN_CONSTRAINT_NOT_NULL = 3;
+    final static int K_DROP_COLUMN = 4;
+
+    /**
+     * This class is used to hold logically different objects for
+     * space efficiency. {@code kind} represents the logical object
+     * type. See also {@link ValueNode#isSameNodeKind}.
+     */
+    final int kind;
+
+    ModifyColumnNode(int kind,
             String name,
             ValueNode defaultNode,
             DataTypeDescriptor dataTypeServices,
             long[] autoIncrementInfo,
             ContextManager cm) throws StandardException {
         super(name, defaultNode, dataTypeServices, autoIncrementInfo, cm);
-        setNodeType(type);
+        this.kind = kind;
     }
+
 	/**
 	 * Get the UUID of the old column default.
 	 *
@@ -96,8 +110,9 @@ class ModifyColumnNode extends ColumnDef
     void checkUserType(TableDescriptor td)
 		throws StandardException
 	{
-		if (getNodeType() != C_NodeTypes.MODIFY_COLUMN_TYPE_NODE)
-			return;				// nothing to do if user not changing length
+        if (kind != K_MODIFY_COLUMN_TYPE) {
+            return; // nothing to do if user not changing length
+        }
 
         ColumnDescriptor cd = td.getColumnDescriptor(name);
 		if (cd == null)
@@ -157,9 +172,9 @@ class ModifyColumnNode extends ColumnDef
     void checkExistingConstraints(TableDescriptor td)
 	             throws StandardException
 	{
-		if ((getNodeType() != C_NodeTypes.MODIFY_COLUMN_TYPE_NODE) &&
-			(getNodeType() != C_NodeTypes.MODIFY_COLUMN_CONSTRAINT_NODE) &&
-			(getNodeType() != C_NodeTypes.MODIFY_COLUMN_CONSTRAINT_NOT_NULL_NODE))
+        if ((kind != K_MODIFY_COLUMN_TYPE) &&
+            (kind != K_MODIFY_COLUMN_CONSTRAINT) &&
+            (kind != K_MODIFY_COLUMN_CONSTRAINT_NOT_NULL))
 			return;
 
 		DataDictionary           dd          = getDataDictionary();
@@ -185,7 +200,7 @@ class ModifyColumnNode extends ColumnDef
 			// and fkey columns.
 			if ((constraintType == DataDictionary.FOREIGNKEY_CONSTRAINT) 
 				&&
-				(getNodeType() == C_NodeTypes.MODIFY_COLUMN_TYPE_NODE))
+                (kind == K_MODIFY_COLUMN_TYPE))
 			{
 				throw StandardException.newException(
 					 SQLState.LANG_MODIFY_COLUMN_FKEY_CONSTRAINT, 
@@ -196,10 +211,9 @@ class ModifyColumnNode extends ColumnDef
 				if (!dd.checkVersion(
 					DataDictionary.DD_VERSION_DERBY_10_4, null)) 
 				{
-					//if a column is part of unique constraint it can't be
-					//made nullable in soft upgrade mode from a pre-10.4 db.
-					if ((getNodeType() == 
-						C_NodeTypes.MODIFY_COLUMN_CONSTRAINT_NODE) &&
+                    // If a column is part of unique constraint it can't be
+                    // made nullable in soft upgrade mode from a pre-10.4 db.
+                    if (kind == K_MODIFY_COLUMN_CONSTRAINT &&
 						(existingConstraint.getConstraintType() == 
 							DataDictionary.UNIQUE_CONSTRAINT)) 
 					{
@@ -209,10 +223,9 @@ class ModifyColumnNode extends ColumnDef
 					}
 				}
 
-				// a column that is part of a primary key
+                // A column that is part of a primary key
                 // is being made nullable; can't be done.
-				if ((getNodeType() == 
-					 C_NodeTypes.MODIFY_COLUMN_CONSTRAINT_NODE) &&
+                if ((kind == K_MODIFY_COLUMN_CONSTRAINT) &&
 					((existingConstraint.getConstraintType() == 
 					 DataDictionary.PRIMARYKEY_CONSTRAINT)))
 				{
@@ -270,6 +283,7 @@ class ModifyColumnNode extends ColumnDef
 			}
 		}
     }
+
 	/**
 	 * Get the action associated with this node.
 	 *
@@ -278,32 +292,37 @@ class ModifyColumnNode extends ColumnDef
     @Override
 	int getAction()
 	{
-		switch (getNodeType())
-		{
-		case C_NodeTypes.MODIFY_COLUMN_DEFAULT_NODE:
-			if (autoinc_create_or_modify_Start_Increment == ColumnDefinitionNode.MODIFY_AUTOINCREMENT_RESTART_VALUE)
-				return ColumnInfo.MODIFY_COLUMN_DEFAULT_RESTART;
-			else if (autoinc_create_or_modify_Start_Increment ==
-				ColumnDefinitionNode.MODIFY_AUTOINCREMENT_INC_VALUE)
-				return ColumnInfo.MODIFY_COLUMN_DEFAULT_INCREMENT;
-			else
-				return ColumnInfo.MODIFY_COLUMN_DEFAULT_VALUE;
-		case C_NodeTypes.MODIFY_COLUMN_TYPE_NODE:
-			return ColumnInfo.MODIFY_COLUMN_TYPE;
-		case C_NodeTypes.MODIFY_COLUMN_CONSTRAINT_NODE:
-			return ColumnInfo.MODIFY_COLUMN_CONSTRAINT;
-		case C_NodeTypes.MODIFY_COLUMN_CONSTRAINT_NOT_NULL_NODE:
-			return ColumnInfo.MODIFY_COLUMN_CONSTRAINT_NOT_NULL;
-		case C_NodeTypes.DROP_COLUMN_NODE:
-			return ColumnInfo.DROP;
-		default:
-			if (SanityManager.DEBUG)
-			{
-				SanityManager.THROWASSERT("Unexpected nodeType = " + 
-										  getNodeType());
-			}
-			return 0;
-		}
+        switch (kind) {
+            case K_MODIFY_COLUMN_DEFAULT:
+                if (autoinc_create_or_modify_Start_Increment ==
+                        ColumnDefinitionNode.MODIFY_AUTOINCREMENT_RESTART_VALUE) {
+                    return ColumnInfo.MODIFY_COLUMN_DEFAULT_RESTART;
+
+                } else if (autoinc_create_or_modify_Start_Increment ==
+                        ColumnDefinitionNode.MODIFY_AUTOINCREMENT_INC_VALUE) {
+                    return ColumnInfo.MODIFY_COLUMN_DEFAULT_INCREMENT;
+
+                } else {
+                    return ColumnInfo.MODIFY_COLUMN_DEFAULT_VALUE;
+                }
+            case K_MODIFY_COLUMN_TYPE:
+                return ColumnInfo.MODIFY_COLUMN_TYPE;
+
+            case K_MODIFY_COLUMN_CONSTRAINT:
+                return ColumnInfo.MODIFY_COLUMN_CONSTRAINT;
+
+            case K_MODIFY_COLUMN_CONSTRAINT_NOT_NULL:
+                return ColumnInfo.MODIFY_COLUMN_CONSTRAINT_NOT_NULL;
+
+            case K_DROP_COLUMN:
+                return ColumnInfo.DROP;
+
+            default:
+                if (SanityManager.DEBUG) {
+                    SanityManager.THROWASSERT("Unexpected type = " + kind);
+                }
+                return 0;
+        }
 	}
 
 	/**
@@ -337,8 +356,7 @@ class ModifyColumnNode extends ColumnDef
 		columnPosition = cd.getPosition();
 
 		// No other work to do if no user specified default
-		if (getNodeType() != C_NodeTypes.MODIFY_COLUMN_DEFAULT_NODE)
-		{
+        if (kind != K_MODIFY_COLUMN_DEFAULT) {
 			return;
 		}
 
@@ -401,7 +419,7 @@ class ModifyColumnNode extends ColumnDef
 		ColumnDescriptor cd;
 
 		// a column that has an autoincrement default can't be made nullable
-		if (getNodeType() == C_NodeTypes.MODIFY_COLUMN_CONSTRAINT_NODE)
+        if (kind == K_MODIFY_COLUMN_CONSTRAINT)
 		{
 			cd = getLocalColumnDescriptor(name, td);
 			if (cd.isAutoincrement())

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/NOPStatementNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/NOPStatementNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/NOPStatementNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/NOPStatementNode.java Thu Jul 25 07:12:46 2013
@@ -24,7 +24,6 @@ package	org.apache.derby.impl.sql.compil
 import org.apache.derby.iapi.error.StandardException;
 import org.apache.derby.iapi.reference.SQLState;
 import org.apache.derby.iapi.services.context.ContextManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 
 /**
  * A NOPStatement node is for statements that don't do anything.  At the
@@ -38,7 +37,6 @@ class NOPStatementNode extends Statement
 
     NOPStatementNode(ContextManager cm) {
         super(cm);
-        setNodeType(C_NodeTypes.NOP_STATEMENT_NODE);
     }
 
     String statementToString()

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/NewInvocationNode.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/NewInvocationNode.java?rev=1506827&r1=1506826&r2=1506827&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/NewInvocationNode.java (original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/sql/compile/NewInvocationNode.java Thu Jul 25 07:12:46 2013
@@ -33,7 +33,6 @@ import org.apache.derby.iapi.services.co
 import org.apache.derby.iapi.services.i18n.MessageService;
 import org.apache.derby.iapi.services.loader.ClassInspector;
 import org.apache.derby.iapi.services.sanity.SanityManager;
-import org.apache.derby.iapi.sql.compile.C_NodeTypes;
 import org.apache.derby.iapi.sql.dictionary.TableDescriptor;
 import org.apache.derby.iapi.util.JBitSet;
 
@@ -69,7 +68,6 @@ class NewInvocationNode extends MethodCa
 		throws StandardException
 	{
         super("<init>", cm);
-        setNodeType(C_NodeTypes.NEW_INVOCATION_NODE);
         addParms(params);
 
         this.javaClassName = javaClassName;
@@ -118,7 +116,6 @@ class NewInvocationNode extends MethodCa
 		throws StandardException
 	{
         super("<init>", cm);
-        setNodeType(C_NodeTypes.NEW_INVOCATION_NODE);
         addParms(params);
 
 		if (SanityManager.DEBUG)



Mime
View raw message