public class AnnotationJoin extends Object implements Join
Throws an UnsupportedOperationException
if
Query.getQueryType()
isn't QueryType.HQL
.
Annotations.innerJoin(AnnotationType, String)
,
Annotations.leftJoin(AnnotationType, String)
Modifier and Type | Field and Description |
---|---|
private String |
alias |
private AnnotationType |
annotationType |
private String |
joinedAlias |
private JoinType |
joinType |
Constructor and Description |
---|
AnnotationJoin(JoinType joinType,
String alias,
AnnotationType annotationType,
String joinedAlias) |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object other)
This join is equal to another AnnotationJoin if they
join to the same annotation type with the same alias.
|
Collection<? extends QueryElement> |
getChildren()
Get the children of this query element or null if it has no children.
|
String |
getThetaJoin(Query query,
DbControl dc) |
String |
getThetaJoinCondition(Query query,
DbControl dc) |
int |
hashCode() |
String |
toQl(Query query,
DbControl dc)
Create a query language string of the query element.
|
String |
toString() |
private final JoinType joinType
private final String alias
private final AnnotationType annotationType
private final String joinedAlias
AnnotationJoin(JoinType joinType, String alias, AnnotationType annotationType, String joinedAlias)
public String toQl(Query query, DbControl dc) throws BaseException
QueryElement
Query.getQueryType()
method to find out which query language is wanted
in case the element requires different syntax for different languages.toQl
in interface QueryElement
query
- The query that is about to be executeddc
- The DbControl
object used to execute the queryBaseException
- If there is any other errorpublic Collection<? extends QueryElement> getChildren()
QueryElement
AddExpression
has two children, the expression
beeing added.getChildren
in interface QueryElement
public String getThetaJoin(Query query, DbControl dc) throws BaseException
getThetaJoin
in interface Join
BaseException
public String getThetaJoinCondition(Query query, DbControl dc) throws BaseException
getThetaJoinCondition
in interface Join
BaseException
public boolean equals(Object other)