org.datanucleus.store.rdbms.sql
Class SQLJoin

java.lang.Object
  extended by org.datanucleus.store.rdbms.sql.SQLJoin

public class SQLJoin
extends java.lang.Object

Representation of a join in an SQL statement. The join is of a type (see ANSI SQL), and with inner/left outer/right outer is accompanied by join condition(s), joining from the source table to the target table via columns. Additionally other conditions can be applied to restrict the join (such as discriminator).


Nested Class Summary
static class SQLJoin.JoinType
           
 
Constructor Summary
SQLJoin(SQLJoin.JoinType type, SQLTable tbl, BooleanExpression condition)
          Constructor for a join.
 
Method Summary
 BooleanExpression getCondition()
          Accessor for the conditions of the join.
 SQLTable getTable()
           
 SQLJoin.JoinType getType()
           
 void setType(SQLJoin.JoinType type)
           
 java.lang.String toFromClause(RDBMSAdapter dba, boolean lock)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SQLJoin

public SQLJoin(SQLJoin.JoinType type,
               SQLTable tbl,
               BooleanExpression condition)
Constructor for a join.

Parameters:
type - Type of join (one of the defined types in this class).
tbl - Table to join to (required)
condition - Join condition
Method Detail

getType

public SQLJoin.JoinType getType()

setType

public void setType(SQLJoin.JoinType type)

getTable

public SQLTable getTable()

getCondition

public BooleanExpression getCondition()
Accessor for the conditions of the join. These conditions can include

Returns:
The conditions

toFromClause

public java.lang.String toFromClause(RDBMSAdapter dba,
                                     boolean lock)


Copyright © 2009. All Rights Reserved.