Package org.datanucleus.store.rdbms.sql
Class SQLTableGroup
- java.lang.Object
-
- org.datanucleus.store.rdbms.sql.SQLTableGroup
-
public class SQLTableGroup extends java.lang.ObjectGroup of tables in an SQL statement. Tables are grouped to represent a particular object, so equates to an inheritance tree. In this way, if we have a class B which extends class A and they have tables B and A respectively then tables B and A will be in the same group when related to that object.
-
-
Field Summary
Fields Modifier and Type Field Description (package private) SQLJoin.JoinTypejoinTypeType of join to this group (from the candidate group presumably).(package private) java.lang.StringnameName of this group.(package private) java.util.Map<java.lang.String,SQLTable>tablesByAliasMap of tables in this group, keyed by their alias.
-
Constructor Summary
Constructors Constructor Description SQLTableGroup(java.lang.String name, SQLJoin.JoinType joinType)Constructor for a group with this name.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddTable(SQLTable tbl)SQLJoin.JoinTypegetJoinType()java.lang.StringgetName()intgetNumberOfTables()SQLTable[]getTables()java.lang.StringtoString()
-
-
-
Field Detail
-
name
java.lang.String name
Name of this group.
-
joinType
SQLJoin.JoinType joinType
Type of join to this group (from the candidate group presumably).
-
tablesByAlias
java.util.Map<java.lang.String,SQLTable> tablesByAlias
Map of tables in this group, keyed by their alias.
-
-
Constructor Detail
-
SQLTableGroup
SQLTableGroup(java.lang.String name, SQLJoin.JoinType joinType)Constructor for a group with this name.- Parameters:
name- Name of the group
-
-
Method Detail
-
getName
public java.lang.String getName()
-
getJoinType
public SQLJoin.JoinType getJoinType()
-
addTable
public void addTable(SQLTable tbl)
-
getNumberOfTables
public int getNumberOfTables()
-
getTables
public SQLTable[] getTables()
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-