com.triactive.jdo.store.sql.expr
Class TableExpression

java.lang.Object
  extended bycom.triactive.jdo.store.sql.expr.TableExpression
Direct Known Subclasses:
TableExprAsJoins, TableExprAsSubjoins, TableExprAsSubquery

public abstract class TableExpression
extends java.lang.Object

Represents a SQL table expression as might be listed in the FROM clause of a SELECT statement. A table expression is a fragment of a larger containing QueryStatement.

A table expression has a base "main" table. If that table serves as backing for a Java class, and that class has persistence-capable superclasses, then the table expression may include joins to superclass tables, or may cause such joins to occur in its surrounding QueryStatement.

Author:
Mike Martin
See Also:
QueryStatement

Field Summary
protected  CorrelationName mainRangeVar
           
protected  Table mainTable
           
protected  java.util.Set outerJoinedOn
           
protected  QueryStatement qs
           
protected  java.lang.String sqlText
           
 
Constructor Summary
protected TableExpression(QueryStatement qs, Table mainTable, CorrelationName mainRangeVar)
           
 
Method Summary
protected  void assertNotFrozen()
           
 QueryStatement.QueryColumn getColumn(Column col)
           
 QueryStatement.QueryColumn[] getColumns(Column[] cols)
           
 QueryStatement getQueryStatement()
           
 boolean isOuterJoined()
           
 CorrelationName mainRangeVariable()
           
 Table mainTable()
           
 java.util.Set outerJoinedOn()
           
abstract  java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

qs

protected final QueryStatement qs

mainTable

protected final Table mainTable

mainRangeVar

protected final CorrelationName mainRangeVar

sqlText

protected java.lang.String sqlText

outerJoinedOn

protected java.util.Set outerJoinedOn
Constructor Detail

TableExpression

protected TableExpression(QueryStatement qs,
                          Table mainTable,
                          CorrelationName mainRangeVar)
Method Detail

assertNotFrozen

protected void assertNotFrozen()

getQueryStatement

public final QueryStatement getQueryStatement()

mainTable

public final Table mainTable()

mainRangeVariable

public final CorrelationName mainRangeVariable()

getColumn

public QueryStatement.QueryColumn getColumn(Column col)

getColumns

public QueryStatement.QueryColumn[] getColumns(Column[] cols)

isOuterJoined

public boolean isOuterJoined()

outerJoinedOn

public java.util.Set outerJoinedOn()

toString

public abstract java.lang.String toString()


Copyright © 2001-2007 The TJDO Project All Rights Reserved.