org.openrdf.sail.rdbms.algebra
Class UnionItem

java.lang.Object
  extended by org.openrdf.query.algebra.QueryModelNodeBase
      extended by org.openrdf.sail.rdbms.algebra.base.RdbmsQueryModelNodeBase
          extended by org.openrdf.sail.rdbms.algebra.base.FromItem
              extended by org.openrdf.sail.rdbms.algebra.UnionItem
All Implemented Interfaces:
Cloneable, QueryModelNode

public class UnionItem
extends FromItem

An SQL UNION expression between two FromItems.

Author:
James Leigh

Constructor Summary
UnionItem(String alias)
           
 
Method Summary
 void addUnion(FromItem from)
           
 List<ColumnVar> appendVars(List<ColumnVar> columns)
           
 UnionItem clone()
          Returns a (deep) clone of this query model node.
 FromItem getFromItem(String alias)
           
 List<ColumnVar> getSelectColumns()
           
 List<String> getSelectVarNames()
           
 List<FromItem> getUnion()
           
 ColumnVar getVar(String name)
           
 ColumnVar getVarForChildren(String name)
           
 void replaceChildNode(QueryModelNode current, QueryModelNode replacement)
          Default implementation of QueryModelNode.replaceChildNode(QueryModelNode, QueryModelNode) that throws an IllegalArgumentException indicating that current is not a child node of this node.
<X extends Exception>
void
visit(RdbmsQueryModelVisitorBase<X> visitor)
           
<X extends Exception>
void
visitChildren(QueryModelVisitor<X> visitor)
          Dummy implementation of QueryModelNode.visitChildren(org.openrdf.query.algebra.QueryModelVisitor) that does nothing.
 
Methods inherited from class org.openrdf.sail.rdbms.algebra.base.FromItem
addFilter, addJoin, addJoinBefore, getAlias, getFilters, getJoins, getSignature, isLeft, joinAdded, removeFilter, setLeft
 
Methods inherited from class org.openrdf.sail.rdbms.algebra.base.RdbmsQueryModelNodeBase
visit
 
Methods inherited from class org.openrdf.query.algebra.QueryModelNodeBase
getParentNode, replaceWith, setParentNode, toString
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

UnionItem

public UnionItem(String alias)
Method Detail

getFromItem

public FromItem getFromItem(String alias)
Overrides:
getFromItem in class FromItem

getSelectVarNames

public List<String> getSelectVarNames()

getSelectColumns

public List<ColumnVar> getSelectColumns()

appendVars

public List<ColumnVar> appendVars(List<ColumnVar> columns)
Overrides:
appendVars in class FromItem

getVar

public ColumnVar getVar(String name)
Overrides:
getVar in class FromItem

getVarForChildren

public ColumnVar getVarForChildren(String name)
Overrides:
getVarForChildren in class FromItem

addUnion

public void addUnion(FromItem from)

getUnion

public List<FromItem> getUnion()

clone

public UnionItem clone()
Description copied from interface: QueryModelNode
Returns a (deep) clone of this query model node. This method recursively clones the entire node tree, starting from this nodes.

Specified by:
clone in interface QueryModelNode
Overrides:
clone in class FromItem
Returns:
A deep clone of this query model node.

visit

public <X extends Exception> void visit(RdbmsQueryModelVisitorBase<X> visitor)
           throws X extends Exception
Specified by:
visit in class RdbmsQueryModelNodeBase
Throws:
X extends Exception

replaceChildNode

public void replaceChildNode(QueryModelNode current,
                             QueryModelNode replacement)
Description copied from class: QueryModelNodeBase
Default implementation of QueryModelNode.replaceChildNode(QueryModelNode, QueryModelNode) that throws an IllegalArgumentException indicating that current is not a child node of this node.

Specified by:
replaceChildNode in interface QueryModelNode
Overrides:
replaceChildNode in class FromItem
Parameters:
current - The current child node.
replacement - The new child node.

visitChildren

public <X extends Exception> void visitChildren(QueryModelVisitor<X> visitor)
                   throws X extends Exception
Description copied from class: QueryModelNodeBase
Dummy implementation of QueryModelNode.visitChildren(org.openrdf.query.algebra.QueryModelVisitor) that does nothing. Subclasses should override this method when they have child nodes.

Specified by:
visitChildren in interface QueryModelNode
Overrides:
visitChildren in class FromItem
Throws:
X extends Exception


Copyright © 2001-2008 Aduna. All Rights Reserved.