Top Description Fields Constructors Methods
org.apache.derby.impl.sql.compile

pack-priv Class ReferencedTablesVisitor

extends Object
implements Visitor
Class Inheritance
All Implemented Interfaces
org.apache.derby.iapi.sql.compile.Visitor
Imports
org.apache.derby.shared.common.error.StandardException, org.apache.derby.iapi.sql.compile.Visitable, .Visitor, org.apache.derby.iapi.util.JBitSet

Build a JBitSet of all of the referenced tables in the tree.

Field Summary

Modifier and TypeField and Description
private JBitSet

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Modifier and TypeMethod and Description
pack-priv JBitSet
public boolean

Returns:

Whether or not to go below the node.
skipChildren
(Visitable
the node to process
node
)

Implements org.apache.derby.iapi.sql.compile.Visitor.skipChildren.

No need to go below a Predicate or ResultSet.

public boolean
stopTraversal()

Implements org.apache.derby.iapi.sql.compile.Visitor.stopTraversal.

Method that is called to see if query tree traversal should be stopped before visiting all nodes.

public Visitable

Returns:

me
visit
(Visitable
the node to process
node
)

Implements org.apache.derby.iapi.sql.compile.Visitor.visit.

Don't do anything unless we have a ColumnReference, Predicate or ResultSetNode node.

public boolean
visitChildrenFirst(Visitable
the top node of a sub-tree about to be visited
node
)

Implements org.apache.derby.iapi.sql.compile.Visitor.visitChildrenFirst.

Method that is called to see if visit() should be called on the children of node before it is called on node itself.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

tableMapback to summary
private JBitSet tableMap

Constructor Detail

ReferencedTablesVisitorback to summary
pack-priv ReferencedTablesVisitor(JBitSet tableMap)

Method Detail

getTableMapback to summary
pack-priv JBitSet getTableMap()
skipChildrenback to summary
public boolean skipChildren(Visitable node)

Implements org.apache.derby.iapi.sql.compile.Visitor.skipChildren.

No need to go below a Predicate or ResultSet.

Parameters
node:Visitable

Doc from org.apache.derby.iapi.sql.compile.Visitor.skipChildren.

the node to process

Returns:boolean

Whether or not to go below the node.

stopTraversalback to summary
public boolean stopTraversal()

Implements org.apache.derby.iapi.sql.compile.Visitor.stopTraversal.

Doc from org.apache.derby.iapi.sql.compile.Visitor.stopTraversal.

Method that is called to see if query tree traversal should be stopped before visiting all nodes. Useful for short circuiting traversal if we already know we are done.

Returns:boolean

true/false

visitback to summary
public Visitable visit(Visitable node) throws StandardException

Implements org.apache.derby.iapi.sql.compile.Visitor.visit.

Don't do anything unless we have a ColumnReference, Predicate or ResultSetNode node.

Parameters
node:Visitable

the node to process

Returns:Visitable

me

Exceptions
StandardException:
on error
visitChildrenFirstback to summary
public boolean visitChildrenFirst(Visitable node)

Implements org.apache.derby.iapi.sql.compile.Visitor.visitChildrenFirst.

Doc from org.apache.derby.iapi.sql.compile.Visitor.visitChildrenFirst.

Method that is called to see if visit() should be called on the children of node before it is called on node itself. If this method always returns true, the visitor will walk the tree bottom-up. If it always returns false, the tree is visited top-down.

Parameters
node:Visitable

the top node of a sub-tree about to be visited

Returns:boolean

true if node's children should be visited before node, false otherwise