|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.eobjects.metamodel.util.BaseObject
org.eobjects.metamodel.query.FromItem
public class FromItem
Represents a FROM item. FROM items can take different forms:
FromClause,
Serialized Form| Constructor Summary | |
|---|---|
FromItem(JoinType join,
FromItem leftSide,
FromItem rightSide,
SelectItem[] leftOn,
SelectItem[] rightOn)
Constructor for advanced join types with custom relationships |
|
FromItem(JoinType join,
Relationship relationship)
Constructor for join FROM clauses that join two tables using their relationship. |
|
FromItem(Query subQuery)
Constructor for sub-query FROM clauses |
|
FromItem(String expression)
Creates a single unvalidated from item based on a expression. |
|
FromItem(Table table)
Constructor for table FROM clauses |
|
| Method Summary | |
|---|---|
protected FromItem |
clone()
|
protected void |
decorateIdentity(List<Object> identifiers)
Subclasses should implement this method and add all fields to the list that are to be included in equals(...) and hashCode() evaluation |
String |
getAlias()
|
String |
getAlias(Table table)
Gets the alias of a table, if it is registered (and visible, ie. not part of a sub-query) in the FromItem |
String |
getExpression()
|
JoinType |
getJoin()
|
SelectItem[] |
getLeftOn()
|
FromItem |
getLeftSide()
|
Query |
getQuery()
|
SelectItem[] |
getRightOn()
|
FromItem |
getRightSide()
|
String |
getSameQueryAlias()
|
Query |
getSubQuery()
|
Table |
getTable()
|
FromItem |
setAlias(String alias)
|
QueryItem |
setQuery(Query query)
|
String |
toSql()
|
String |
toSql(boolean includeSchemaInColumnPaths)
|
String |
toString()
|
String |
toStringNoAlias()
|
String |
toStringNoAlias(boolean includeSchemaInColumnPaths)
|
| Methods inherited from class org.eobjects.metamodel.util.BaseObject |
|---|
classEquals, equals, hashCode |
| Methods inherited from class java.lang.Object |
|---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public FromItem(Table table)
public FromItem(Query subQuery)
subQuery - the subquery to use
public FromItem(JoinType join,
Relationship relationship)
join - the join type to userelationship - the relationship to use for joining the tables
public FromItem(JoinType join,
FromItem leftSide,
FromItem rightSide,
SelectItem[] leftOn,
SelectItem[] rightOn)
join - the join type to useleftSide - the left side of the joinrightSide - the right side of the joinleftOn - what left-side select items to use for the ON clauserightOn - what right-side select items to use for the ON clausepublic FromItem(String expression)
expression - An expression to use for the from item, for example "MYTABLE".| Method Detail |
|---|
public String getAlias()
public String getSameQueryAlias()
public FromItem setAlias(String alias)
public Table getTable()
public Query getSubQuery()
public JoinType getJoin()
public FromItem getLeftSide()
public FromItem getRightSide()
public SelectItem[] getLeftOn()
public SelectItem[] getRightOn()
public String getExpression()
public String toSql()
toSql in interface QueryItempublic String toSql(boolean includeSchemaInColumnPaths)
toSql in interface QueryItempublic String toStringNoAlias()
public String toStringNoAlias(boolean includeSchemaInColumnPaths)
public String getAlias(Table table)
table - the table to get the alias for
public Query getQuery()
getQuery in interface QueryItempublic QueryItem setQuery(Query query)
setQuery in interface QueryItemprotected FromItem clone()
clone in class Objectprotected void decorateIdentity(List<Object> identifiers)
BaseObject
decorateIdentity in class BaseObjectpublic String toString()
toString in interface QueryItemtoString in class BaseObject
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||